22.12.2010, 09:57
Its a Bug with onplayerupdate.
onplayerupdate ignor this if a player is into a vehicle.
I add another timer and then all works fine.
First pic I'm sitting in the car and nothing...
I get out the car and... oO works...
onplayerupdate ignor this if a player is into a vehicle.
I add another timer and then all works fine.
Код:
if(WantedLevel[playerid]>=2 && PlayerCuffed[playerid]==0 && PlayerTied[playerid]==0 && PlayerInfo[playerid][pCrimInRangeWanted]==0)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(IsPlayerNPC(i) && PlayerInfo[i][pMember]==1 && CrimInRange(30.0, playerid,i))
{
WantedPoints[playerid]+=2;
SetPlayerCriminal(playerid,255, "Suspect is near a NPC Cop in Los Santos");
PlayerPlaySound(playerid, 1058, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pCrimInRangeWanted] = 1;
SetTimerEx("CrimInRangeWanted", 284850, 0, "i", playerid);
return 1;
}
if(IsPlayerNPC(i) && PlayerInfo[i][pMember]==15 && CrimInRange(30.0, playerid,i))
{
WantedPoints[playerid]+=2;
SetPlayerCriminal(playerid,255, "Suspect is near a NPC Cop in San Fierro");
PlayerPlaySound(playerid, 1058, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pCrimInRangeWanted] = 1;
SetTimerEx("CrimInRangeWanted", 284850, 0, "i", playerid);
return 1;
}
if(IsPlayerNPC(i) && PlayerInfo[i][pMember]==23 && CrimInRange(30.0, playerid,i))
{
WantedPoints[playerid]+=2;
SetPlayerCriminal(playerid,255, "Suspect is near a NPC Cop in Las Venturas");
PlayerPlaySound(playerid, 1058, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pCrimInRangeWanted] = 1;
SetTimerEx("CrimInRangeWanted", 284850, 0, "i", playerid);
return 1;
}
}
}
}
I get out the car and... oO works...

