Police only...
#2

Why are you using a table (more space) if you got only 1 function in it?
Try
pawn Code:
new Cars[MAX_VEHICLES];
new Skins[MAX_PLAYERS];
new Job[MAX_PLAYERS];
Add someone in OnPlayerCommandText
pawn Code:
if(!strcmp(cmdtext, "/police", true))
{
  Job[playerid] = 1;
   return 1;
}

if(!strcmp(cmdtext, "/civilian", true))
{
  Job[playerid] = 0;
  return 1;
}
Remove the Cars[Police] =, and add also at your OnPlayerEnterVehicle

pawn Code:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  if(GetVehicleModel(vehicleid))
 {
    switch(GetVehicleModel))
   {
      case 596, 598, 597:
      {
        if(Job[playerid] != 1) return RemovePlayerFromVehicle(vehicleid); // kicks them when they'r not job 1 == police
        return 1;
      }    
    }
 }
 return 1;
}
Reply


Messages In This Thread
Police only... - by Luis- - 06.08.2010, 21:06
Re: Police only... - by KennethRandall - 06.08.2010, 21:14
Re: Police only... - by JaTochNietDan - 06.08.2010, 21:16
Re: Police only... - by Luis- - 06.08.2010, 21:35
Re: Police only... - by Kar - 06.08.2010, 21:47
Re: Police only... - by Jacks - 07.08.2010, 03:27

Forum Jump:


Users browsing this thread: 2 Guest(s)