<?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=CR%3D</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=CR%3D"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/wiki/Special:Contributions/CR%3D"/>
	<updated>2026-04-25T15:18:10Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Installing_and_Running_MTASA_Server_on_GNU_Linux&amp;diff=39103</id>
		<title>Installing and Running MTASA Server on GNU Linux</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Installing_and_Running_MTASA_Server_on_GNU_Linux&amp;diff=39103"/>
		<updated>2014-03-17T21:38:47Z</updated>

		<summary type="html">&lt;p&gt;CR=: /* Default config */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Installation ==&lt;br /&gt;
&lt;br /&gt;
=== Main binary ===&lt;br /&gt;
Download the latest stable Linux binaries from here:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://linux.mtasa.com/dl/135/multitheftauto_linux-{{Current Version|full}}.tar.gz&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
or if you are feeling daring, get the latest nightly build from here:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://nightly.mtasa.com/?multitheftauto_linux-{{Current Version|full}}-latest&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
Unpack into a directory:&lt;br /&gt;
 tar -xf multitheftauto_linux*&lt;br /&gt;
&lt;br /&gt;
=== Default config ===&lt;br /&gt;
Download the default config files:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://linux.mtasa.com/dl/135/baseconfig-{{Current Version|full}}.tar.gz&lt;br /&gt;
&lt;br /&gt;
Unpack and move into the deathmatch directory:&amp;lt;br/&amp;gt;&lt;br /&gt;
('''''Note:''' Only do this for new installations as it will overwrite any existing config files.)''&lt;br /&gt;
 tar -xf baseconfig*&lt;br /&gt;
 mv baseconfig*/* multitheftauto_linux*/mods/deathmatch&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
