Scripting/Squirrel/Functions/Vehicle.Health: Difference between revisions
Jump to navigation
Jump to search
This wiki is using an old backup from 2020
Some information may be old/missing
Line 7: | Line 7: | ||
<pre>if (cmd == "carhp") | <pre>if (cmd == "carhp") | ||
{ | { | ||
if ( !player.Vehicle ) MessagePlayer("You | if ( !player.Vehicle ) MessagePlayer("You must be in a vehicle to use this command.", player ); | ||
else { | else { | ||
local veh = player.Vehicle; | local veh = player.Vehicle; |
Latest revision as of 07:53, 26 April 2019
Syntax
Vehicle.Health();
Example
if (cmd == "carhp") { if ( !player.Vehicle ) MessagePlayer("You must be in a vehicle to use this command.", player ); else { local veh = player.Vehicle; MessagePlayer("Your car health is " + veh.Health + "", player); } }
Related Functions
- ResetAllVehicleHandling
- IsHandlingRuleSet
- SetHandlingRule
- GetHandlingRule
- ResetHandlingRule
- ResetVehicleHandling
- Vehicle.AddRelTurnSpeed
- Vehicle.AddSpeed
- Vehicle.AddTurnSpeed
- Vehicle.Alarm
- Vehicle.Angle
- Vehicle.Colour1
- Vehicle.Colour2
- Vehicle.Damage
- Vehicle.Delete
- Vehicle.Driver
- Vehicle.EulerAngle
- Vehicle.EulerSpawnAngle
- Vehicle.Fix
- Vehicle.GetHandlingData
- Vehicle.GetOccupant
- Vehicle.GetPart
- Vehicle.GetTyre
- Vehicle.Health
- Vehicle.ID
- Vehicle.Immunity
- Vehicle.IsGhost
- Vehicle.IsHandlingSet
- Vehicle.Kill
- Vehicle.Lights
- Vehicle.Locked
- Vehicle.Model
- Vehicle.Pos
- Vehicle.Radio
- Vehicle.RadioLocked
- Vehicle.RelativeSpeed
- Vehicle.RelativeTurnSpeed
- Vehicle.ResetAllHandling
- Vehicle.ResetHandlingData
- Vehicle.Respawn
- Vehicle.RespawnTimer
- Vehicle.Rotation
- Vehicle.SetFlatTyres
- Vehicle.SetHandlingData
- Vehicle.SetPart
- Vehicle.SetTyre
- Vehicle.Siren
- Vehicle.SpawnAngle
- Vehicle.SpawnPos
- Vehicle.Speed
- Vehicle.StreamedForPlayer
- Vehicle.SyncSource
- Vehicle.SyncType
- Vehicle.TurnSpeed
- Vehicle.TurretRotation
- Vehicle.World
- Vehicle.Wrecked