<?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=MaK%24iM</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=MaK%24iM"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/wiki/Special:Contributions/MaK$iM"/>
	<updated>2026-04-05T14:33:45Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetValidPedModels&amp;diff=53935</id>
		<title>GetValidPedModels</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetValidPedModels&amp;diff=53935"/>
		<updated>2018-02-13T11:48:24Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Server client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function returns all valid ped models.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
table getValidPedModels ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a [[table]] with all valid ped models.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example will get if the specified skin is a valid skin or not.&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 isValidSkin( thePlayer, command, specifiedSkin )  -- Define the function&lt;br /&gt;
    if ( specifiedSkin ) then -- If skin specified&lt;br /&gt;
        local allSkins = getValidPedModels ( ) -- Get valid skin IDs&lt;br /&gt;
        local result = false -- Define result, it is currently false&lt;br /&gt;
        for key, skin in ipairs( allSkins ) do -- Check all skins&lt;br /&gt;
            if skin == tonumber( specifiedSkin ) then -- If skin equals specified one, it is valid&lt;br /&gt;
                result = skin -- So set it as result&lt;br /&gt;
                break --stop looping through a table after we found the skin&lt;br /&gt;
            end&lt;br /&gt;
        end&lt;br /&gt;
        if ( result ) then -- If we got results&lt;br /&gt;
            outputChatBox( result .. &amp;quot; is a valid skin ID.&amp;quot;, thePlayer, 0, 255, 0 ) -- It is valid, output it&lt;br /&gt;
        else -- If we didn't get results&lt;br /&gt;
            outputChatBox( specifiedSkin .. &amp;quot; is not a valid skin ID.&amp;quot;, thePlayer, 0, 255, 0 ) -- No result, it is not valid&lt;br /&gt;
        end&lt;br /&gt;
    else -- If no skin specified&lt;br /&gt;
        outputChatBox( &amp;quot;Please specify a skin ID to check!&amp;quot;, thePlayer, 255, 0, 0 ) -- Tell it to the player&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;checkskin&amp;quot;,isValidSkin) -- bind 'checkskin' command to 'isValidSkin' function&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;
{{Ped functions}}&lt;br /&gt;
&lt;br /&gt;
[[pl:GetValidPedModels]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetPedCameraRotation&amp;diff=53934</id>
		<title>GetPedCameraRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetPedCameraRotation&amp;diff=53934"/>
		<updated>2018-02-13T10:48:52Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{client function}}&lt;br /&gt;
{{Note|The camera rotation angle returned by this function is 360º - α (where α is the actual camera rotation angle). See example to know how to deal with this.}}&lt;br /&gt;
This function gets the current camera rotation of a [[ped]].&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float getPedCameraRotation( ped thePed )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{OOP||[[ped]]:getCameraRotation|cameraRotation|setPedCameraRotation}}&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''thePed:''' the [[ped]] to retrieve the camera rotation of.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the camera rotation of the [[ped]] in degrees if successful. Returns ''false'' if an invalid element was passed.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example creates a '''/getrotation''' command which outputs the expected camera rotation of the player which types it.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler( &amp;quot;getrotation&amp;quot;, &lt;br /&gt;
    function ()&lt;br /&gt;
        local rot = 360 - getPedCameraRotation(localPlayer) -- Also fix the camera rotation&lt;br /&gt;
        outputChatBox(&amp;quot;Your camera rotation is &amp;quot; .. rot .. &amp;quot;º&amp;quot;, 0, 225, 0)&lt;br /&gt;
    end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client ped functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehiclesLODDistance&amp;diff=51690</id>
		<title>SetVehiclesLODDistance</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehiclesLODDistance&amp;diff=51690"/>
		<updated>2017-07-17T12:19:40Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}__NOTOC__&lt;br /&gt;
{{New feature/item|3.0154|1.5.3|11199|&lt;br /&gt;
Sets the distance of vehicles LOD.&lt;br /&gt;
}}&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 setVehiclesLODDistance ( float vehiclesDistance, float trainsAndPlanesDistance = vehiclesDistance * 2.14 )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''vehiclesDistance:''' general distance used for most vehicles, this value is clamped to 0 – 500&lt;br /&gt;
===Optional Arguments===&lt;br /&gt;
*'''trainsAndPlanesDistance:''' distance used for trains and planes, this value is clamped to 0 – 500&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientResourceStart&amp;quot;,resourceRoot,function()&lt;br /&gt;
	setVehiclesLODDistance(10)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