=== Default resources ===&lt;br /&gt;
Download the latest default resources:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://mtasa-resources.googlecode.com/files/mtasa-resources-r959.zip&lt;br /&gt;
(mtasa-resources-r959.zip is an example. Check https://code.google.com/p/mtasa-resources/downloads/list?q=label:Latest for the latest file name)&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Test ===&lt;br /&gt;
You can now test if the server will start correctly, by entering the install directory:&lt;br /&gt;
 cd multitheftauto_linux*&lt;br /&gt;
&lt;br /&gt;
and launching:&lt;br /&gt;
 ./mta-server&lt;br /&gt;
&lt;br /&gt;
== Running with 32 or 64 bit Linux==&lt;br /&gt;
=== Make sure your server libraries and stuff are up to date ===&lt;br /&gt;
On Debian/Ubuntu this is done with:&lt;br /&gt;
 apt-get update&lt;br /&gt;
 apt-get upgrade&lt;br /&gt;
&lt;br /&gt;
== Running with 32 bit Linux ==&lt;br /&gt;
===32 bit Troubleshooting===&lt;br /&gt;
* If you get a problem with such as &amp;quot;libreadline.so.5: cannot open shared object file: No such file or directory.&amp;quot;, it can be solved on 32 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install libreadline5&lt;br /&gt;
&lt;br /&gt;
* If you get a problem with such as &amp;quot;libncursesw.so.5 cannot open shared object file: No such file or directory&amp;quot;, it can be solved on 32 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install libncursesw5&lt;br /&gt;
&lt;br /&gt;
== Running with 64 bit Linux ==&lt;br /&gt;
===Install 32 bit libs for your 64 bit distro===&lt;br /&gt;
For 64 bit Debian, this is achieved with:&amp;lt;br/&amp;gt;&lt;br /&gt;
''(Some 64 bit distros have 32 bit libs already installed for you. So this step might not be required)''&lt;br /&gt;
&lt;br /&gt;
 apt-get install ia32-libs&lt;br /&gt;
&lt;br /&gt;
===64 bit Troubleshooting===&lt;br /&gt;
* If you get a problem with such as &amp;quot;libreadline.so.5: cannot open shared object file: No such file or directory.&amp;quot;, it can be solved on 64 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install lib32readline5&lt;br /&gt;
&lt;br /&gt;
* If you get a problem with such as &amp;quot;libncursesw.so.5 cannot open shared object file: No such file or directory&amp;quot;, it can be solved on 64 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install lib32ncursesw5&lt;br /&gt;
&lt;br /&gt;
* Further 64 bit solutions can be found [http://forum.mtasa.com/viewtopic.php?f=106&amp;amp;t=35328#p367282 on the forums]&lt;br /&gt;
&lt;br /&gt;
== MySQL Troubleshooting==&lt;br /&gt;
* If you are using the inbuild MySQL functions such as [[dbConnect]] and [[dbQuery]], you will need to have '''libmysqlclient.so.15''' installed.&lt;br /&gt;
* If you can't get '''libmysqlclient.so.15''' installed by conventional means, then try [http://nightly.mtasa.com/files/libmysqlclient.so.15 downloading the file from here] and copying it to your Linux server '''/usr/lib/''' directory.&lt;br /&gt;
&lt;br /&gt;
==Cent OS Troubleshooting==&lt;br /&gt;
* If you are using Cent OS and you get something like /usr/lib/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by xmll.so) this can be resolved by doing downloading the archive [[http://archives.fedoraproject.org/pub/archive/fedora/linux/releases/9/Fedora/i386/os/Packages/libstdc++-4.3.0-8.i386.rpm here]] and unpacking it with the following command:&lt;br /&gt;
&lt;br /&gt;
 rpm2cpio libstdc++-4.3.0-8.i386.rpm | cpio -i --make-directories&lt;br /&gt;
&lt;br /&gt;
== Server crashes ==&lt;br /&gt;
&lt;br /&gt;
If your Linux server crashes, please obtain a backtrace and post a report on our [http://bugs.mtasa.com/ Bug tracker]&lt;br /&gt;
&lt;br /&gt;
====To obtain a backtrace:====&lt;br /&gt;
===Do you have a core dump file in the the MTA server directory?===&lt;br /&gt;
It's usually called 'core', and usually over 100MB, and looks something like this:&lt;br /&gt;
 [[Image:Core.png]]&lt;br /&gt;
====If you have a core dump file in the the MTA server directory:====&lt;br /&gt;
*Install gdb. To install gdb on Debian, use this command:&lt;br /&gt;
 apt-get install gdb&lt;br /&gt;
*And from the MTA install directory do this command&lt;br /&gt;
 gdb mta-server -c core&lt;br /&gt;
*When gdb launches, do this command to get a  module list:&lt;br /&gt;
 i sh&lt;br /&gt;
*And then this command to get a backtrace:&lt;br /&gt;
 bt&lt;br /&gt;
*Save the output&lt;br /&gt;
*(To exit gdb, use the quit command)&lt;br /&gt;
&lt;br /&gt;
====If you do not have a core dump file in the the MTA server directory:====&lt;br /&gt;
*Install gdb. To install gdb on Debian, use this command:&lt;br /&gt;
 apt-get install gdb&lt;br /&gt;
*And from the MTA server directory start the mta-server like this:&lt;br /&gt;
 gdb mta-server -ex &amp;quot;set print thread-events off&amp;quot; --eval-command run&lt;br /&gt;
*Now wait for a crash. (Ignore any weird screen output in the meantime)&lt;br /&gt;
*When a crash occurs, do this command to get a module list:&lt;br /&gt;
 i sh&lt;br /&gt;
*And then this command to get a backtrace:&lt;br /&gt;
 bt&lt;br /&gt;
*Save the output&lt;br /&gt;
*(To exit gdb, use the quit command)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Server freezes''' ==&lt;br /&gt;
&lt;br /&gt;
If your Linux server freezes, please obtain a backtrace with thread information and post a report on our [http://bugs.mtasa.com/ Bug tracker]&lt;br /&gt;
&lt;br /&gt;
====To obtain a backtrace with thread information:====&lt;br /&gt;
*Install gdb. To install gdb on Debian, use this command:&lt;br /&gt;
 apt-get install gdb&lt;br /&gt;
*And from the MTA server directory start the mta-server like this:&lt;br /&gt;
 gdb mta-server -ex &amp;quot;set print thread-events off&amp;quot; --eval-command run&lt;br /&gt;
*Now wait for a freeze. (Ignore any weird screen output in the meantime)&lt;br /&gt;
*When a freeze occurs, press ctrl-c to start gdb&lt;br /&gt;
*Then do this command to get a module list:&lt;br /&gt;
 i sh&lt;br /&gt;
*And then this command to get a backtrace:&lt;br /&gt;
 bt&lt;br /&gt;
*And then this command to get thread information:&lt;br /&gt;
 info threads&lt;br /&gt;
*Save the output&lt;br /&gt;
*(To exit gdb, use the quit command)&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Installing_and_Running_MTASA_Server_on_GNU_Linux&amp;diff=39102</id>
		<title>Installing and Running MTASA Server on GNU Linux</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Installing_and_Running_MTASA_Server_on_GNU_Linux&amp;diff=39102"/>
		<updated>2014-03-17T21:36:11Z</updated>

		<summary type="html">&lt;p&gt;CR=: /* Main binary */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Installation ==&lt;br /&gt;
&lt;br /&gt;
=== Main binary ===&lt;br /&gt;
Download the latest stable Linux binaries from here:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://linux.mtasa.com/dl/135/multitheftauto_linux-{{Current Version|full}}.tar.gz&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
or if you are feeling daring, get the latest nightly build from here:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://nightly.mtasa.com/?multitheftauto_linux-{{Current Version|full}}-latest&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
Unpack into a directory:&lt;br /&gt;
 tar -xf multitheftauto_linux*&lt;br /&gt;
&lt;br /&gt;
=== Default config ===&lt;br /&gt;
Download the default config files:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://linux.mtasa.com/dl/134/baseconfig-{{Current Version|full}}.tar.gz&lt;br /&gt;
&lt;br /&gt;
Unpack and move into the deathmatch directory:&amp;lt;br/&amp;gt;&lt;br /&gt;
('''''Note:''' Only do this for new installations as it will overwrite any existing config files.)''&lt;br /&gt;
 tar -xf baseconfig*&lt;br /&gt;
 mv baseconfig*/* multitheftauto_linux*/mods/deathmatch&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
=== Default resources ===&lt;br /&gt;
Download the latest default resources:&lt;br /&gt;
 wget &amp;lt;nowiki&amp;gt;http&amp;lt;/nowiki&amp;gt;://mtasa-resources.googlecode.com/files/mtasa-resources-r959.zip&lt;br /&gt;
(mtasa-resources-r959.zip is an example. Check https://code.google.com/p/mtasa-resources/downloads/list?q=label:Latest for the latest file name)&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
=== Test ===&lt;br /&gt;
You can now test if the server will start correctly, by entering the install directory:&lt;br /&gt;
 cd multitheftauto_linux*&lt;br /&gt;
&lt;br /&gt;
and launching:&lt;br /&gt;
 ./mta-server&lt;br /&gt;
&lt;br /&gt;
== Running with 32 or 64 bit Linux==&lt;br /&gt;
=== Make sure your server libraries and stuff are up to date ===&lt;br /&gt;
On Debian/Ubuntu this is done with:&lt;br /&gt;
 apt-get update&lt;br /&gt;
 apt-get upgrade&lt;br /&gt;
&lt;br /&gt;
== Running with 32 bit Linux ==&lt;br /&gt;
===32 bit Troubleshooting===&lt;br /&gt;
* If you get a problem with such as &amp;quot;libreadline.so.5: cannot open shared object file: No such file or directory.&amp;quot;, it can be solved on 32 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install libreadline5&lt;br /&gt;
&lt;br /&gt;
* If you get a problem with such as &amp;quot;libncursesw.so.5 cannot open shared object file: No such file or directory&amp;quot;, it can be solved on 32 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install libncursesw5&lt;br /&gt;
&lt;br /&gt;
== Running with 64 bit Linux ==&lt;br /&gt;
===Install 32 bit libs for your 64 bit distro===&lt;br /&gt;
For 64 bit Debian, this is achieved with:&amp;lt;br/&amp;gt;&lt;br /&gt;
''(Some 64 bit distros have 32 bit libs already installed for you. So this step might not be required)''&lt;br /&gt;
&lt;br /&gt;
 apt-get install ia32-libs&lt;br /&gt;
&lt;br /&gt;
===64 bit Troubleshooting===&lt;br /&gt;
* If you get a problem with such as &amp;quot;libreadline.so.5: cannot open shared object file: No such file or directory.&amp;quot;, it can be solved on 64 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install lib32readline5&lt;br /&gt;
&lt;br /&gt;
* If you get a problem with such as &amp;quot;libncursesw.so.5 cannot open shared object file: No such file or directory&amp;quot;, it can be solved on 64 bit Debian/Ubuntu by doing this:&lt;br /&gt;
&lt;br /&gt;
 apt-get install lib32ncursesw5&lt;br /&gt;
&lt;br /&gt;
* Further 64 bit solutions can be found [http://forum.mtasa.com/viewtopic.php?f=106&amp;amp;t=35328#p367282 on the forums]&lt;br /&gt;
&lt;br /&gt;
== MySQL Troubleshooting==&lt;br /&gt;
* If you are using the inbuild MySQL functions such as [[dbConnect]] and [[dbQuery]], you will need to have '''libmysqlclient.so.15''' installed.&lt;br /&gt;
* If you can't get '''libmysqlclient.so.15''' installed by conventional means, then try [http://nightly.mtasa.com/files/libmysqlclient.so.15 downloading the file from here] and copying it to your Linux server '''/usr/lib/''' directory.&lt;br /&gt;
&lt;br /&gt;
==Cent OS Troubleshooting==&lt;br /&gt;
* If you are using Cent OS and you get something like /usr/lib/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by xmll.so) this can be resolved by doing downloading the archive [[http://archives.fedoraproject.org/pub/archive/fedora/linux/releases/9/Fedora/i386/os/Packages/libstdc++-4.3.0-8.i386.rpm here]] and unpacking it with the following command:&lt;br /&gt;
&lt;br /&gt;
 rpm2cpio libstdc++-4.3.0-8.i386.rpm | cpio -i --make-directories&lt;br /&gt;
&lt;br /&gt;
== Server crashes ==&lt;br /&gt;
&lt;br /&gt;
If your Linux server crashes, please obtain a backtrace and post a report on our [http://bugs.mtasa.com/ Bug tracker]&lt;br /&gt;
&lt;br /&gt;
====To obtain a backtrace:====&lt;br /&gt;
===Do you have a core dump file in the the MTA server directory?===&lt;br /&gt;
It's usually called 'core', and usually over 100MB, and looks something like this:&lt;br /&gt;
 [[Image:Core.png]]&lt;br /&gt;
====If you have a core dump file in the the MTA server directory:====&lt;br /&gt;
*Install gdb. To install gdb on Debian, use this command:&lt;br /&gt;
 apt-get install gdb&lt;br /&gt;
*And from the MTA install directory do this command&lt;br /&gt;
 gdb mta-server -c core&lt;br /&gt;
*When gdb launches, do this command to get a  module list:&lt;br /&gt;
 i sh&lt;br /&gt;
*And then this command to get a backtrace:&lt;br /&gt;
 bt&lt;br /&gt;
*Save the output&lt;br /&gt;
*(To exit gdb, use the quit command)&lt;br /&gt;
&lt;br /&gt;
====If you do not have a core dump file in the the MTA server directory:====&lt;br /&gt;
*Install gdb. To install gdb on Debian, use this command:&lt;br /&gt;
 apt-get install gdb&lt;br /&gt;
*And from the MTA server directory start the mta-server like this:&lt;br /&gt;
 gdb mta-server -ex &amp;quot;set print thread-events off&amp;quot; --eval-command run&lt;br /&gt;
*Now wait for a crash. (Ignore any weird screen output in the meantime)&lt;br /&gt;
*When a crash occurs, do this command to get a module list:&lt;br /&gt;
 i sh&lt;br /&gt;
*And then this command to get a backtrace:&lt;br /&gt;
 bt&lt;br /&gt;
*Save the output&lt;br /&gt;
*(To exit gdb, use the quit command)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Server freezes''' ==&lt;br /&gt;
&lt;br /&gt;
If your Linux server freezes, please obtain a backtrace with thread information and post a report on our [http://bugs.mtasa.com/ Bug tracker]&lt;br /&gt;
&lt;br /&gt;
====To obtain a backtrace with thread information:====&lt;br /&gt;
*Install gdb. To install gdb on Debian, use this command:&lt;br /&gt;
 apt-get install gdb&lt;br /&gt;
*And from the MTA server directory start the mta-server like this:&lt;br /&gt;
 gdb mta-server -ex &amp;quot;set print thread-events off&amp;quot; --eval-command run&lt;br /&gt;
*Now wait for a freeze. (Ignore any weird screen output in the meantime)&lt;br /&gt;
*When a freeze occurs, press ctrl-c to start gdb&lt;br /&gt;
*Then do this command to get a module list:&lt;br /&gt;
 i sh&lt;br /&gt;
*And then this command to get a backtrace:&lt;br /&gt;
 bt&lt;br /&gt;
*And then this command to get thread information:&lt;br /&gt;
 info threads&lt;br /&gt;
*Save the output&lt;br /&gt;
*(To exit gdb, use the quit command)&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetSoundBPM&amp;diff=34184</id>
		<title>GetSoundBPM</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetSoundBPM&amp;diff=34184"/>
		<updated>2012-12-06T12:43:19Z</updated>

		<summary type="html">&lt;p&gt;CR=: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__ &lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{New feature/item|4.0140|1.3.0|4145|&lt;br /&gt;
This function gets the beats per minute of a specific [[sound]] element.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;int getSoundBPM( element sound )&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''sound:''' A sound element that is created using [[playSound]] or [[playSound3D]]&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the beats per minute of the given sound.&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;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function bpm ()&lt;br /&gt;
    -- Long version (might be more understandable as example)&lt;br /&gt;
    sound = playSound ( &amp;quot;song.mp3&amp;quot; ) -- Play the song&lt;br /&gt;
    beats = getSoundBPM ( sound ) -- Get the beats per minute of the song&lt;br /&gt;
    outputChatBox ( &amp;quot;Long code version: &amp;quot; .. beats ) -- Output the beats to the chat box&lt;br /&gt;
&lt;br /&gt;
    -- Short version + Would save some memory&lt;br /&gt;
    outputChatBox ( &amp;quot;Short code version: &amp;quot; .. getSoundBPM ( playSound ( &amp;quot;song.mp3&amp;quot; ) ) )&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;bpm&amp;quot;, bpm )&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|n/a|1.3.0-9.04162|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetSoundBPM&amp;diff=34183</id>
		<title>GetSoundBPM</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetSoundBPM&amp;diff=34183"/>
		<updated>2012-12-06T12:43:02Z</updated>

		<summary type="html">&lt;p&gt;CR=: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__ &lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{New feature/item|4.0140|1.3.0|4145|&lt;br /&gt;
This function gets the beats per minute of a specific [[sound]] element.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;int getSoundBPM( element sound )&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''sound:''' A sound element that is created using [[playSound]] or [[playSound3D]]&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns the beats per minute of the given sound.&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;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function bpm ()&lt;br /&gt;
    -- Long version (might be more understandable as example)&lt;br /&gt;
    sound = playSound ( &amp;quot;song.mp3&amp;quot; ) -- Play the song&lt;br /&gt;
    beats = getSoundBPM ( sound ) -- Get the beats per minute of the song&lt;br /&gt;
    outputChatBox ( &amp;quot;Long code version: &amp;quot; .. beats ) -- Output the beats to the chat box&lt;br /&gt;
&lt;br /&gt;
    -- Short version + Would save some memory&lt;br /&gt;
    outputChatBox ( &amp;quot;Short code version: &amp;quot; .. getSoundBPM ( playSound ( &amp;quot;song.mp3&amp;quot; ) ) )&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;bpm&amp;quot;, bpm )&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|n/a|1.3.0-9.04162|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_audio_functions}}&lt;br /&gt;
[[Category:Needs Example]]&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=33743</id>
		<title>IsElementMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=33743"/>
		<updated>2012-10-12T15:01:27Z</updated>

		<summary type="html">&lt;p&gt;CR=: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Useful Function}}&lt;br /&gt;
&amp;lt;lowercasetitle/&amp;gt;&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
This function checks if an element is moving.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; bool isElementMoving( element theElement ) &amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the element is moving, otherwise false.&lt;br /&gt;
&lt;br /&gt;
===Code===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;function isElementMoving(theElement)&lt;br /&gt;
    if isElement(theElement)then --First check if the given argument is an element&lt;br /&gt;
        local x, y, z = getElementVelocity(theElement) --Get the velocity of the element given in our argument&lt;br /&gt;
        if x == 0 and y == 0 and z == 0 then --When there is no movement on X, Y or Z return false because our element is not moving&lt;br /&gt;
            return false&lt;br /&gt;
        else&lt;br /&gt;
            return true&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
end&amp;lt;/syntaxhighlight&amp;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 piece of client side code writes the moving state to the client his screen&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local screenWidth, screenHeight = guiGetScreenSize () -- Get the screen resolution (width and height)&lt;br /&gt;
&lt;br /&gt;
function idleCheck ()&lt;br /&gt;
    if isElementMoving( getLocalPlayer() ) then --Check if it is the player &amp;quot;strolling&amp;quot;&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    elseif isElementMoving( getPedOccupiedVehicle ( getLocalPlayer() ) ) then --Player is not &amp;quot;Strolling&amp;quot; maybe the player is in a vehicle&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    else --The player not moving on feet or in a vehicle&lt;br /&gt;
        state = &amp;quot;Idling&amp;quot;&lt;br /&gt;
    end&lt;br /&gt;
	--Write our state string to the lower left corner of the screen&lt;br /&gt;
    dxDrawText ( state, 40, screenHeight - 40, screenWidth, screenHeight, tocolor ( 255, 255, 255, 255 ), 1, &amp;quot;default&amp;quot; )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addEventHandler ( &amp;quot;onClientRender&amp;quot;, getRootElement(), idleCheck ) -- keep the text visible with onClientRender.&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Useful_Functions}}&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Talk:IsObjectMoving&amp;diff=33742</id>
		<title>Talk:IsObjectMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Talk:IsObjectMoving&amp;diff=33742"/>
		<updated>2012-10-12T15:00:45Z</updated>

		<summary type="html">&lt;p&gt;CR=: moved Talk:IsObjectMoving to Talk:IsElementMoving: This &amp;quot;useful&amp;quot; function is not only useful for objects but also for elements like players/vehicles (Also fixed a bug check out talk page)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Talk:IsElementMoving]]&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Talk:IsElementMoving&amp;diff=33741</id>
		<title>Talk:IsElementMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Talk:IsElementMoving&amp;diff=33741"/>
		<updated>2012-10-12T15:00:45Z</updated>

		<summary type="html">&lt;p&gt;CR=: moved Talk:IsObjectMoving to Talk:IsElementMoving: This &amp;quot;useful&amp;quot; function is not only useful for objects but also for elements like players/vehicles (Also fixed a bug check out talk page)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Does this even work? It doesn't look like it does because it will always return false as that timer will execute 3000ms after that function, not inside it. Also did you check if getElementVelocity on the object works? Maybe it does.&lt;br /&gt;
