GetFreeVehicleSlot
#6

Quote:
Originally Posted by Pooh7
Посмотреть сообщение
Well, just put "return VSlot + 1;" at the end of the function. It'll return a value for 1 bigger than it normally would, which should fix the issue.
pawn Код:
stock GetFreeVehicleSlot()
{
    new VSlot;
    for(new v = 0; v < MAX_VEHICLES; v ++)
    {
        VSlot = v;
        if(VSlot != Vehicles[v][CarFileID])
        {
            return VSlot;
        }
    }
    return VSlot+1;
}

Nope keeps returning the same thing untill I restart the script.
Reply


Messages In This Thread
GetFreeVehicleSlot - by Stefand - 04.06.2013, 15:39
Re: GetFreeVehicleSlot - by nmader - 04.06.2013, 16:52
Re: GetFreeVehicleSlot - by Stefand - 04.06.2013, 16:57
Re: GetFreeVehicleSlot - by Pooh7 - 04.06.2013, 17:08
Re: GetFreeVehicleSlot - by Stefand - 04.06.2013, 17:09
Re: GetFreeVehicleSlot - by Stefand - 04.06.2013, 17:16
Re: GetFreeVehicleSlot - by nmader - 04.06.2013, 17:27
Re: GetFreeVehicleSlot - by Stefand - 04.06.2013, 17:44
Re: GetFreeVehicleSlot - by Stefand - 04.06.2013, 18:23
Re: GetFreeVehicleSlot - by Stefand - 04.06.2013, 18:34

Forum Jump:


Users browsing this thread: 1 Guest(s)