SA-MP Forums Archive
Vehicles number plate - Question - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Vehicles number plate - Question (/showthread.php?tid=249771)



Vehicles number plate - Question - AlexXx95 - 20.04.2011

I was wonderig if there is any way to set a default number plate for all vehicles on the server.
Some help please xD.


Re: Vehicles number plate - Question - Stigg - 20.04.2011

Here you go:

pawn Код:
public OnGameModeInit()
{
    new model;
    for(new i=1; i<MAX_VEHICLES; i++)
    {
        if(!IsAPlane(model) && !IsABoat(model)) SetVehicleNumberPlate(i, "Your plate");
    }
    return 1;
}

stock IsAPlane(model)
{
    switch(model)
    {
        case 593,592,577,563,553,548,520,519,513,512,511,
        497,488,487,476,469,460,447,425,417,493,484,453: return 1;
        default: return 0;
    }
    return 0;
}

stock IsABoat(model)
{
    switch(model)
    {
        case 472,473,595,493,430,453,484,446,452,454: return 1;
        default: return 0;
    }
    return 0;
}
Enjoy.


Re: Vehicles number plate - Question - AlexXx95 - 20.04.2011

tanxxxxxx dude


Re: Vehicles number plate - Question - Stigg - 20.04.2011

Quote:
Originally Posted by AlexXx95
Посмотреть сообщение
tanxxxxxx dude
No prob's m8'y, glad i could help.