&lt;br /&gt;
--[[User:Arran Fortuna|Arran Fortuna]] 14:11, 7 October 2012 (UTC)&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Arran you are partly right about &amp;quot;Does this even work?&amp;quot; it can return true but this only happens when there is movement on the X axis (it still returns false if there is only movement on the Y and or Z axis.&lt;br /&gt;
Also fyi getElementVelocity() does work on objects because an object is also an element.&lt;br /&gt;
&lt;br /&gt;
'''Things that should get changed (imo) are:'''&amp;lt;br/&amp;gt;&lt;br /&gt;
- isObjectMoving() should be changed to isElementMoving() (because you can use this function all elements not only objects)&amp;lt;br/&amp;gt;&lt;br /&gt;
- The function should not only check for the movement on the X axis but also on the Y and Z&lt;br /&gt;
&lt;br /&gt;
==It would look like this==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function isElementMoving(theElement)&lt;br /&gt;
	if isElement(theElement)then --First check if the given argument is an element&lt;br /&gt;
		local x, y, z = getElementVelocity(theElement) --Get the velocity of the element given in our argument&lt;br /&gt;
		if x == 0 and y == 0 and z == 0 then --When there is no movement on X, Y or Z return false because our element is not moving&lt;br /&gt;
			return false&lt;br /&gt;
		else&lt;br /&gt;
			return true&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;
I will change the page later today and also add some sample code!&amp;lt;br/&amp;gt;&lt;br /&gt;
[[User:CR=|CR=]] 11:35, 12 October 2012 (UTC)&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsObjectMoving&amp;diff=33740</id>
		<title>IsObjectMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsObjectMoving&amp;diff=33740"/>
		<updated>2012-10-12T15:00:45Z</updated>

		<summary type="html">&lt;p&gt;CR=: moved IsObjectMoving to IsElementMoving: This &amp;quot;useful&amp;quot; function is not only useful for objects but also for elements like players/vehicles (Also fixed a bug check out talk page)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[IsElementMoving]]&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=33739</id>
		<title>IsElementMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=33739"/>
		<updated>2012-10-12T15:00:45Z</updated>

		<summary type="html">&lt;p&gt;CR=: moved IsObjectMoving to IsElementMoving: This &amp;quot;useful&amp;quot; function is not only useful for objects but also for elements like players/vehicles (Also fixed a bug check out talk page)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Useful Function}}&lt;br /&gt;
