View Single Post
Old 28/05/2020, 08:58 AM   #6
Little Clucker
Join Date: Apr 2020
Posts: 4
Reputation: 0
Default Re: trying to do IsPlayerOnVehicle

Originally Posted by Runn3R View Post
Alternatively, you can use the SAMap plugin to retrieve the Z position (if the player is on the ground) and do it like that?
But that has nothing to do with teleport ?

Originally Posted by xRadical3 View Post
Maybe this method will help, I have no other idea.

1) Check if the player is in the vehicle.
2) If he is in a vehicle, save the model and coordinates then destroy the vehicle.
3) Create the vehicle after the player is teleported.
4) Put the player in the vehicle as driver.
That way, players are standing on vehicle won't teleport with driver.
I think this method is not optimized, because it takes a little time to destroy, create and than put players.
Some servers have check like this function IsPlayerOnVehicle(..);
ChampDotChamp is offline   Reply With Quote