27.11.2011, 16:53
Tried that. Its a FS btw.
(95) : error 017: undefined symbol "PlayerInfo"
(95) : warning 215: expression has no effect
(95) : error 001: expected token: ";", but found "]"
(95) : error 029: invalid expression, assumed zero
(95) : error 017: undefined symbol "PlayerInfo"
(95) : warning 215: expression has no effect
(95) : error 001: expected token: ";", but found "]"
(95) : error 029: invalid expression, assumed zero
PHP код:
CMD:operation(playerid, params[])
{
new id;
if(sscanf(params, "d", id)) return SendClientMessage(playerid, 0xffffffff, "[Usage]: /operation <playerid>");
if(PlayerInfo[playerid][pFaction] != 255 && DynamicFactions[PlayerInfo[playerid][pFaction]][fType] == 3 || PlayerInfo[playerid][pAdmin] >= 1) return SendClientMessage(playerid, 0xffffffff, "You're not medic!");
if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, 0xffffffff, "Invalid playerid!");
if(!Injured[id]) return SendClientMessage(playerid, 0xffffffff, "This person isn't injured!");
TogglePlayerControllable(id, 0);
TogglePlayerControllable(playerid, 0);
SendClientMessage(id, 0xffffffff, "A medic started to operate you!");
SendClientMessage(playerid, 0xffffffff, "You started an operation!");
SetTimerEx("OperationFinish", 180000, 0, "dd", playerid, id);
return 1;
}