lock cars on spawn.
#1

hi, i have created a command script for spawning cars(/veh), which is only for admins. but i dont know how to add lock on spawn system. like when i spawn a car, only admins can use it[which is locked for other players].

and it should only work with that command only.

someone please help me with this.
Thanks.
Reply
#2

Simple example
pawn Код:
//OnPlayerEnterVehicle
if(vehicleid == CAR_SPAWNED) // you need to save the id of the spawned car
{
    if(!IsPlayerAdmin(playerid))
    {
        new VBPos[3];
        GetPlayerPos(playerid,VBPos[0],VBPos[1],VBPos[2]);
        SetPlayerPos(playerid,VBPos[0],VBPos[1],VBPos[2]);
    }
}
Reply
#3

i want some kind of code like when normal player enter vehicle. they should get ejected with message. 'admin only vehicle'
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)