<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Lxgiwyl</id>
	<title>Multi Theft Auto: Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Lxgiwyl"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/wiki/Special:Contributions/Lxgiwyl"/>
	<updated>2026-04-29T19:17:25Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsVehicleOnGround&amp;diff=20365</id>
		<title>IsVehicleOnGround</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsVehicleOnGround&amp;diff=20365"/>
		<updated>2009-07-05T16:02:17Z</updated>

		<summary type="html">&lt;p&gt;Lxgiwyl: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Server client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
Checks to see if a vehicle has contact with the ground.&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool isVehicleOnGround ( vehicle theVehicle )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theVehicle:''' The vehicle you wish to check.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if vehicle is on the ground, ''false'' if it is not.&lt;br /&gt;
&lt;br /&gt;
==Example== &lt;br /&gt;
&lt;br /&gt;
This example tells you when you've jumped out of a vehicle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;section name=&amp;quot;Server&amp;quot; class=&amp;quot;server&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function checkVState ( vehicle, seat, jacked )&lt;br /&gt;
	vehName = getVehicleName ( vehicle )&lt;br /&gt;
&lt;br /&gt;
	if isVehicleOnGround ( vehicle ) == false then&lt;br /&gt;
		outputChatBox ( &amp;quot;You jumped out of a &amp;quot;..vehName..&amp;quot;!&amp;quot;, source, 255, 0, 0  )&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
end&lt;br /&gt;
addEventHandler ( &amp;quot;onPlayerVehicleExit&amp;quot;, getRootElement(), checkVState )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Vehicle functions}}&lt;br /&gt;
[[Category:Needs_Example]]&lt;/div&gt;</summary>
		<author><name>Lxgiwyl</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsVehicleOnGround&amp;diff=20364</id>
		<title>IsVehicleOnGround</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsVehicleOnGround&amp;diff=20364"/>
		<updated>2009-07-05T16:01:09Z</updated>

		<summary type="html">&lt;p&gt;Lxgiwyl: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Server client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
Checks to see if a vehicle has contact with the ground.&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool isVehicleOnGround ( vehicle theVehicle )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theVehicle:''' The vehicle you wish to check.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if vehicle is on the ground, ''false'' if it is not.&lt;br /&gt;
&lt;br /&gt;
==Example== &lt;br /&gt;
&lt;br /&gt;
This example tells you when you've jumped out of a vehicle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function checkVState ( vehicle, seat, jacked )&lt;br /&gt;
	vehName = getVehicleName ( vehicle )&lt;br /&gt;
&lt;br /&gt;
	if isVehicleOnGround ( vehicle ) == false then&lt;br /&gt;
		outputChatBox ( &amp;quot;You jumped out of a &amp;quot;..vehName..&amp;quot;!&amp;quot;, source, 255, 0, 0  )&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
end&lt;br /&gt;
addEventHandler ( &amp;quot;onPlayerVehicleExit&amp;quot;, getRootElement(), checkVState )&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Vehicle functions}}&lt;br /&gt;
[[Category:Needs_Example]]&lt;/div&gt;</summary>
		<author><name>Lxgiwyl</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetElementAlpha&amp;diff=20362</id>
		<title>SetElementAlpha</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetElementAlpha&amp;diff=20362"/>
		<updated>2009-07-05T15:12:10Z</updated>

		<summary type="html">&lt;p&gt;Lxgiwyl: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Server client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function sets the alpha(transparency) value for the specified [[element]]. This can be a [[player]] or a [[vehicle]].&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool setElementAlpha ( element theElement, int alpha )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' The [[element]] whose alpha you want to set.&lt;br /&gt;
*'''alpha:'''  The alpha value to set. Value can be 0-255, where 255 is fully opaque and 0 is fully transparent.&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''false'' if invalid arguments were passed.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Clientside example&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This example makes the player invisible.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function invisible()&lt;br /&gt;
        setElementAlpha(getLocalPlayer(), 0)&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;invisible&amp;quot;, invisible )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;section name=&amp;quot;Serverside example&amp;quot; class=&amp;quot;server&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This example lets you toggle invisibility when you write /invis.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;qb = 0	-- set a variable 'qb' saying you're not invisible.&lt;br /&gt;
&lt;br /&gt;
function toggleInvis ( source )	-- source is whoever executed the command&lt;br /&gt;
	if qb == 0 then		-- if the source player is NOT invisible&lt;br /&gt;
		qb  = 1		-- set qb to say the source player is invisible&lt;br /&gt;
		setElementAlpha ( source, 0 )	-- set the players alpha to 0 (make them invisible)&lt;br /&gt;
	else			-- else, if the source player IS visible&lt;br /&gt;
		qb = 0		-- set qb to say the source player is visible.&lt;br /&gt;
		setElementAlpha ( source, 255 )	-- set the players alpha to 255 (make them 100% visible)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;invis&amp;quot;, toggleInvis )	-- When /invis is typed, the function 'toggleInvis' will start.&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Element functions}}&lt;/div&gt;</summary>
		<author><name>Lxgiwyl</name></author>
	</entry>
</feed>