* [[engineGetModelLODDistance]]&lt;br /&gt;
* [[engineSetModelLODDistance]]&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehiclesLODDistance&amp;diff=51689</id>
		<title>SetVehiclesLODDistance</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehiclesLODDistance&amp;diff=51689"/>
		<updated>2017-07-17T12:16:17Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: Example&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}{{Needs Example}}__NOTOC__&lt;br /&gt;
{{New feature/item|3.0154|1.5.3|11199|&lt;br /&gt;
Sets the distance of vehicles LOD.&lt;br /&gt;
}}&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 setVehiclesLODDistance ( float vehiclesDistance, float trainsAndPlanesDistance = vehiclesDistance * 2.14 )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''vehiclesDistance:''' general distance used for most vehicles, this value is clamped to 0 – 500&lt;br /&gt;
===Optional Arguments===&lt;br /&gt;
*'''trainsAndPlanesDistance:''' distance used for trains and planes, this value is clamped to 0 – 500&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientResourceStart&amp;quot;,resourceRoot,function()&lt;br /&gt;
	setVehiclesLODDistance(10)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
* [[engineGetModelLODDistance]]&lt;br /&gt;
* [[engineSetModelLODDistance]]&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51674</id>
		<title>GetVehiclesLODDistance</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51674"/>
		<updated>2017-07-16T11:48:53Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}__NOTOC__&lt;br /&gt;
{{New feature/item|3.0154|1.5.3|11199|&lt;br /&gt;
Returns the distance of vehicles LOD.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float getVehiclesLODDistance ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Returns ==&lt;br /&gt;
* '''float:''' general distance used for most vehicles&lt;br /&gt;
* '''float:''' distance used for trains and planes&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example shows the lod distance of vehicles&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientResourceStart&amp;quot;,resourceRoot,function()&lt;br /&gt;
	local vehicles,planes_trains = getVehiclesLODDistance()&lt;br /&gt;
	outputChatBox(&amp;quot;general distance of most vehicles: &amp;quot;..math.floor(vehicles),0,255,0)&lt;br /&gt;
	outputChatBox(&amp;quot;distance of planes and trains: &amp;quot;..math.floor(planes_trains),0,255,0)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
* [[engineGetModelLODDistance]]&lt;br /&gt;
* [[engineSetModelLODDistance]]&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51673</id>
		<title>GetVehiclesLODDistance</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51673"/>
		<updated>2017-07-16T11:47:54Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}{{Needs Example}}__NOTOC__&lt;br /&gt;
{{New feature/item|3.0154|1.5.3|11199|&lt;br /&gt;
Returns the distance of vehicles LOD.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float getVehiclesLODDistance ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Returns ==&lt;br /&gt;
* '''float:''' general distance used for most vehicles&lt;br /&gt;
* '''float:''' distance used for trains and planes&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example shows the lod distance of vehicles&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientResourceStart&amp;quot;,resourceRoot,function()&lt;br /&gt;
	local vehicles,planes_trains = getVehiclesLODDistance()&lt;br /&gt;
	outputChatBox(&amp;quot;general distance of most vehicles: &amp;quot;..math.floor(vehicles),0,255,0)&lt;br /&gt;
	outputChatBox(&amp;quot;distance of planes and trains: &amp;quot;..math.floor(planes_trains),0,255,0)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
* [[engineGetModelLODDistance]]&lt;br /&gt;
* [[engineSetModelLODDistance]]&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51672</id>
		<title>GetVehiclesLODDistance</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51672"/>
		<updated>2017-07-16T11:30:56Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}{{Needs Example}}__NOTOC__&lt;br /&gt;
{{New feature/item|3.0154|1.5.3|11199|&lt;br /&gt;
Returns the distance of vehicles LOD.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float getVehiclesLODDistance ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Returns ==&lt;br /&gt;
* '''float:''' general distance used for most vehicles&lt;br /&gt;
* '''float:''' distance used for trains and planes&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
* [[engineGetModelLODDistance]]&lt;br /&gt;
* [[engineSetModelLODDistance]]&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51671</id>
		<title>GetVehiclesLODDistance</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetVehiclesLODDistance&amp;diff=51671"/>
		<updated>2017-07-16T11:30:04Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}{{Needs Example}}__NOTOC__&lt;br /&gt;
{{New feature/item|3.0154|1.5.3|11199|&lt;br /&gt;
Returns the distance of vehicles LOD.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float getVehiclesLODDistance ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Returns ==&lt;br /&gt;
* '''float:''' general distance used for most vehicles&lt;br /&gt;
* '''float:''' distance used for trains and planes&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example shows the LOD distance of vehicles, helicopters and trains when the client resource started&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientResourceStart&amp;quot;,resourceRoot,function()&lt;br /&gt;
	local vehicle,planes_trains = getVehiclesLODDistance()&lt;br /&gt;
	outputChatBox(&amp;quot;LOD Distance of Vehicles: &amp;quot;..math.floor(vehicle),0,255,0)&lt;br /&gt;
	outputChatBox(&amp;quot;LOD Distance of Planes and Trains: &amp;quot;..math.floor(planes_trains),0,255,0)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
* [[engineGetModelLODDistance]]&lt;br /&gt;
* [[engineSetModelLODDistance]]&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiGridListGetSelectedItems&amp;diff=51645</id>
		<title>GuiGridListGetSelectedItems</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiGridListGetSelectedItems&amp;diff=51645"/>
		<updated>2017-07-14T11:05:05Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function returns the items selected in the specified [[Element/GUI/Gridlist|grid list]].&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
table guiGridListGetSelectedItems ( element gridList )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''gridList:''' The [[Element/GUI/Gridlist|grid list]] which selected items you want to retrieve.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a table over the selected items in the [[Element/GUI/Gridlist|grid list]] in this format:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
table = {&lt;br /&gt;
    [1] = {&lt;br /&gt;
        [&amp;quot;column&amp;quot;], -- has the first selected item's column ID&lt;br /&gt;
        [&amp;quot;row&amp;quot;] -- has the first selected item's row ID&lt;br /&gt;
    },&lt;br /&gt;
    [2] = {&lt;br /&gt;
        [&amp;quot;column&amp;quot;],-- has the second selected item's column ID&lt;br /&gt;
        [&amp;quot;row&amp;quot;] -- has the second selected item's row ID&lt;br /&gt;
    },&lt;br /&gt;
    ...&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
if everything was successful or ''false'' if invalid arguments were passed.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--Vladislav_Nenakhov&lt;br /&gt;
--Create window&lt;br /&gt;
playerWindow = guiCreateWindow(526, 230, 291, 284, &amp;quot;&amp;quot;, false)&lt;br /&gt;
guiWindowSetSizable(playerWindow, false)&lt;br /&gt;
&lt;br /&gt;
gridlistPlayers = guiCreateGridList(9, 23, 272, 201, false, playerWindow)&lt;br /&gt;
guiGridListAddColumn(gridlistPlayers, &amp;quot;Players&amp;quot;, 0.9)&lt;br /&gt;
for _, players in ipairs(getElementsByType(&amp;quot;player&amp;quot;)) do &lt;br /&gt;
   local row = guiGridListAddRow(gridlistPlayers)&lt;br /&gt;
   guiGridListSetItemText(gridlistPlayers, row, 1, getPlayerName(players), false, false)&lt;br /&gt;
end &lt;br /&gt;
buttonSelectedPlayer = guiCreateButton(9, 227, 272, 20, &amp;quot;Selected&amp;quot;, false, playerWindow)&lt;br /&gt;
&lt;br /&gt;
-- Gui click&lt;br /&gt;
addEventHandler(&amp;quot;onClientGUIClick&amp;quot;, getRootElement(), function()&lt;br /&gt;
   if source == buttonSelectedPlayer then &lt;br /&gt;
       if #guiGridListGetSelectedItems(gridlistPlayers) &amp;gt; 0 then &lt;br /&gt;
          outputChatBox(&amp;quot;Yes&amp;quot;)&lt;br /&gt;
       else&lt;br /&gt;
          outputChatBox(&amp;quot;No&amp;quot;)&lt;br /&gt;
       end &lt;br /&gt;
   end &lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetVehicleGravity&amp;diff=51635</id>
		<title>GetVehicleGravity</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetVehicleGravity&amp;diff=51635"/>
		<updated>2017-07-12T11:41:48Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
&lt;br /&gt;
Retrieves the current gravity vector of a vehicle. This is the direction in which the vehicle falls, also the cameras of any passengers will be rotated to match it.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;float float float getVehicleGravity ( vehicle theVehicle )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theVehicle:''' the vehicle to retrieve the gravity vector of.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the x, y and z components of the gravity vector if successful, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This command will get gravity of your vehicle and output to chat using the /grav command&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;grav&amp;quot;,function()&lt;br /&gt;
	local vehicle = getPedOccupiedVehicle(localPlayer)&lt;br /&gt;
	if (vehicle) then&lt;br /&gt;
		local x,y,z = getVehicleGravity(vehicle)&lt;br /&gt;
		outputChatBox(&amp;quot;Your vehicle's gravity is: &amp;quot;..x..&amp;quot; &amp;quot;..y..&amp;quot; &amp;quot;..z,0,255,0)&lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client vehicle functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetVehicleGravity&amp;diff=51634</id>
		<title>GetVehicleGravity</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetVehicleGravity&amp;diff=51634"/>
		<updated>2017-07-12T11:39:43Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
&lt;br /&gt;
Retrieves the current gravity vector of a vehicle. This is the direction in which the vehicle falls, also the cameras of any passengers will be rotated to match it.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;float float float getVehicleGravity ( vehicle theVehicle )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theVehicle:''' the vehicle to retrieve the gravity vector of.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the x, y and z components of the gravity vector if successful, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This command will get gravity of your vehicle using the /grav command&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;grav&amp;quot;,function()&lt;br /&gt;
	local vehicle = getPedOccupiedVehicle(localPlayer)&lt;br /&gt;
	if (vehicle) then&lt;br /&gt;
		local x,y,z = getVehicleGravity(vehicle)&lt;br /&gt;
		outputChatBox(&amp;quot;Your vehicle's gravity is: &amp;quot;..x..&amp;quot; &amp;quot;..y..&amp;quot; &amp;quot;..z,0,255,0)&lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client vehicle functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetVehicleGravity&amp;diff=51633</id>
		<title>GetVehicleGravity</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetVehicleGravity&amp;diff=51633"/>
		<updated>2017-07-12T11:39:28Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
&lt;br /&gt;
Retrieves the current gravity vector of a vehicle. This is the direction in which the vehicle falls, also the cameras of any passengers will be rotated to match it.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;float float float getVehicleGravity ( vehicle theVehicle )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theVehicle:''' the vehicle to retrieve the gravity vector of.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the x, y and z components of the gravity vector if successful, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example&lt;br /&gt;
This command will get gravity of your vehicle using the /grav command&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;grav&amp;quot;,function()&lt;br /&gt;
	local vehicle = getPedOccupiedVehicle(localPlayer)&lt;br /&gt;
	if (vehicle) then&lt;br /&gt;
		local x,y,z = getVehicleGravity(vehicle)&lt;br /&gt;
		outputChatBox(&amp;quot;Your vehicle's gravity is: &amp;quot;..x..&amp;quot; &amp;quot;..y..&amp;quot; &amp;quot;..z,0,255,0)&lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client vehicle functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehicleGravity&amp;diff=51632</id>
		<title>SetVehicleGravity</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehicleGravity&amp;diff=51632"/>
		<updated>2017-07-12T11:29:07Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
&lt;br /&gt;
Sets the gravity vector of a vehicle. The vehicle will fall in this direction, and the camera of any occupants will also be rotated to match it. Can be used for e.g. driving on walls or upside down on ceilings.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool setVehicleGravity ( vehicle theVehicle, float x, float y, float z )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theVehicle:''' the vehicle of which to change the gravity.&lt;br /&gt;
*'''x, y, z:''' the components of the new gravity vector. If this vector has length 1, the strength of the gravity will be same as the global gravity for other entities. If it is 2, it will be twice as strong, etc.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if successful, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
This example will set 0 gravity to the vehicle if a local player enters it&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientVehicleEnter&amp;quot;,getRootElement(),function(thePlayer)&lt;br /&gt;
	if (thePlayer == localPlayer) then -- if thePlayer is localPlayer&lt;br /&gt;
		local gravity = setVehicleGravity(source,0,0,0) -- Set the gravity&lt;br /&gt;
		if (gravity) then -- If the gravity was set succesfully&lt;br /&gt;
			local gravity_pos = Vector3(getVehicleGravity(source)) -- get the gravity vector&lt;br /&gt;
			outputChatBox(&amp;quot;Gravity was set to &amp;quot;..gravity_pos.x..&amp;quot; &amp;quot;..gravity_pos.y..&amp;quot; &amp;quot;..gravity_pos.z,0,255,0) -- output to chat&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client vehicle functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehicleGravity&amp;diff=51631</id>
		<title>SetVehicleGravity</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehicleGravity&amp;diff=51631"/>
		<updated>2017-07-12T11:28:26Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
&lt;br /&gt;
Sets the gravity vector of a vehicle. The vehicle will fall in this direction, and the camera of any occupants will also be rotated to match it. Can be used for e.g. driving on walls or upside down on ceilings.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool setVehicleGravity ( vehicle theVehicle, float x, float y, float z )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theVehicle:''' the vehicle of which to change the gravity.&lt;br /&gt;
*'''x, y, z:''' the components of the new gravity vector. If this vector has length 1, the strength of the gravity will be same as the global gravity for other entities. If it is 2, it will be twice as strong, etc.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if successful, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
This example will set 0 gravity to the vehicle if a local player enters it&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientVehicleEnter&amp;quot;,getRootElement(),function(thePlayer)&lt;br /&gt;
	if (thePlayer == localPlayer) then -- if thePlayer is localPlayer&lt;br /&gt;
		local gravity = setVehicleGravity(source,0,0,0) -- Set the gravity&lt;br /&gt;
		if (gravity) then -- If the gravity was set succesfully&lt;br /&gt;
			local gravity_pos = Vector3(getVehicleGravity(source)) -- get the gravity vector&lt;br /&gt;
			outputChatBox(&amp;quot;Gravity was set to &amp;quot;..gravity_pos.x..&amp;quot; &amp;quot;..gravity_pos.y..&amp;quot; &amp;quot;..gravity_pos.z,0,255,0) -- output to chat&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client vehicle functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiMemoGetCaretIndex&amp;diff=51630</id>
		<title>GuiMemoGetCaretIndex</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiMemoGetCaretIndex&amp;diff=51630"/>
		<updated>2017-07-12T09:40:54Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
{{New feature/item|3.0135|1.3.5|6054|&lt;br /&gt;
This function returns the caret (the text cursor) position within the memo box.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
int guiMemoGetCaretIndex ( element theElement )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theElement:''' The memo box you want to get the caret position from&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the caret index on success, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the caret position of the memo to the chat&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local memo = guiCreateMemo(0.4,0.1,0.3,0.3,&amp;quot;&amp;quot;,true)&lt;br /&gt;
&lt;br /&gt;
addEventHandler(&amp;quot;onClientGUIChanged&amp;quot;,memo,function()&lt;br /&gt;
	outputChatBox(&amp;quot;Caret index is: &amp;quot;..guiMemoGetCaretIndex(memo)) -- output index to chat&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiMemoGetCaretIndex&amp;diff=51629</id>
		<title>GuiMemoGetCaretIndex</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiMemoGetCaretIndex&amp;diff=51629"/>
		<updated>2017-07-12T09:40:32Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
{{New feature/item|3.0135|1.3.5|6054|&lt;br /&gt;
This function returns the caret (the text cursor) position within the memo box.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
int guiMemoGetCaretIndex ( element theElement )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theElement:''' The memo box you want to get the caret position from&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the caret index on success, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the caret position of the memo to the chat&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local memo = guiCreateMemo(0.4,0.1,0.3,0.3,&amp;quot;&amp;quot;,true)&lt;br /&gt;
&lt;br /&gt;
addEventHandler(&amp;quot;onClientGUIChanged&amp;quot;,memo,function()&lt;br /&gt;
	outputChatBox(&amp;quot;Caret index is: &amp;quot;..guiMemoGetCaretIndex(memo)) -- output index to chat&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetMinuteDuration&amp;diff=51628</id>
		<title>GetMinuteDuration</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetMinuteDuration&amp;diff=51628"/>
		<updated>2017-07-12T09:32:52Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server client function}}&lt;br /&gt;
Tells you how long an ingame minute takes in real-world milliseconds. The default GTA value is 1000.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
int getMinuteDuration ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
''None''&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the number of real-world milliseconds that go in an ingame minute.&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
This example prints the server's minute duration&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;duration&amp;quot;,function()&lt;br /&gt;
	outputChatBox(&amp;quot;minute duration is :&amp;quot;..getMinuteDuration())&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetMinuteDuration&amp;diff=51627</id>
		<title>GetMinuteDuration</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetMinuteDuration&amp;diff=51627"/>
		<updated>2017-07-12T09:32:35Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
Tells you how long an ingame minute takes in real-world milliseconds. The default GTA value is 1000.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
int getMinuteDuration ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
''None''&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the number of real-world milliseconds that go in an ingame minute.&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
This example prints the server's minute duration&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;duration&amp;quot;,function()&lt;br /&gt;
	outputChatBox(&amp;quot;minute duration is :&amp;quot;..getMinuteDuration())&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{World functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsAmbientSoundEnabled&amp;diff=51626</id>
		<title>IsAmbientSoundEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsAmbientSoundEnabled&amp;diff=51626"/>
		<updated>2017-07-12T09:13:42Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
This function allows you to check if some background sound effects are enabled.&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 isAmbientSoundEnabled( string theType )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theType:''' The type of ambient sound to test. Can be either &amp;quot;gunfire&amp;quot; or &amp;quot;general&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if the ambient sound is enabled, ''false'' if it is disabled or invalid values were passed.&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
This command checks if the type of  ambient sound is enabled or not.&lt;br /&gt;
/check &amp;lt;type&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;check&amp;quot;,function(_,_type)&lt;br /&gt;
	if isAmbientSoundEnabled(_type) then&lt;br /&gt;
		outputChatBox(_type..&amp;quot; is enabled!&amp;quot;,0,255,0)&lt;br /&gt;
	else&lt;br /&gt;
		outputChatBox(_type..&amp;quot; is disabled!&amp;quot;,255,0,0)&lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client world functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsAmbientSoundEnabled&amp;diff=51625</id>
		<title>IsAmbientSoundEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsAmbientSoundEnabled&amp;diff=51625"/>
		<updated>2017-07-12T09:13:18Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
This function allows you to check if some background sound effects are enabled.&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 isAmbientSoundEnabled( string theType )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theType:''' The type of ambient sound to test. Can be either &amp;quot;gunfire&amp;quot; or &amp;quot;general&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if the ambient sound is enabled, ''false'' if it is disabled or invalid values were passed.&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
This command checks if the type of  ambient sound is enabled or not.&lt;br /&gt;
/check &amp;lt;type&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;check&amp;quot;,function(_,_type)&lt;br /&gt;
	if isAmbientSoundEnabled(_type) then&lt;br /&gt;
		outputChatBox(_type..&amp;quot; is enabled!&amp;quot;,0,255,0)&lt;br /&gt;
	else&lt;br /&gt;
		outputChatBox(_type..&amp;quot; is disabled!&amp;quot;,255,0,0)&lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client world functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetDevelopmentMode&amp;diff=51623</id>
		<title>GetDevelopmentMode</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetDevelopmentMode&amp;diff=51623"/>
		<updated>2017-07-11T23:37:50Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server client function}}&lt;br /&gt;
&lt;br /&gt;
This function is used to get the development mode of the client. For more information see [[setDevelopmentMode]]&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 getDevelopmentMode ()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if the development mode is on, ''false'' if off.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This command enables / disables the development mode&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;dev&amp;quot;,function()&lt;br /&gt;
	local boolean = not getDevelopmentMode() -- true/false&lt;br /&gt;
	setDevelopmentMode(boolean)&lt;br /&gt;
	outputChatBox(&amp;quot;DevelopmentMode: &amp;quot;..tostring(boolean))&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|1.5.4-9.11305|1.1.1-9.03355|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_utility_functions}}&lt;br /&gt;
&lt;br /&gt;
[[pl:GetDevelopmentMode]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetDevelopmentMode&amp;diff=51621</id>
		<title>GetDevelopmentMode</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetDevelopmentMode&amp;diff=51621"/>
		<updated>2017-07-11T22:50:47Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
This function is used to get the development mode of the client. For more information see [[setDevelopmentMode]]&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 getDevelopmentMode ()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if the development mode is on, ''false'' if off.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This command enables / disables the development mode&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;dev&amp;quot;,function()&lt;br /&gt;
	local boolean = not getDevelopmentMode() -- true/false&lt;br /&gt;
	setDevelopmentMode(boolean)&lt;br /&gt;
	outputChatBox(&amp;quot;DevelopmentMode: &amp;quot;..tostring(boolean))&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|1.5.4-9.11305|1.1.1-9.03355|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_utility_functions}}&lt;br /&gt;
&lt;br /&gt;
[[pl:GetDevelopmentMode]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetDevelopmentMode&amp;diff=51620</id>
		<title>GetDevelopmentMode</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetDevelopmentMode&amp;diff=51620"/>
		<updated>2017-07-11T22:50:30Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Returns */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
This function is used to get the development mode of the client. For more information see [[setDevelopmentMode]]&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 getDevelopmentMode ()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if the development mode is on, ''false'' if off.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This ommand enables / disables the development mode&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;dev&amp;quot;,function()&lt;br /&gt;
	local boolean = not getDevelopmentMode() -- true/false&lt;br /&gt;
	setDevelopmentMode(boolean)&lt;br /&gt;
	outputChatBox(&amp;quot;DevelopmentMode: &amp;quot;..tostring(boolean))&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|1.5.4-9.11305|1.1.1-9.03355|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_utility_functions}}&lt;br /&gt;
&lt;br /&gt;
[[pl:GetDevelopmentMode]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51619</id>
		<title>GetInteriorSoundsEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51619"/>
		<updated>2017-07-11T21:46:14Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
&lt;br /&gt;
This function checks to see if the music played by default in clubs is disabled or not.&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 getInteriorSoundsEnabled ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Returns==&lt;br /&gt;
Returns true if music is playing, returns false if music is not playing.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
Command check_sounds checks if the interior sounds enabled or not&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;check_sounds&amp;quot;,&lt;br /&gt;
function()&lt;br /&gt;
	if getInteriorSoundsEnabled() then &lt;br /&gt;
		outputChatBox(&amp;quot;Interior sounds are enabled!!!&amp;quot;,0,255,0)&lt;br /&gt;
	else&lt;br /&gt;
		outputChatBox(&amp;quot;Interior sounds are disabled!!!&amp;quot;,255,0,0) &lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client world functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51618</id>
		<title>GetInteriorSoundsEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51618"/>
		<updated>2017-07-11T21:46:01Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
&lt;br /&gt;
This function checks to see if the music played by default in clubs is disabled or not.&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 getInteriorSoundsEnabled ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Returns==&lt;br /&gt;
Returns true if music is playing, returns false if music is not playing.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
Command check_sound checks if the interior sounds enabled or not&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;check_sounds&amp;quot;,&lt;br /&gt;
function()&lt;br /&gt;
	if getInteriorSoundsEnabled() then &lt;br /&gt;
		outputChatBox(&amp;quot;Interior sounds are enabled!!!&amp;quot;,0,255,0)&lt;br /&gt;
	else&lt;br /&gt;
		outputChatBox(&amp;quot;Interior sounds are disabled!!!&amp;quot;,255,0,0) &lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client world functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51616</id>
		<title>GetInteriorSoundsEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51616"/>
		<updated>2017-07-11T21:35:48Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
&lt;br /&gt;
This function checks to see if the music played by default in clubs is disabled or not.&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 getInteriorSoundsEnabled ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Returns==&lt;br /&gt;
Returns true if music is playing, returns false if music is not playing.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler(&amp;quot;check_sounds&amp;quot;,&lt;br /&gt;
function()&lt;br /&gt;
	if getInteriorSoundsEnabled() then &lt;br /&gt;
		outputChatBox(&amp;quot;Interior sounds are enabled!!!&amp;quot;,0,255,0)&lt;br /&gt;
	else&lt;br /&gt;
		outputChatBox(&amp;quot;Interior sounds are disabled!!!&amp;quot;,255,0,0) &lt;br /&gt;
	end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client world functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51612</id>
		<title>GetInteriorSoundsEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51612"/>
		<updated>2017-07-11T20:28:51Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
&lt;br /&gt;
This function checks to see if the music played by default in clubs is disabled or not.&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 getInteriorSoundsEnabled ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Returns==&lt;br /&gt;
Returns true if music is playing, returns false if music is not playing.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
 --&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client world functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51611</id>
		<title>GetInteriorSoundsEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetInteriorSoundsEnabled&amp;diff=51611"/>
		<updated>2017-07-11T20:27:42Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Returns */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
&lt;br /&gt;
This function checks to see if the music played by default in clubs is disabled or not.&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 getInteriorSoundsEnabled ( )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Returns==&lt;br /&gt;
Returns true if music is playing, returns false if music is not playing.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client world functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiEditGetCaretIndex&amp;diff=51610</id>
		<title>GuiEditGetCaretIndex</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiEditGetCaretIndex&amp;diff=51610"/>
		<updated>2017-07-11T18:00:09Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
{{New feature/item|3.0135|1.3.5|6054|&lt;br /&gt;
This function returns the caret (the text cursor) position within the editbox.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
int guiEditGetCaretIndex ( element theElement )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theElement:''' The edit box you want to get the caret position from&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the caret index on success, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the caret position of the edit field to the chat&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local edit = guiCreateEdit(0.4,0.4,0.3,0.1,&amp;quot;&amp;quot;,true)&lt;br /&gt;
&lt;br /&gt;
addEventHandler(&amp;quot;onClientGUIChanged&amp;quot;,edit,function()&lt;br /&gt;
	outputChatBox(&amp;quot;Caret index is: &amp;quot;..guiEditGetCaretIndex(edit)) -- output index to chat&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51609</id>
		<title>GuiScrollBarSetScrollPosition</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51609"/>
		<updated>2017-07-11T13:21:03Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
This function is used to set the scroll amount of a scrollbar as a percentage.&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 guiScrollBarSetScrollPosition ( gui-scrollBar theScrollBar, float amount )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theScrollBar''': The scrollbar you want to change the progress of&lt;br /&gt;
*'''amount''': a float ranging from 0 - 100 representing the amount you wish to set the scroll bar.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the scroll position was successfully set, false otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
In this example, you can set the scrolling position using the command /pos &amp;lt;amount&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local window = guiCreateWindow(0.3,0.3,0.3,0.3,&amp;quot;Scroll-Position&amp;quot;,true)&lt;br /&gt;
local scroll_bar = guiCreateScrollBar(5,25,30,245,false,false,window)&lt;br /&gt;
&lt;br /&gt;
function scroll_bar_setPos(_,position)&lt;br /&gt;
	if (tonumber(position)) then -- If we have typed a position&lt;br /&gt;
		guiScrollBarSetScrollPosition(scroll_bar,position) --Set the position in the scroll bar&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;pos&amp;quot;,scroll_bar_setPos)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;br /&gt;
[[Catogory:Needs_Example]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51608</id>
		<title>GuiScrollBarSetScrollPosition</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51608"/>
		<updated>2017-07-11T09:32:48Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
This function is used to set the scroll amount of a scrollbar as a percentage.&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 guiScrollBarSetScrollPosition ( gui-scrollBar theScrollBar, float amount )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theScrollBar''': The scrollbar you want to change the progress of&lt;br /&gt;
*'''amount''': a float ranging from 0 - 100 representing the amount you wish to set the scroll bar.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the scroll position was successfully set, false otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local window = guiCreateWindow(0.3,0.3,0.3,0.3,&amp;quot;Scroll-Position&amp;quot;,true)&lt;br /&gt;
local scroll_bar = guiCreateScrollBar(5,25,30,245,false,false,window)&lt;br /&gt;
&lt;br /&gt;
function scroll_bar_setPos(_,position)&lt;br /&gt;
	if (tonumber(position)) then -- If we have typed a position&lt;br /&gt;
		guiScrollBarSetScrollPosition(scroll_bar,position) --Set the position in the scroll bar&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;pos&amp;quot;,scroll_bar_setPos)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;br /&gt;
[[Catogory:Needs_Example]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51603</id>
		<title>GuiScrollBarSetScrollPosition</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51603"/>
		<updated>2017-07-11T08:46:23Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
This function is used to set the scroll amount of a scrollbar as a percentage.&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 guiScrollBarSetScrollPosition ( gui-scrollBar theScrollBar, float amount )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theScrollBar''': The scrollbar you want to change the progress of&lt;br /&gt;
*'''amount''': a float ranging from 0 - 100 representing the amount you wish to set the scroll bar.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the scroll position was successfully set, false otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local window = guiCreateWindow(0.3,0.3,0.3,0.3,&amp;quot;Scroll-Position&amp;quot;,true)&lt;br /&gt;
local scroll_bar = guiCreateScrollBar(5,25,30,245,false,false,window)&lt;br /&gt;
&lt;br /&gt;
function scroll_bar_setPos(_,position)&lt;br /&gt;
	local position = tonumber(position)&lt;br /&gt;
	if (position) then -- If we have typed a position&lt;br /&gt;
		guiScrollBarSetScrollPosition(scroll_bar,position) --Set the position in the scroll bar&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;pos&amp;quot;,scroll_bar_setPos)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;br /&gt;
[[Catogory:Needs_Example]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51602</id>
		<title>GuiScrollBarSetScrollPosition</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GuiScrollBarSetScrollPosition&amp;diff=51602"/>
		<updated>2017-07-11T08:45:54Z</updated>

		<summary type="html">&lt;p&gt;MaK$iM: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
This function is used to set the scroll amount of a scrollbar as a percentage.&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 guiScrollBarSetScrollPosition ( gui-scrollBar theScrollBar, float amount )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theScrollBar''': The scrollbar you want to change the progress of&lt;br /&gt;
*'''amount''': a float ranging from 0 - 100 representing the amount you wish to set the scroll bar.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the scroll position was successfully set, false otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This page lacks an example&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local window = guiCreateWindow(0.3,0.3,0.3,0.3,&amp;quot;Scroll-Position&amp;quot;,true)&lt;br /&gt;
local scroll_bar = guiCreateScrollBar(5,25,30,245,false,false,window)&lt;br /&gt;
&lt;br /&gt;
function scroll_bar_setPos(_,position)&lt;br /&gt;
	local position = tonumber(position)&lt;br /&gt;
	if (position) then -- If we have typed a position&lt;br /&gt;
		guiScrollBarSetScrollPosition(scroll_bar,position) --Set the position in the scroll bar&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;pos&amp;quot;,scroll_bar_setPos)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;br /&gt;
[[Catogory:Needs_Example]]&lt;/div&gt;</summary>
		<author><name>MaK$iM</name></author>
	</entry>
</feed>