&amp;lt;lowercasetitle/&amp;gt;&lt;br /&gt;
__NOTOC__&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
&lt;br /&gt;
This function checks if an element is moving.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; bool isElementMoving( element theElement ) &amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the element is moving, otherwise false.&lt;br /&gt;
&lt;br /&gt;
===Code===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;function isElementMoving(theElement)&lt;br /&gt;
    if isElement(theElement)then --First check if the given argument is an element&lt;br /&gt;
        local x, y, z = getElementVelocity(theElement) --Get the velocity of the element given in our argument&lt;br /&gt;
        if x == 0 and y == 0 and z == 0 then --When there is no movement on X, Y or Z return false because our element is not moving&lt;br /&gt;
            return false&lt;br /&gt;
        else&lt;br /&gt;
            return true&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
end&amp;lt;/syntaxhighlight&amp;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 piece of client side code writes the moving state to the client his screen&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local screenWidth, screenHeight = guiGetScreenSize () -- Get the screen resolution (width and height)&lt;br /&gt;
&lt;br /&gt;
function idleCheck ()&lt;br /&gt;
    if isElementMoving( getLocalPlayer() ) then --Check if it is the player &amp;quot;strolling&amp;quot;&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    elseif isElementMoving( getPedOccupiedVehicle ( getLocalPlayer() ) ) then --Player is not &amp;quot;Strolling&amp;quot; maybe the player is in a vehicle&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    else --The player not moving on feet or in a vehicle&lt;br /&gt;
        state = &amp;quot;Idling&amp;quot;&lt;br /&gt;
    end&lt;br /&gt;
	--Write our state string to the lower left corner of the screen&lt;br /&gt;
    dxDrawText ( state, 40, screenHeight - 40, screenWidth, screenHeight, tocolor ( 255, 255, 255, 255 ), 1, &amp;quot;default&amp;quot; )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addEventHandler ( &amp;quot;onClientRender&amp;quot;, getRootElement(), idleCheck ) -- keep the text visible with onClientRender.&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Useful_Functions}}&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=33738</id>
		<title>IsElementMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=33738"/>
		<updated>2012-10-12T14:59:06Z</updated>

		<summary type="html">&lt;p&gt;CR=: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Useful Function}}&lt;br /&gt;
