Scripting/Squirrel/Functions/Vehicle.IsGhost: Difference between revisions

From Vice City Multiplayer
Jump to navigation Jump to search
Caution icon
This wiki is using an old backup from 2020
Some information may be old/missing
(Created page with " == Syntax == <pre.Vehicle.IsGhost = true;</pre> <pre>Vehicle.IsGhost = false;</pre>")
 
(Add description and sloppy examples.)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Get or Set the vehicle `IsGhost` boolean property.
Ghost cars don't collide with other vehicles or players but still interact with the world.


== Syntax ==
== Syntax ==
<pre.Vehicle.IsGhost = true;</pre>
<source lang=squirrel>Vehicle.IsGhost</source>
<pre>Vehicle.IsGhost = false;</pre>
 
== Arguments ==
* ''None''
 
== Example ==
1. Set vehicle to `ghost`
<source lang=squirrel>
Vehicle.IsGhost = true;
</source>
2. Unset vehicle `ghost` property
<source lang=squirrel>
Vehicle.IsGhost = false;
</source>
3. Probe to see whether or not a vehicle is a ghost
<source lang=squirrel>
local vehicleIsGhost = Vehicle.IsGhost;
</source>
 
== Related Functions ==
{{Scripting/Squirrel/Functions/Vehicle_Functions}}
[[Category:Scripting/Squirrel/Functions/Vehicle_Functions]]

Latest revision as of 10:39, 26 April 2019

Get or Set the vehicle `IsGhost` boolean property. Ghost cars don't collide with other vehicles or players but still interact with the world.

Syntax

Vehicle.IsGhost

Arguments

  • None

Example

1. Set vehicle to `ghost`

Vehicle.IsGhost = true;

2. Unset vehicle `ghost` property

Vehicle.IsGhost = false;

3. Probe to see whether or not a vehicle is a ghost

local vehicleIsGhost = Vehicle.IsGhost;

Related Functions