16.11.2012, 08:22
sscanf problems with me now
1- when i use /i (id) some times work some times crash the whole server and closes and console
2- when it work it send unkown command but the command is responding....
the code:
heeelp pls
1- when i use /i (id) some times work some times crash the whole server and closes and console
2- when it work it send unkown command but the command is responding....
the code:
pawn Код:
InfoFunction(playerid, params[])
{
new ID;
if(sscanf(params, "ius", ID)) SendClientMessage(playerid, BLANCO, "USAGE: /info(/i) [ID]");
else if(ID == INVALID_PLAYER_ID) SendClientMessage(playerid, ROJO, "Player is not connected!");
else
{
pawn Код:
TextDrawShowForPlayer(playerid,PlayerInfo2);
TextDrawShowForPlayer(playerid,PlayerLocationetc);
new carid = GetPlayerVehicleID(ID);
new zone[MAX_ZONE_NAME], string[100], name[50];
GetPlayer2DZone(playerid, zone, MAX_ZONE_NAME);
GetPlayerName(ID,name,MAX_PLAYER_NAME+1);
new Float:X, Float:Y, Float:Z;
GetPlayerPos(ID, X, Y, Z);
if(!IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 0 && SInfo[ID][pRegular] == 0)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(playerid, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~'LCTRL/LMB' ~w~For Hide The~n~~w~Player Info!",5000,3);
}
else if(IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 0 && SInfo[ID][pRegular] == 0)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LALT ~w~To Hide The~n~~w~Player Info!",5000,3);
}
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
if(!IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 0 && SInfo[ID][pRegular] == 1)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(playerid, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~'LCTRL/LMB' ~w~For Hide The~n~~w~Player Info!",5000,3);
}
else if(IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 0 && SInfo[ID][pRegular] == 1)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LALT ~w~To Hide The~n~~w~Player Info!",5000,3);
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
if(!IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 1 && SInfo[ID][pRegular] == 1)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(playerid, X, Y, Z), GetPlayerWantedLevel(ID));
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LMB ~w~For Hide The~n~~w~Player Info!",5000,3);
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LMB ~w~For Hide The~n~~w~Player Info!",5000,3);
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LMB ~w~For Hide The~n~~w~Player Info!",5000,3);
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LMB ~w~For Hide The~n~~w~Player Info!",5000,3);
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LMB ~w~For Hide The~n~~w~Player Info!",5000,3);
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~'LCTRL/LMB' ~w~For Hide The~n~~w~Player Info!",5000,3);
}
else if(IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 1 && SInfo[ID][pRegular] == 1)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Regular Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LALT ~w~To Hide The~n~~w~Player Info!",5000,3);
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
if(!IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 1 && SInfo[ID][pRegular] == 0)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(playerid, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~NONE ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~0 MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID));
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~'LCTRL/LMB' ~w~For Hide The~n~~w~Player Info!",5000,3);
}
else if(IsPlayerInAnyVehicle(ID) && SInfo[ID][pDonator] == 1 && SInfo[ID][pRegular] == 0)
{
if(civilianteam[ID]==1 || ciateam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Civilian ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(armyteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~w~%d ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Army ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(copteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Cop ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==1)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~Medic ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
else if(medicteam[ID]==0 && copteam[ID]==0 && armyteam[ID]==0 && ciateam[ID]==0 && civilianteam[ID]==0)
{
format(string, 256, "~n~ ~b~~h~%s (%d)~n~~n~~g~Location: ~w~%s ~n~~g~Distance: ~w~%d Feet ~n~~g~Wanted Level: ~w~%d ~n~~g~Vehicle: ~w~%s ~n~~g~Team: ~w~NONE ~n~~g~Speed: ~w~%d MPH ~n~~n~~b~Normal Player/Donator Player", name, ID, zone, GetPlayerDistanceFromPoint(ID, X, Y, Z), GetPlayerWantedLevel(ID),VehicleNames[GetVehicleModel(carid)-400], GetPlayerSpeed(ID));
TextDrawSetString(PlayerLocationetc,string);
}
GameTextForPlayer(playerid,"~n~ ~w~Press ~r~~h~LALT ~w~To Hide The~n~~w~Player Info!",5000,3);
}
}
return 1;
}
command(i, playerid, params[])
{
return InfoFunction(playerid, params);
}