04.08.2015, 18:18
alguem me ajuda com esse comando pf
ele era em zcmd passei pra strcmp e nгo pega agora
Agora em Strcmp
ele era em zcmd passei pra strcmp e nгo pega agora
pawn Код:
CMD:startrace(playerid, params[])
{
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, RED, "<!> You are not an administrator!");
if(AutomaticRace == true) return SendClientMessage(playerid, RED, "<!> Not possible. Automatic race is enabled!");
if(BuildRace != 0) return SendClientMessage(playerid, RED, "<!> There's someone building a race!");
if(RaceBusy == 0x01 || RaceStarted == 1) return SendClientMessage(playerid, RED, "<!> There's a race currently. Wait first till race ends!");
if(isnull(params)) return SendClientMessage(playerid, RED, "<!> /startrace [racename]");
LoadRace(playerid, params);
return 1;
}
pawn Код:
if(strcmp(cmd, "/iniciarcorrida", true) == 0)
{
tmp = strtok(cmdtext, idx);
if(CallRemoteFunction("GetPlayerAdminLevel","i",playerid) < 1) return SendClientMessage(playerid,0x66CCFFAA,StringTable[8]);
if(BuildRace != 0) return SendClientMessage(playerid, RED, "Nгo й possнvel. Corrida automбtica estб ativada!");
if(RaceBusy == 0x01 || RaceStarted == 1) return SendClientMessage(playerid, RED, "Hб alguйm a construзгo de uma corrida!");
if(!strlen(tmp)) return SendClientMessage(playerid, -1, "Use /Iniciarcorrida [Nome-Da-Corrida]");
LoadRace(playerid, cmd);
return 1;
}