[UNSOLVED] make it arrayed
#1

Hello,

I'm using the folowing code to define factioncars:

pawn Код:
public IsACopCar(carid)
{
    if((carid >= 35) && (carid <= 60) || carid == 66 || carid == 67 || carid == 91 || carid == 92 || carid == 93 || carid == 36)
    {
      if((carid >= 121) && (carid <= 125) || carid == 45 || carid == 46 || carid == 55 || carid == 59) { return 0; }
        return 1;
    }
    return 0;
}
how to make an array of carids, so I don't need to retype them?
(I know it's probably very easy, but I didn't find it immidietly in the help, please help me)
thanks in advance, Jonasty
Reply
#2

You can use variables to keep track of create vehicles. Like copcar[31] = CreateVehicle(..) while under OnGameModeInit
Reply
#3

oww yeah, forgot that
but an easier way to check them then? because when using vars you'll have to enter all of them in it not?
(as you can't use the same variable name twice...)

off topic: you're hangman animation has a fault, he's hanging already, then you hang him
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)