Wieso ist bei meinem System die Wpvergabe auch außerhalb von Fahrzeugen und wenn man nicht an den definierten Orten steht möglich ?
ocmd:su(playerid,params[])
{
new pID,Wps,Grund[128];
if(sscanf(params,"uis",pID,Wps,Grund))return SendClientMessage(playerid,GRAU,"/su [ID] [WANTEDS] [Grund]");
if(GetPVarInt(playerid,"Fraktion")!=1)return SendClientMessage(playerid,GRAU,"Du bist kein Polizist");
if(GetVehicleModel(GetPlayerVehicleID(playerid))==523||490||596||599||427)
{
if(Wps>=1||Wps<=69)
{
if(GetPVarInt(pID,"Wanted")>Wps)
{
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
SpielerSpeichern(pID);
}
else if(Wps>=1&&Wps<10)
{
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=10&&Wps<20)
{
SetPlayerWantedLevel(pID,1);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=20&&Wps<30)
{
SetPlayerWantedLevel(pID,2);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=30&&Wps<40)
{
SetPlayerWantedLevel(pID,3);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=40&&Wps<50)
{
SetPlayerWantedLevel(pID,4);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=50&&Wps<60)
{
SetPlayerWantedLevel(pID,5);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=60&&Wps<70)
{
SetPlayerWantedLevel(pID,6);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
return 1;
}
else
{
SendClientMessage(playerid,GRAU,"WPS zwischen 1-69");
}
}
else
{
if(IsPlayerInRangeOfPoint(playerid,2,LSPDWpVergabeZellen)||IsPlayerInRangeOfPoint(playerid,2,LSPDWpVergabeSU))return SendClientMessage(playerid,GRAU,"Du in keinem Streifenwagen oder an der Su");
{
if(Wps>=1||Wps<=69)
{
if(GetPVarInt(pID,"Wanted")>Wps)
{
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
SpielerSpeichern(pID);
}
else if(Wps>=1&&Wps<10)
{
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=10&&Wps<20)
{
SetPlayerWantedLevel(pID,1);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=20&&Wps<30)
{
SetPlayerWantedLevel(pID,2);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=30&&Wps<40)
{
SetPlayerWantedLevel(pID,3);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=40&&Wps<50)
{
SetPlayerWantedLevel(pID,4);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=50&&Wps<60)
{
SetPlayerWantedLevel(pID,5);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
else if(Wps>=60&&Wps<70)
{
SetPlayerWantedLevel(pID,6);
SetPVarInt(pID,"Wanted",Wps);
SpielerSpeichern(pID);
new string[128];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"Du hast ein Verbrechen begangen: %s (Reporter: %s)",Grund,name);
SendClientMessage(pID,COLOR_RED,string);
}
return 1;
}
else
{
SendClientMessage(playerid,GRAU,"WPS zwischen 1-69");
}
}
}
return 1;
}