Vehicle Number Plates - Random OnVehicleSpawn
#5

Jizz. Nice bump haha. For some other reason I felt to restate what he said.

You have to respawn the vehicle, when calling it under OnVehicleSpawn().
pawn Код:
public OnVehicleSpawn(vehicleid)
{
    new string[32];
    if(vehicleid >= 1 && vehicleid <= 9)
    {
        new randnumb = 1 + random(9);
        format(string, sizeof(string),"NGRP %d%d%d",randnumb,randnumb,randnumb);
        SetVehicleNumberPlate(vehicleid, string);
        SetVehicleToRespawn(vehicleid);
    }
    return 1;
}
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)