&amp;lt;lowercasetitle/&amp;gt;&lt;br /&gt;
__NOTOC__&lt;br /&gt;
{{Needs Example}}&lt;br /&gt;
&lt;br /&gt;
This function checks if an element is moving.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; bool isElementMoving( element theElement ) &amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the element is moving, otherwise false.&lt;br /&gt;
&lt;br /&gt;
===Code===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;function isElementMoving(theElement)&lt;br /&gt;
    if isElement(theElement)then --First check if the given argument is an element&lt;br /&gt;
        local x, y, z = getElementVelocity(theElement) --Get the velocity of the element given in our argument&lt;br /&gt;
        if x == 0 and y == 0 and z == 0 then --When there is no movement on X, Y or Z return false because our element is not moving&lt;br /&gt;
            return false&lt;br /&gt;
        else&lt;br /&gt;
            return true&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
end&amp;lt;/syntaxhighlight&amp;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 piece of client side code writes the moving state to the client his screen&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local screenWidth, screenHeight = guiGetScreenSize () -- Get the screen resolution (width and height)&lt;br /&gt;
&lt;br /&gt;
function idleCheck ()&lt;br /&gt;
    if isElementMoving( getLocalPlayer() ) then --Check if it is the player &amp;quot;strolling&amp;quot;&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    elseif isElementMoving( getPedOccupiedVehicle ( getLocalPlayer() ) ) then --Player is not &amp;quot;Strolling&amp;quot; maybe the player is in a vehicle&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    else --The player not moving on feet or in a vehicle&lt;br /&gt;
        state = &amp;quot;Idling&amp;quot;&lt;br /&gt;
    end&lt;br /&gt;
	--Write our state string to the lower left corner of the screen&lt;br /&gt;
    dxDrawText ( state, 40, screenHeight - 40, screenWidth, screenHeight, tocolor ( 255, 255, 255, 255 ), 1, &amp;quot;default&amp;quot; )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addEventHandler ( &amp;quot;onClientRender&amp;quot;, getRootElement(), idleCheck ) -- keep the text visible with onClientRender.&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Useful_Functions}}&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Talk:IsElementMoving&amp;diff=33737</id>
		<title>Talk:IsElementMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Talk:IsElementMoving&amp;diff=33737"/>
		<updated>2012-10-12T11:35:48Z</updated>

		<summary type="html">&lt;p&gt;CR=: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Does this even work? It doesn't look like it does because it will always return false as that timer will execute 3000ms after that function, not inside it. Also did you check if getElementVelocity on the object works? Maybe it does.&lt;br /&gt;
