04.11.2012, 03:55
Quote:
First ones the error, second ones the scripting. I've written it out the exact same way as the other cmds are, and the script gives no problem. But with THIS command, the script decides to throw a bitch fit and not compile. What am i doing wrong D:
F:\Jay Vortex 2 Script (FCRP)\gamemodes\vx-rp.pwn(9246) : error 001: expected token: ")", but found "return" Код:
CMD:mwalk(playerid, params[]) { if(GetPlayerState(playerid != 1) return SendClientMessage(playerid, COLOR_GREY, "You can only use this animation while on foot."); if(playerVariables[playerid][pFreezeTime] !=0) return SendClientMessage(playerid, COLOR_GREY, "You can't use animations while cuffed, tazed, or frozen."); if(playerVariables[playerid][pEvent] == 1) return SendClientMessage(playerid, COLOR_GREY, "You can't use animations while in an event."); ApplyAnimation(playerid,"PED","WALK_player",4.1,1,1,1,1,1); return 1; } |
pawn Код:
CMD:mwalk(playerid, params[]) {
if(GetPlayerState(playerid != 1) return SendClientMessage(playerid, COLOR_GREY, "You can only use this animation while on foot.");
if(playerVariables[playerid][pFreezeTime] !=0) return SendClientMessage(playerid, COLOR_GREY, "You can't use animations while cuffed, tazed, or frozen.");
if(playerVariables[playerid][pEvent] == 1) return SendClientMessage(playerid, COLOR_GREY, "You can't use animations while in an event.");
ApplyAnimation(playerid,"PED","WALK_player",4.1,1,1,1,1,1,1);
return 1;
}