CityWide Problem
#1

I added some new cars in my script(LSPD,SFPD and LVPD Cars) . But I want to make it that ONLY the cops to drive them, so I must modify the kind of the car(Like the IsATaxiCar, IsAnAmbulance etc.). The problem is: HOW can I?!
pawn Код:
public IsACopCar(carid)
{
    if (CarInfo[carid][cType]==CARTYPE_COP) return 1;
    return 0;
}
How can I make the Car Type of the cars to Cop Car Types?!
Sorry for my bad English.
Reply
#2

try this one
pawn Код:
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  if(IsACopCar(vehicleid))
  {
    if(!IsACop(playerid))
    {    
      new Float:PAX, Float:PAY, Float:PAY;
      GetPlayerPos(playerid, PAX, PAY, PAZ);
      SetPlayerPos(playerid, PAX, PAY, PAZ);
      SendClientMessage(playerid, COLOR_LIGHTRED, "You are not allowed to enter this vehicle(cops only)");
      return 1;    
    }
    return 1;
  }
}
Reply
#3

OMG...I don't want to restrict...I want to make a car into a COP CAR One!
Reply
#4

Anybody? OMG! I am desperate
Reply
#5

Quote:
Originally Posted by Ov3r
But I want to make it that ONLY the cops to drive them
That's what James' script does foo'

It checks if it's a police car, and checks if the player entering isn't a cop. If they're not a cop, it effectively ejects them.
Reply
#6

Another one... I want to make a simple car to a cop car...So that script is useless if I don't even have a cop car...
Reply
#7

Quote:
Originally Posted by Ov3r
Another one... I want to make a simple car to a cop car...So that script is useless if I don't even have a cop car...
You sir, are an idiot (like WeeDar sais)
We are trying to help you, and you response like ''this is not good, i want another script''
Reply
#8

The script is only useless because you don't have a ****ing clue what you are asking for...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)