&lt;br /&gt;
--[[User:Arran Fortuna|Arran Fortuna]] 14:11, 7 October 2012 (UTC)&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Arran you are partly right about &amp;quot;Does this even work?&amp;quot; it can return true but this only happens when there is movement on the X axis (it still returns false if there is only movement on the Y and or Z axis.&lt;br /&gt;
Also fyi getElementVelocity() does work on objects because an object is also an element.&lt;br /&gt;
&lt;br /&gt;
'''Things that should get changed (imo) are:'''&amp;lt;br/&amp;gt;&lt;br /&gt;
- isObjectMoving() should be changed to isElementMoving() (because you can use this function all elements not only objects)&amp;lt;br/&amp;gt;&lt;br /&gt;
- The function should not only check for the movement on the X axis but also on the Y and Z&lt;br /&gt;
&lt;br /&gt;
==It would look like this==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function isElementMoving(theElement)&lt;br /&gt;
	if isElement(theElement)then --First check if the given argument is an element&lt;br /&gt;
		local x, y, z = getElementVelocity(theElement) --Get the velocity of the element given in our argument&lt;br /&gt;
		if x == 0 and y == 0 and z == 0 then --When there is no movement on X, Y or Z return false because our element is not moving&lt;br /&gt;
			return false&lt;br /&gt;
		else&lt;br /&gt;
			return true&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;
I will change the page later today and also add some sample code!&amp;lt;br/&amp;gt;&lt;br /&gt;
[[User:CR=|CR=]] 11:35, 12 October 2012 (UTC)&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33730</id>
		<title>SetVehicleAdjustableProperty</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33730"/>
		<updated>2012-10-09T11:05:04Z</updated>

		<summary type="html">&lt;p&gt;CR=: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function is used for adjusting the movable parts of a model, for example hydra jets or dump truck tray.&lt;br /&gt;
This function only works on vehicles with adjustable properties.&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 setVehicleAdjustableProperty ( element theVehicle, int value )&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 change the adjustable property of.&lt;br /&gt;
*'''value''': A value from 0 between ?. (Set the adjustable value between 0 and N. 0 is the default value. It is possible to force the setting beyond default maximum, for example setting above 5000 on the dump truck (normal max 2500) will cause the tray to be fully vertical.)&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the adjustable property was set, ''false'' otherwise.&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 clientside function allows the user to set the vehicle adjustable property of a vehicle that the user is in by typing a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function adjustProperty ( command, adjustValue )&lt;br /&gt;
    --First check if our player is in a vehicle (otherwise there is nothing to adjust)&lt;br /&gt;
    if isPedInVehicle (getLocalPlayer()) then&lt;br /&gt;
        --Next check if there is a property to adjust on this vehicle that our player is in&lt;br /&gt;
        if getVehicleAdjustableProperty(getPedOccupiedVehicle(getLocalPlayer())) then&lt;br /&gt;
            --Set the vehicle property to the argument that was given with the command (adjustValue)&lt;br /&gt;
            setVehicleAdjustableProperty (getPedOccupiedVehicle(getLocalPlayer()), adjustValue )&lt;br /&gt;
        else&lt;br /&gt;
            outputChatBox(&amp;quot;You are in a vehicle that has no adjustable property!&amp;quot;)&lt;br /&gt;
        end&lt;br /&gt;
    else&lt;br /&gt;
        outputChatBox(&amp;quot;You are not in a vehicle!&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;adjust&amp;quot;, adjustProperty )&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;
{{Client_vehicle_functions}}&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33729</id>
		<title>SetVehicleAdjustableProperty</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33729"/>
		<updated>2012-10-09T11:04:34Z</updated>

		<summary type="html">&lt;p&gt;CR=: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function is used for adjusting the movable parts of a model, for example hydra jets or dump truck tray.&lt;br /&gt;
This function only works on vehicles with adjustable properties.&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 setVehicleAdjustableProperty ( element theVehicle, int value )&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 change the adjustable property of.&lt;br /&gt;
*'''value''': A value from 0 between ?. (Set the adjustable value between 0 and N. 0 is the default value. It is possible to force the setting beyond default maximum, for example setting above 5000 on the dump truck (normal max 2500) will cause the tray to be fully vertical.)&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the adjustable property was set, ''false'' otherwise.&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 clientside function allows the user to set the vehicle adjustable property of a vehicle that he/she is in by typing a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function adjustProperty ( command, adjustValue )&lt;br /&gt;
    --First check if our player is in a vehicle (otherwise there is nothing to adjust)&lt;br /&gt;
    if isPedInVehicle (getLocalPlayer()) then&lt;br /&gt;
        --Next check if there is a property to adjust on this vehicle that our player is in&lt;br /&gt;
        if getVehicleAdjustableProperty(getPedOccupiedVehicle(getLocalPlayer())) then&lt;br /&gt;
            --Set the vehicle property to the argument that was given with the command (adjustValue)&lt;br /&gt;
            setVehicleAdjustableProperty (getPedOccupiedVehicle(getLocalPlayer()), adjustValue )&lt;br /&gt;
        else&lt;br /&gt;
            outputChatBox(&amp;quot;You are in a vehicle that has no adjustable property!&amp;quot;)&lt;br /&gt;
        end&lt;br /&gt;
    else&lt;br /&gt;
        outputChatBox(&amp;quot;You are not in a vehicle!&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;adjust&amp;quot;, adjustProperty )&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;
{{Client_vehicle_functions}}&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33728</id>
		<title>SetVehicleAdjustableProperty</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33728"/>
		<updated>2012-10-09T11:03:40Z</updated>

		<summary type="html">&lt;p&gt;CR=: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function is used for adjusting the movable parts of a model, for example hydra jets or dump truck tray.&lt;br /&gt;
This function only works on vehicles with adjustable properties.&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 setVehicleAdjustableProperty ( element theVehicle, int value )&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 change the adjustable property of.&lt;br /&gt;
*'''value''': A value from 0 between ?. (Set the adjustable value between 0 and N. 0 is the default value. It is possible to force the setting beyond default maximum, for example setting above 5000 on the dump truck (normal max 2500) will cause the tray to be fully vertical.)&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the adjustable property was set, ''false'' otherwise.&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 clientside function allows the user to set the vehicle adjustable property by typing a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function adjustProperty ( command, adjustValue )&lt;br /&gt;
    --First check if our player is in a vehicle (otherwise there is nothing to adjust)&lt;br /&gt;
    if isPedInVehicle (getLocalPlayer()) then&lt;br /&gt;
        --Next check if there is a property to adjust on this vehicle that our player is in&lt;br /&gt;
        if getVehicleAdjustableProperty(getPedOccupiedVehicle(getLocalPlayer())) then&lt;br /&gt;
            --Set the vehicle property to the argument that was given with the command (adjustValue)&lt;br /&gt;
            setVehicleAdjustableProperty (getPedOccupiedVehicle(getLocalPlayer()), adjustValue )&lt;br /&gt;
        else&lt;br /&gt;
            outputChatBox(&amp;quot;You are in a vehicle that has no adjustable property!&amp;quot;)&lt;br /&gt;
        end&lt;br /&gt;
    else&lt;br /&gt;
        outputChatBox(&amp;quot;You are not in a vehicle!&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;adjust&amp;quot;, adjustProperty )&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;
{{Client_vehicle_functions}}&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33727</id>
		<title>SetVehicleAdjustableProperty</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetVehicleAdjustableProperty&amp;diff=33727"/>
		<updated>2012-10-09T11:01:11Z</updated>

		<summary type="html">&lt;p&gt;CR=: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function is used for adjusting the movable parts of a model, for example hydra jets or dump truck tray.&lt;br /&gt;
This function only works on vehicles with adjustable properties.&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 setVehicleAdjustableProperty ( element theVehicle, int value )&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 change the adjustable property of.&lt;br /&gt;
*'''value''': A value from 0 between ?. (Set the adjustable value between 0 and N. 0 is the default value. It is possible to force the setting beyond default maximum, for example setting above 5000 on the dump truck (normal max 2500) will cause the tray to be fully vertical.)&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the adjustable property was set, ''false'' otherwise.&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 clientside function allows the user to set the vehicle adjustable property by typing a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function adjustProperty ( command, adjustValue )&lt;br /&gt;
    --First check if our player is in a vehicle (otherwise there is nothing to adjust)&lt;br /&gt;
    if isPedInVehicle (getLocalPlayer()) then&lt;br /&gt;
        --Next check if there is a property to adjust on this vehicle that our player is in&lt;br /&gt;
        if getVehicleAdjustableProperty(getPedOccupiedVehicle(getLocalPlayer())) then&lt;br /&gt;
            --Set the vehicle property to the argument that was given with the command (adjustValue)&lt;br /&gt;
            setVehicleAdjustableProperty (getPedOccupiedVehicle(getLocalPlayer()), adjustValue )&lt;br /&gt;
        else&lt;br /&gt;
            outputChatBox(&amp;quot;You are in a vehicle that has no adjustable property!&amp;quot;)&lt;br /&gt;
        end&lt;br /&gt;
    else&lt;br /&gt;
        outputChatBox(&amp;quot;You are not in a vehicle!&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;adjust&amp;quot;, adjustProperty )&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;
{{Client_vehicle_functions}}&lt;br /&gt;
[[Category:Needs_Example]]&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Help:Editing_Guidelines&amp;diff=33726</id>
		<title>Help:Editing Guidelines</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Help:Editing_Guidelines&amp;diff=33726"/>
		<updated>2012-10-09T10:45:03Z</updated>

		<summary type="html">&lt;p&gt;CR=: /* Protected Pages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Before you contribute to the Multi Theft Auto Wiki make sure you know/understand the basics of [http://www.mediawiki.org/wiki/Help:Contents MediaWiki]. This article is a guide on how to edit the MTA Wiki properly.&lt;br /&gt;
&lt;br /&gt;
== Editing Pages ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size: 85%;&amp;quot;&amp;gt;''MediaWiki general help page: [http://www.mediawiki.org/wiki/Help:Editing_pages Editing Pages]''&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Minor Edits ===&lt;br /&gt;
From Wikipedia: &amp;quot;A check to the &amp;quot;minor edit&amp;quot; box signifies that only superficial differences exist between the version with your edit and the previous version: typo corrections, formatting and presentational changes, rearranging of text without modifying content, etc. A minor edit is a version that the editor believes requires no review and could never be the subject of a dispute. The &amp;quot;minor edit&amp;quot; option is one of several options available only to registered users.&amp;quot;&amp;lt;ref&amp;gt;http://en.wikipedia.org/wiki/Help:Minor_edit&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Editing Function/Event Pages ===&lt;br /&gt;
[[File:Layout function page.png|thumb|Layout Function Pages]]&lt;br /&gt;
&lt;br /&gt;
Specific information for editing the MTA Wiki.&lt;br /&gt;
&lt;br /&gt;
===== Contents of Function/Event Pages =====&lt;br /&gt;
Function and event pages have a layout that is easy to identify and consistent. Before adding function and/or event pages make sure they do exist in the MTA Core!&lt;br /&gt;
&lt;br /&gt;
====== Layout Function Pages ======&lt;br /&gt;
* No Table of Contents: &amp;lt;nowiki&amp;gt;__NOTOC__&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* Define if function is server and/or client: &amp;lt;nowiki&amp;gt;{{Server client function}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** Server only function:  &amp;lt;nowiki&amp;gt;{{Server function}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** Client only function:  &amp;lt;nowiki&amp;gt;{{Client function}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** Both client and server: &amp;lt;nowiki&amp;gt;{{Server client function}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* Explain the function&lt;br /&gt;
* Syntax: Use &amp;lt;nowiki&amp;gt;&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&amp;lt;/syntaxhighlight&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** Required Arguments&lt;br /&gt;
** Optional Arguments (not always necessary)&lt;br /&gt;
* Returns&lt;br /&gt;
* Example&lt;br /&gt;
* See Also: Add the template to which function group this function belongs&lt;br /&gt;
&lt;br /&gt;
====== Layout Event Pages ======&lt;br /&gt;
* No Table of Contents: &amp;lt;nowiki&amp;gt;__NOTOC__&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* Define if event is server or client: &amp;lt;nowiki&amp;gt;{{server event}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** Server event:  &amp;lt;nowiki&amp;gt;{{Server event}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** Client event:  &amp;lt;nowiki&amp;gt;{{Client event}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* Parameters&lt;br /&gt;
* Source: The source of the event.&lt;br /&gt;
* Example&lt;br /&gt;
* See Also&lt;br /&gt;
&lt;br /&gt;
Events can only be server or client side not both.&lt;br /&gt;
&lt;br /&gt;
===== Tips =====&lt;br /&gt;
* When creating a new page for a function or event, you need to edit the template for 'See Also' too. If you don't add it to a function/event group template this page is orphaned.&lt;br /&gt;
* When you don't want to add examples, add the &amp;lt;nowiki&amp;gt;{{Needs Example}}&amp;lt;/nowiki&amp;gt; template at the top of the page.&lt;br /&gt;
* If you added examples to a page make sure to remove template &amp;lt;nowiki&amp;gt;{{Needs Example}}&amp;lt;/nowiki&amp;gt; when necessary. &lt;br /&gt;
&lt;br /&gt;
== Script Examples ==&lt;br /&gt;
{{note|When writing a script example always test and verify that your example is working, submitting not working examples is a waste of time for everyone.}}&lt;br /&gt;
&lt;br /&gt;
* Preferably use four spaces instead of one tabulator.&lt;br /&gt;
* Use the syntaxhighlighting codebox provided on this wiki. (&amp;lt;nowiki&amp;gt;&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;(CODE HERE)&amp;lt;/syntaxhighlight&amp;gt;&amp;lt;/nowiki&amp;gt;)&lt;br /&gt;
* If the event/function is both client and server you should use the section template with server and/or client classes.&lt;br /&gt;
** For server side examples: &amp;lt;nowiki&amp;gt;&amp;lt;section name=&amp;quot;Example 1&amp;quot; &amp;lt;/nowiki&amp;gt;'''class=&amp;quot;server&amp;quot;'''&amp;lt;nowiki&amp;gt; show=&amp;quot;true&amp;quot;&amp;gt;&amp;lt;/section&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** For client side examples: &amp;lt;nowiki&amp;gt;&amp;lt;section name=&amp;quot;Example 2&amp;quot; &amp;lt;/nowiki&amp;gt;'''class=&amp;quot;client&amp;quot;'''&amp;lt;nowiki&amp;gt; show=&amp;quot;false&amp;quot;&amp;gt;&amp;lt;/section&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When an event/function is only client or server side you should only use the code box not the section tags. &lt;br /&gt;
&lt;br /&gt;
If there are enough scripting examples, remove the template &amp;lt;nowiki&amp;gt;{{Needs Example}}&amp;lt;/nowiki&amp;gt; or the &amp;lt;nowiki&amp;gt;[[Category:Needs Example]]&amp;lt;/nowiki&amp;gt; when necessary.&lt;br /&gt;
&lt;br /&gt;
== Templates ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size: 85%;&amp;quot;&amp;gt;''MediaWiki general help page: [http://www.mediawiki.org/wiki/Help:Templates Templates]''&amp;lt;/div&amp;gt;&lt;br /&gt;
Templates are a consistent set of visual styling and can be used in articles to get the reader's attention or mark a page for example as outdated. Some templates also require arguments, for more information on how to use MTA's specific wiki templates go [[MTA Wiki:Specific Templates |here]].&lt;br /&gt;
{{Tip|If you want to avoid spacing between the page title and the template itself, you should include the template before __NOTOC__ other templates and/or [http://www.mediawiki.org/wiki/Help:Magic_words magic words].}}&lt;br /&gt;
Using templates is recommended when using the same content over a large number of pages. This will save you time when you want to change something in that content and doesn't require you to edit all the pages but just the template.&lt;br /&gt;
&lt;br /&gt;
* [[MTA Wiki:Specific Templates |How to use MTA Wiki's Specific templates]]&lt;br /&gt;
&lt;br /&gt;
== Protected Pages ==&lt;br /&gt;
Protected pages cannot be modified by normal users, if you want to change something on a protected page you will have to ask someone who has the right permissions to modify them.&amp;lt;ref&amp;gt;http://www.mediawiki.org/wiki/Help:Protected_pages&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Orphaned Pages ==&lt;br /&gt;
A page is considered orphaned when no other page(s) link to that page. This means no one will find it unless they use the search function. &lt;br /&gt;
&lt;br /&gt;
* [[Adding Pages to Categories and Templates]]&lt;br /&gt;
&lt;br /&gt;
== Icons ==&lt;br /&gt;
When you want to use icons, it is recommended to use general icons this improves the consistency of the wiki. &lt;br /&gt;
&lt;br /&gt;
* [[MTA Wiki:Tango Icon List |Tango Icon List]]&lt;br /&gt;
&lt;br /&gt;
== Helpful links ==&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Wikipedia:Cheatsheet Wikipedia Cheatsheet] - Quick overview of general editing tags and functions.&lt;br /&gt;
* [http://www.mediawiki.org/wiki/Help:Contents MediaWiki Help] - General help for the MediaWiki software.&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references&amp;gt;&amp;lt;/references&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:MTA Wiki:Editing]]&lt;/div&gt;</summary>
		<author><name>CR=</name></author>
	</entry>
</feed>