SA-MP Forums Archive
Passenger Seat - 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)
+--- Thread: Passenger Seat (/showthread.php?tid=441361)



Passenger Seat - AchievementMaster360 - 02.06.2013

I made this system that you can enter a custom interior of a truck i wonder how can i make it so when you are a passenger in passenger seat 2 or 3 you teleport instead of being in passenger seat number this is what i use
PLAYER_STATE_PASSENGER how would i change it to passenger seat 2 or 3?


Re: Passenger Seat - Chenko - 02.06.2013

You can use GetPlayerVehicleSeat to get the seat number.

https://sampwiki.blast.hk/wiki/GetPlayerVehicleSeat


Re: Passenger Seat - RenSoprano - 02.06.2013

pawn Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
        if (ispassenger != 0)
        {
              // Your Code here
        }
        return 1;
}

You can do something like this example.


Re: Passenger Seat - AchievementMaster360 - 02.06.2013

Quote:
Originally Posted by RenSoprano
Посмотреть сообщение
pawn Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
        if (ispassenger != 0)
        {
              // Your Code here
        }
        return 1;
}

You can do something like this example.
Wait if (ispassenger != 2) is set to 2 will it only work to the second passenger


Re: Passenger Seat - RenSoprano - 02.06.2013

Код:
!= 0
That mean different from Driver used it. This check only passangers