still wont work
#1

hi im trying to get a car anti jack to work in my server as i have having a problem with people stealing peoples cars this is what i got it for some reason it dont work i want it so it kills the driver not the passenger for getting in to




public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
for(new i = 0; i < GetMaxPlayers(); i++)
{
if(IsPlayerInVehicle(i, vehicleid) && GetPlayerState(i) == PLAYER_STATE_DRIVER && GetPlayerState(playerid) == 5)
{
SetPlayerHealth(playerid, 0);
new pName[MAX_PLAYER_NAME],string[128];
GetPlayerName(playerid, pName, sizeof(pName));
format(string, sizeof(string), "[Anti-Jack]: %s has just been killed for car jacking (n00b!).", pName);
SendClientMessageToAll(red, string);
SendClientMessage(playerid,red,"Error: Car jacking is not allowed!.");
}
}
return 1;
}
Reply


Messages In This Thread
still wont work - by [SF]RobMob - 09.02.2010, 11:26
Re: still wont work - by Joe Staff - 09.02.2010, 11:44
Re: still wont work - by matthewdriftking - 05.04.2010, 08:39

Forum Jump:


Users browsing this thread: 1 Guest(s)