GetPlayerOccupiedVehicle
Jump to navigation
Jump to search
Description
This function returns a vehicle that the player is currently in, if any. This function returns false if the player is on foot, or the player doesn't exist.
Syntax
vehicle getPlayerOccupiedVehicle ( player player )
Required Arguments
- player: The player whose vehicle you're looking up.
Example
if ( vehicle = getPlayerOccupiedVehicle ( findPlayer ( "Someguy" ) ) ) OutputChatBox ( "Someguy is in a vehicle with ", getVehicleHealth ( vehicle ), " health." ) else Outputchatbox ( "Someguy is not in a vehicle." ) end
See Also
- getPlayerTeam
- getPlayerBlurLevel
- setPlayerBlurLevel
- getPlayerSerial
- forcePlayerMap
- getPlayerScriptDebugLevel
- getPlayerFromName
- getPlayerMoney
- getPlayerName
- getPlayerNametagColor
- getPlayerNametagText
- getPlayerPing
- getPlayerWantedLevel
- givePlayerMoney
- isPlayerMapForced
- isPlayerNametagShowing
- setPlayerHudComponentVisible
- setPlayerMoney
- setPlayerNametagColor
- setPlayerNametagShowing
- setPlayerNametagText
- takePlayerMoney
- countPlayersInTeam
- getPlayersInTeam
- isVoiceEnabled
- setControlState
- getControlState