24.05.2015, 06:59
i created these commands:
So when IG i do /flares it crashes samp-server.exe
Код:
if(strcmp(cmd, "/flares", true) == 0)
{
if(PlayerInfo[playerid][pMember] != 1 || PlayerInfo[playerid][pAdmin] <= 0) return SendClientMessage(playerid, COLOR_GREY, "*You are not authorized to use that command!");
else {
new Float:angle, Float:x, Float:y, Float:z;
GetPlayerPos(x, y, z);
GetPlayerFacingAngle(playerid, angle);
CreateFlare(x, y, z-2.2, angle);
}
return 1;
}
if(strcmp(cmd, "/dflaresall", true) == 0)
{
if(PlayerInfo[playerid][pMember] != 1 || PlayerInfo[playerid][pMember] != 2 || PlayerInfo[playerid][pMember]!=3 || PlayerInfo[playerid][pAdmin] <=0) return SendClientMessage(playerid, COLOR_GREY, "*You are not authorized to use that command!");
DeleteAllFlare();
return 1;
}
if(strcmp(cmd, "/dflares", true) == 0)
{
if(PlayerInfo[playerid][pMember] != 1 || PlayerInfo[playerid][pMember] != 2 || PlayerInfo[playerid][pMember]!=3 || PlayerInfo[playerid][pAdmin] <=0) return SendClientMessage(playerid, COLOR_GREY, "*You are not authorized to use that command!");
DeleteClosestFlare(playerid);
return 1;
}


