https://wiki.multitheftauto.com/api.php?action=feedcontributions&user=John&feedformat=atomMulti Theft Auto: Wiki - User contributions [en]2024-03-29T15:30:29ZUser contributionsMediaWiki 1.39.3https://wiki.multitheftauto.com/index.php?title=Server_Manual&diff=33846Server Manual2012-10-27T05:46:46Z<p>John: added a tutorial for ubuntu server 12.04.1 LTS</p>
<hr />
<div>__TOC__<br />
<br />
==Getting started==<br />
It is much easier than it looks to get a server up and running for your internet or LAN buddies; follow this wiki article and you will hopefully be on your way to hosting your own MTA:SA server in no time!<br />
<br />
==Installing the server==<br />
The dedicated server application is available in different flavours depending on the platform of the server.<br />
<br />
===Linux installation===<br />
There are different ways of getting a Linux server up and running:<br />
* [http://linux.mtasa.com Getting a precompiled package]<br />
* [[Building MTASA Server on GNU Linux]]<br />
* [https://docs.google.com/document/d/1LbPb3hQZLy-gcGH8GHXIN0Cx4nN_UJIqFGunYAezF5M/edit#heading=h.5e08dapl96eq Setting up MTASA server on Ubuntu Server 12.04.1 LTS (32 and 64 bit)]<br />
<br />
===FreeBSD installation===<br />
<br />
You can run MTA:SA under FreeBSD using Linux emulation.<br />
* Enable [http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/linuxemu-lbc-install.html Linux binary compatibility]<br />
* Install following packages or compile them from ports: hs-terminfo, linux_base-f10, linux-f10-sqlite3<br />
* Install [http://linux.mtasa.com/ Linux precompiled package]<br />
<br />
===Windows installation===<br />
Installation of the MTA:SA server on Windows is easy as pie.<br />
*Go to the [http://mtasa.com/ download page] and download the installer.<br />
*Once the installer is downloaded, open it.<br />
*Select a folder where you want to install the server.<br />
*Click Install.<br />
*Done!<br />
<br />
''For a full explanation of acl.xml (access control list) read: [[Access_Control_List|Access Control List]]''<br/><br/><br />
<br />
==Configuring your server==<br />
The Multi Theft Auto dedicated server is initially configurable through it's console window, from within the game, and from a webbrowser. In order to make use of the two last options, it is necessary to add at least one administrator user to your configuration file.<br />
<br />
===General configuration===<br />
All general configuration options can be found in the 'mods/deathmatch/[[Server_mtaserver.conf|'''mtaserver.conf''']]' file and can be opened by any regular text editor.<br />
<br />
This file is fairly straightforward; every variable has a [[Server_mtaserver.conf|description of what to do with it and how to change it]].<br />
<br />
===Port forwarding===<br />
If you run your server on your own private computer, and you have an router between the internet and your computer. You need to forward 3 ports.<br />
<br />
First of all open the file 'mods/deathmatch/[[Server_mtaserver.conf|'''mtaserver.conf''']]' and search for the next lines:<br />
<syntaxhighlight lang="xml"><br />
<serverport>22003</serverport> <br />
<httpport>22005</httpport><br />
</syntaxhighlight><br />
<br />
The ports are needed to setup the server correctly. We explain later how to set them, but first if you want your server to appear in the server browser there is another port we need, and that is the ASE port. <br />
(quick example for how to turn ASE on or off):<br />
<syntaxhighlight lang="xml"><br />
<ase>1</ase> <!-- 0 = off, 1 = on --><br />
</syntaxhighlight><br />
<br />
Now we going to forward the ports in your router, which is not needed if you already have all ports open, or if you don't have a router with a firewall. If so, skip this part.<br />
<br />
If you don't know how port forwarding works in your router, go to the [http://portforward.com/ Port Forward website], find your router model there, and follow the instructions there.<br />
<br />
In almost every router you can set the port type: UDP or TCP. The following list will explain which port type is needed for what:<br />
<br />
<br />
Main server port: UDP<br />
<br />
HTTP Port: TCP<br />
<br />
ASE Port: UDP (this is needed if you want your server to appear in the server list)<br />
<br />
<br />
The ASE port is also simple to get:<br />
<br />
ASE port = Main server port + 123<br />
<br />
So, if you have the main server port set to 22003, then the ASE port will be 22126.<br />
<br />
Good luck!<br />
<br />
''In the latest version of the server, you can check the port status by using the server command [[Server_Commands#openports|openports]].''<br />
<br />
===Client Checks===<br />
<br />
The MTA server can be configured to disable the anti-cheat. It can also allow specific or all files to be modified (e.g. carmods.dat), and make sure clients are of a minimum version.<br />
<br />
All of these settings are within the file 'mods/deathmatch/[[Server_mtaserver.conf|'''mtaserver.conf''']]'. See the [[Anti-cheat_guide|Anti-cheat guide]] for more details.<br/><br />
<br />
If you want to force a minimum client version, search for the following line:<br />
<syntaxhighlight lang="xml"><br />
<minclientversion></minclientversion><br />
</syntaxhighlight><br />
Accepted values look like: 1.1.1-9.02320<br />
<br />
===Adding administrators===<br />
It is strongly recommended to add at least one administrator to your server in order to make use of the built-in webserver to easily maintain and configure your server. This administrator will then also be able to log-in from within the game and control the server.<br />
<br />
To add an administrator to your server, follow these steps:<br><br />
<ol><br />
<li>While the server is running, add a new account by typing '''[[Server_Commands#addaccount|addaccount name password]]''' into the server window. For example, to add user BennyLava you could type:<br />
<div style="margin: 10px 10px 10px 10px;"><br />
<syntaxhighlight lang="xml"><br />
addaccount BennyLava 123password<br />
</syntaxhighlight><br />
</div><br />
<div style="margin: 10px 10px 10px 20px;"><br />
''Note: If you do not have access to the server window, and the 'admin' resource is running, you can add the example account by issuing the chatbox command '''/register BennyLava 123password'''''<br />
</div><br />
<li>The server should display a message confirming the account has been added.<br />
<li>Next, shutdown the server by typing '''shutdown''' into the server window.<br />
<li>Make sure your server is stopped; if your server is still running, the following changes you make will be overwritten</li><br />
<li>Open the file 'mods/deathmatch/'acl.xml'''' with any text editor</li><br />
<li>Add the account to the ''Admin'' group by using the XML-syntax below<br />
<div style="padding: 10px"><br />
<syntaxhighlight lang="xml"><br />
<acl><br />
...<br />
<group name="Admin"><br />
<acl name="Admin"/><br />
...<br />
<object name="user.BennyLava" /><br />
</group><br />
...<br />
</acl><br />
</syntaxhighlight><br />
</div><br />
<br />
You're done! You can add as many administrators or users as you want this way, take a look at some of the other groups and ACLs for example. The ACL is also accessible through the [[Access_Control_List|Lua scripting engine]].<br><br />
<br />
It is recommended to take a look at the web interface, we will explain how to do this below.<br />
</li><br />
</ol><br />
'''Note''': There are also ways to add accounts and edit rights for the server while it's running. "[[Server_Commands#addaccount|addaccount <user> <password>]]" is an internal command to add accounts, but you will have to use the web interface to add these accounts to specific groups/ACLs!<br /><br />
<br />
===Using the web interface===<br />
The dedicated server comes with a few Lua [[resources]] that provide a nice little web interface to your server. This can be used to easily maintain your server, as it allows you to add users, start/stop resources, and more.<br />
<br />
The web interface resources are enabled by default and are served through the built-in HTTP web server. To make sure the built-in HTTP web server runs on a port you like (22005 by default), follow these steps:<br />
<ol><br />
<li>Make sure your server is stopped<br />
<li>Open the file 'mods/deathmatch/[[Server_mtaserver.conf|'''mtaserver.conf''']]' with any text editor</li><br />
<li>Verify that the HTTP server is enabled:<br />
<div style="padding: 10px"><br />
<syntaxhighlight lang="xml"><br />
<httpserver>1</httpserver><br />
</syntaxhighlight><br />
</div><br />
</li><br />
<li>Change the HTTP server port to your liking:<br />
<div style="padding: 10px"><br />
<syntaxhighlight lang="xml"><br />
<httpport>22005</httpport><br />
</syntaxhighlight><br />
</div><br />
</li><br />
<li>Save and close the configuration file</li><br />
<li>Start your server</li><br />
<li>If you happened to have changed the start-up resources in your configuration file, make sure the following resources are started:<br />
<br />
# resourcebrowser<br />
# resourcemanager<br />
# webadmin<br />
# webmap<br />
<br />
These are automatically started in the default configuration file, in case you just installed your server.<br />
</li><br />
<li>Open a web browser (Internet Explorer 6 or 7 are NOT supported; use [http://www.mozilla.com/firefox Mozilla Firefox], [http://www.google.com/chrome Google Chrome], [http://www.apple.com/safari/download Apple Safari], [http://www.opera.com Opera] or others) and navigate to the HTTP server URL: '''http://server:port/'''. For example, If you are running a local server on HTTP port 22005, use '''http://127.0.0.1:22005/'''.</li><br />
<li>Enter the username and password of the administrator you added in the previous section.</li><br />
</ol><br />
<br />
<br /><br />
You should now be able to maintain your server from the web interface.<br />
<br />
=== Configuring an external web server ===<br />
The built-in web server is also used to serve files that are required by resources running on your server to any player that is connected to your server. For example, if you are running a game script with a scripted graphical user interface, or custom models, these need to be transferred to every connected player in order to function properly. This is done by either the built-in web server, or an external web server (that is usually a bit faster) but needs to be set up separately.<br />
<br />
For performance or consistency reasons during the game, you could choose to make use of such an external web server if you have one set up. The external web server needs to be accessible for the public, so any client will be able to download the necessary client-side files in order to join and play on your server.<br />
<br />
To enable downloading off an external web server, you should configure the [[Server_mtaserver.conf#httpdownloadurl|httpdownloadurl]] tag in your server configuration:<br />
<br />
<div style="padding: 10px"><br />
<syntaxhighlight lang="xml"> <br />
<httpdownloadurl>http://www.myserver.tld/directory/here</httpdownloadurl><br />
</syntaxhighlight></div><br />
<br />
Since all the default resources provided with the dedicated server are zipped, and are normally automatically extracted by the built-in web server, you now have to provide a way for the clients to download the compressed files to their computers. To configure MTA to maintain a copy of only your unzipped client resources, set [[Server_mtaserver.conf#httpautoclientfiles|httpautoclientfiles]] in your server configuration: <br />
<br />
<div style="padding: 10px"><br />
<syntaxhighlight lang="xml"><httpautoclientfiles>1</httpautoclientfiles><br />
</syntaxhighlight></div><br />
<br />
Now when you launch the server, the directory '''<SERVER>/mods/deathmatch/resource-cache/http-client-files''' will contain the correct client files for hosting on an external web server. If the web server is on the same machine, you can simply link the appropriate web server directory to '''http-client-files'''. If the web server is on a separate machine, ensure it has access to '''http-client-files''' via a network path, or maintain a remote copy using synchronization software.<br />
<br />
'''Note 1''': Please try to avoid any special characters (e.g. ~, !) in your download URLs.<br /><br />
'''Note 2''': Please do not use a trailing slash in your download URL (e.g. ''hxxp://www.myserver.tld/directory'' rather than ''hxxp://www.myserver.tld/directory/'')<br />
<br />
==Starting your server==<br />
Begin by making sure that you have finished all configuration of your server, starting your server is the last stage so everything must be ready!<br />
<br />
To start your server double click on MTA Server.exe, make sure you allow it through any firewalls and forward ports where necessary.<br />
<br />
==Installing/Updating resources on your server==<br />
Resources can come in two formats, either a ZIP format or just a normal folder with the script files inside it. The MTA:SA server supports both these methods.<br />
<br />
# Move or copy the new resource to your <SERVER>\mods\deathmatch\resources folder.<br />
# In the server window type in the command [[Server_Commands#refresh|refresh]], this will re-scan the resources folder and update the live resources where necessary.<br />
<br />
==Uninstalling resources==<br />
Resources can easily be removed from your server if you no longer want them.<br />
<br />
# Delete the ZIP file or the folder of the resource you wish to uninstall<br />
# In the server window type in the command "refresh" (without the quotes), this will re-scan the resources folder and update the live resources where necessary.<br />
<br />
==Administrating your server==<br />
You can start resources by typing the command "start resourcename" in the server console, or stop ones with "stop resourcename".<br />
<br />
It's also possible to execute these and other admin commands from the in-game console (which you can bring up with the ` key or F8); for this to work, you first need to log in with the command "[[Server_Commands#login|login username password]]". Additionally, you can press the p key to bring up the admin panel: this is a graphical interface which allows you to easily kick or ban misbehaving players, among others.<br />
<br />
For further commands, type [[Server_Commands#help|help]] in a console.<br />
<br />
==Starting a map/gamemode==<br />
See the commands section of the documentation for [[Resource:Map manager|mapmanager]] for more information.<br />
<br />
==Useful Notes==<br />
<br />
# You may also update the resources while in-game as long as you have the correct access levels by typing "refresh" in the clients console or "/refresh" in the chat window. This may cause a second of lag if you have many resources.<br />
# In the above instructions, <SERVER> is the path to your server's main directory. In most cases this is C:\Program Files\MTA San Andreas\server<br />
# You can choose a different config file for the server to use by passing it in the command line after a --config argument, e.g. mtaserver.exe --config anotherconfig.cfg.<br />
# Do not be alarmed by the warning regarding the parsing of the settings.xml file. This happens because your server installation is still clean and unused.<br />
<br />
====Need further help?====<br />
Why not pop over to our [http://forum.mtasa.com/ Forums] or join us on [irc://irc.multitheftauto.com/mta IRC] (irc.multitheftauto.com #mta - [http://www.mirc.com mIRC])<br />
<br />
[[es:Manual del Servidor]]<br />
[[de:Server Anleitung]]<br />
[[it:Manuale del Server]]<br />
[[nl:Server Manual]]<br />
[[ru:Server Manual]]<br />
[[pl:Server Manual]]<br />
<br />
[[Category:Support]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetPedClothesID&diff=32635GetPedClothesID2012-08-23T10:47:51Z<p>John: </p>
<hr />
<div>[[Category:Useful_Functions]]<br />
{{Useful Function}}<br />
<lowercasetitle/><br />
__NOTOC__<br />
This function allows you get a ped's clothing ID, allowing you to forget about texture and model names. <strong>This is intended to overwrite the native getPedClothes function, but has been renamed getPedClothesID here on the wiki. It is also intended to be used in conjunction with [[setPedClothes]].</strong><br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">int getPedClothesID(ped thePed, int clothingSlot)</syntaxhighlight><br />
<br />
===Required Arguments===<br />
* '''thePed''': The ped to examine.<br />
* '''clothingSlot''': The clothing slot to examine. See the [[CJ Clothes|clothes catalog]] for more info.<br />
<br />
===Returns===<br />
This function returns the [[CJ Clothes|clothing ID]] if successful, false otherwise.<br />
<br />
==Code==<br />
<section show="true"><br />
<syntaxhighlight lang="lua"><br />
function getPedClothesID(thePed, clothingSlot)<br />
if not isElement(thePed) or type(clothingSlot) ~= "number" then<br />
error("Invalid arguments to setPedClothes()!", 2)<br />
end<br />
<br />
local texture, model = getPedClothes(thePed, clothingSlot)<br />
if not texture then<br />
return false<br />
else<br />
local _, id = getTypeIndexFromClothes(texture, model)<br />
return id<br />
end<br />
end<br />
</syntaxhighlight><br />
</section><br />
<br />
==Example==<br />
<section name="Server" class="server" show="true"><br />
<syntaxhighlight lang="lua"><br />
-- TODO<br />
</syntaxhighlight><br />
</section><br />
<br />
Author: John<br />
<br />
==See Also==<br />
{{Useful_Functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetPedClothesID&diff=32634GetPedClothesID2012-08-23T10:46:07Z<p>John: </p>
<hr />
<div>{{Useful Function}}<br />
[[:Category:Usefull Function]]<br />
<lowercasetitle/><br />
__NOTOC__<br />
This function allows you get a ped's clothing ID, allowing you to forget about texture and model names. <strong>This is intended to overwrite the native getPedClothes function, but has been renamed getPedClothesID here on the wiki. It is also intended to be used in conjunction with [[setPedClothes]].</strong><br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">int getPedClothesID(ped thePed, int clothingSlot)</syntaxhighlight><br />
<br />
===Required Arguments===<br />
* '''thePed''': The ped to examine.<br />
* '''clothingSlot''': The clothing slot to examine. See the [[CJ Clothes|clothes catalog]] for more info.<br />
<br />
===Returns===<br />
This function returns the [[CJ Clothes|clothing ID]] if successful, false otherwise.<br />
<br />
==Code==<br />
<section show="true"><br />
<syntaxhighlight lang="lua"><br />
function getPedClothesID(thePed, clothingSlot)<br />
if not isElement(thePed) or type(clothingSlot) ~= "number" then<br />
error("Invalid arguments to setPedClothes()!", 2)<br />
end<br />
<br />
local texture, model = getPedClothes(thePed, clothingSlot)<br />
if not texture then<br />
return false<br />
else<br />
local _, id = getTypeIndexFromClothes(texture, model)<br />
return id<br />
end<br />
end<br />
</syntaxhighlight><br />
</section><br />
<br />
==Example==<br />
<section name="Server" class="server" show="true"><br />
<syntaxhighlight lang="lua"><br />
-- TODO<br />
</syntaxhighlight><br />
</section><br />
<br />
Author: John<br />
<br />
==See Also==<br />
{{Useful_Functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetPedClothesID&diff=32633GetPedClothesID2012-08-23T10:41:38Z<p>John: Created page with "{{Useful Function}} <lowercasetitle/> __NOTOC__ This function allows you get a ped's clothing ID, allowing you to forget about texture and model names. <strong>This is intended t..."</p>
<hr />
<div>{{Useful Function}}<br />
<lowercasetitle/><br />
__NOTOC__<br />
This function allows you get a ped's clothing ID, allowing you to forget about texture and model names. <strong>This is intended to overwrite the native getPedClothes function, but has been renamed getPedClothesID here on the wiki. It is also intended to be used in conjunction with [[setPedClothes]].</strong><br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">int getPedClothesID(ped thePed, int clothingSlot)</syntaxhighlight><br />
<br />
===Required Arguments===<br />
* '''thePed''': The ped to examine.<br />
* '''clothingSlot''': The clothing slot to examine. See the [[CJ Clothes|clothes catalog]] for more info.<br />
<br />
===Returns===<br />
This function returns the [[CJ Clothes|clothing ID]] if successful, false otherwise.<br />
<br />
==Code==<br />
<section show="true"><br />
<syntaxhighlight lang="lua"><br />
function getPedClothesID(thePed, clothingSlot)<br />
if not isElement(thePed) or type(clothingSlot) ~= "number" then<br />
error("Invalid arguments to setPedClothes()!", 2)<br />
end<br />
<br />
local texture, model = getPedClothes(thePed, clothingSlot)<br />
if not texture then<br />
return false<br />
else<br />
local _, id = getTypeIndexFromClothes(texture, model)<br />
return id<br />
end<br />
end<br />
</syntaxhighlight><br />
</section><br />
<br />
==Example==<br />
<section name="Server" class="server" show="true"><br />
<syntaxhighlight lang="lua"><br />
-- TODO<br />
</syntaxhighlight><br />
</section><br />
<br />
Author: John<br />
<br />
==See Also==<br />
{{Useful_Functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=SetPedClothes&diff=32627SetPedClothes2012-08-23T10:32:35Z<p>John: </p>
<hr />
<div>{{Useful Function}}<br />
<lowercasetitle/><br />
__NOTOC__<br />
This function allows you set a ped's clothes with just the slot and clothing index, allowing you to forget about texture and model names.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">bool setPedClothes(ped thePed, int clothingSlot, int/bool clothingID)</syntaxhighlight><br />
<br />
===Required Arguments===<br />
* '''thePed''': The ped to dress up.<br />
* '''clothingSlot''': The clothing slot to change. See the [[CJ Clothes|clothes catalog]] for more info.<br />
* '''clothingID''': The clothing ID to set the slot to, or false to remove clothing from this slot (only applicable to slot IDs > 3). See the [[CJ Clothes|clothes catalog]] for more info.<br />
<br />
===Returns===<br />
This function returns ''true'' if the clothes were set successfully, ''false'' otherwise.<br />
<br />
==Code==<br />
<section show="true"><br />
<syntaxhighlight lang="lua"><br />
function setPedClothes(thePed, clothingSlot, clothingID)<br />
if not isElement(thePed) or type(clothingSlot) ~= "number" then<br />
error("Invalid arguments to setPedClothes()!", 2)<br />
end<br />
<br />
if not clothingID then<br />
return removePedClothes(thePed, clothingSlot)<br />
end<br />
<br />
local hasClothes = getPedClothes(thePed, clothingSlot) <br />
if hasClothes then<br />
removePedClothes(thePed, clothingSlot)<br />
end<br />
<br />
local texture, model = getClothesByTypeIndex(clothingSlot, clothingID)<br />
return addPedClothes(thePed, texture, model, clothingSlot)<br />
end<br />
</syntaxhighlight><br />
</section><br />
<br />
==Example==<br />
<section name="Server" class="server" show="true"><br />
This example adds a '/setClothes [slot] [id]' command.<br />
<syntaxhighlight lang="lua"><br />
local function clothesCommand(player, slot, id)<br />
if not tonumber(slot) then<br />
outputChatBox("SYNTAX: /setClothes [slot] [id]", player, 255, 0, 0)<br />
return<br />
end<br />
<br />
setPedClothes(player, slot, id)<br />
end<br />
addCommandHandler("/setClothes", clothesCommand)<br />
</syntaxhighlight><br />
</section><br />
<br />
Author: John<br />
<br />
==See Also==<br />
{{Useful_Functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=SetPedClothes&diff=32624SetPedClothes2012-08-23T10:31:09Z<p>John: Created page with "{{Useful Function}} <lowercasetitle/> __NOTOC__ This function allows you set a ped's clothes with just the slot and clothing index, allowing you to forget about texture and model..."</p>
<hr />
<div>{{Useful Function}}<br />
<lowercasetitle/><br />
__NOTOC__<br />
This function allows you set a ped's clothes with just the slot and clothing index, allowing you to forget about texture and model names.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">bool setPedClothes(ped thePed, int clothingSlot, int/bool clothingID)</syntaxhighlight><br />
<br />
===Required Arguments===<br />
* '''thePed''': The ped to dress up.<br />
* '''clothingSlot''': The clothing slot to change. See the [[CJ Clothes|clothes catalog]] for more info.<br />
* '''clothingID''': The clothing ID to set the slot to, or false to remove clothing from this slot (only applicable to slot IDs > 3). See the [[CJ Clothes|clothes catalog]] for more info.<br />
<br />
===Returns===<br />
This function returns ''true'' if the clothes were set successfully, ''false'' otherwise.<br />
<br />
==Code==<br />
<section show="true"><br />
<syntaxhighlight lang="lua"><br />
function setPedClothes(thePed, clothingSlot, clothingID)<br />
if not isElement(thePed) or type(clothingSlot) ~= "number" then<br />
error("Invalid arguments to setPedClothes()!", 2)<br />
end<br />
<br />
if not clothingID then<br />
return removePedClothes(thePed, clothingSlot)<br />
end<br />
<br />
local hasClothes = getPedClothes(thePed, clothingSlot) <br />
if hasClothes then<br />
removePedClothes(thePed, clothingSlot)<br />
end<br />
<br />
local texture, model = getClothesByTypeIndex(clothingSlot, clothingID)<br />
return addPedClothes(thePed, texture, model, clothingSlot)<br />
end<br />
</syntaxhighlight><br />
</section><br />
<br />
==Example==<br />
<section name="Server" class="server" show="true"><br />
This example adds a '/setClothes [id]' command.<br />
<syntaxhighlight lang="lua"><br />
local function clothesCommand(player, slot, id)<br />
if not tonumber(slot) then<br />
outputChatBox("SYNTAX: /setClothes [slot] [id]", player, 255, 0, 0)<br />
return<br />
end<br />
<br />
setPedClothes(player, slot, id)<br />
end<br />
addCommandHandler("/setClothes", clothesCommand)<br />
</syntaxhighlight><br />
</section><br />
<br />
Author: John<br />
<br />
==See Also==<br />
{{Useful_Functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetCameraMatrix&diff=32606GetCameraMatrix2012-08-23T02:54:50Z<p>John: </p>
<hr />
<div>__NOTOC__<br />
{{Server client function}}<br />
This function gets the position of the camera and the position of the point it is facing.<br />
<br />
Note: The server-side version of this function returns the last camera matrix that was set by the server, and thus does not necessarily indicate the current matrix of the camera (since it may have been changed client-side).<br />
<br />
==Syntax==<br />
<section name="Server" class="server" show="true"><br />
<syntaxhighlight lang="lua"><br />
float cameraX, float cameraY, float cameraZ, float targetX, float targetY, float targetZ, float roll, float fov = getCameraMatrix ( player thePlayer )<br />
</syntaxhighlight><br />
<br />
===Required Arguments=== <br />
*'''thePlayer:''' The player whose camera matrix is to be returned.<br />
</section><br />
<br />
<section name="Client" class="client" show="true"><br />
<syntaxhighlight lang="lua"><br />
float cameraX, float cameraY, float cameraZ, float targetX, float targetY, float targetZ, float roll, float fov = getCameraMatrix ( )<br />
</syntaxhighlight><br />
<br />
===Required Arguments=== <br />
''None.''<br />
</section><br />
<br />
===Returns===<br />
Returns eight ''float'' numbers if the argument(s) are valid; the first three indicate the position of the camera, the next three indicate the position of the point it's facing, and the last two are the roll and FOV (field of view). Returns ''false'' if the arguments are invalid.<br />
<br />
==Example==<br />
'''Example 1:''' This clientside example moves camera +1 unit on X axis.<br />
<syntaxhighlight lang="lua"><br />
local x, y, z, lx, ly, lz = getCameraMatrix() -- Get the current location and lookat of camera<br />
x, lx = x + 1, lx + 1 -- What will be the new x and x lookat values<br />
setCameraMatrix(x,y,z,lx,ly,lz) -- Set camera to new position<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
{{Camera functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=IsTrainDerailable&diff=30722IsTrainDerailable2012-05-15T04:04:03Z<p>John: PROPER example added</p>
<hr />
<div>__NOTOC__ <br />
{{Server client function}}<br />
This function will check if a train or tram is derailable.<br />
<br />
==Syntax== <br />
<syntaxhighlight lang="lua"><br />
bool isTrainDerailable ( vehicle vehicleToCheck ) <br />
</syntaxhighlight> <br />
<br />
===Required Arguments=== <br />
*'''vehicleToCheck:''' The vehicle you wish to check.<br />
<br />
===Returns===<br />
Returns ''true'' if the train is derailable, ''false'' otherwise.<br />
<br />
==Example==<br />
This example warns the player if their train can be derailed.<br />
<section name="Client" class="client" show="true"><br />
<syntaxhighlight lang="lua"><br />
local function playerVehicleEnter()<br />
local localVehicle = getPedOccupiedVehicle(localPlayer)<br />
if not isElement(localVehicle) then return end -- In case getPedOccupiedVehicle() does not return a valid vehicle, for whatever reason<br />
<br />
if getVehicleType(localVehicle) == "Train" then<br />
if isTrainDerailable(localVehicle) then<br />
outputChatBox("* Warning: this train could derail!", 255, 0, 0)<br />
end<br />
end<br />
end<br />
addEventHandler("onClientPlayerVehicleEnter", localPlayer, playerVehicleEnter)<br />
</syntaxhighlight><br />
</section><br />
<br />
==See Also==<br />
{{Vehicle_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=User_talk:John&diff=30514User talk:John2012-05-06T00:43:53Z<p>John: Drafted an updated wiki page for Stealth 4</p>
<hr />
<div>Stealth is a team elimination based gamemode that contains elements from counterstrike, splinter-cell, urban terror, and many original ideas thrown in. Players are encouraged to be stealthy in order to not reveal their location, and work with teammates using strategy and teamwork to win.<br />
<br />
=Gameplay=<br />
<br />
When a player joins a server, they are prompted to choose a team (either Mercenaries, Spies, or Spectators). You can return the team selection GUI by pressing F3.<br />
When the round begins, players are given a menu to select their weapons and gear. If a player takes too long to select their gear, they will be moved to the spectators team. Once the player hits spawn on the menu, they spawn as either a spy or a mercenary along with their teammates.<br />
The round is over when a team is eliminated or the timer runs out.<br />
The team with the most living players at the end of the round wins.<br />
<br />
==Noise==<br />
The noise indication bar appears at the bottom right of the screen (labeled as "dB" for decibels). Whenever a player does something that creates noise, the noise bar will begin to increase. If a player is being noisy, their nametag will become visible to enemies, possibly giving away their location. If a player is being very noisy, a blip will be placed on the radar, giving away their position. In order to move about undetected players should operate as stealthily and methodically as possible.<br />
<br />
==Headshots and Limping==<br />
By default, if a player is shot in the head, they will be killed instantly. If they are shot in the leg, they will become crippled, slowing down movement. This can be changed via the [[#Resource_Settings|resource settings]].<br />
<br />
==Gadgets==<br />
Players are given several options to choose as their gadget. the default button to activate it is "R". Most gadgets have limited uses. The icon to the left to the noise bar shows which is the current gadget and how many uses it has left (if there is a limit). Available gadgets include:<br />
*'''CLOAK''' Makes the player nearly invisible for a short period of time, allowing them to bypass proximity mines and sneak by players.<br />
*'''RADAR BURST''' Reveals all the living players exact locations at the time of the gadgets activation.<br />
*'''PROX MINE''' A player can crouch to place a mine that explodes when a member of the opposite team gets too close.<br />
*'''GOGGLES''' A player can use the gadget button to toggle between infrared and night vision while holding the goggles in your hand. The goggles counteract any cloaking from other players and reveal locations of proximity mines and cameras while in night vision mode, and player positions while in infrared mode.<br />
*'''CAMERA''' Pressing the gadget button while facing a wall places a camera. Pressing it again while standing away from it will activate the camera view. Use the arrow keys to moves the cameras angle around. Press fire while in Camera view to drop a smoke grenade from the camera. You can also pick up your own camera by approaching it and pressing the gadget button again so you can place the camera elsewhere.<br />
*'''ARMOR''' Gives extra protection, as well as prevents headshots or legshot limping for as long as there is armor left.<br />
*'''SHIELD''' A bulletproof riot shield.<br />
<br />
=Resource Settings=<br />
Stealth provides a plethora of options that can be modified via the [[Resource:admin|admin panel]]:<br />
*General Settings:<br />
**Friendly fire: whether or not to enable friendly fire (0 for off, 1 for on, 0 by default)<br />
**Round delay: the delay between rounds, in seconds (10-60 accepted, 15 by default)<br />
**Round length: round length, in minutes (1-1440 accepted, 5 by default)<br />
**Map round limit: maximum number of rounds allowed per map (in a row) (-1-9999 accepted, -1 for infinite rounds, 3 by default)<br />
**Weapon selection timeout: amount of time players have to choose their weapons before being moved to the spectator team, in seconds (1-439 accepted, 30 by default)<br />
**Minimum player count: the minimum number of players needed for a round to start (2-4096 accepted, 2 by default)<br />
**Enable damage effects: <b>TODO</b><br />
*Ped Stat Settings:<br />
**Use stealth ped stats: whether or not to use stealth's ped stats (0 to ignore ped stats, 1 to apply, 1 by default)<br />
**The rest of the ped stat settings are the skill levels players will spawn with. (0-999 accepted)<br />
*Weapon Ammo Settings:<br />
**All weapons have their own weapon ammo setting - this is the amount of ammo players will spawn with for the given weapon. (0-10000 accepted)</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetResourceGUIElement&diff=30197GetResourceGUIElement2012-04-30T20:50:39Z<p>John: </p>
<hr />
<div>__NOTOC__ <br />
{{Client function}}<br />
This function retrieves a resource's GUI element. The resource's GUI element is the element in the element tree which is the default parent of all GUI elements that belong to a particular resource. This has the tag 'guiroot', and each resource has one of these. You can attach event handlers to this element to easily capture events that originate from your resource (and global events that originate from the root element).<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">element getResourceGUIElement ( [resource theResource=getThisResource()] )</syntaxhighlight><br />
<br />
===Optional Arguments===<br />
{{OptionalArg}}<br />
*'''theResource:''' the resource whose GUI element we are getting. If not specified, assumes the current resource.<br />
<br />
===Returns===<br />
Returns the root GUI element that contains all the other GUI elements.<br />
<br />
==Example== <br />
This example provides a function for destroying all the GUI elements of a resource.<br />
<syntaxhighlight lang="lua">function destroyAllGUIs()<br />
-- Destroy all of the gui-root's children<br />
for _, guiElement in ipairs(getElementChildren(getResourceGUIElement())) do<br />
if isElement(guiElement) then -- This checks that the element still exists (in case we already destroyed it's parent).<br />
destroyElement(guiElement)<br />
end<br />
end<br />
end<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
{{Client_resource_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetResourceGUIElement&diff=30196GetResourceGUIElement2012-04-30T20:49:18Z<p>John: Added a proper example</p>
<hr />
<div>__NOTOC__ <br />
{{Client function}}<br />
This function retrieves a resource's GUI element. The resource's GUI element is the element in the element tree which is the default parent of all GUI elements that belong to a particular resource. This has the tag 'guiroot', and each resource has one of these.<!-- You can attach event handlers to this element to easily capture events that originate from your resource (and global events that originate from the root element). ---- Confirm please? ---- --><br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">element getResourceGUIElement ( [resource theResource=getThisResource()] )</syntaxhighlight><br />
<br />
===Optional Arguments===<br />
{{OptionalArg}}<br />
*'''theResource:''' the resource whose GUI element we are getting. If not specified, assumes the current resource. (the resource returned from [[getThisResource]])<br />
<br />
===Returns===<br />
Returns the root GUI element that contains all the other GUI elements.<br />
<br />
==Example== <br />
This example provides a function for destroying all the GUI elements of a resource.<br />
<syntaxhighlight lang="lua">function destroyAllGUIs()<br />
-- Destroy all of the gui-root's children<br />
for _, guiElement in ipairs(getElementChildren(getResourceGUIElement())) do<br />
if isElement(guiElement) then -- This checks that the element still exists (in case we already destroyed it's parent).<br />
destroyElement(guiElement)<br />
end<br />
end<br />
end<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
{{Client_resource_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Talk:SetPedGoTo&diff=30195Talk:SetPedGoTo2012-04-30T20:36:36Z<p>John: Created page with "This isn't really a "usefull function" as much as it is a script, and should be uploaded as a resource to the community center, not posted here.--~~~~"</p>
<hr />
<div>This isn't really a "usefull function" as much as it is a script, and should be uploaded as a resource to the community center, not posted here.--[[User:John|John]] 20:36, 30 April 2012 (UTC)</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30183Resource:Shadermanager2012-04-29T04:23:25Z<p>John: </p>
<hr />
<div>{{Resource page}}<br />
{{Warning|This is a <em>planned</em> resource (it's not ready yet!)|true}}<br />
Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Adoption of the #shadername.defaultState setting to determine whether or not to enable the shader by default (0 for no, 1 for yes, 0 by default).<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled<br />
<br />
==Making your shader resource compatible with <em>shadermanager</em>==<br />
To make your shader resource compatible with shadermanager (which you should do), be sure to:<br />
*Setup your resource's [[Meta.xml|meta.xml]] file properly:<br />
**Set the resource's type to "shader"<br />
**;<syntaxhighlight lang="lua"><info name="myawesomeshader" author="John_Michael" version="1.0.0" type="shader" description="My awesome shader!" /></syntaxhighlight><br />
**Setup the resource's settings. You should provide a default state setting, that will determine whether or not the shader is enabled by default (use "0" for disabled, "1" for enabled). If you do not provide this, it will default to "0".<br />
**;<syntaxhighlight lang="lua"><settings> <setting name="#shader_water.defaultState" value="1" /> </settings></syntaxhighlight><br />
<br />
*Ensure the following exported functions are available:<br />
**(TODO)</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30182Resource:Shadermanager2012-04-29T04:21:50Z<p>John: </p>
<hr />
<div>{{Resource page}}<br />
{{Warning|This is a <em>planned</em> resource (it's not ready yet!)|true}}<br />
Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Adoption of the #shadername.defaultState setting to determine whether or not to enable the shader by default (0 for no, 1 for yes, 0 by default).<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled<br />
<br />
==Making your shader resource compatible with <em>shadermanager</em>==<br />
To make your shader resource compatible with shadermanager (which you should do), be sure to:<br />
*Setup your resource's [[Meta.xml|meta.xml]] file properly:<br />
**Set the resource's type to "shader"<br />
**;<syntaxhighlight lang="lua"><info name="myawesomeshader" author="John_Michael" version="1.0.0" type="shader" description="My awesome shader!" /></syntaxhighlight><br />
**Setup the resource's settings. You should provide a default state setting, that will determine whether or not the shader is enabled by default (use "0" for off, "1" for on). If you do not provide this, it will default to "0".<br />
**;<syntaxhighlight lang="lua"><settings> <setting name="#shader_water.defaultState" value="1" /> </settings></syntaxhighlight><br />
<br />
*Ensure the following exported functions are available:<br />
**(TODO)</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30181Resource:Shadermanager2012-04-29T04:21:31Z<p>John: Began the compatibility section</p>
<hr />
<div>{{Resource page}}<br />
{{Warning|This is a <em>planned</em> resource (it's not ready yet!)|true}}<br />
Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Adoption of the #shadername.defaultState setting to determine whether or not to enable the shader by default (0 for no, 1 for yes, 0 by default).<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled<br />
<br />
==Making your shader resource compatible with <em>shadermanager</em>==<br />
To make your shader resource compatible with shadermanager (which you should do), be sure to:<br />
*Setup your resource's [[Meta.xml|meta.xml]] file:<br />
**Set the resource's type to "shader"<br />
**;<syntaxhighlight lang="lua"><info name="myawesomeshader" author="John_Michael" version="1.0.0" type="shader" description="My awesome shader!" /></syntaxhighlight><br />
**Setup the resource's settings. You should provide a default state setting, that will determine whether or not the shader is enabled by default (use "0" for off, "1" for on). If you do not provide this, it will default to "0".<br />
**;<syntaxhighlight lang="lua"><settings> <setting name="#shader_water.defaultState" value="1" /> </settings></syntaxhighlight><br />
<br />
*Ensure the following exported functions are available:<br />
**(TODO)</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30178Resource:Shadermanager2012-04-29T02:24:15Z<p>John: Added info about the defaultState setting</p>
<hr />
<div>{{Resource page}}<br />
{{Warning|This is a <em>planned</em> resource (it's not ready yet!)|true}}<br />
Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Adoption of the #shadername.defaultState setting to determine whether or not to enable the shader by default (0 for no, 1 for yes, 0 by default).<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30177Resource:Shadermanager2012-04-29T01:38:39Z<p>John: </p>
<hr />
<div>{{Resource page}}<br />
{{Warning|This is a <em>planned</em> resource (it's not ready yet!)|true}}<br />
Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled</div>Johnhttps://wiki.multitheftauto.com/index.php?title=XmlCreateFile&diff=30176XmlCreateFile2012-04-29T01:36:38Z<p>John: No it's not.</p>
<hr />
<div>__NOTOC__<br />
{{Server client function}}<br />
This function creates a new XML document, which can later be saved to a file by using [[xmlSaveFile]]. This function will overwrite the file specified if it already exists.<br />
<br />
==Syntax== <br />
<section name="Server" class="server" show="true"><br />
<syntaxhighlight lang="lua"><br />
xmlnode xmlCreateFile ( string filePath, string rootNodeName )<br />
</syntaxhighlight> <br />
<br />
===Required Arguments=== <br />
*'''filePath:''' The [[filepath]] of the file in the following format: '''":resourceName/path"'''. 'resourceName' is the name of the resource the file will be in, and 'path' is the path from the root directory of the resource to the file.<br />
:For example, if you want to create a file named 'new.xml' in the resource 'ctf', it can be created from another resource this way: ''xmlCreateFile(":ctf/new.xml", "newroot")''.<br />
:If the file is in the current resource, only the file path is necessary, e.g. ''xmlCreateFile("new.xml", "newroot")''.<br />
:Note that if a different resource than default is being accessed, the caller resource needs access to general.ModifyOtherObjects in the [[ACL]].<br />
*'''rootNodeName:''' the name of the root node in the XML document.<br />
<br />
</section><br />
<br />
<section name="Client" class="client" show="true"><br />
<syntaxhighlight lang="lua"><br />
xmlnode xmlCreateFile ( string filePath, string rootNodeName )<br />
</syntaxhighlight> <br />
<br />
===Required Arguments=== <br />
*'''filePath:''' The [[filepath]] of the file in the following format: '''":resourceName/path"'''. 'resourceName' is the name of the resource the file will be in, and 'path' is the path from the root directory of the resource to the file.<br />
:For example, if you want to create a file named 'new.xml' in the resource 'ctf', it can be created from another resource this way: ''xmlCreateFile(":ctf/new.xml", "newroot")''.<br />
:If the file is in the current resource, only the file path is necessary, e.g. ''xmlCreateFile("new.xml", "newroot")''.<br />
:Note that if a different resource than default is being accessed, the caller resource needs access to general.ModifyOtherObjects in the [[ACL]].<br />
*'''rootNodeName:''' the name of the root node in the XML document.<br />
</section><br />
<br />
===Returns===<br />
Returns the root [[xmlnode]] object of the new XML file if successful, or ''false'' otherwise.<br />
<br />
==Example==<br />
<section name="Client" class="client" show="true"><br />
This example allows a player to use the command 'createfile' to create an .xml file.<br />
<syntaxhighlight lang="lua"><br />
-- Creates a file named "new.xml" with root node "newroot" and childnode "newchild".<br />
function createFileHandler()<br />
local RootNode = xmlCreateFile("new.xml"," newroot")<br />
local NewNode = xmlCreateChild(RootNode, "newchild")<br />
xmlSaveFile(RootNode)<br />
end<br />
<br />
addCommandHandler("createfile", createFileHandler)<br />
</syntaxhighlight><br />
</section><br />
<br />
==See Also==<br />
{{XML_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30175Resource:Shadermanager2012-04-29T01:16:19Z<p>John: </p>
<hr />
<div>{{Resource page}}<br />
Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Shadermanager&diff=30174Shadermanager2012-04-29T01:15:46Z<p>John: moved Shadermanager to Resource:Shadermanager</p>
<hr />
<div>#REDIRECT [[Resource:Shadermanager]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30173Resource:Shadermanager2012-04-29T01:15:46Z<p>John: moved Shadermanager to Resource:Shadermanager</p>
<hr />
<div>Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30172Resource:Shadermanager2012-04-29T00:49:33Z<p>John: </p>
<hr />
<div>Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Exported functions to allow shadermanager to function as a backend for other scripts (allowing someone else to implement their own GUI, for example).<br />
** getShaderFromName, getAllShaders, setShaderEnabled, isShaderEnabled, isShaderCompatibleWithClient<br />
* Adoption of certain exported functions for shaders to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30171Resource:Shadermanager2012-04-29T00:48:02Z<p>John: Added proposed features.</p>
<hr />
<div>Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.<br />
<br />
==Proposed Features==<br />
* Adoption of a "type='shader'" standard to allow shadermanager to find all the shaders on a server.<br />
* Minimalistic GUI to allow for the enabling/disabling of shaders.<br />
** Small log to allow for viewing of shader-specific errors.<br />
* Adoption of certain exported resources to allow shadermanager to control all the shaders on a server.<br />
** setShaderEnabled, isShaderEnabled</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Resource:Shadermanager&diff=30170Resource:Shadermanager2012-04-29T00:40:56Z<p>John: Created page with "Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to shar..."</p>
<hr />
<div>Shadermanager is a <em>planned</em> resource to facilitate the managment of shaders in MTA, analogous to mapmanager for maps. This page is simply here to serve as a place to share the proposed system. To discuss, contact [[User:John|John]] on #mta.</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GuiLabelSetHorizontalAlign&diff=30169GuiLabelSetHorizontalAlign2012-04-28T23:57:12Z<p>John: </p>
<hr />
<div>{{Client function}}<br />
__NOTOC__<br />
This function sets the horizontal alignment of a text label.<br />
<br />
==Syntax== <br />
<syntaxhighlight lang="lua"><br />
bool guiLabelSetHorizontalAlign ( element theLabel, string align, [ bool wordwrap = false ] )<br />
</syntaxhighlight> <br />
<br />
===Required Arguments=== <br />
*'''theLabel:''' The text label to set the horizontal alignment on.<br />
*'''align:''' The alignment type. Valid type strings are:<br />
**"left"<br />
**"center"<br />
**"right"<br />
*'''wordwrap:''' Whether or not to enable wordwrap for the gui-label.<br />
<br />
===Returns===<br />
Returns ''true'' on success, ''false'' otherwise.<br />
<br />
==Example== <br />
<br />
==See Also==<br />
{{GUI functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Interior_IDs&diff=30053Interior IDs2012-04-22T16:09:53Z<p>John: </p>
<hr />
<div>San Andreas Interior ID list.<br />
<br><br />
<br><br />
*'''ID 0:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Normal world''' || <br />
|-<br />
|}<br />
<br><br />
*'''ID 1:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-nation 1''' || 289.7870 || -35.7190 || 1003.5160<br />
|-<br />
| '''Burglary House 1''' || 224.6351 || 1289.012 || 1082.141 <br />
|-<br />
| '''The Wellcome Pump (Catalina?)''' || 681.65 || -452.86 || -25.62<br />
|-<br />
| '''Restaurant 1''' || 446.6941 || -9.7977 || 1000.7340<br />
|-<br />
| '''Caligulas Casino''' || 2235.2524 || 1708.5146 || 1010.6129<br />
|-<br />
| '''Denise's Place''' || 244.0892 || 304.8456 || 999.1484<br />
|-<br />
| '''Shamal cabin''' || 1.6127 || 34.7411 || 1199.0<br />
|-<br />
| '''Liberty City''' || -750.80 || 491.00 || 1371.70<br />
|-<br />
| '''Sweet's House''' || 2525.0420 || -1679.1150 || 1015.4990<br />
|-<br />
| '''Transfender''' || 621.7850 || -12.5417 || 1000.9220<br />
|-<br />
| '''Safe House 4''' || 2216.5400 || -1076.2900 || 1050.4840<br />
|-<br />
| '''Trials(Hyman Memorial?) Stadium''' || -1401.13 || 106.110 || 1032.273<br />
|-<br />
| '''Warehouse 1''' || 1405.3120 || -8.2928 || 1000.9130<br />
|-<br />
| '''Doherty Garage''' || -2042.42 || 178.59 || 28.84 || <br />
|-<br />
| '''Sindacco Abatoir''' || 963.6078 || 2108.3970 || 1011.0300<br />
|-<br />
| '''Sub Urban''' || 203.8173 || -46.5385 || 1001.8050<br />
|-<br />
| '''Wu Zi Mu's Betting place''' || -2159.9260 || 641.4587 || 1052.3820<br />
|-<br />
|}<br />
<br><br />
*'''ID 2:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ryder's House''' || 2464.2110 || -1697.9520 || 1013.5080<br />
|-<br />
| '''Angel Pine Trailer''' || 0.3440 || -0.5140 || 1000.5490ยจ<br />
|-<br />
| '''The Pig Pen''' || 1213.4330 ||-6.6830 || 1000.9220<br />
|-<br />
| '''BDups Crack Palace''' || 1523.7510 || -46.0458 || 1002.1310<br />
|-<br />
| '''Big Smoke's Crack Palace''' || 2543.6610 || -1303.9320 || 1025.0700<br />
|-<br />
| '''Burglary House 2''' || 225.756 || 1240.000 || 1082.149<br />
|-<br />
| '''Burglary House 3''' || 447.470 || 1398.348 || 1084.305<br />
|-<br />
| '''Burglary House 4''' || 491.740 || 1400.541 || 1080.265<br />
|-<br />
| '''Katie's Place''' || 267.2290 || 304.7100 || 999.1480<br />
|-<br />
| '''Loco Low Co.''' || 612.5910 || -75.6370 || 997.9920<br />
|-<br />
| '''Reece's Barbershop''' || 612.5910 || -75.6370 || 997.9920<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 3:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Jizzy's Pleasure Domes''' || -2636.7190 || 1402.9170 || 906.4609<br />
|-<br />
| '''Brothel''' || 940.6520 || -18.4860 || 1000.9300<br />
|-<br />
| '''Brothel 2''' || 967.5334 || -53.0245 || 1001.1250<br />
|-<br />
| '''BDups Apartment''' || 1527.38 || -11.02 || 1002.10 <br />
|-<br />
| '''Bike School''' || 1494.3350 || 1305.6510 || 1093.2890<br />
|-<br />
| '''Big Spread Ranch''' || 1210.2570 || -29.2986 || 1000.8790<br />
|-<br />
| '''LV Tattoo Parlour''' || -204.4390 || -43.6520 || 1002.2990<br />
|-<br />
| '''LVPD HQ''' || 289.7703 || 171.7460 || 1007.1790<br />
|-<br />
| '''OG Loc's House''' || 516.8890 || -18.4120 || 1001.5650<br />
|-<br />
| '''Pro-Laps''' || 207.3560 || -138.0029 || 1003.3130<br />
|-<br />
| '''Las Venturas Planning Dep.''' || 374.6708 || 173.8050 || 1008.3893<br />
|-<br />
| '''Record Label Hallway''' || 1038.2190 || 6.9905 || 1001.2840<br />
|-<br />
| '''Driving School''' || -2027.9200 || -105.1830 || 1035.1720<br />
|-<br />
| '''Johnson House''' || 2496.0500 || -1693.9260 || 1014.7420<br />
|-<br />
| '''Budget Inn Motel Room''' || <br />
|-<br />
| '''Burglary House 5''' || 234.733 || 1190.391 || 1080.258<br />
|-<br />
| '''Gay Gordo's Barbershop''' || 418.6530 || -82.6390 || 1001.8050<br />
|-<br />
| '''Helena's Place''' || 292.4459 || 308.7790 || 999.1484<br />
|-<br />
| '''Inside Track Betting''' || 826.8863 || 5.5091 || 1004.4830<br />
|-<br />
| '''Sex Shop''' || -106.7268 || -19.6444 || 1000.7190<br />
|-<br />
| '''Wheel Arch Angels''' || 614.3889 || -124.0991 || 997.9950<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 4:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 1''' || -27.3769 || -27.6416 || 1003.5570<br />
|-<br />
| '''Ammu-Nation 2''' || 285.8000 || -84.5470 || 1001.5390<br />
|-<br />
| '''Burglary House 6''' || -262.91 || 1454.966 || 1084.367<br />
|-<br />
| '''Burglary House 7''' || 221.4296 || 1142.423 || 1082.609<br />
|-<br />
| '''Burglary House 8''' || 261.1168 || 1286.519 || 1080.258<br />
|-<br />
| '''Diner 2''' || 460.0 || -88.43 || 999.62 <br />
|-<br />
| '''Dirtbike Stadium''' || -1435.8690 || -662.2505 || 1052.4650<br />
|-<br />
| '''Michelle's Place''' || 302.6404 || 304.8048 || 999.1484<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 5:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Madd Dogg's Mansion''' || 1272.9116 || -768.9028 || 1090.5097<br />
|-<br />
| '''Well Stacked Pizza Co.''' || 377.7758 || -126.2766 || 1001.4920<br />
|-<br />
| '''Victim''' || 221.3310 || -6.6169 || 1005.1977<br />
|-<br />
| '''Burning Desire House''' || 2351.1540 || -1180.5770 || 1027.9770<br />
|-<br />
| '''Barbara's Place''' || (Police Station??)<br />
|-<br />
| '''Burglary House 9''' || 22.79996 || 1404.642 || 1084.43<br />
|-<br />
| '''Burglary House 10''' || 228.9003 || 1114.477 || 1080.992<br />
|-<br />
| '''Burglary House 11''' || 140.5631 || 1369.051 || 1083.864<br />
|-<br />
| '''The Crack Den''' || 322.1117 || 1119.3270 || 1083.8830<br />
|-<br />
| '''Police Station (Barbara's)''' || 322.72 || 306.43 || 999.15<br />
|-<br />
| '''Diner 1''' || 448.7435 || -110.0457 || 1000.0772<br />
|-<br />
| '''Ganton Gym''' || 768.0793 || 5.8606 || 1000.7160<br />
|-<br />
| '''Vank Hoff Hotel ''' || 2232.8210 || -1110.0180 || 1050.8830<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 6:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-Nation 3''' || 297.4460 || -109.9680 || 1001.5160<br />
|-<br />
| '''Ammu-Nation 4''' || 317.2380 || -168.0520 || 999.5930<br />
|-<br />
| '''LSPD HQ ''' || 246.4510 || 65.5860 ||1003.6410<br />
|-<br />
| '''Safe House 3''' || 2333.0330 || -1073.9600 || 1049.0230<br />
|-<br />
| '''Safe House 5''' || 2194.2910 || -1204.0150 || 1049.0230<br />
|-<br />
| '''Safe House 6''' || 2308.8710 || -1210.7170 || 1049.0230<br />
|-<br />
| '''Cobra Marital Arts Gym''' || 774.0870 ||-47.9830 || 1000.5860<br />
|-<br />
| '''24/7 shop 2''' || -26.7180 || -55.9860 || 1003.5470<br />
|-<br />
| '''Millie's Bedroom''' || 344.5200 || 304.8210 || 999.1480<br />
|-<br />
| '''Fanny Batter's Brothel''' || 744.2710 || 1437.2530 || 1102.7030<br />
|-<br />
| '''Restaurant 2''' || 443.9810 || -65.2190 || 1050.0000<br />
|-<br />
| '''Burglary House 15''' || 234.319 || 1066.455 || 1084.208<br />
|-<br />
| '''Burglary House 16''' || -69.049 || 1354.056 || 1080.211<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 7:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-Nation 5 (2 Floors)''' || 315.3850 || -142.2420 || 999.6010<br />
|-<br />
| '''8-Track Stadium''' || -1417.8720 || -276.4260 || 1051.1910<br />
|-<br />
| '''Below the Belt Gym''' || 774.2430 || -76.0090 || 1000.6540<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 8:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Safe house 2''' || <br />
|-<br />
| '''Colonel Fuhrberger's House''' || 2807.8990 || -1172.9210 || 1025.5700<br />
|-<br />
| '''Burglary House 22''' || -42.490 || 1407.644 || 1084.43<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 9:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Unknown safe house''' || 2253.1740 || -1139.0100 || 1050.6330<br />
|-<br />
| '''Andromada Cargo hold''' || 315.48 || 984.13 || 1959.11<br />
|-<br />
| '''Burglary House 12''' || 85.32596 || 1323.585 || 1083.859<br />
|-<br />
| '''Burglary House 13''' || 260.3189 || 1239.663 || 1084.258<br />
|-<br />
| '''Cluckin' Bell''' || 365.67 || -11.61 || 1000.87<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 10:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Four Dragons Casino''' || 2009.4140 || 1017.8990 || 994.4680<br />
|-<br />
| '''RC Zero's Battlefield''' || -975.5766 || 1061.1312 || 1345.6719<br />
|-<br />
| '''Burger Shot''' || 366.4220 || -73.4700 || 1001.5080<br />
|-<br />
| '''Burglary House 14''' || 21.241 || 1342.153 || 1084.375 <br />
|-<br />
| '''Janitor room(Four Dragons Maintenance)''' || 1891.3960 ||1018.1260 || 31.8820<br />
|-<br />
| '''Safe House 1''' || <br />
|-<br />
| '''Hashbury safe house''' || 2264.5231 || -1210.5229 || 1049.0234<br />
|-<br />
| '''24/7 shop 3''' || 6.0780 || -28.6330 || 1003.5490<br />
|-<br />
| '''Abandoned AC Tower''' || 419.6140 || 2536.6030 || 10.0000<br />
|-<br />
| '''SFPD HQ''' || 246.4410 || 112.1640 || 1003.2190<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 11:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''The Four Dragons Office''' || 2011.6030 || 1017.0230 || 39.0910<br />
|-<br />
| '''Los Santos safe house''' || <br />
|-<br />
| '''Ten Green Bottles Bar''' || 502.3310 || -70.6820 || 998.7570<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 12:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Budget Inn Motel Room''' || <br />
|-<br />
| '''The Casino''' || 1132.9450 || -8.6750 || 1000.6800<br />
|-<br />
| '''Macisla's Barbershop''' || 411.6410 || -51.8460 || 1001.8980<br />
|-<br />
| '''Safe house 7''' || 2237.2970 || -1077.9250 || 1049.0230<br />
|-<br />
| '''Modern safe house''' || 2324.4990 || -1147.0710 || 1050.7100<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 13:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
|'''LS Atrium''' || 1724.33 || -1625.784 || 20.211<br />
|-<br />
|'''CJ's Garage''' || -2043.966 || 172.932 || 28.835<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 14:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Kickstart Stadium''' || -1464.5360 || 1557.6900 || 1052.5310<br />
|-<br />
| '''Didier Sachs''' || 204.1789 || -165.8740 || 1000.5230<br />
|-<br />
| '''Francis Int. Airport (Front ext.)''' || -1827.1473 || 7.2074 || 1061.1435<br />
|-<br />
| '''Francis Int. Airport (Baggage Claim/Ticket Sales)''' || -1855.5687 || 41.2631 || 1061.1435<br />
|-<br />
| '''Wardrobe''' || 255.7190 || -41.1370 || 1002.0230<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 15:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Binco''' || 207.5430 || -109.0040 || 1005.1330<br />
|-<br />
| '''Blood Bowl Stadium''' || -1394.20 || 987.62 || 1023.96<br />
|-<br />
| '''Jefferson Motel''' || 2217.6250 || -1150.6580 || 1025.7970<br />
|-<br />
| '''Burglary House 17''' || -285.711 || 1470.697 || 1084.375<br />
|-<br />
| '''Burglary House 18''' || 327.808 || 1479.74 || 1084.438<br />
|-<br />
| '''Burglary House 19''' || 375.572 || 1417.439 || 1081.328<br />
|-<br />
| '''Burglary House 20''' || 384.644 || 1471.479 || 1080.195<br />
|-<br />
| '''Burglary House 21''' || 295.467 || 1474.697 || 1080.258<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 16:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 4''' || -25.3730 || -139.6540 || 1003.5470<br />
|-<br />
| '''LS Tattoo Parlour''' || -204.5580 || -25.6970 || 1002.2730<br />
|-<br />
| '''Sumoring? stadium''' || -1400 || 1250 || 1040 <br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 17:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 5''' || -25.3930 || -185.9110 || 1003.5470<br />
|-<br />
| '''Club''' || 493.4687 || -23.0080 || 1000.6796<br />
|-<br />
| '''Rusty Brown's - Ring Donuts''' || 377.0030 || -192.5070 || 1000.6330<br />
|-<br />
| '''The Sherman's Dam Generator Hall''' || -942.1320 || 1849.1420 || 5.0050<br />
|-<br />
| '''Hemlock Tattoo''' || 377.0030 || -192.5070 || 1000.6330<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 18:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Lil Probe Inn''' || -227.0280 || 1401.2290 || 27.7690<br />
|-<br />
| '''24/7 shop 6''' || -30.9460 || -89.6090 || 1003.5490<br />
|-<br />
| '''Atrium''' || 1726.1370 || -1645.2300 || 20.2260<br />
|-<br />
| '''Warehouse 2''' || 1296.6310 || 0.5920 || 1001.0230<br />
|-<br />
| '''Zip''' || 161.4620 || -91.3940 || 1001.8050<br />
|-<br />
|}<br />
<br />
<br><br />
==See Also==<br />
[[id|ID Lists]]<br />
<br><br />
[[setElementInterior]]<br />
<br><br />
[[getElementInterior]]<br />
[[Category:Scripting Concepts]]<br />
[[Category:ID Lists]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Interior_IDs&diff=30052Interior IDs2012-04-22T16:08:31Z<p>John: </p>
<hr />
<div>San Andreas Interior ID list.<br />
<br><br />
<br><br />
*'''ID 0:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Normal world''' || <br />
|-<br />
|}<br />
<br><br />
*'''ID 1:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-nation 1''' || 289.7870 || -35.7190 || 1003.5160<br />
|-<br />
| '''Burglary House 1''' || 224.6351 || 1289.012 || 1082.141 <br />
|-<br />
| '''The Wellcome Pump (Catalina?)''' || 681.65 || -452.86 || -25.62<br />
|-<br />
| '''Restaurant 1''' || 446.6941 || -9.7977 || 1000.7340<br />
|-<br />
| '''Caligulas Casino''' || 2235.2524 || 1708.5146 || 1010.6129<br />
|-<br />
| '''Denise's Place''' || 244.0892 || 304.8456 || 999.1484<br />
|-<br />
| '''Shamal cabin''' || 1.6127 || 34.7411 || 1199.0<br />
|-<br />
| '''Liberty City''' || -750.80 || 491.00 || 1371.70<br />
|-<br />
| '''Sweet's House''' || 2525.0420 || -1679.1150 || 1015.4990<br />
|-<br />
| '''Transfender''' || 621.7850 || -12.5417 || 1000.9220<br />
|-<br />
| '''Safe House 4''' || 2216.5400 || -1076.2900 || 1050.4840<br />
|-<br />
| '''Trials(Hyman Memorial?) Stadium''' || -1401.13 || 106.110 || 1032.273<br />
|-<br />
| '''Warehouse 1''' || 1405.3120 || -8.2928 || 1000.9130<br />
|-<br />
| '''Doherty Garage''' || -2042.42 || 178.59 || 28.84 || <br />
|-<br />
| '''Sindacco Abatoir''' || 963.6078 || 2108.3970 || 1011.0300<br />
|-<br />
| '''Sub Urban''' || 203.8173 || -46.5385 || 1001.8050<br />
|-<br />
| '''Wu Zi Mu's Betting place''' || -2159.9260 || 641.4587 || 1052.3820<br />
|-<br />
|}<br />
<br><br />
*'''ID 2:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ryder's House''' || 2464.2110 || -1697.9520 || 1013.5080<br />
|-<br />
| '''Angel Pine Trailer''' || 0.3440 || -0.5140 || 1000.5490ยจ<br />
|-<br />
| '''The Pig Pen''' || 1213.4330 ||-6.6830 || 1000.9220<br />
|-<br />
| '''BDups Crack Palace''' || 1523.7510 || -46.0458 || 1002.1310<br />
|-<br />
| '''Big Smoke's Crack Palace''' || 2543.6610 || -1303.9320 || 1025.0700<br />
|-<br />
| '''Burglary House 2''' || 225.756 || 1240.000 || 1082.149<br />
|-<br />
| '''Burglary House 3''' || 447.470 || 1398.348 || 1084.305<br />
|-<br />
| '''Burglary House 4''' || 491.740 || 1400.541 || 1080.265<br />
|-<br />
| '''Katie's Place''' || 267.2290 || 304.7100 || 999.1480<br />
|-<br />
| '''Loco Low Co.''' || 612.5910 || -75.6370 || 997.9920<br />
|-<br />
| '''Reece's Barbershop''' || 612.5910 || -75.6370 || 997.9920<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 3:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Jizzy's Pleasure Domes''' || -2636.7190 || 1402.9170 || 906.4609<br />
|-<br />
| '''Brothel''' || 940.6520 || -18.4860 || 1000.9300<br />
|-<br />
| '''Brothel 2''' || 967.5334 || -53.0245 || 1001.1250<br />
|-<br />
| '''BDups Apartment''' || 1527.38 || -11.02 || 1002.10 <br />
|-<br />
| '''Bike School''' || 1494.3350 || 1305.6510 || 1093.2890<br />
|-<br />
| '''Big Spread Ranch''' || 1210.2570 || -29.2986 || 1000.8790<br />
|-<br />
| '''LV Tattoo Parlour''' || -204.4390 || -43.6520 || 1002.2990<br />
|-<br />
| '''LVPD HQ''' || 289.7703 || 171.7460 || 1007.1790<br />
|-<br />
| '''OG Loc's House''' || 516.8890 || -18.4120 || 1001.5650<br />
|-<br />
| '''Pro-Laps''' || 207.3560 || -138.0029 || 1003.3130<br />
|-<br />
| '''Las Venturas Planning Dep.''' || 374.6708 || 173.8050 || 1008.3893<br />
|-<br />
| '''Record Label Hallway''' || 1038.2190 || 6.9905 || 1001.2840<br />
|-<br />
| '''Driving School''' || -2027.9200 || -105.1830 || 1035.1720<br />
|-<br />
| '''Johnson House''' || 2496.0500 || -1693.9260 || 1014.7420<br />
|-<br />
| '''Budget Inn Motel Room''' || <br />
|-<br />
| '''Burglary House 5''' || 234.733 || 1190.391 || 1080.258<br />
|-<br />
| '''Gay Gordo's Barbershop''' || 418.6530 || -82.6390 || 1001.8050<br />
|-<br />
| '''Helena's Place''' || 292.4459 || 308.7790 || 999.1484<br />
|-<br />
| '''Inside Track Betting''' || 826.8863 || 5.5091 || 1004.4830<br />
|-<br />
| '''Sex Shop''' || -106.7268 || -19.6444 || 1000.7190<br />
|-<br />
| '''Wheel Arch Angels''' || 614.3889 || -124.0991 || 997.9950<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 4:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 1''' || -27.3769 || -27.6416 || 1003.5570<br />
|-<br />
| '''Ammu-Nation 2''' || 285.8000 || -84.5470 || 1001.5390<br />
|-<br />
| '''Burglary House 6''' || -262.91 || 1454.966 || 1084.367<br />
|-<br />
| '''Burglary House 7''' || 221.4296 || 1142.423 || 1082.609<br />
|-<br />
| '''Burglary House 8''' || 261.1168 || 1286.519 || 1080.258<br />
|-<br />
| '''Diner 2''' || 460.0 || -88.43 || 999.62 <br />
|-<br />
| '''Dirtbike Stadium''' || -1435.8690 || -662.2505 || 1052.4650<br />
|-<br />
| '''Michelle's Place''' || 302.6404 || 304.8048 || 999.1484<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 5:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Madd Dogg's Mansion''' || 1272.9116 || -768.9028 || 1090.5097<br />
|-<br />
| '''Well Stacked Pizza Co.''' || 377.7758 || -126.2766 || 1001.4920<br />
|-<br />
| '''Victim''' || 221.3310 || -6.6169 || 1005.1977<br />
|-<br />
| '''Burning Desire House''' || 2351.1540 || -1180.5770 || 1027.9770<br />
|-<br />
| '''Barbara's Place''' || (Police Station??)<br />
|-<br />
| '''Burglary House 9''' || 22.79996 || 1404.642 || 1084.43<br />
|-<br />
| '''Burglary House 10''' || 228.9003 || 1114.477 || 1080.992<br />
|-<br />
| '''Burglary House 11''' || 140.5631 || 1369.051 || 1083.864<br />
|-<br />
| '''The Crack Den''' || 322.1117 || 1119.3270 || 1083.8830<br />
|-<br />
| '''Police Station (Barbara's)''' || 322.72 || 306.43 || 999.15<br />
|-<br />
| '''Diner 1''' || 448.7435 || -110.0457 || 1000.0772<br />
|-<br />
| '''Ganton Gym''' || 768.0793 || 5.8606 || 1000.7160<br />
|-<br />
| '''Vank Hoff Hotel ''' || 2232.8210 || -1110.0180 || 1050.8830<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 6:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-Nation 3''' || 297.4460 || -109.9680 || 1001.5160<br />
|-<br />
| '''Ammu-Nation 4''' || 317.2380 || -168.0520 || 999.5930<br />
|-<br />
| '''LSPD HQ ''' || 246.4510 || 65.5860 ||1003.6410<br />
|-<br />
| '''Safe House 3''' || 2333.0330 || -1073.9600 || 1049.0230<br />
|-<br />
| '''Safe House 5''' || 2194.2910 || -1204.0150 || 1049.0230<br />
|-<br />
| '''Safe House 6''' || 2308.8710 || -1210.7170 || 1049.0230<br />
|-<br />
| '''Cobra Marital Arts Gym''' || 774.0870 ||-47.9830 || 1000.5860<br />
|-<br />
| '''24/7 shop 2''' || -26.7180 || -55.9860 || 1003.5470<br />
|-<br />
| '''Millie's Bedroom''' || 344.5200 || 304.8210 || 999.1480<br />
|-<br />
| '''Fanny Batter's Brothel''' || 744.2710 || 1437.2530 || 1102.7030<br />
|-<br />
| '''Restaurant 2''' || 443.9810 || -65.2190 || 1050.0000<br />
|-<br />
| '''Burglary House 15''' || 234.319 || 1066.455 || 1084.208<br />
|-<br />
| '''Burglary House 16''' || -69.049 || 1354.056 || 1080.211<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 7:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-Nation 5 (2 Floors)''' || 315.3850 || -142.2420 || 999.6010<br />
|-<br />
| '''8-Track Stadium''' || -1417.8720 || -276.4260 || 1051.1910<br />
|-<br />
| '''Below the Belt Gym''' || 774.2430 || -76.0090 || 1000.6540<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 8:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Safe house 2''' || <br />
|-<br />
| '''Colonel Fuhrberger's House''' || 2807.8990 || -1172.9210 || 1025.5700<br />
|-<br />
| '''Burglary House 22''' || -42.490 || 1407.644 || 1084.43<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 9:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Unknown safe house''' || 2253.1740 || -1139.0100 || 1050.6330<br />
|-<br />
| '''Andromada Cargo hold''' || 315.48 || 984.13 || 1959.11<br />
|-<br />
| '''Burglary House 12''' || 85.32596 || 1323.585 || 1083.859<br />
|-<br />
| '''Burglary House 13''' || 260.3189 || 1239.663 || 1084.258<br />
|-<br />
| '''Cluckin' Bell''' || 365.67 || -11.61 || 1000.87<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 10:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Four Dragons Casino''' || 2009.4140 || 1017.8990 || 994.4680<br />
|-<br />
| '''RC Zero's Battlefield''' || -975.5766 || 1061.1312 || 1345.6719<br />
|-<br />
| '''Burger Shot''' || 366.4220 || -73.4700 || 1001.5080<br />
|-<br />
| '''Burglary House 14''' || 21.241 || 1342.153 || 1084.375 <br />
|-<br />
| '''Janitor room(Four Dragons Maintenance)''' || 1891.3960 ||1018.1260 || 31.8820<br />
|-<br />
| '''Safe House 1''' || <br />
|-<br />
| '''Hashbury safe house''' || 2264.5231 || -1210.5229 || 1049.0234<br />
|-<br />
| '''24/7 shop 3''' || 6.0780 || -28.6330 || 1003.5490<br />
|-<br />
| '''Abandoned AC Tower''' || 419.6140 || 2536.6030 || 10.0000<br />
|-<br />
| '''SFPD HQ''' || 246.4410 || 112.1640 || 1003.2190<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 11:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''The Four Dragons Office''' || 2011.6030 || 1017.0230 || 39.0910<br />
|-<br />
| '''Los Santos safe house''' || <br />
|-<br />
| '''Ten Green Bottles Bar''' || 502.3310 || -70.6820 || 998.7570<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 12:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Budget Inn Motel Room''' || <br />
|-<br />
| '''The Casino''' || 1132.9450 || -8.6750 || 1000.6800<br />
|-<br />
| '''Macisla's Barbershop''' || 411.6410 || -51.8460 || 1001.8980<br />
|-<br />
| '''Safe house 7''' || 2237.2970 || -1077.9250 || 1049.0230<br />
|-<br />
| '''Modern safe house''' || 2324.4990 || -1147.0710 || 1050.7100<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 13:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
|'''LS Atrium''' || 1724.33 || -1625.784 || 20.211<br />
|-<br />
|'''CJ's Garage''' || -2043.966 || 172.932 || 28.835<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 14:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Kickstart Stadium''' || -1464.5360 || 1557.6900 || 1052.5310<br />
|-<br />
| '''Didier Sachs''' || 204.1789 || -165.8740 || 1000.5230<br />
|-<br />
| '''Francis Int. Airport (Front ext.)''' || -1827.1473 || 7.2074 || 1061.1435<br />
|-<br />
| '''Francis Int. Airport (Baggage Claim/Ticket Sales)''' || -1855.5687 || 41.2631 || 1061.1435<br />
|-<br />
| '''Wardrobe''' || 255.7190 || -41.1370 || 1002.0230<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 15:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Binco''' || 207.5430 || -109.0040 || 1005.1330<br />
|-<br />
| '''Blood Bowl Stadium''' || -1394.20 || 987.62 || 1023.96<br />
|-<br />
| '''Jefferson Motel''' || 2217.6250 || -1150.6580 || 1025.7970<br />
|-<br />
| '''Burglary House 17''' || -285.711 || 1470.697 || 1084.375<br />
|-<br />
| '''Burglary House 18''' || 327.808 || 1479.74 || 1084.438<br />
|-<br />
| '''Burglary House 19''' || 375.572 || 1417.439 || 1081.328<br />
|-<br />
| '''Burglary House 20''' || 384.644 || 1471.479 || 1080.195<br />
|-<br />
| '''Burglary House 21''' || 295.467 || 1474.697 || 1080.258<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 16:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 4''' || -25.3730 || -139.6540 || 1003.5470<br />
|-<br />
| '''LS Tattoo Parlour''' || -204.5580 || -25.6970 || 1002.2730<br />
|-<br />
| '''Sumoring? stadium''' || -1400 || 1250 || 1040 <br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 17:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 5''' || -25.3930 || -185.9110 || 1003.5470<br />
|-<br />
| '''Club''' || 493.4687 || -23.0080 || 1000.6796<br />
|-<br />
| '''Rusty Brown's - Ring Donuts''' || 377.0030 || -192.5070 || 1000.6330<br />
|-<br />
| '''The Sherman's Dam Generator Hall''' || -942.1320 || 1849.1420 || 5.0050<br />
|-<br />
| '''Hemlock Tattoo''' || 377.0030 || -192.5070 || 1000.6330<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 18:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Lil Probe Inn''' || -227.0280 || 1401.2290 || 27.7690<br />
|-<br />
| '''24/7 shop 6''' || -30.9460 || -89.6090 || 1003.5490<br />
|-<br />
| '''Atrium''' || 1726.1370 || -1645.2300 || 20.2260<br />
|-<br />
| '''Warehouse 2''' || 1296.6310 || 0.5920 || 1001.0230<br />
|-<br />
| '''Zip''' || 161.4620 || -91.3940 || 1001.8050<br />
|-<br />
|}<br />
<br />
<br><br />
==See Also==<br />
[[id|ID Lists]]<br />
[[setElementInterior]]<br />
[[getElementInterior]]<br />
[[Category:Scripting Concepts]]<br />
[[Category:ID Lists]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Interior_IDs&diff=30051Interior IDs2012-04-22T16:08:18Z<p>John: Undo revision 30050 by Jaysds (talk)</p>
<hr />
<div>San Andreas Interior ID list.<br />
<br><br />
<br><br />
*'''ID 0:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Normal world''' || <br />
|-<br />
|}<br />
<br><br />
*'''ID 1:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-nation 1''' || 289.7870 || -35.7190 || 1003.5160<br />
|-<br />
| '''Burglary House 1''' || 224.6351 || 1289.012 || 1082.141 <br />
|-<br />
| '''The Wellcome Pump (Catalina?)''' || 681.65 || -452.86 || -25.62<br />
|-<br />
| '''Restaurant 1''' || 446.6941 || -9.7977 || 1000.7340<br />
|-<br />
| '''Caligulas Casino''' || 2235.2524 || 1708.5146 || 1010.6129<br />
|-<br />
| '''Denise's Place''' || 244.0892 || 304.8456 || 999.1484<br />
|-<br />
| '''Shamal cabin''' || 1.6127 || 34.7411 || 1199.0<br />
|-<br />
| '''Liberty City''' || -750.80 || 491.00 || 1371.70<br />
|-<br />
| '''Sweet's House''' || 2525.0420 || -1679.1150 || 1015.4990<br />
|-<br />
| '''Transfender''' || 621.7850 || -12.5417 || 1000.9220<br />
|-<br />
| '''Safe House 4''' || 2216.5400 || -1076.2900 || 1050.4840<br />
|-<br />
| '''Trials(Hyman Memorial?) Stadium''' || -1401.13 || 106.110 || 1032.273<br />
|-<br />
| '''Warehouse 1''' || 1405.3120 || -8.2928 || 1000.9130<br />
|-<br />
| '''Doherty Garage''' || -2042.42 || 178.59 || 28.84 || <br />
|-<br />
| '''Sindacco Abatoir''' || 963.6078 || 2108.3970 || 1011.0300<br />
|-<br />
| '''Sub Urban''' || 203.8173 || -46.5385 || 1001.8050<br />
|-<br />
| '''Wu Zi Mu's Betting place''' || -2159.9260 || 641.4587 || 1052.3820<br />
|-<br />
|}<br />
<br><br />
*'''ID 2:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ryder's House''' || 2464.2110 || -1697.9520 || 1013.5080<br />
|-<br />
| '''Angel Pine Trailer''' || 0.3440 || -0.5140 || 1000.5490ยจ<br />
|-<br />
| '''The Pig Pen''' || 1213.4330 ||-6.6830 || 1000.9220<br />
|-<br />
| '''BDups Crack Palace''' || 1523.7510 || -46.0458 || 1002.1310<br />
|-<br />
| '''Big Smoke's Crack Palace''' || 2543.6610 || -1303.9320 || 1025.0700<br />
|-<br />
| '''Burglary House 2''' || 225.756 || 1240.000 || 1082.149<br />
|-<br />
| '''Burglary House 3''' || 447.470 || 1398.348 || 1084.305<br />
|-<br />
| '''Burglary House 4''' || 491.740 || 1400.541 || 1080.265<br />
|-<br />
| '''Katie's Place''' || 267.2290 || 304.7100 || 999.1480<br />
|-<br />
| '''Loco Low Co.''' || 612.5910 || -75.6370 || 997.9920<br />
|-<br />
| '''Reece's Barbershop''' || 612.5910 || -75.6370 || 997.9920<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 3:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Jizzy's Pleasure Domes''' || -2636.7190 || 1402.9170 || 906.4609<br />
|-<br />
| '''Brothel''' || 940.6520 || -18.4860 || 1000.9300<br />
|-<br />
| '''Brothel 2''' || 967.5334 || -53.0245 || 1001.1250<br />
|-<br />
| '''BDups Apartment''' || 1527.38 || -11.02 || 1002.10 <br />
|-<br />
| '''Bike School''' || 1494.3350 || 1305.6510 || 1093.2890<br />
|-<br />
| '''Big Spread Ranch''' || 1210.2570 || -29.2986 || 1000.8790<br />
|-<br />
| '''LV Tattoo Parlour''' || -204.4390 || -43.6520 || 1002.2990<br />
|-<br />
| '''LVPD HQ''' || 289.7703 || 171.7460 || 1007.1790<br />
|-<br />
| '''OG Loc's House''' || 516.8890 || -18.4120 || 1001.5650<br />
|-<br />
| '''Pro-Laps''' || 207.3560 || -138.0029 || 1003.3130<br />
|-<br />
| '''Las Venturas Planning Dep.''' || 374.6708 || 173.8050 || 1008.3893<br />
|-<br />
| '''Record Label Hallway''' || 1038.2190 || 6.9905 || 1001.2840<br />
|-<br />
| '''Driving School''' || -2027.9200 || -105.1830 || 1035.1720<br />
|-<br />
| '''Johnson House''' || 2496.0500 || -1693.9260 || 1014.7420<br />
|-<br />
| '''Budget Inn Motel Room''' || <br />
|-<br />
| '''Burglary House 5''' || 234.733 || 1190.391 || 1080.258<br />
|-<br />
| '''Gay Gordo's Barbershop''' || 418.6530 || -82.6390 || 1001.8050<br />
|-<br />
| '''Helena's Place''' || 292.4459 || 308.7790 || 999.1484<br />
|-<br />
| '''Inside Track Betting''' || 826.8863 || 5.5091 || 1004.4830<br />
|-<br />
| '''Sex Shop''' || -106.7268 || -19.6444 || 1000.7190<br />
|-<br />
| '''Wheel Arch Angels''' || 614.3889 || -124.0991 || 997.9950<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 4:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 1''' || -27.3769 || -27.6416 || 1003.5570<br />
|-<br />
| '''Ammu-Nation 2''' || 285.8000 || -84.5470 || 1001.5390<br />
|-<br />
| '''Burglary House 6''' || -262.91 || 1454.966 || 1084.367<br />
|-<br />
| '''Burglary House 7''' || 221.4296 || 1142.423 || 1082.609<br />
|-<br />
| '''Burglary House 8''' || 261.1168 || 1286.519 || 1080.258<br />
|-<br />
| '''Diner 2''' || 460.0 || -88.43 || 999.62 <br />
|-<br />
| '''Dirtbike Stadium''' || -1435.8690 || -662.2505 || 1052.4650<br />
|-<br />
| '''Michelle's Place''' || 302.6404 || 304.8048 || 999.1484<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 5:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Madd Dogg's Mansion''' || 1272.9116 || -768.9028 || 1090.5097<br />
|-<br />
| '''Well Stacked Pizza Co.''' || 377.7758 || -126.2766 || 1001.4920<br />
|-<br />
| '''Victim''' || 221.3310 || -6.6169 || 1005.1977<br />
|-<br />
| '''Burning Desire House''' || 2351.1540 || -1180.5770 || 1027.9770<br />
|-<br />
| '''Barbara's Place''' || (Police Station??)<br />
|-<br />
| '''Burglary House 9''' || 22.79996 || 1404.642 || 1084.43<br />
|-<br />
| '''Burglary House 10''' || 228.9003 || 1114.477 || 1080.992<br />
|-<br />
| '''Burglary House 11''' || 140.5631 || 1369.051 || 1083.864<br />
|-<br />
| '''The Crack Den''' || 322.1117 || 1119.3270 || 1083.8830<br />
|-<br />
| '''Police Station (Barbara's)''' || 322.72 || 306.43 || 999.15<br />
|-<br />
| '''Diner 1''' || 448.7435 || -110.0457 || 1000.0772<br />
|-<br />
| '''Ganton Gym''' || 768.0793 || 5.8606 || 1000.7160<br />
|-<br />
| '''Vank Hoff Hotel ''' || 2232.8210 || -1110.0180 || 1050.8830<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 6:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-Nation 3''' || 297.4460 || -109.9680 || 1001.5160<br />
|-<br />
| '''Ammu-Nation 4''' || 317.2380 || -168.0520 || 999.5930<br />
|-<br />
| '''LSPD HQ ''' || 246.4510 || 65.5860 ||1003.6410<br />
|-<br />
| '''Safe House 3''' || 2333.0330 || -1073.9600 || 1049.0230<br />
|-<br />
| '''Safe House 5''' || 2194.2910 || -1204.0150 || 1049.0230<br />
|-<br />
| '''Safe House 6''' || 2308.8710 || -1210.7170 || 1049.0230<br />
|-<br />
| '''Cobra Marital Arts Gym''' || 774.0870 ||-47.9830 || 1000.5860<br />
|-<br />
| '''24/7 shop 2''' || -26.7180 || -55.9860 || 1003.5470<br />
|-<br />
| '''Millie's Bedroom''' || 344.5200 || 304.8210 || 999.1480<br />
|-<br />
| '''Fanny Batter's Brothel''' || 744.2710 || 1437.2530 || 1102.7030<br />
|-<br />
| '''Restaurant 2''' || 443.9810 || -65.2190 || 1050.0000<br />
|-<br />
| '''Burglary House 15''' || 234.319 || 1066.455 || 1084.208<br />
|-<br />
| '''Burglary House 16''' || -69.049 || 1354.056 || 1080.211<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 7:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Ammu-Nation 5 (2 Floors)''' || 315.3850 || -142.2420 || 999.6010<br />
|-<br />
| '''8-Track Stadium''' || -1417.8720 || -276.4260 || 1051.1910<br />
|-<br />
| '''Below the Belt Gym''' || 774.2430 || -76.0090 || 1000.6540<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 8:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Safe house 2''' || <br />
|-<br />
| '''Colonel Fuhrberger's House''' || 2807.8990 || -1172.9210 || 1025.5700<br />
|-<br />
| '''Burglary House 22''' || -42.490 || 1407.644 || 1084.43<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 9:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Unknown safe house''' || 2253.1740 || -1139.0100 || 1050.6330<br />
|-<br />
| '''Andromada Cargo hold''' || 315.48 || 984.13 || 1959.11<br />
|-<br />
| '''Burglary House 12''' || 85.32596 || 1323.585 || 1083.859<br />
|-<br />
| '''Burglary House 13''' || 260.3189 || 1239.663 || 1084.258<br />
|-<br />
| '''Cluckin' Bell''' || 365.67 || -11.61 || 1000.87<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 10:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Four Dragons Casino''' || 2009.4140 || 1017.8990 || 994.4680<br />
|-<br />
| '''RC Zero's Battlefield''' || -975.5766 || 1061.1312 || 1345.6719<br />
|-<br />
| '''Burger Shot''' || 366.4220 || -73.4700 || 1001.5080<br />
|-<br />
| '''Burglary House 14''' || 21.241 || 1342.153 || 1084.375 <br />
|-<br />
| '''Janitor room(Four Dragons Maintenance)''' || 1891.3960 ||1018.1260 || 31.8820<br />
|-<br />
| '''Safe House 1''' || <br />
|-<br />
| '''Hashbury safe house''' || 2264.5231 || -1210.5229 || 1049.0234<br />
|-<br />
| '''24/7 shop 3''' || 6.0780 || -28.6330 || 1003.5490<br />
|-<br />
| '''Abandoned AC Tower''' || 419.6140 || 2536.6030 || 10.0000<br />
|-<br />
| '''SFPD HQ''' || 246.4410 || 112.1640 || 1003.2190<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 11:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''The Four Dragons Office''' || 2011.6030 || 1017.0230 || 39.0910<br />
|-<br />
| '''Los Santos safe house''' || <br />
|-<br />
| '''Ten Green Bottles Bar''' || 502.3310 || -70.6820 || 998.7570<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 12:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Budget Inn Motel Room''' || <br />
|-<br />
| '''The Casino''' || 1132.9450 || -8.6750 || 1000.6800<br />
|-<br />
| '''Macisla's Barbershop''' || 411.6410 || -51.8460 || 1001.8980<br />
|-<br />
| '''Safe house 7''' || 2237.2970 || -1077.9250 || 1049.0230<br />
|-<br />
| '''Modern safe house''' || 2324.4990 || -1147.0710 || 1050.7100<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 13:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
|'''LS Atrium''' || 1724.33 || -1625.784 || 20.211<br />
|-<br />
|'''CJ's Garage''' || -2043.966 || 172.932 || 28.835<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 14:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Kickstart Stadium''' || -1464.5360 || 1557.6900 || 1052.5310<br />
|-<br />
| '''Didier Sachs''' || 204.1789 || -165.8740 || 1000.5230<br />
|-<br />
| '''Francis Int. Airport (Front ext.)''' || -1827.1473 || 7.2074 || 1061.1435<br />
|-<br />
| '''Francis Int. Airport (Baggage Claim/Ticket Sales)''' || -1855.5687 || 41.2631 || 1061.1435<br />
|-<br />
| '''Wardrobe''' || 255.7190 || -41.1370 || 1002.0230<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 15:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Binco''' || 207.5430 || -109.0040 || 1005.1330<br />
|-<br />
| '''Blood Bowl Stadium''' || -1394.20 || 987.62 || 1023.96<br />
|-<br />
| '''Jefferson Motel''' || 2217.6250 || -1150.6580 || 1025.7970<br />
|-<br />
| '''Burglary House 17''' || -285.711 || 1470.697 || 1084.375<br />
|-<br />
| '''Burglary House 18''' || 327.808 || 1479.74 || 1084.438<br />
|-<br />
| '''Burglary House 19''' || 375.572 || 1417.439 || 1081.328<br />
|-<br />
| '''Burglary House 20''' || 384.644 || 1471.479 || 1080.195<br />
|-<br />
| '''Burglary House 21''' || 295.467 || 1474.697 || 1080.258<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 16:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 4''' || -25.3730 || -139.6540 || 1003.5470<br />
|-<br />
| '''LS Tattoo Parlour''' || -204.5580 || -25.6970 || 1002.2730<br />
|-<br />
| '''Sumoring? stadium''' || -1400 || 1250 || 1040 <br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 17:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''24/7 shop 5''' || -25.3930 || -185.9110 || 1003.5470<br />
|-<br />
| '''Club''' || 493.4687 || -23.0080 || 1000.6796<br />
|-<br />
| '''Rusty Brown's - Ring Donuts''' || 377.0030 || -192.5070 || 1000.6330<br />
|-<br />
| '''The Sherman's Dam Generator Hall''' || -942.1320 || 1849.1420 || 5.0050<br />
|-<br />
| '''Hemlock Tattoo''' || 377.0030 || -192.5070 || 1000.6330<br />
|-<br />
|}<br />
<br />
<br><br />
*'''ID 18:'''<br />
{| class="prettytable" style="width:50%;"<br />
|-<br />
| '''Lil Probe Inn''' || -227.0280 || 1401.2290 || 27.7690<br />
|-<br />
| '''24/7 shop 6''' || -30.9460 || -89.6090 || 1003.5490<br />
|-<br />
| '''Atrium''' || 1726.1370 || -1645.2300 || 20.2260<br />
|-<br />
| '''Warehouse 2''' || 1296.6310 || 0.5920 || 1001.0230<br />
|-<br />
| '''Zip''' || 161.4620 || -91.3940 || 1001.8050<br />
|-<br />
|}<br />
<br />
<br><br />
==See Also==<br />
[[id|ID Lists]]<br />
[[Category:Scripting Concepts]]<br />
[[Category:ID Lists]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientRender&diff=29999OnClientRender2012-04-20T02:41:07Z<p>John: Added a link to the game processing order page.</p>
<hr />
<div>__NOTOC__<br />
{{Client event}} <br />
This event is triggered every time GTA renders a new frame. It is required for the DirectX drawing functions, and also useful for other clientside operations that have to be applied repeatedly with very short time differences between them.<br />
<br />
==Parameters==<br />
''None''<br />
<br />
==Source==<br />
The [[event system#Event source|source]] of this event is the client's [[root element]].<br />
<br />
==Example==<br />
This example makes the camera follow the player in a GTA2-like way. This will be a little bit laggy. If you want the camera to follow something (eg. player or vehicle) then use [[onClientPreRender]] instead.<br />
<syntaxhighlight lang="lua"><br />
root = getRootElement ()<br />
function updateCamera ()<br />
local x, y, z = getElementPosition ( getLocalPlayer () )<br />
setCameraMatrix ( x, y, z + 50, x, y, z )<br />
end<br />
addEventHandler ( "onClientRender", root, updateCamera )<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===[[Game_Processing_Order|Game Processing Order]]===<br />
===Other client events===<br />
{{Client_other_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientHUDRender&diff=29998OnClientHUDRender2012-04-20T02:40:36Z<p>John: Added a link to the game processing order page.</p>
<hr />
<div>__NOTOC__<br />
{{Client event}} <br />
This event is triggered before GTA renders the HUD. This is particularly useful if you want to use [[dxUpdateScreenSource]] to capture the screen onto a texture without capturing the HUD, or to alter HUD textures using [[Element/Shader|shaders]] before they are drawn onto the screen.<br />
<br />
==Parameters==<br />
''None''<br />
<br />
==Source==<br />
The [[event system#Event source|source]] of this event is the client's [[root element]].<br />
<br />
==Example==<br />
<syntaxhighlight lang="lua"><br />
-- TODO<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===[[Game_Processing_Order|Game Processing Order]]===<br />
===Other client events===<br />
{{Client_other_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}<br />
<br />
[[Category:Needs Example]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientPreRender&diff=29997OnClientPreRender2012-04-20T02:40:07Z<p>John: Added a link to the game processing order page.</p>
<hr />
<div>__NOTOC__<br />
{{Client event}} <br />
This event is triggered every time before GTA renders a new frame.<br />
<br />
==Parameters==<br />
<syntaxhighlight lang="lua"><br />
float timeSlice<br />
</syntaxhighlight><br />
*'''timeSlice:''' The interval between this frame and the previous one in milliseconds.<br />
<br />
==Source==<br />
The [[event system#Event source|source]] of this event is the client's [[root element]].<br />
<br />
==Example==<br />
This example makes the camera follow the player in a GTA2-like way.<br />
<syntaxhighlight lang="lua"><br />
root = getRootElement ()<br />
function updateCamera ()<br />
local x, y, z = getElementPosition ( getLocalPlayer () )<br />
setCameraMatrix ( x, y, z + 50, x, y, z )<br />
end<br />
addEventHandler ( "onClientPreRender", root, updateCamera )<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===[[Game_Processing_Order|Game Processing Order]]===<br />
===Other client events===<br />
{{Client_other_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=SetWindVelocity&diff=29983SetWindVelocity2012-04-18T20:58:36Z<p>John: </p>
<hr />
<div>__NOTOC__<br />
{{Server client function}}<br />
This function changes the wind velocity.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
bool setWindVelocity ( float velocityX, float velocityY, float velocityZ )<br />
</syntaxhighlight><br />
<br />
===Required Arguments===<br />
*'''velocityX''': The velocity of the wind along the x axis<br />
*'''velocityY''': The velocity of the wind along the y axis<br />
*'''velocityZ''': The velocity of the wind along the z axis<br />
<br />
===Returns===<br />
Returns ''true'' if successful, ''false'' otherwise.<br />
<br />
==Example==<br />
<section name="Client" class="client" show="true"><br />
This example shows how to make a simple /windVelocity command.<br />
<syntaxhighlight lang="lua"><br />
local function windVelocityCommand(_, x, y, z)<br />
-- Ensure all arguments are valid (default to 0 otherwise)<br />
x = tonumber(x) or 0<br />
y = tonumber(y) or 0<br />
z = tonumber(z) or 0<br />
<br />
-- Set the wind velocity, and inform the user of the change.<br />
setWindVelocity(x, y, z)<br />
outputChatBox("* Wind velocity set to ("..x..", "..y..", "..z..").", 0, 255, 0)<br />
end<br />
addCommandHandler("windVelocity", windVelocityCommand)<br />
</syntaxhighlight><br />
</section><br />
<br />
==See Also==<br />
{{Client_world_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=SetWindVelocity&diff=29982SetWindVelocity2012-04-18T20:58:07Z<p>John: Cleaned up the grammar & example.</p>
<hr />
<div>__NOTOC__<br />
{{Server client function}}<br />
This function changes the wind velocity.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
bool setWindVelocity ( float velocityX, float velocityY, float velocityZ )<br />
</syntaxhighlight><br />
<br />
===Required Arguments===<br />
*'''velocityX''': The velocity of the wind along the x axis<br />
*'''velocityY''': The velocity of the wind along the y axis<br />
*'''velocityZ''': The velocity of the wind along the z axis<br />
<br />
===Returns===<br />
Returns ''true'' if successful, ''false'' otherwise.<br />
<br />
==Example==<br />
This example shows how to make a simple /windVelocity command.<br />
<section name="Client" class="client" show="true"><br />
<syntaxhighlight lang="lua"><br />
local function windVelocityCommand(_, x, y, z)<br />
-- Ensure all arguments are valid (default to 0 otherwise)<br />
x = tonumber(x) or 0<br />
y = tonumber(y) or 0<br />
z = tonumber(z) or 0<br />
<br />
-- Set the wind velocity, and inform the user of the change.<br />
setWindVelocity(x, y, z)<br />
outputChatBox("* Wind velocity set to ("..x..", "..y..", "..z..").", 0, 255, 0)<br />
end<br />
addCommandHandler("windVelocity", windVelocityCommand)<br />
</syntaxhighlight><br />
</section><br />
<br />
==See Also==<br />
{{Client_world_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientPlayerPickupHit&diff=29658OnClientPlayerPickupHit2012-03-19T03:41:31Z<p>John: Typo</p>
<hr />
<div>{{Client event}}<br />
__NOTOC__<br />
This event triggers whenever a player hits a pickup locally.<br />
<br />
==Parameters==<br />
<syntaxhighlight lang="lua"><br />
pickup thePickup, bool matchingDimension<br />
</syntaxhighlight><br />
*'''thePickup:''' the pickup that was hit.<br />
*'''matchingDimension:''' ''true'' if thePickup is in the same dimension as the player, ''false'' otherwise.<br />
<br />
==Source==<br />
The source of this event is the player that hit the pickup.<br />
<br />
==Example== <br />
This example outputs a message whenever the local player hits a pickup.<br />
<syntaxhighlight lang="lua"><br />
local function clientPlayerPickupHit(thePickup, matchingDimension)<br />
outputChatBox("* You have hit a pickup!", 255, 0, 0)<br />
end<br />
addEventHandler("onClientPlayerPickupHit", localPlayer, clientPlayerPickupHit)<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===Client pickup events===<br />
{{Client_pickup_events}}<br />
===Client player events===<br />
{{Client_player_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Template:Client_player_events&diff=29657Template:Client player events2012-03-19T03:40:51Z<p>John: Added new player pickup events.</p>
<hr />
<div>*[[onClientPlayerJoin]]<br />
*[[onClientPlayerQuit]]<br />
*[[onClientPlayerWeaponFire]]<br />
*[[onClientPlayerWeaponSwitch]]<br />
*[[onClientPlayerTarget]]<br />
*[[onClientPlayerDamage]]<br />
*[[onClientPlayerSpawn]]<br />
*[[onClientPlayerWasted]]<br />
*[[onClientPlayerVehicleEnter]]<br />
*[[onClientPlayerVehicleExit]]<br />
*[[onClientPlayerChangeNick]]<br />
*[[onClientPlayerStuntStart]]<br />
*[[onClientPlayerStuntFinish]]<br />
{{New items|3|1.0|<br />
*[[onClientPlayerChoke]]<br />
*[[onClientPlayerRadioSwitch]]<br />
}}<br />
{{New items|3.0004|1.0.4|<br />
*[[onClientPlayerStealthKill]]<br />
}}<br />
{{New items|3.0110|1.1|<br />
*[[onClientPlayerVoiceStart]]<br />
*[[onClientPlayerVoiceStop]]<br />
}}<br />
{{New items|3.0152|1.3.1|<br />
* [[onClientPlayerHeliKilled]]<br />
* [[onClientPlayerPickupHit]]<br />
* [[onClientPlayerPickupLeave]]<br />
}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientPlayerPickupHit&diff=29656OnClientPlayerPickupHit2012-03-19T03:38:19Z<p>John: Documented onClientPlayerPickupHit</p>
<hr />
<div>{{Client event}}<br />
__NOTOC__<br />
This event triggers whenever a player hits a pickup locally.<br />
<br />
==Parameters==<br />
<syntaxhighlight lang="lua"><br />
pickup thePickup, bool matchingDimension<br />
</syntaxhighlight><br />
*'''thePickup:''' the pickup that was hit.<br />
*'''matchingDimension:''' ''true'' if thePickup is in the same dimension as the player, ''false'' otherwise.<br />
<br />
==Source==<br />
The source of this event is the player that hit the pickup.<br />
<br />
==Example== <br />
This example outputs a message whenever the local player hits a pickup.<br />
<syntaxhighlight lang="lua"><br />
local function clientPlayerPickupHit(thePickup, matchingDimension)<br />
outputChatBox("* You have hit a pickup!", 255, 0, 0)<br />
end<br />
addEventHandler("onClientPlayerPickupHit", root, clientPlayerPickupHit)<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===Client pickup events===<br />
{{Client_pickup_events}}<br />
===Client player events===<br />
{{Client_player_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientPlayerPickupLeave&diff=29655OnClientPlayerPickupLeave2012-03-19T03:36:25Z<p>John: Typo</p>
<hr />
<div>{{Client event}}<br />
__NOTOC__<br />
This event triggers whenever a player leaves pickup locally.<br />
<br />
==Parameters==<br />
<syntaxhighlight lang="lua"><br />
pickup thePickup, bool matchingDimension<br />
</syntaxhighlight><br />
*'''thePickup:''' the pickup that was left.<br />
*'''matchingDimension:''' ''true'' if thePickup is in the same dimension as the player, ''false'' otherwise.<br />
<br />
==Source==<br />
The source of this event is the player that left the pickup.<br />
<br />
==Example== <br />
This example outputs a message whenever the local player leaves a pickup.<br />
<syntaxhighlight lang="lua"><br />
local function clientPlayerPickupLeave(thePickup, matchingDimension)<br />
outputChatBox("* You have left a pickup!", 255, 0, 0)<br />
end<br />
addEventHandler("onClientPlayerPickupLeave", localPlayer, clientPlayerPickupLeave)<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===Client pickup events===<br />
{{Client_pickup_events}}<br />
===Client player events===<br />
{{Client_player_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientPlayerPickupLeave&diff=29654OnClientPlayerPickupLeave2012-03-19T03:32:47Z<p>John: Documented onClientPlayerPickupLeave</p>
<hr />
<div>{{Client event}}<br />
__NOTOC__<br />
This event triggers whenever a player leaves pickup locally.<br />
<br />
==Parameters==<br />
<syntaxhighlight lang="lua"><br />
player thePickup, bool matchingDimension<br />
</syntaxhighlight><br />
*'''thePickup:''' the pickup that was left.<br />
*'''matchingDimension:''' ''true'' if thePickup is in the same dimension as the player, ''false'' otherwise.<br />
<br />
==Source==<br />
The source of this event is the player that left the pickup.<br />
<br />
==Example== <br />
This example outputs a message whenever the local player leaves a pickup.<br />
<syntaxhighlight lang="lua"><br />
local function clientPlayerPickupLeave(thePickup, matchingDimension)<br />
outputChatBox("* You have left a pickup!", 255, 0, 0)<br />
end<br />
addEventHandler("onClientPlayerPickupLeave", localPlayer, clientPlayerPickupLeave)<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===Client pickup events===<br />
{{Client_pickup_events}}<br />
===Client player events===<br />
{{Client_player_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Client_Scripting_Events&diff=29652Client Scripting Events2012-03-18T06:57:07Z<p>John: Added pickup events to the list</p>
<hr />
<div><pageclass class="client"></pageclass><br />
This page lists all '''client-side''' scripting [[event]]s that have been implemented and are available in the Deathmatch mod. To request a function or event, use [[Requested Functions and Events]].<br />
<br />
'''Server-side scripting events can be found here: [[Server Scripting Events]]<br />
<br />
==Colshape events==<br />
{{Client_colshape_events}}<br />
<br />
==Element events==<br />
{{Client_element_events}}<br />
<br />
==GUI events==<br />
{{GUI_events}}<br />
<br />
==Marker events==<br />
{{Client_marker_events}}<br />
<br />
==Ped events==<br />
{{Client_ped_events}}<br />
<br />
==Pickup events==<br />
{{Client_pickup_events}}<br />
<br />
==Player events==<br />
{{Client_player_events}}<br />
<br />
==Projectile events==<br />
{{Client_projectile_events}}<br />
<br />
==Resource events==<br />
{{Client_resource_events}}<br />
<br />
==Sound events==<br />
{{Sound_events}}<br />
<br />
==Vehicle events==<br />
{{Client_vehicle_events}}<br />
<br />
==Other events==<br />
{{Client_other_events}}<br />
<br />
[[pl:Zdarzenia_po_stronie_klienta]]<br />
[[ru:Client Scripting Events]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientPickupLeave&diff=29651OnClientPickupLeave2012-03-18T06:53:13Z<p>John: Documented onClientPickupLeave</p>
<hr />
<div>{{Client event}}<br />
__NOTOC__<br />
This event triggers whenever a pickup is left clientside.<br />
<br />
==Parameters==<br />
<syntaxhighlight lang="lua"><br />
player thePlayer, bool matchingDimension<br />
</syntaxhighlight><br />
*'''thePlayer:''' the player that left the pickup<br />
*'''matchingDimension:''' ''true'' if thePlayer is in the same dimension as the pickup, ''false'' otherwise.<br />
<br />
==Source==<br />
The source of this event is the pickup that was left.<br />
<br />
==Example== <br />
This example outputs a message whenever a player leaves a pickup locally.<br />
<syntaxhighlight lang="lua"><br />
local function clientPickupLeave(thePlayer, matchingDimension)<br />
outputChatBox("* "..getPlayerName(thePlayer).." left a pickup!", 255, 0, 0)<br />
end<br />
addEventHandler("onClientPickupLeave", root, clientPickupLeave)<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===Client pickup events===<br />
{{Client_pickup_events}}<br />
===Client player events===<br />
{{Client_player_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Template:Client_pickup_events&diff=29650Template:Client pickup events2012-03-18T06:51:14Z<p>John: Added client pickup event template</p>
<hr />
<div>*[[onClientPickupHit]]<br />
*[[onClientPickupLeave]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=OnClientPickupHit&diff=29649OnClientPickupHit2012-03-18T06:49:59Z<p>John: Documented onClientPickupHit</p>
<hr />
<div>{{Client event}}<br />
__NOTOC__<br />
This event triggers whenever a pickup is hit clientside.<br />
<br />
==Parameters==<br />
<syntaxhighlight lang="lua"><br />
player thePlayer, bool matchingDimension<br />
</syntaxhighlight><br />
*'''thePlayer:''' the player that hit the pickup<br />
*'''matchingDimension:''' ''true'' if thePlayer is in the same dimension as the pickup, ''false'' otherwise.<br />
<br />
==Source==<br />
The source of this event is the pickup that was hit.<br />
<br />
==Example== <br />
This example outputs a message whenever a player hits a pickup locally.<br />
<syntaxhighlight lang="lua"><br />
local function clientPickupHit(thePlayer, matchingDimension)<br />
outputChatBox("* "..getPlayerName(thePlayer).." hit a pickup!", 255, 0, 0)<br />
end<br />
addEventHandler("onClientPickupHit", root, clientPickupHit)<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
===Client pickup events===<br />
{{Client_pickup_events}}<br />
===Client player events===<br />
{{Client_player_events}}<br />
===Client event functions===<br />
{{Client_event_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=Tocolor&diff=29588Tocolor2012-03-06T02:14:32Z<p>John: Added a proper example</p>
<hr />
<div>__NOTOC__ <br />
{{Client function}} <br />
This function retrieves the hex number of a specified color, useful for the dx functions.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
int tocolor ( int red, int green, int blue [, int alpha = 255] )<br />
</syntaxhighlight><br />
<br />
===Required Arguments=== <br />
* '''red:''' The amount of [http://en.wikipedia.org/wiki/RGBA_color_space red] in the color (0-255).<br />
* '''green:''' The amount of [http://en.wikipedia.org/wiki/RGBA_color_space green] in the color (0-255).<br />
* '''blue:''' The amount of [http://en.wikipedia.org/wiki/RGBA_color_space blue] in the color (0-255).<br />
<br />
===Optional Arguments===<br />
* '''alpha:''' The amount of [http://en.wikipedia.org/wiki/RGBA_color_space alpha] in the color (0-255).<br />
<br />
===Returns===<br />
Returns a single value representing the color.<br />
<br />
==Example== <br />
This example displays the text "Tuna" in small at the top left side of your screen. The color of this text can be changed using the command /tunaColor.<br />
<syntaxhighlight lang="lua"><br />
local tunaColor = tocolor(255, 0, 0, 255) -- Default color<br />
<br />
-- This function draws the text<br />
local function drawTuna()<br />
dxDrawText("Tuna", 5, 5, 100, 100, tunaColor)<br />
end<br />
addEventHandler("onClientRender", root, drawTuna)<br />
<br />
--This function handles the /tunaColor command, allowing players to set the color of tuna<br />
local function tunaColorCommand(command, red, green, blue, alpha)<br />
red, green, blue, alpha = tonumber(red), tonumber(green), tonumber(blue), tonumber(alpha) -- Convert all the args to numbers. NOTE: tonumber will return false if the arg is not provided/is not valid.<br />
<br />
-- Remind the user of the proper syntax if they failed to provide all the args<br />
if not red or not green or not blue then<br />
outputChatBox("* USAGE: /tunaColor [red] [green] [blue] [alpha]", 255, 0, 0)<br />
return<br />
end<br />
<br />
-- Make the alpha arg optional<br />
if not alpha then<br />
alpha = 255<br />
end<br />
<br />
-- Update the color<br />
tunaColor = tocolor(red, green, blue, alpha)<br />
end<br />
addCommandHandler("tunaColor", tunaColorCommand)<br />
-- Example /setcoloroftuna 255 0 0 255 - for red.<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
{{Client_utility_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=DxDrawLine&diff=29086DxDrawLine2012-01-22T04:32:16Z<p>John: Changed the example entirely, because I fail at editing.</p>
<hr />
<div>__NOTOC__ <br />
{{Client function}} <br />
This function draws a 2D line across the screen - rendered for '''one''' frame. This should be used in conjunction with [[onClientRender]] in order to display continuously.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
bool dxDrawLine ( int startX, int startY, int endX, int endY, int color, [float width=1, bool postGUI=false] )<br />
</syntaxhighlight><br />
<br />
===Required Arguments=== <br />
* '''startX:''' An integer representing the '''absolute''' start X position of the line, represented by pixels on the screen.<br />
* '''startY:''' An integer representing the '''absolute''' start Y position of the line, represented by pixels on the screen.<br />
* '''endX:''' An integer representing the '''absolute''' end X position of the line, represented by pixels on the screen.<br />
* '''endY:''' An integer representing the '''absolute''' end Y position of the line, represented by pixels on the screen.<br />
* '''color:''' An integer of the hex color, produced using [[tocolor]] or 0xAARRGGBB (AA = alpha, RR = red, GG = green, BB = blue).<br />
<br />
==Optional Arguments==<br />
{{OptionalArg}}<br />
* '''width:''' The width/thickness of the line <br />
* '''postGUI:''' A bool representing whether the line should be drawn on top of or behind any ingame GUI (rendered by CEGUI).<br />
<br />
===Returns===<br />
Returns a true if the operation was successful, false otherwise. <br />
<br />
==Example==<br />
<section name="Client" class="client" show="true"><br />
This example draws an 'X' across the screen.<br />
<syntaxhighlight lang="lua"><br />
local screenWidth, screenHeight = guiGetScreenSize() <br />
local lineColor = tocolor(255, 0, 0)<br />
function drawLinesAcrossScreen()<br />
dxDrawLine(0, 0, screenWidth, screenHeight, lineColor)<br />
dxDrawLine(screenWidth, 0, 0, screenHeight, lineColor)<br />
end<br />
addEventHandler("onClientRender", root, drawLinesAcrossScreen)<br />
</syntaxhighlight><br />
</section><br />
<br />
==See Also==<br />
{{Drawing_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=DxDrawLine&diff=29085DxDrawLine2012-01-22T04:25:43Z<p>John: </p>
<hr />
<div>__NOTOC__ <br />
{{Client function}} <br />
This function draws a 2D line across the screen - rendered for '''one''' frame. This should be used in conjunction with [[onClientRender]] in order to display continuously.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
bool dxDrawLine ( int startX, int startY, int endX, int endY, int color, [float width=1, bool postGUI=false] )<br />
</syntaxhighlight><br />
<br />
===Required Arguments=== <br />
* '''startX:''' An integer representing the '''absolute''' start X position of the line, represented by pixels on the screen.<br />
* '''startY:''' An integer representing the '''absolute''' start Y position of the line, represented by pixels on the screen.<br />
* '''endX:''' An integer representing the '''absolute''' end X position of the line, represented by pixels on the screen.<br />
* '''endY:''' An integer representing the '''absolute''' end Y position of the line, represented by pixels on the screen.<br />
* '''color:''' An integer of the hex color, produced using [[tocolor]] or 0xAARRGGBB (AA = alpha, RR = red, GG = green, BB = blue).<br />
<br />
==Optional Arguments==<br />
{{OptionalArg}}<br />
* '''width:''' The width/thickness of the line <br />
* '''postGUI:''' A bool representing whether the line should be drawn on top of or behind any ingame GUI (rendered by CEGUI).<br />
<br />
===Returns===<br />
Returns a true if the operation was successful, false otherwise. <br />
<br />
==Example==<br />
<section name="Client" class="client" show="true"><br />
Example code for drawing crosshair for Tank.<br />
<syntaxhighlight lang="lua"><br />
local width, height = guiGetScreenSize ( ) -- Get player's screen resolution (width and height).<br />
local centerX, centerY = ( width / 2 ), ( height / 2 ) -- Get x and y co-ordinates of the center of the screen.<br />
local colGreen = tocolor ( 0, 255, 0, 255 ) -- Get green color.<br />
<br />
function draw2DLine( )<br />
dxDrawLine ( centerX, centerY - 200, centerX, centerY - 170, colGreen, 1 ) -- Draw vertical crosshair line<br />
dxDrawLine ( centerY - 20, centerY - 185, centerX + 20, centerY - 185, colGreen, 1 ) -- Draw horizontal crosshair line<br />
end <br />
addEventHandler ( "onClientRender", resourceRoot, draw2DLine)<br />
</syntaxhighlight><br />
</section><br />
<br />
==See Also==<br />
{{Drawing_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=DxDrawLine&diff=29084DxDrawLine2012-01-22T04:25:29Z<p>John: Cleaned the example up a bit.</p>
<hr />
<div>__NOTOC__ <br />
{{Client function}} <br />
This function draws a 2D line across the screen - rendered for '''one''' frame. This should be used in conjunction with [[onClientRender]] in order to display continuously.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
bool dxDrawLine ( int startX, int startY, int endX, int endY, int color, [float width=1, bool postGUI=false] )<br />
</syntaxhighlight><br />
<br />
===Required Arguments=== <br />
* '''startX:''' An integer representing the '''absolute''' start X position of the line, represented by pixels on the screen.<br />
* '''startY:''' An integer representing the '''absolute''' start Y position of the line, represented by pixels on the screen.<br />
* '''endX:''' An integer representing the '''absolute''' end X position of the line, represented by pixels on the screen.<br />
* '''endY:''' An integer representing the '''absolute''' end Y position of the line, represented by pixels on the screen.<br />
* '''color:''' An integer of the hex color, produced using [[tocolor]] or 0xAARRGGBB (AA = alpha, RR = red, GG = green, BB = blue).<br />
<br />
==Optional Arguments==<br />
{{OptionalArg}}<br />
* '''width:''' The width/thickness of the line <br />
* '''postGUI:''' A bool representing whether the line should be drawn on top of or behind any ingame GUI (rendered by CEGUI).<br />
<br />
===Returns===<br />
Returns a true if the operation was successful, false otherwise. <br />
<br />
==Example==<br />
<section name="Client" class="client" show="true"><br />
Example code for drawing crosshair for Tank.<br />
<syntaxhighlight lang="lua"><br />
local width, height = guiGetScreenSize ( ) -- Get player's screen resolution (width and height).<br />
local centerX, centerY = ( width / 2 ), ( height / 2 ) -- Get x and y co-ordinates of the center of the screen.<br />
local colGreen = tocolor ( 0, 255, 0, 255 ) -- Get green color.<br />
<br />
function draw2DLine( )<br />
dxDrawLine ( centerX, centerY - 200, centerX, centerY - 170, colGreen, 1 ) -- Draw vertical crosshair line<br />
dxDrawLine ( centerY - 20, centerY - 185, centerX + 20, centerY - 185, colGreen, 1 ) -- Draw horizontal crosshair line<br />
end <br />
addEventHandler ( "onClientResourceStart", resourceRoot, draw2DLine)<br />
</syntaxhighlight><br />
</section><br />
<br />
==See Also==<br />
{{Drawing_functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetPlayerFromName&diff=28808GetPlayerFromName2011-12-24T05:29:50Z<p>John: Undo revision 28803 by TAPL (talk) Example was not really relevant, should be in the 'usefull functions' section.</p>
<hr />
<div>{{Server client function}}<br />
__NOTOC__<br />
This function returns a [[player]] [[element]] for the player with the name passed to the function.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
player getPlayerFromName ( string playerName )<br />
</syntaxhighlight><br />
<br />
===Required Arguments===<br />
* '''playerName''': A string containing the name of the player you want to reference<br />
<br />
===Returns===<br />
Returns a [[player]] [[element]] for the player with the nickname provided. If there is no player with that name, ''false'' is returned.<br />
<br />
==Example==<br />
This example finds a [[player]] as specified in the command and outputs the direction and distance he is from the player who entered the command. For example: 'locate someguy'.<br />
<syntaxhighlight lang="lua"><br />
function locatePlayer( sourcePlayer, command, who )<br />
local targetPlayer = getPlayerFromName ( who ) -- find the player that was specified in the command<br />
if ( targetPlayer ) then -- if a player was found<br />
local x,y,z = getElementPosition ( sourcePlayer ) -- save the position of the player who entered the command<br />
local xp,yp,zp = getElementPosition ( targetPlayer ) -- save the position of the player who should be located<br />
local dir = nil<br />
if (yp > y) then<br />
dir = "N"<br />
else<br />
dir = "S"<br />
end<br />
if (xp > x) then<br />
dir = dir .. "E"<br />
else<br />
dir = dir .. "W"<br />
end<br />
local distance = math.ceil ( getDistanceBetweenPoints3D(x, y, z, xp, yp, zp) )<br />
outputChatBox( who .. " found " .. dir .. " (" .. distance .. ")", sourcePlayer) -- output the message<br />
end<br />
end<br />
addCommandHandler ( "locate", locatePlayer )<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
{{Player functions}}<br />
[[ru:getPlayerFromName]]</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetVehicleDoorState&diff=28807GetVehicleDoorState2011-12-24T05:28:21Z<p>John: Changed the wording.</p>
<hr />
<div>__NOTOC__<br />
{{Server client function}}<br />
This function returns the current state of the specifed door on the vehicle.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">int getVehicleDoorState ( vehicle theVehicle, int door )</syntaxhighlight><br />
<br />
==Required Arguments==<br />
*'''theVehicle:''' The vehicle you want to get the door status of.<br />
*'''door:''' A whole number representing which door to get the status of. Valid values are:<br />
** '''0:''' Hood<br />
** '''1:''' Trunk<br />
** '''2:''' Front left<br />
** '''3:''' Front right<br />
** '''4:''' Rear left<br />
** '''5:''' Rear right<br />
<br />
==Returns==<br />
If successful, one of the following integers will be returned:<br />
* '''0:''' Shut, intact (also returned if the door does not exist)<br />
* '''1:''' Ajar, intact<br />
* '''2:''' Shut, damaged<br />
* '''3:''' Ajar, damaged<br />
* '''4:''' Missing<br />
<br />
<br />
==Example==<br />
This example implements a doesVehicleHaveDoorOpen() function, that returns true if any of the doors on a vehicle are open.<br />
<syntaxhighlight lang="lua">function doesVehicleHaveDoorOpen(vehicle)<br />
local isDoorAjar = false<br />
for i=0,5 do<br />
local doorState = getVehicleDoorState(vehicle, i)<br />
if doorState == 1 or doorState == 3 or doorState == 4 then<br />
isDoorAjar = true<br />
end<br />
end<br />
<br />
return isDoorAjar<br />
end</syntaxhighlight><br />
<br />
==See Also==<br />
{{Vehicle functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=SetVehicleDoorState&diff=28806SetVehicleDoorState2011-12-24T05:25:57Z<p>John: Clarified some things.</p>
<hr />
<div>__NOTOC__<br />
{{Server client function}}<br />
This function sets the state of the specified door on a vehicle.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua"><br />
bool setVehicleDoorState ( vehicle theVehicle, int door, int state )<br />
</syntaxhighlight><br />
<br />
==Required Arguments==<br />
*'''theVehicle:''' The [[vehicle]] that you wish to change the door state of.<br />
*'''door:''' An integer representing which door to set the state of. Valid values are:<br />
**'''0:''' Hood<br />
**'''1:''' Trunk<br />
**'''2:''' Front left<br />
**'''3:''' Front right<br />
**'''4:''' Rear left<br />
**'''5:''' Rear right<br />
*'''state:''' An integer representing the state to set the door to. Valid values are:<br />
**'''0:''' Shut, intact<br />
**'''1:''' Ajar, intact<br />
**'''2:''' Shut, damaged<br />
**'''3:''' Ajar, damaged<br />
**'''4:''' Missing<br />
<br />
==Returns==<br />
Returns ''true'' if the door state was successfully set, ''false'' otherwise.<br />
<br />
==Example==<br />
<syntaxhighlight lang="lua"><br />
-- create a new vehicle<br />
local newcar = createVehicle ( 520, 1024, 1024, 1024 )<br />
-- break its front left door off<br />
state = setVehicleDoorState ( newcar, 2, 4 )<br />
</syntaxhighlight><br />
<br />
==See Also==<br />
{{Vehicle functions}}</div>Johnhttps://wiki.multitheftauto.com/index.php?title=GetVehicleDoorState&diff=28805GetVehicleDoorState2011-12-24T04:01:17Z<p>John: Added an example.</p>
<hr />
<div>__NOTOC__<br />
{{Server client function}}<br />
This function returns the current state of the specifed door on the vehicle.<br />
<br />
==Syntax==<br />
<syntaxhighlight lang="lua">int getVehicleDoorState ( vehicle theVehicle, int door )</syntaxhighlight><br />
<br />
==Required Arguments==<br />
*'''theVehicle:''' The vehicle you want to get the door status of.<br />
*'''door:''' A whole number representing which door to get the status of. Valid values are:<br />
** '''0:''' Hood<br />
** '''1:''' Trunk<br />
** '''2:''' Front left<br />
** '''3:''' Front right<br />
** '''4:''' Rear left<br />
** '''5:''' Rear right<br />
<br />
==Returns==<br />
If successful, one of the following integers will be returned:<br />
* '''0:''' Shut (Undamaged) (also returned if no such door exists on the vehicle)<br />
* '''1:''' Open (Undamaged)<br />
* '''2:''' Shut (Damaged)<br />
* '''3:''' Open (Damaged)<br />
* '''4:''' Fallen off<br />
<br />
<br />
==Example==<br />
This example implements a doesVehicleHaveDoorOpen() function, that returns true if any of the doors on a vehicle are open.<br />
<syntaxhighlight lang="lua">function doesVehicleHaveDoorOpen(vehicle)<br />
local isDoorAjar = false<br />
for i=0,5 do<br />
local doorState = getVehicleDoorState(vehicle, i)<br />
if doorState == 1 or doorState == 3 or doorState == 4 then<br />
isDoorAjar = true<br />
end<br />
end<br />
<br />
return isDoorAjar<br />
end</syntaxhighlight><br />
<br />
==See Also==<br />
{{Vehicle functions}}</div>John