Squirrel/Server/Functions/Vehicles/Fix

From Liberty Unleashed Wiki
(Difference between revisions)
Jump to: navigation, search
m (Forgot title)
 
Line 1: Line 1:
__NOTOC__
+
{{Squirrel/Title|Vehicle.Fix}}
 
This ''Vehicle'' class method function fixes the visible and engine damage of the given vehicle.
 
This ''Vehicle'' class method function fixes the visible and engine damage of the given vehicle.
  

Latest revision as of 02:14, 29 September 2010

Home   |   Squirrel Scripting   |   Server Functions   |   Server Events   |   Client Functions   |   Client Events

This Vehicle class method function fixes the visible and engine damage of the given vehicle.

[edit] Syntax

  1. bool Vehicle.Fix()

[edit] Arguments

  • none

[edit] Example

If the player is in a vehicle, this command will fix it for them.

  1.  
  2. function onPlayerCommand( player, cmd, text )
  3. {
  4. if ( cmd == "fix" )
  5. {
  6. if ( player.Vehicle ) player.Vehicle.Fix();
  7. }
  8. return 1;
  9. }
  10.  

[edit] Notes

The function Player.Vehicle and call onPlayerCommand were used in in this example. More info about them in the corresponding pages.

[edit] Related Functions

Personal tools
Namespaces

Variants
Actions
Navigation
scripting
Toolbox