Spawn in Derby Vehicle problem (2 in 1 car)
#1

Sometimes, if the derby has 3 or more players, the "spawn in car" thing gets bugged.
Like, 2 players get spawned in 1 car.

Here's the code:
pawn Код:
//This is @ OnPlayerSpawn, and if the derby has NOT started.
for(new x; x < 15; x++)
                    {
                        if(IsVehicleOccupied(DerbyVehicle[x])) continue;
                        else PutPlayerInVehicle(playerid, DerbyVehicle[x], 0);
                        break;
                    }
pawn Код:
//This is @ my 'ResetDerby' stock.
foreach(Player, i)
    {
        if(SpawnMode[ i ] != SPAWNMODE_DERBY) continue;
        PlayerInfo[ i ][ InDerbyArea ] = 1;
        TogglePlayerControllable(i, false);
        for(new x; x < 15; x++)
        {
            if(IsVehicleOccupied(DerbyVehicle[x])) continue;
            else PutPlayerInVehicle(i, DerbyVehicle[x], 0);
            break;
        }
    }
Reply


Messages In This Thread
Spawn in Derby Vehicle problem (2 in 1 car) - by Kyance - 25.01.2015, 10:15
Re: Spawn in Derby Vehicle problem (2 in 1 car) - by BroZeus - 25.01.2015, 10:46
Re: Spawn in Derby Vehicle problem (2 in 1 car) - by Kyance - 25.01.2015, 11:10

Forum Jump:


Users browsing this thread: 1 Guest(s)