<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=AlexsSteel</id>
	<title>Multi Theft Auto: Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=AlexsSteel"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/wiki/Special:Contributions/AlexsSteel"/>
	<updated>2026-04-30T06:50:33Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/CreateExplosion&amp;diff=39196</id>
		<title>ES/CreateExplosion</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/CreateExplosion&amp;diff=39196"/>
		<updated>2014-03-30T17:22:38Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__ &lt;br /&gt;
{{Server client function}}&lt;br /&gt;
Crea una explosion en la posicion especificada, si se especifica al creador, la explosión solo sera percibida en la dimensión de este.&lt;br /&gt;
&lt;br /&gt;
==Sintaxis== &lt;br /&gt;
&amp;lt;section name=&amp;quot;Server&amp;quot; class=&amp;quot;server&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool createExplosion ( float x, float y, float z, int tipo[, player creador = nil ] )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Argumentos requeridos=== &lt;br /&gt;
*'''x:''' Valor que determina la coordenada X donde se creará la explosión&lt;br /&gt;
*'''y:''' Valor que determina la coordenada Y donde se creará la explosión&lt;br /&gt;
*'''z:''' Valor que determina la coordenada Z donde se creará la explosión&lt;br /&gt;
*'''tipo:''' Valor que determina el tipo de explosión.&lt;br /&gt;
**'''0:''' Granada&lt;br /&gt;
**'''1:''' Cóctel Molotov&lt;br /&gt;
**'''2:''' Cohete&lt;br /&gt;
**'''3:''' Cohete (débil)&lt;br /&gt;
**'''4:''' Automóvil&lt;br /&gt;
**'''5:''' Automóvil (rápido)&lt;br /&gt;
**'''6:''' Bote&lt;br /&gt;
**'''7:''' Helicóptero&lt;br /&gt;
**'''8:''' Mina&lt;br /&gt;
**'''9:''' Objeto&lt;br /&gt;
**'''10:''' Proyectil de Tanque&lt;br /&gt;
**'''11:''' Pequeño&lt;br /&gt;
**'''12:''' Diminuto&lt;br /&gt;
&lt;br /&gt;
===Argumentos Opcionales===&lt;br /&gt;
*'''creador:''' Determina al [[player]] responsable por la explosión.&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool createExplosion ( float x, float y, float z, int tipo[, bool sonido = true, float agitarCamara = -1.0, bool daño = true ] )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Argumentos requeridos=== &lt;br /&gt;
*'''x:''' Valor que determina la coordenada X donde se creará la explosión&lt;br /&gt;
*'''y:''' Valor que determina la coordenada Y donde se creará la explosión&lt;br /&gt;
*'''z:''' Valor que determina la coordenada Z donde se creará la explosión&lt;br /&gt;
*'''tipo:''' Valor que determina el tipo de explosión.&lt;br /&gt;
**'''0:''' Granada&lt;br /&gt;
**'''1:''' Cóctel Molotov&lt;br /&gt;
**'''2:''' Cohete&lt;br /&gt;
**'''3:''' Cohete (débil)&lt;br /&gt;
**'''4:''' Automóvil&lt;br /&gt;
**'''5:''' Automóvil (rápido)&lt;br /&gt;
**'''6:''' Bote&lt;br /&gt;
**'''7:''' Helicóptero&lt;br /&gt;
**'''8:''' Mina&lt;br /&gt;
**'''9:''' Objeto&lt;br /&gt;
**'''10:''' Proyectil de Tanque&lt;br /&gt;
**'''11:''' Pequeño&lt;br /&gt;
**'''12:''' Diminuto&lt;br /&gt;
&lt;br /&gt;
===Argumentos opcionales===&lt;br /&gt;
*'''sonido:''' Boolean que determina si la explosión sera (o no) oída por el jugador.&lt;br /&gt;
*'''agitarCamara :'''  Valor que determina la intensidad de movimiento de la cámara.&lt;br /&gt;
*'''daño:'''  Boolean que determina si la explosión hará (o no) daño al jugador.&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Devuelve===&lt;br /&gt;
Devuelve ''true'' si la la explosión fue creada, de lo contrario devolvería ''false''.&lt;br /&gt;
&lt;br /&gt;
==Example== &lt;br /&gt;
&amp;lt;section name=&amp;quot;Server&amp;quot; class=&amp;quot;server&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
'''Example 1:''' Este código consigue la posición del jugador cuando este ''spawnea'' y crea una explosión en ese lugar.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;function explosionOnSpawn ( )&lt;br /&gt;
  -- Se obtiene la posición del jugador.&lt;br /&gt;
  local pX, pY, pZ = getElementPosition ( source )&lt;br /&gt;
  -- Crea la explosión.&lt;br /&gt;
  createExplosion ( pX, pY, pZ, 6, source )&lt;br /&gt;
end&lt;br /&gt;
-- Se adjunta un evento que se ejecute cuando el jugador spawnea.&lt;br /&gt;
addEventHandler ( &amp;quot;onPlayerSpawn&amp;quot;, getRootElement(), explosionOnSpawn )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Explosion functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38828</id>
		<title>ES/Página Principal</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38828"/>
		<updated>2014-02-09T19:45:23Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
__NOEDITSECTION__&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding: 10px; height: 140px;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Mtalogo.png|left|100px]]'''&lt;br /&gt;
Bienvenid@ a la Wiki de Multi Theft Auto: San Andreas en español.''' Aquí puedes encontrar mucha información sobre el uso de Multi Theft Auto. &lt;br /&gt;
&lt;br /&gt;
Hay muchas [[ES/Cómo puedes ayudar|cosas que puedes hacer para ayudarnos]] a mejorar MTA - crea un mapa, un modo de juego, escribe códigos de ejemplo, tutoriales, traduce páginas del inglés al español, o simplemente juega y reporta los bugs que encuentres.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:10px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Input-gaming.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== El Juego ===&lt;br /&gt;
&amp;lt;div style=&amp;quot;background: #FFEEAA;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Go-down.png|link=http://mtasa.com/]] ''' [http://mtasa.com/ Descargar Multi Theft Auto: San Andreas {{Current Version|full}}]'''&amp;lt;/div&amp;gt;&lt;br /&gt;
* [[ES/Manual del Cliente|Manual del Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[ES/Cambios en la versión 1.3|Cambios de la versión 1.3]] [[Image:flag_es.png|En Español|20px]] (Traducción 80%)&lt;br /&gt;
* [[ES/Problemas_Conocidos_-_FAQ|Problemas Conocidos]] [[Image:flag_es.png|En Español|20px]] (Traducción: 10%)&lt;br /&gt;
* [[Upgrading_from_MTA:Race|Cambiando MTA:Race a MTA:SA 1.0.x]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Manual del Servidor|Manual del Servidor]] [[Image:flag_es.png|En Español|20px]] (Traducción: 90%)&lt;br /&gt;
* [[Map_manager|El Resource &amp;quot;Map Manager&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&lt;br /&gt;
====Editor de Mapas====&lt;br /&gt;
*[[ES/Resource:Editor|Manual del Editor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[[Resource:Editor/EDF|EDF: Formato de Definiciones del Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[Resource:Editor/Plugins|Plugins para el Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[ES/Resource:Editor#Preguntas_Frecuentes|Preguntas Frecuentes]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
&lt;br /&gt;
====Bases de Datos====&lt;br /&gt;
* [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Scripts de Cliente|Scripts de Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Modules| Módulos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-development.png‎‎‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====Desarrollando Multi Theft Auto====&lt;br /&gt;
[[File:Go-down.png|link=http://nightly.mtasa.com/]] [http://nightly.mtasa.com/ Nightly builds]&lt;br /&gt;
* [[Compiling_MTASA|Compilando MTA:SA en Windows]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_Mac_OS_X|Compilando MTA:SA en Mac OS X]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_GNU_Linux|Compilando MTA:SA en GNU/Linux]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Coding guidelines|Guías de Codificación]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://code.google.com/p/mtasa-blue Google Code SVN] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/roadmap_page.php Seguimiento de Versiones] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/ Central de Reportes de Bugs] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-office.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
===Wiki - Cómo puedes ayudar===&lt;br /&gt;
* Termina la documentación para [[:Category:Incomplete|funciones incompletas]].&lt;br /&gt;
* [[:Category:Needs_Example|Crea ejemplos para eventos y funciones]].&lt;br /&gt;
* Revisa y verifica [[:Category:Needs Checking|páginas que necesitan revisión]].&lt;br /&gt;
* Escribe tutoriales para ayudar a la gente.&lt;br /&gt;
* Traduce las páginas del wiki.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Internet-group-chat.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Comunidad ===&lt;br /&gt;
* [http://forum.multitheftauto.com/ Foro] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [http://forum.multitheftauto.com/viewforum.php?f=122&amp;amp;sid=72be1c29dd00c4442f8112cc09818283 Sección en español] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [irc://irc.multitheftauto.com/mta Canal IRC] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://community.mtasa.com/ Comunidad MTA] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://www.youtube.com/user/MTAQA Canal de YouTube oficial] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding:4px 8px 8px 8px; margin:10px; text-align:center&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Osi symbol.png|75px|link=http://opensource.org/]]&lt;br /&gt;
'''Multi Theft Auto''' es un '''Proyecto Open Source'''. &lt;br /&gt;
¡Todos podemos contribuir a mejorar Multi Theft Auto!&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Accessories-text-editor.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Scripting ===&lt;br /&gt;
* [[ES/Resources|Introducción a los Resources]]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
** [[Resource Web Access|Acceso Web con Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[Meta.xml|Sobre el archivo &amp;quot;meta.xml&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[ES/ACL|Lista de Control del Acceso (ACL)]]  [[Image:flag_es.png|En Español|20px]] (Traducción: 10%)&lt;br /&gt;
* [[ES/Introducción a Lua|Introducción a Lua]] [[Image:flag_es.png|En Español|20px]] (Traducción: 85%)&lt;br /&gt;
** [[ES/Introducción a la Programación de GUI|Introducción al GUI]] [[Image:flag_es.png|En Español|20px]] (Traducción: 40%)&lt;br /&gt;
** [[Debugging|Tutorial de Depuración]] [[Image:flag_us.png|En Inglés|20px]] - Encontrar errores en scripts.&lt;br /&gt;
* [[ES/Useful_Functions| Funciones útiles]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Writing_Gamemodes|Escribiendo Modos de Juego]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
====Ayuda General de Lua====&lt;br /&gt;
*[http://www.lua.org/manual/5.1/es/manual.html Manual de Referencia de Lua 5.1]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[http://www.lua.org/pil/index.html Manual Programando en Lua]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://lua-users.org/wiki/TutorialDirectory Lua Wiki]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://nixstaller.berlios.de/manual/0.2/nixstaller_9.html Guía general de Lua de Nixstaller]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
====Referencia====&lt;br /&gt;
* [[Client Scripting Functions|Funciones de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Client Scripting Events|Eventos de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Funciones de Servidor|Funciones de Servidor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Server Scripting Events|Eventos de Servidor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;!-- Incomplete * [[Module functions|Lista de funciones de módulos externos de servidor]] [[Image:flag_us.png|En Inglés]] --&amp;gt;&lt;br /&gt;
* [[ES/Clases MTA| Clases de MTA]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
**[[Element tree| Árbol de Elementos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:System-file-manager.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====[[Id|Lista de ID's]]====&lt;br /&gt;
*[[Animations|Animaciones]]&lt;br /&gt;
*[[ES/Skins de Personajes|Skins]]&lt;br /&gt;
*[[CJ_Clothes|Ropa]]&lt;br /&gt;
*[[Garage|Garajes]]&lt;br /&gt;
*[[Interior IDs|Interiores]]&lt;br /&gt;
*[[Projectiles|Proyectiles]]&lt;br /&gt;
*[[Radar Blips|Iconos de Radar]]&lt;br /&gt;
*[[Sounds|Sonidos]]&lt;br /&gt;
*[[Vehicle IDs|ID's de Vehículos]]&lt;br /&gt;
*[[Vehicle Colors|Colores de Vehículos]]&lt;br /&gt;
*[[Vehicle Upgrades|Mejoras de Vehículos]]&lt;br /&gt;
*[[Weapons|Armas]]&lt;br /&gt;
*[[ES/Climas|Climas]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Equipo de Traducción====&lt;br /&gt;
* [mailto:zorrigas@gtagamingchile.com zorrigas@gtagamingchile.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:Brijido_XD@hotmail.com Brijido_XD@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* Benxamix2/The Kid&lt;br /&gt;
* [mailto:matiuno@gmail.com matiuno@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:cesarcastillo4@gmail.com cesarcastillo4@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:alex_firexx@hotmail.com alex_firexx@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:carlos_olivo@msn.com carlos_olivo@msn.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* AlexD&lt;br /&gt;
* Alexs_Steel[mailto:alexTO123@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
'''¡NO ELIMINES CONTENIDO SIN AUTORIZACIÓN!'''&amp;lt;br&amp;gt; Tampoco uses modismos, usa el Castellano (Internacional), y trata de que al traducir todo quede tan claro como puedas, y la ortografía sea la mejor posible.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
{{Languages list|es}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38827</id>
		<title>ES/ACL</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38827"/>
		<updated>2014-02-09T19:43:42Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Grupos por defecto */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''Multi Theft Auto'' incluye una completa y útil Lista de Control de Acceso (''ACL'') la que te permite asegurar y limitar el acceso a distintas funciones, recursos del servidor de múltiples maneras.&lt;br /&gt;
&lt;br /&gt;
El concepto en ''Multi Theft Auto'' de ''ACL'' es el de dar a un objeto especifico una serie de derechos. En el caso de ''Multi Theft Auto'', los objetos son una de dos cosas - recursos o usuarios. Hay numerosos derechos disponibles en ''Multi Theft Auto'' - estos están enfocados principalmente en las funciones del lado del servidor.&lt;br /&gt;
&lt;br /&gt;
Lo que esto significa, esencialmente es que el ''ACL'' te permite escoger con exactitud a que funciones (un recurso o un usuario) pueden acceder. Esto, por ejemplo, puede prevenir que los jugadores de tu servidor sean capaces de ''banearse'' mutuamente o prevenir que errores en recursos aun no probados causen daños y problemas en tu servidor.&lt;br /&gt;
&lt;br /&gt;
Por supuesto ''un gran poder conlleva una gran responsabilidad'' y es muy sencillo causar graves problemas con los recursos, por ejemplo, deshabilitar la función [[spawnPlayer]] para cada recurso causaría que los jugadores ya no puedan ''spawnear''. Por supuesto, existen situaciones en las que se busca hacer esto. (Si deseas hacer que un solo recurso se encargue de ''spawnear'' a los jugadores, por ejemplo.)&lt;br /&gt;
&lt;br /&gt;
==Entiendido el funcionamiento==&lt;br /&gt;
Existen dos grandes componentes en el ''ACL'': grupos y listas ''ACL''. Estos aparecen como '''&amp;lt;group name=&amp;quot;&amp;quot;&amp;gt;''' y '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;'''.&lt;br /&gt;
Cuyo propósito es:&amp;lt;br \&amp;gt;&lt;br /&gt;
'''1.''' Garantizar a los usuarios el permiso de controlar el servidor y utilizar comandos. Ejemplos:''&amp;lt;br \&amp;gt;&lt;br /&gt;
*Permitir solo a los administradores utilizar la función [[giveWeapon]] en ''freeroam''.&lt;br /&gt;
*Permitir a todos los jugadores iniciar un recurso.&lt;br /&gt;
'''2.''' Garantizar a los recursos el permiso de utilizar una función o funciones de otros recursos. Ejemplos:&amp;lt;br \&amp;gt;&lt;br /&gt;
*Permitir a un recurso utilizar la funcion [[restartResource]].&lt;br /&gt;
*Permitir a un recurso llamar funciones exportadas desde otro recurso.&lt;br /&gt;
&lt;br /&gt;
===Grupos por defecto===&lt;br /&gt;
''Multi Theft Auto'' trae por defecto algunos grupos con ciertos permisos. Estos son:&lt;br /&gt;
*'''Everyone''' - Toda cuenta registrada, por defecto, es añadida a este grupo.&lt;br /&gt;
*'''Moderator'''&lt;br /&gt;
*'''SuperModerator'''&lt;br /&gt;
*'''Admin'''&lt;br /&gt;
*'''Console''' - Este grupo controla los permisos del usuario de la Consola '''&amp;lt;object name=&amp;quot;user.Console&amp;quot; /&amp;gt;'''&lt;br /&gt;
*'''RPC''' - Procedimientos Remotos (En ingles, ''Remote Procedure Call''). Garantiza el acceso a [[callRemote]], para mas información revisa la información de la función.&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A modo de ejemplo, utilizare el grupo ''Everyone''. Por defecto, este luce así:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;group name=&amp;quot;Everyone&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.*&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.*&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Lo primero que deberías notar es el nombre ''ACL'' (''acl name'') asignado dentro del grupo. Esto define que permisos tiene el grupo en cuestión, usuarios y recursos en este grupo pueden acceder a los permisos especificados dentro de la lista ''ACL'' llamada &amp;quot;Default&amp;quot;.&lt;br /&gt;
''*Nota: Como notaras, este grupo en especial incluye a todos los usuarios y recursos gracias al uso del '''*'''.''&lt;br /&gt;
&lt;br /&gt;
Now, scroll further down the ACL and you will see the '''&amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;''' listing. Note I have trimmed this list dramatically due to its length.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.start&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stop&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stopall&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.executeCommandHandler&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.setPlayerMuted&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.restartResource&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_players&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_resources&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.shout&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.spectate&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
*'''Function''' entries are MTA scripting functions. For example, if a resource needed to use restartResource and was only in the 'Everyone' group (with the 'Default' list), it would be denied access to restartResource and fail to work correctly.&lt;br /&gt;
*'''Commands''' are created when a resource uses [[addCommandHandler]]. An example would be typing '''/createvehicle [vehicle]''' in the chatbox for the freeroam resource. This controls whether users in the group using this ACL can use the command. ''Note: commands have no effect on resources within the group. Commands are only related to users.''&lt;br /&gt;
**''General is a custom right name group created by the admin resource but it works on the same principles. The script works with them by using [[hasObjectPermissionTo]]''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will notice some groups such as admin have multiple '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' nodes. An example is the admin group:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;Admin&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Moderator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;SuperModerator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;RPC&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.webadmin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.Ransom&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This gives all the permissions defined in each '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' node in order of listing. So for example, the admin group makes sure all the permissions are given to admins by using all the lists. If there are any conflicts, the lowest entry wins. For example, pretend these 2 acls were in a group in the following order:&lt;br /&gt;
&lt;br /&gt;
'''1.''' '''&amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''2.''' '''&amp;lt;acl name=&amp;quot;Admin&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''3.''' For all users and resources in group admin: &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&amp;lt;br\&amp;gt;&lt;br /&gt;
&amp;lt;br\&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Resource Groups and ACLs ===&lt;br /&gt;
You will notice there are some other groups that came with MTA. These were defined by resources that came with MTA. If a resource wants to designate specific ACL rights not provided by the default MTA groups, it can create its own ACL name and a group to use it. I will show AMX's entry as an example. AMX is designed to emulate SA-MP scripts and it needs a certain set of permissions that doesn't fit the default groups well. It is shown below:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;AMX&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.amx&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;acl name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.startResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.stopResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.kick&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.mute&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Modifying the ACL==&lt;br /&gt;
There are three ways you can modify the ACL - how you do it depends who you are.&lt;br /&gt;
&lt;br /&gt;
===HTTP Interface===&lt;br /&gt;
You can use the [[Resource/webadmin|webadmin]] http interface to modify the ACL in your web browser. This is by far the easiest way to do so. Just make sure the ''webadmin'' resource is started on your server and visit ''&amp;lt;nowiki&amp;gt;http://ServerIP:HttpPort/&amp;lt;/nowiki&amp;gt;''. You can then use the two sections - ACLs and Groups. ACLs allows you to create your Access Control Lists - lists of rights. Groups allow you to group together collections of users and assign ACLs to them. For example, the ACLs section allows you to specify that the Admin ACL has access to the ''start'' console command. You can the go to the Groups section and create an Admin ''group'' that has access to your Admin ''acl''. You can then add users to your Admin ''group''.&lt;br /&gt;
&lt;br /&gt;
===XML file===&lt;br /&gt;
You can modify the ACL.xml file manually. This has a fairly straightforward syntax, but it can get a bit confusing at times. If you do it while the server is running, don't forget to call the scripting function [[aclReload]] (&amp;quot;start runcode&amp;quot;, &amp;quot;run aclReload()&amp;quot;) so the new ACL is loaded, or otherwise stop your server before modifying. This also prevents your changes from being accidentally overwritten by the server.&lt;br /&gt;
&lt;br /&gt;
===Scripting functions===&lt;br /&gt;
You can use a large number of ACL scripting functions to modify the ACL on the fly. Of course, you can (and really should!) limit access to the ACL functions with the ACL. Note that the '''admin resource''' that comes with MTA can be used to manage the ACL from the resources tab. You must be setup as admin to use the admin panel. [http://wiki.multitheftauto.com/wiki/Admin Click here for admin setup instructions].&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{ACL functions}}&lt;br /&gt;
[[Category:Scripting Concepts]]&lt;br /&gt;
[[ru:Access Control List]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38826</id>
		<title>ES/ACL</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38826"/>
		<updated>2014-02-09T19:43:03Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Grupos por defecto */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''Multi Theft Auto'' incluye una completa y útil Lista de Control de Acceso (''ACL'') la que te permite asegurar y limitar el acceso a distintas funciones, recursos del servidor de múltiples maneras.&lt;br /&gt;
&lt;br /&gt;
El concepto en ''Multi Theft Auto'' de ''ACL'' es el de dar a un objeto especifico una serie de derechos. En el caso de ''Multi Theft Auto'', los objetos son una de dos cosas - recursos o usuarios. Hay numerosos derechos disponibles en ''Multi Theft Auto'' - estos están enfocados principalmente en las funciones del lado del servidor.&lt;br /&gt;
&lt;br /&gt;
Lo que esto significa, esencialmente es que el ''ACL'' te permite escoger con exactitud a que funciones (un recurso o un usuario) pueden acceder. Esto, por ejemplo, puede prevenir que los jugadores de tu servidor sean capaces de ''banearse'' mutuamente o prevenir que errores en recursos aun no probados causen daños y problemas en tu servidor.&lt;br /&gt;
&lt;br /&gt;
Por supuesto ''un gran poder conlleva una gran responsabilidad'' y es muy sencillo causar graves problemas con los recursos, por ejemplo, deshabilitar la función [[spawnPlayer]] para cada recurso causaría que los jugadores ya no puedan ''spawnear''. Por supuesto, existen situaciones en las que se busca hacer esto. (Si deseas hacer que un solo recurso se encargue de ''spawnear'' a los jugadores, por ejemplo.)&lt;br /&gt;
&lt;br /&gt;
==Entiendido el funcionamiento==&lt;br /&gt;
Existen dos grandes componentes en el ''ACL'': grupos y listas ''ACL''. Estos aparecen como '''&amp;lt;group name=&amp;quot;&amp;quot;&amp;gt;''' y '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;'''.&lt;br /&gt;
Cuyo propósito es:&amp;lt;br \&amp;gt;&lt;br /&gt;
'''1.''' Garantizar a los usuarios el permiso de controlar el servidor y utilizar comandos. Ejemplos:''&amp;lt;br \&amp;gt;&lt;br /&gt;
*Permitir solo a los administradores utilizar la función [[giveWeapon]] en ''freeroam''.&lt;br /&gt;
*Permitir a todos los jugadores iniciar un recurso.&lt;br /&gt;
'''2.''' Garantizar a los recursos el permiso de utilizar una función o funciones de otros recursos. Ejemplos:&amp;lt;br \&amp;gt;&lt;br /&gt;
*Permitir a un recurso utilizar la funcion [[restartResource]].&lt;br /&gt;
*Permitir a un recurso llamar funciones exportadas desde otro recurso.&lt;br /&gt;
&lt;br /&gt;
===Grupos por defecto===&lt;br /&gt;
''Multi Theft Auto'' trae por defecto algunos grupos con ciertos permisos. Estos son:&lt;br /&gt;
*'''Everyone''' - Toda cuenta registrada, por defecto, es añadida a este grupo.&lt;br /&gt;
*'''Moderator'''&lt;br /&gt;
*'''SuperModerator'''&lt;br /&gt;
*'''Admin'''&lt;br /&gt;
*'''Console''' - Este grupo controla los permisos del usuario de la Consola '''&amp;lt;object name=&amp;quot;user.Console&amp;quot; /&amp;gt;'''&lt;br /&gt;
*'''RPC''' - Procedimientos Remotos (En ingles, ''Remote Procedure Call''). Garantiza el acceso a [[callRemote]], para mas información revisa la información de la función.&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A modo de ejemplo, utilizare el grupo ''Everyone''. Por defecto, este luce así:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;group name=&amp;quot;Everyone&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.*&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.*&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
You will first notice the acl name inside the group. It defines what permissions the group has. Users and resources in this group will have the permissions specified on the &amp;quot;Default&amp;quot; acl name list. ''Note: You will notice this group is special, in that it includes every user and resource by using a '''wildcard (*)''' where the user or resource name would be.''&lt;br /&gt;
&lt;br /&gt;
Lo primero que deberías notar es el nombre ''ACL'' (''acl name'') asignado dentro del grupo. Esto define que permisos tiene el grupo en cuestión, usuarios y recursos en este grupo pueden acceder a los permisos especificados dentro de la lista ''ACL'' llamada &amp;quot;Default&amp;quot;.&lt;br /&gt;
''*Nota: Como notaras, este grupo en especial incluye a todos los usuarios y recursos gracias al uso del '''*'''.''&lt;br /&gt;
&lt;br /&gt;
Now, scroll further down the ACL and you will see the '''&amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;''' listing. Note I have trimmed this list dramatically due to its length.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.start&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stop&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stopall&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.executeCommandHandler&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.setPlayerMuted&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.restartResource&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_players&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_resources&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.shout&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.spectate&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
*'''Function''' entries are MTA scripting functions. For example, if a resource needed to use restartResource and was only in the 'Everyone' group (with the 'Default' list), it would be denied access to restartResource and fail to work correctly.&lt;br /&gt;
*'''Commands''' are created when a resource uses [[addCommandHandler]]. An example would be typing '''/createvehicle [vehicle]''' in the chatbox for the freeroam resource. This controls whether users in the group using this ACL can use the command. ''Note: commands have no effect on resources within the group. Commands are only related to users.''&lt;br /&gt;
**''General is a custom right name group created by the admin resource but it works on the same principles. The script works with them by using [[hasObjectPermissionTo]]''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will notice some groups such as admin have multiple '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' nodes. An example is the admin group:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;Admin&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Moderator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;SuperModerator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;RPC&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.webadmin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.Ransom&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This gives all the permissions defined in each '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' node in order of listing. So for example, the admin group makes sure all the permissions are given to admins by using all the lists. If there are any conflicts, the lowest entry wins. For example, pretend these 2 acls were in a group in the following order:&lt;br /&gt;
&lt;br /&gt;
'''1.''' '''&amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''2.''' '''&amp;lt;acl name=&amp;quot;Admin&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''3.''' For all users and resources in group admin: &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&amp;lt;br\&amp;gt;&lt;br /&gt;
&amp;lt;br\&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Resource Groups and ACLs ===&lt;br /&gt;
You will notice there are some other groups that came with MTA. These were defined by resources that came with MTA. If a resource wants to designate specific ACL rights not provided by the default MTA groups, it can create its own ACL name and a group to use it. I will show AMX's entry as an example. AMX is designed to emulate SA-MP scripts and it needs a certain set of permissions that doesn't fit the default groups well. It is shown below:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;AMX&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.amx&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;acl name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.startResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.stopResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.kick&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.mute&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Modifying the ACL==&lt;br /&gt;
There are three ways you can modify the ACL - how you do it depends who you are.&lt;br /&gt;
&lt;br /&gt;
===HTTP Interface===&lt;br /&gt;
You can use the [[Resource/webadmin|webadmin]] http interface to modify the ACL in your web browser. This is by far the easiest way to do so. Just make sure the ''webadmin'' resource is started on your server and visit ''&amp;lt;nowiki&amp;gt;http://ServerIP:HttpPort/&amp;lt;/nowiki&amp;gt;''. You can then use the two sections - ACLs and Groups. ACLs allows you to create your Access Control Lists - lists of rights. Groups allow you to group together collections of users and assign ACLs to them. For example, the ACLs section allows you to specify that the Admin ACL has access to the ''start'' console command. You can the go to the Groups section and create an Admin ''group'' that has access to your Admin ''acl''. You can then add users to your Admin ''group''.&lt;br /&gt;
&lt;br /&gt;
===XML file===&lt;br /&gt;
You can modify the ACL.xml file manually. This has a fairly straightforward syntax, but it can get a bit confusing at times. If you do it while the server is running, don't forget to call the scripting function [[aclReload]] (&amp;quot;start runcode&amp;quot;, &amp;quot;run aclReload()&amp;quot;) so the new ACL is loaded, or otherwise stop your server before modifying. This also prevents your changes from being accidentally overwritten by the server.&lt;br /&gt;
&lt;br /&gt;
===Scripting functions===&lt;br /&gt;
You can use a large number of ACL scripting functions to modify the ACL on the fly. Of course, you can (and really should!) limit access to the ACL functions with the ACL. Note that the '''admin resource''' that comes with MTA can be used to manage the ACL from the resources tab. You must be setup as admin to use the admin panel. [http://wiki.multitheftauto.com/wiki/Admin Click here for admin setup instructions].&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{ACL functions}}&lt;br /&gt;
[[Category:Scripting Concepts]]&lt;br /&gt;
[[ru:Access Control List]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38825</id>
		<title>ES/ACL</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38825"/>
		<updated>2014-02-09T19:42:29Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: Traducido un 10% mas y corregidos algunos errores.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''Multi Theft Auto'' incluye una completa y útil Lista de Control de Acceso (''ACL'') la que te permite asegurar y limitar el acceso a distintas funciones, recursos del servidor de múltiples maneras.&lt;br /&gt;
&lt;br /&gt;
El concepto en ''Multi Theft Auto'' de ''ACL'' es el de dar a un objeto especifico una serie de derechos. En el caso de ''Multi Theft Auto'', los objetos son una de dos cosas - recursos o usuarios. Hay numerosos derechos disponibles en ''Multi Theft Auto'' - estos están enfocados principalmente en las funciones del lado del servidor.&lt;br /&gt;
&lt;br /&gt;
Lo que esto significa, esencialmente es que el ''ACL'' te permite escoger con exactitud a que funciones (un recurso o un usuario) pueden acceder. Esto, por ejemplo, puede prevenir que los jugadores de tu servidor sean capaces de ''banearse'' mutuamente o prevenir que errores en recursos aun no probados causen daños y problemas en tu servidor.&lt;br /&gt;
&lt;br /&gt;
Por supuesto ''un gran poder conlleva una gran responsabilidad'' y es muy sencillo causar graves problemas con los recursos, por ejemplo, deshabilitar la función [[spawnPlayer]] para cada recurso causaría que los jugadores ya no puedan ''spawnear''. Por supuesto, existen situaciones en las que se busca hacer esto. (Si deseas hacer que un solo recurso se encargue de ''spawnear'' a los jugadores, por ejemplo.)&lt;br /&gt;
&lt;br /&gt;
==Entiendido el funcionamiento==&lt;br /&gt;
Existen dos grandes componentes en el ''ACL'': grupos y listas ''ACL''. Estos aparecen como '''&amp;lt;group name=&amp;quot;&amp;quot;&amp;gt;''' y '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;'''.&lt;br /&gt;
Cuyo propósito es:&amp;lt;br \&amp;gt;&lt;br /&gt;
'''1.''' Garantizar a los usuarios el permiso de controlar el servidor y utilizar comandos. Ejemplos:''&amp;lt;br \&amp;gt;&lt;br /&gt;
*Permitir solo a los administradores utilizar la función [[giveWeapon]] en ''freeroam''.&lt;br /&gt;
*Permitir a todos los jugadores iniciar un recurso.&lt;br /&gt;
'''2.''' Garantizar a los recursos el permiso de utilizar una función o funciones de otros recursos. Ejemplos:&amp;lt;br \&amp;gt;&lt;br /&gt;
*Permitir a un recurso utilizar la funcion [[restartResource]].&lt;br /&gt;
*Permitir a un recurso llamar funciones exportadas desde otro recurso.&lt;br /&gt;
&lt;br /&gt;
===Grupos por defecto===&lt;br /&gt;
''Multi Theft Auto'' trae por defecto algunos grupos con ciertos permisos. Estos son:&lt;br /&gt;
*'''Everyone''' - Toda cuenta registrada, por defecto, es añadida a este grupo.&lt;br /&gt;
*'''Moderator'''&lt;br /&gt;
*'''SuperModerator'''&lt;br /&gt;
*'''Admin'''&lt;br /&gt;
*'''Console''' - Este grupo controla los permisos del usuario de la Consola '''&amp;lt;object name=&amp;quot;user.Console&amp;quot; /&amp;gt;'''&lt;br /&gt;
*'''RPC''' - Remote Procedure Call. Specifically grants access to [[callRemote]] only and disables commands of default resources. Check the function for details.&lt;br /&gt;
*'''RPC''' - Procedimientos Remotos (En ingles, ''Remote Procedure Call''). Garantiza el acceso a [[callRemote]], para mas información revisa la información de la función.&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A modo de ejemplo, utilizare el grupo ''Everyone''. Por defecto, este luce así:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;group name=&amp;quot;Everyone&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.*&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.*&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
You will first notice the acl name inside the group. It defines what permissions the group has. Users and resources in this group will have the permissions specified on the &amp;quot;Default&amp;quot; acl name list. ''Note: You will notice this group is special, in that it includes every user and resource by using a '''wildcard (*)''' where the user or resource name would be.''&lt;br /&gt;
&lt;br /&gt;
Lo primero que deberías notar es el nombre ''ACL'' (''acl name'') asignado dentro del grupo. Esto define que permisos tiene el grupo en cuestión, usuarios y recursos en este grupo pueden acceder a los permisos especificados dentro de la lista ''ACL'' llamada &amp;quot;Default&amp;quot;.&lt;br /&gt;
''*Nota: Como notaras, este grupo en especial incluye a todos los usuarios y recursos gracias al uso del '''*'''.''&lt;br /&gt;
&lt;br /&gt;
Now, scroll further down the ACL and you will see the '''&amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;''' listing. Note I have trimmed this list dramatically due to its length.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.start&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stop&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stopall&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.executeCommandHandler&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.setPlayerMuted&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.restartResource&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_players&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_resources&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.shout&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.spectate&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
*'''Function''' entries are MTA scripting functions. For example, if a resource needed to use restartResource and was only in the 'Everyone' group (with the 'Default' list), it would be denied access to restartResource and fail to work correctly.&lt;br /&gt;
*'''Commands''' are created when a resource uses [[addCommandHandler]]. An example would be typing '''/createvehicle [vehicle]''' in the chatbox for the freeroam resource. This controls whether users in the group using this ACL can use the command. ''Note: commands have no effect on resources within the group. Commands are only related to users.''&lt;br /&gt;
**''General is a custom right name group created by the admin resource but it works on the same principles. The script works with them by using [[hasObjectPermissionTo]]''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will notice some groups such as admin have multiple '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' nodes. An example is the admin group:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;Admin&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Moderator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;SuperModerator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;RPC&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.webadmin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.Ransom&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This gives all the permissions defined in each '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' node in order of listing. So for example, the admin group makes sure all the permissions are given to admins by using all the lists. If there are any conflicts, the lowest entry wins. For example, pretend these 2 acls were in a group in the following order:&lt;br /&gt;
&lt;br /&gt;
'''1.''' '''&amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''2.''' '''&amp;lt;acl name=&amp;quot;Admin&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''3.''' For all users and resources in group admin: &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&amp;lt;br\&amp;gt;&lt;br /&gt;
&amp;lt;br\&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Resource Groups and ACLs ===&lt;br /&gt;
You will notice there are some other groups that came with MTA. These were defined by resources that came with MTA. If a resource wants to designate specific ACL rights not provided by the default MTA groups, it can create its own ACL name and a group to use it. I will show AMX's entry as an example. AMX is designed to emulate SA-MP scripts and it needs a certain set of permissions that doesn't fit the default groups well. It is shown below:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;AMX&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.amx&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;acl name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.startResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.stopResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.kick&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.mute&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Modifying the ACL==&lt;br /&gt;
There are three ways you can modify the ACL - how you do it depends who you are.&lt;br /&gt;
&lt;br /&gt;
===HTTP Interface===&lt;br /&gt;
You can use the [[Resource/webadmin|webadmin]] http interface to modify the ACL in your web browser. This is by far the easiest way to do so. Just make sure the ''webadmin'' resource is started on your server and visit ''&amp;lt;nowiki&amp;gt;http://ServerIP:HttpPort/&amp;lt;/nowiki&amp;gt;''. You can then use the two sections - ACLs and Groups. ACLs allows you to create your Access Control Lists - lists of rights. Groups allow you to group together collections of users and assign ACLs to them. For example, the ACLs section allows you to specify that the Admin ACL has access to the ''start'' console command. You can the go to the Groups section and create an Admin ''group'' that has access to your Admin ''acl''. You can then add users to your Admin ''group''.&lt;br /&gt;
&lt;br /&gt;
===XML file===&lt;br /&gt;
You can modify the ACL.xml file manually. This has a fairly straightforward syntax, but it can get a bit confusing at times. If you do it while the server is running, don't forget to call the scripting function [[aclReload]] (&amp;quot;start runcode&amp;quot;, &amp;quot;run aclReload()&amp;quot;) so the new ACL is loaded, or otherwise stop your server before modifying. This also prevents your changes from being accidentally overwritten by the server.&lt;br /&gt;
&lt;br /&gt;
===Scripting functions===&lt;br /&gt;
You can use a large number of ACL scripting functions to modify the ACL on the fly. Of course, you can (and really should!) limit access to the ACL functions with the ACL. Note that the '''admin resource''' that comes with MTA can be used to manage the ACL from the resources tab. You must be setup as admin to use the admin panel. [http://wiki.multitheftauto.com/wiki/Admin Click here for admin setup instructions].&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{ACL functions}}&lt;br /&gt;
[[Category:Scripting Concepts]]&lt;br /&gt;
[[ru:Access Control List]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38823</id>
		<title>ES/Página Principal</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38823"/>
		<updated>2014-02-09T19:27:48Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: ACL Añadido&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
__NOEDITSECTION__&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding: 10px; height: 140px;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Mtalogo.png|left|100px]]'''&lt;br /&gt;
Bienvenid@ a la Wiki de Multi Theft Auto: San Andreas en español.''' Aquí puedes encontrar mucha información sobre el uso de Multi Theft Auto. &lt;br /&gt;
&lt;br /&gt;
Hay muchas [[ES/Cómo puedes ayudar|cosas que puedes hacer para ayudarnos]] a mejorar MTA - crea un mapa, un modo de juego, escribe códigos de ejemplo, tutoriales, traduce páginas del inglés al español, o simplemente juega y reporta los bugs que encuentres.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:10px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Input-gaming.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== El Juego ===&lt;br /&gt;
&amp;lt;div style=&amp;quot;background: #FFEEAA;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Go-down.png|link=http://mtasa.com/]] ''' [http://mtasa.com/ Descargar Multi Theft Auto: San Andreas {{Current Version|full}}]'''&amp;lt;/div&amp;gt;&lt;br /&gt;
* [[ES/Manual del Cliente|Manual del Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[ES/Cambios en la versión 1.3|Cambios de la versión 1.3]] [[Image:flag_es.png|En Español|20px]] (Traducción 80%)&lt;br /&gt;
* [[ES/Problemas_Conocidos_-_FAQ|Problemas Conocidos]] [[Image:flag_es.png|En Español|20px]] (Traducción: 10%)&lt;br /&gt;
* [[Upgrading_from_MTA:Race|Cambiando MTA:Race a MTA:SA 1.0.x]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Manual del Servidor|Manual del Servidor]] [[Image:flag_es.png|En Español|20px]] (Traducción: 90%)&lt;br /&gt;
* [[Map_manager|El Resource &amp;quot;Map Manager&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&lt;br /&gt;
====Editor de Mapas====&lt;br /&gt;
*[[ES/Resource:Editor|Manual del Editor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[[Resource:Editor/EDF|EDF: Formato de Definiciones del Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[Resource:Editor/Plugins|Plugins para el Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[ES/Resource:Editor#Preguntas_Frecuentes|Preguntas Frecuentes]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
&lt;br /&gt;
====Bases de Datos====&lt;br /&gt;
* [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Scripts de Cliente|Scripts de Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Modules| Módulos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-development.png‎‎‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====Desarrollando Multi Theft Auto====&lt;br /&gt;
[[File:Go-down.png|link=http://nightly.mtasa.com/]] [http://nightly.mtasa.com/ Nightly builds]&lt;br /&gt;
* [[Compiling_MTASA|Compilando MTA:SA en Windows]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_Mac_OS_X|Compilando MTA:SA en Mac OS X]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_GNU_Linux|Compilando MTA:SA en GNU/Linux]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Coding guidelines|Guías de Codificación]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://code.google.com/p/mtasa-blue Google Code SVN] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/roadmap_page.php Seguimiento de Versiones] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/ Central de Reportes de Bugs] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-office.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
===Wiki - Cómo puedes ayudar===&lt;br /&gt;
* Termina la documentación para [[:Category:Incomplete|funciones incompletas]].&lt;br /&gt;
* [[:Category:Needs_Example|Crea ejemplos para eventos y funciones]].&lt;br /&gt;
* Revisa y verifica [[:Category:Needs Checking|páginas que necesitan revisión]].&lt;br /&gt;
* Escribe tutoriales para ayudar a la gente.&lt;br /&gt;
* Traduce las páginas del wiki.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Internet-group-chat.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Comunidad ===&lt;br /&gt;
* [http://forum.multitheftauto.com/ Foro] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [http://forum.multitheftauto.com/viewforum.php?f=122&amp;amp;sid=72be1c29dd00c4442f8112cc09818283 Sección en español] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [irc://irc.multitheftauto.com/mta Canal IRC] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://community.mtasa.com/ Comunidad MTA] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://www.youtube.com/user/MTAQA Canal de YouTube oficial] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding:4px 8px 8px 8px; margin:10px; text-align:center&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Osi symbol.png|75px|link=http://opensource.org/]]&lt;br /&gt;
'''Multi Theft Auto''' es un '''Proyecto Open Source'''. &lt;br /&gt;
¡Todos podemos contribuir a mejorar Multi Theft Auto!&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Accessories-text-editor.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Scripting ===&lt;br /&gt;
* [[ES/Resources|Introducción a los Resources]]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
** [[Resource Web Access|Acceso Web con Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[Meta.xml|Sobre el archivo &amp;quot;meta.xml&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[ES/ACL|Lista de Control del Acceso (ACL)]]  [[Image:flag_es.png|En Español|20px]] (Traducción: 10%)&lt;br /&gt;
* [[ES/Introducción a Lua|Introducción a Lua]] [[Image:flag_es.png|En Español|20px]] (Traducción: 85%)&lt;br /&gt;
** [[ES/Introducción a la Programación de GUI|Introducción al GUI]] [[Image:flag_es.png|En Español|20px]] (Traducción: 40%)&lt;br /&gt;
** [[Debugging|Tutorial de Depuración]] [[Image:flag_us.png|En Inglés|20px]] - Encontrar errores en scripts.&lt;br /&gt;
* [[ES/Useful_Functions| Funciones útiles]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Writing_Gamemodes|Escribiendo Modos de Juego]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
====Ayuda General de Lua====&lt;br /&gt;
*[http://www.lua.org/manual/5.1/es/manual.html Manual de Referencia de Lua 5.1]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[http://www.lua.org/pil/index.html Manual Programando en Lua]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://lua-users.org/wiki/TutorialDirectory Lua Wiki]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://nixstaller.berlios.de/manual/0.2/nixstaller_9.html Guía general de Lua de Nixstaller]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
====Referencia====&lt;br /&gt;
* [[Client Scripting Functions|Funciones de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Client Scripting Events|Eventos de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Funciones de Servidor|Funciones de Servidor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Server Scripting Events|Eventos de Servidor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;!-- Incomplete * [[Module functions|Lista de funciones de módulos externos de servidor]] [[Image:flag_us.png|En Inglés]] --&amp;gt;&lt;br /&gt;
* [[ES/Clases MTA| Clases de MTA]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
**[[Element tree| Árbol de Elementos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:System-file-manager.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====[[Id|Lista de ID's]]====&lt;br /&gt;
*[[Animations|Animaciones]]&lt;br /&gt;
*[[ES/Skins de Personajes|Skins]]&lt;br /&gt;
*[[CJ_Clothes|Ropa]]&lt;br /&gt;
*[[Garage|Garajes]]&lt;br /&gt;
*[[Interior IDs|Interiores]]&lt;br /&gt;
*[[Projectiles|Proyectiles]]&lt;br /&gt;
*[[Radar Blips|Iconos de Radar]]&lt;br /&gt;
*[[Sounds|Sonidos]]&lt;br /&gt;
*[[Vehicle IDs|ID's de Vehículos]]&lt;br /&gt;
*[[Vehicle Colors|Colores de Vehículos]]&lt;br /&gt;
*[[Vehicle Upgrades|Mejoras de Vehículos]]&lt;br /&gt;
*[[Weapons|Armas]]&lt;br /&gt;
*[[ES/Climas|Climas]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Equipo de Traducción====&lt;br /&gt;
* [mailto:zorrigas@gtagamingchile.com zorrigas@gtagamingchile.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:Brijido_XD@hotmail.com Brijido_XD@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* Benxamix2/The Kid&lt;br /&gt;
* [mailto:matiuno@gmail.com matiuno@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:cesarcastillo4@gmail.com cesarcastillo4@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:alex_firexx@hotmail.com alex_firexx@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:carlos_olivo@msn.com carlos_olivo@msn.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* AlexD&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
'''¡NO ELIMINES CONTENIDO SIN AUTORIZACIÓN!'''&amp;lt;br&amp;gt; Tampoco uses modismos, usa el Castellano (Internacional), y trata de que al traducir todo quede tan claro como puedas, y la ortografía sea la mejor posible.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
{{Languages list|es}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38822</id>
		<title>ES/ACL</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38822"/>
		<updated>2014-02-09T19:25:12Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: Introduccion traducida.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''Multi Theft Auto'' incluye una completa y útil Lista de Control de Acceso (''ACL'') la que te permite asegurar y limitar el acceso a distintas funciones, recursos del servidor de múltiples maneras.&lt;br /&gt;
&lt;br /&gt;
El concepto en ''Multi Theft Auto'' de ''ACL'' es el de dar a un objeto especifico una serie de derechos. En el caso de ''Multi Theft Auto'', los objetos son una de dos cosas - recursos o usuarios. Hay numerosos derechos disponibles en ''Multi Theft Auto'' - estos están enfocados principalmente en las funciones del lado del servidor.&lt;br /&gt;
&lt;br /&gt;
Lo que esto significa, esencialmente es que el ''ACL'' te permite escoger con exactitud a que funciones (un recurso o un usuario) pueden acceder. Esto, por ejemplo, puede prevenir que los jugadores de tu servidor sean capaces de ''banearse'' mutuamente o prevenir que errores en recursos aun no probados causen daños y problemas en tu servidor.&lt;br /&gt;
&lt;br /&gt;
Por supuesto ''un gran poder conlleva una gran responsabilidad'' y es muy sencillo causar graves problemas con los recursos, por ejemplo, deshabilitar la función [[spawnPlayer]] para cada recurso causaría que los jugadores ya no puedan ''spawnear''. Por supuesto, existen situaciones en las que se busca hacer esto. (Si deseas hacer que un solo recurso se encargue de ''spawnear'' a los jugadores, por ejemplo.)&lt;br /&gt;
&lt;br /&gt;
==Understanding the ACL==&lt;br /&gt;
There are two major components to the ACL: groups and ACL lists. They appear as '''&amp;lt;group name=&amp;quot;&amp;quot;&amp;gt;''' nodes and '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' nodes. Their purpose is to:&amp;lt;br \&amp;gt;&lt;br /&gt;
'''1.''' Grant users permission to control the server and use resource commands. Examples:''&amp;lt;br \&amp;gt;&lt;br /&gt;
*Allowing only admins to use the giveweapon function of freeroam&lt;br /&gt;
*Allowing all users to start a resource&lt;br /&gt;
'''2.''' Grant resources permission to use script functions and functions of other resources. Examples:&amp;lt;br \&amp;gt;&lt;br /&gt;
*Allowing a resource to use the restartResource function&lt;br /&gt;
*Allowing a resource to use the call function to use exported functions from another script&lt;br /&gt;
&lt;br /&gt;
===Default Groups===&lt;br /&gt;
MTA has provided some default groups with increasing permissions. These groups are:&lt;br /&gt;
*'''Everyone'''&lt;br /&gt;
*'''Moderator'''&lt;br /&gt;
*'''SuperModerator'''&lt;br /&gt;
*'''Admin'''&lt;br /&gt;
*'''Console''' - This controls permissions of people who are using the console through '''&amp;lt;object name=&amp;quot;user.Console&amp;quot; /&amp;gt;'''&lt;br /&gt;
*'''RPC''' - Remote Procedure Call. Specifically grants access to [[callRemote]] only and disables commands of default resources. Check the function for details.&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To explain further, I will use the Everyone group as an example. By default it looks like this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;group name=&amp;quot;Everyone&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.*&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.*&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
You will first notice the acl name inside the group. It defines what permissions the group has. Users and resources in this group will have the permissions specified on the &amp;quot;Default&amp;quot; acl name list. ''Note: You will notice this group is special, in that it includes every user and resource by using a '''wildcard (*)''' where the user or resource name would be.''&lt;br /&gt;
&lt;br /&gt;
Now, scroll further down the ACL and you will see the '''&amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;''' listing. Note I have trimmed this list dramatically due to its length.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.start&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stop&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stopall&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.executeCommandHandler&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.setPlayerMuted&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.restartResource&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_players&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_resources&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.shout&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.spectate&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
*'''Function''' entries are MTA scripting functions. For example, if a resource needed to use restartResource and was only in the 'Everyone' group (with the 'Default' list), it would be denied access to restartResource and fail to work correctly.&lt;br /&gt;
*'''Commands''' are created when a resource uses [[addCommandHandler]]. An example would be typing '''/createvehicle [vehicle]''' in the chatbox for the freeroam resource. This controls whether users in the group using this ACL can use the command. ''Note: commands have no effect on resources within the group. Commands are only related to users.''&lt;br /&gt;
**''General is a custom right name group created by the admin resource but it works on the same principles. The script works with them by using [[hasObjectPermissionTo]]''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will notice some groups such as admin have multiple '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' nodes. An example is the admin group:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;Admin&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Moderator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;SuperModerator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;RPC&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.webadmin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.Ransom&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This gives all the permissions defined in each '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' node in order of listing. So for example, the admin group makes sure all the permissions are given to admins by using all the lists. If there are any conflicts, the lowest entry wins. For example, pretend these 2 acls were in a group in the following order:&lt;br /&gt;
&lt;br /&gt;
'''1.''' '''&amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''2.''' '''&amp;lt;acl name=&amp;quot;Admin&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''3.''' For all users and resources in group admin: &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&amp;lt;br\&amp;gt;&lt;br /&gt;
&amp;lt;br\&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Resource Groups and ACLs ===&lt;br /&gt;
You will notice there are some other groups that came with MTA. These were defined by resources that came with MTA. If a resource wants to designate specific ACL rights not provided by the default MTA groups, it can create its own ACL name and a group to use it. I will show AMX's entry as an example. AMX is designed to emulate SA-MP scripts and it needs a certain set of permissions that doesn't fit the default groups well. It is shown below:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;AMX&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.amx&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;acl name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.startResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.stopResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.kick&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.mute&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Modifying the ACL==&lt;br /&gt;
There are three ways you can modify the ACL - how you do it depends who you are.&lt;br /&gt;
&lt;br /&gt;
===HTTP Interface===&lt;br /&gt;
You can use the [[Resource/webadmin|webadmin]] http interface to modify the ACL in your web browser. This is by far the easiest way to do so. Just make sure the ''webadmin'' resource is started on your server and visit ''&amp;lt;nowiki&amp;gt;http://ServerIP:HttpPort/&amp;lt;/nowiki&amp;gt;''. You can then use the two sections - ACLs and Groups. ACLs allows you to create your Access Control Lists - lists of rights. Groups allow you to group together collections of users and assign ACLs to them. For example, the ACLs section allows you to specify that the Admin ACL has access to the ''start'' console command. You can the go to the Groups section and create an Admin ''group'' that has access to your Admin ''acl''. You can then add users to your Admin ''group''.&lt;br /&gt;
&lt;br /&gt;
===XML file===&lt;br /&gt;
You can modify the ACL.xml file manually. This has a fairly straightforward syntax, but it can get a bit confusing at times. If you do it while the server is running, don't forget to call the scripting function [[aclReload]] (&amp;quot;start runcode&amp;quot;, &amp;quot;run aclReload()&amp;quot;) so the new ACL is loaded, or otherwise stop your server before modifying. This also prevents your changes from being accidentally overwritten by the server.&lt;br /&gt;
&lt;br /&gt;
===Scripting functions===&lt;br /&gt;
You can use a large number of ACL scripting functions to modify the ACL on the fly. Of course, you can (and really should!) limit access to the ACL functions with the ACL. Note that the '''admin resource''' that comes with MTA can be used to manage the ACL from the resources tab. You must be setup as admin to use the admin panel. [http://wiki.multitheftauto.com/wiki/Admin Click here for admin setup instructions].&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{ACL functions}}&lt;br /&gt;
[[Category:Scripting Concepts]]&lt;br /&gt;
[[ru:Access Control List]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38821</id>
		<title>ES/Página Principal</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38821"/>
		<updated>2014-02-09T19:14:46Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
__NOEDITSECTION__&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding: 10px; height: 140px;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Mtalogo.png|left|100px]]'''&lt;br /&gt;
Bienvenid@ a la Wiki de Multi Theft Auto: San Andreas en español.''' Aquí puedes encontrar mucha información sobre el uso de Multi Theft Auto. &lt;br /&gt;
&lt;br /&gt;
Hay muchas [[ES/Cómo puedes ayudar|cosas que puedes hacer para ayudarnos]] a mejorar MTA - crea un mapa, un modo de juego, escribe códigos de ejemplo, tutoriales, traduce páginas del inglés al español, o simplemente juega y reporta los bugs que encuentres.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:10px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Input-gaming.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== El Juego ===&lt;br /&gt;
&amp;lt;div style=&amp;quot;background: #FFEEAA;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Go-down.png|link=http://mtasa.com/]] ''' [http://mtasa.com/ Descargar Multi Theft Auto: San Andreas {{Current Version|full}}]'''&amp;lt;/div&amp;gt;&lt;br /&gt;
* [[ES/Manual del Cliente|Manual del Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[ES/Cambios en la versión 1.3|Cambios de la versión 1.3]] [[Image:flag_es.png|En Español|20px]] (Traducción 80%)&lt;br /&gt;
* [[ES/Problemas_Conocidos_-_FAQ|Problemas Conocidos]] [[Image:flag_es.png|En Español|20px]] (Traducción: 10%)&lt;br /&gt;
* [[Upgrading_from_MTA:Race|Cambiando MTA:Race a MTA:SA 1.0.x]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Manual del Servidor|Manual del Servidor]] [[Image:flag_es.png|En Español|20px]] (Traducción: 90%)&lt;br /&gt;
* [[Map_manager|El Resource &amp;quot;Map Manager&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&lt;br /&gt;
====Editor de Mapas====&lt;br /&gt;
*[[ES/Resource:Editor|Manual del Editor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[[Resource:Editor/EDF|EDF: Formato de Definiciones del Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[Resource:Editor/Plugins|Plugins para el Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[ES/Resource:Editor#Preguntas_Frecuentes|Preguntas Frecuentes]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
&lt;br /&gt;
====Bases de Datos====&lt;br /&gt;
* [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Scripts de Cliente|Scripts de Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Modules| Módulos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-development.png‎‎‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====Desarrollando Multi Theft Auto====&lt;br /&gt;
[[File:Go-down.png|link=http://nightly.mtasa.com/]] [http://nightly.mtasa.com/ Nightly builds]&lt;br /&gt;
* [[Compiling_MTASA|Compilando MTA:SA en Windows]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_Mac_OS_X|Compilando MTA:SA en Mac OS X]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_GNU_Linux|Compilando MTA:SA en GNU/Linux]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Coding guidelines|Guías de Codificación]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://code.google.com/p/mtasa-blue Google Code SVN] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/roadmap_page.php Seguimiento de Versiones] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/ Central de Reportes de Bugs] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-office.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
===Wiki - Cómo puedes ayudar===&lt;br /&gt;
* Termina la documentación para [[:Category:Incomplete|funciones incompletas]].&lt;br /&gt;
* [[:Category:Needs_Example|Crea ejemplos para eventos y funciones]].&lt;br /&gt;
* Revisa y verifica [[:Category:Needs Checking|páginas que necesitan revisión]].&lt;br /&gt;
* Escribe tutoriales para ayudar a la gente.&lt;br /&gt;
* Traduce las páginas del wiki.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Internet-group-chat.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Comunidad ===&lt;br /&gt;
* [http://forum.multitheftauto.com/ Foro] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [http://forum.multitheftauto.com/viewforum.php?f=122&amp;amp;sid=72be1c29dd00c4442f8112cc09818283 Sección en español] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [irc://irc.multitheftauto.com/mta Canal IRC] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://community.mtasa.com/ Comunidad MTA] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://www.youtube.com/user/MTAQA Canal de YouTube oficial] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding:4px 8px 8px 8px; margin:10px; text-align:center&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Osi symbol.png|75px|link=http://opensource.org/]]&lt;br /&gt;
'''Multi Theft Auto''' es un '''Proyecto Open Source'''. &lt;br /&gt;
¡Todos podemos contribuir a mejorar Multi Theft Auto!&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Accessories-text-editor.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Scripting ===&lt;br /&gt;
* [[ES/Resources|Introducción a los Resources]]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
** [[Resource Web Access|Acceso Web con Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[Meta.xml|Sobre el archivo &amp;quot;meta.xml&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[ACL]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Introducción a Lua|Introducción a Lua]] [[Image:flag_es.png|En Español|20px]] (Traducción: 85%)&lt;br /&gt;
** [[ES/Introducción a la Programación de GUI|Introducción al GUI]] [[Image:flag_es.png|En Español|20px]] (Traducción: 40%)&lt;br /&gt;
** [[Debugging|Tutorial de Depuración]] [[Image:flag_us.png|En Inglés|20px]] - Encontrar errores en scripts.&lt;br /&gt;
* [[ES/Useful_Functions| Funciones útiles]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Writing_Gamemodes|Escribiendo Modos de Juego]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
====Ayuda General de Lua====&lt;br /&gt;
*[http://www.lua.org/manual/5.1/es/manual.html Manual de Referencia de Lua 5.1]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[http://www.lua.org/pil/index.html Manual Programando en Lua]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://lua-users.org/wiki/TutorialDirectory Lua Wiki]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://nixstaller.berlios.de/manual/0.2/nixstaller_9.html Guía general de Lua de Nixstaller]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
====Referencia====&lt;br /&gt;
* [[Client Scripting Functions|Funciones de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Client Scripting Events|Eventos de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Funciones de Servidor|Funciones de Servidor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Server Scripting Events|Eventos de Servidor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;!-- Incomplete * [[Module functions|Lista de funciones de módulos externos de servidor]] [[Image:flag_us.png|En Inglés]] --&amp;gt;&lt;br /&gt;
* [[ES/Clases MTA| Clases de MTA]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
**[[Element tree| Árbol de Elementos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:System-file-manager.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====[[Id|Lista de ID's]]====&lt;br /&gt;
*[[Animations|Animaciones]]&lt;br /&gt;
*[[ES/Skins de Personajes|Skins]]&lt;br /&gt;
*[[CJ_Clothes|Ropa]]&lt;br /&gt;
*[[Garage|Garajes]]&lt;br /&gt;
*[[Interior IDs|Interiores]]&lt;br /&gt;
*[[Projectiles|Proyectiles]]&lt;br /&gt;
*[[Radar Blips|Iconos de Radar]]&lt;br /&gt;
*[[Sounds|Sonidos]]&lt;br /&gt;
*[[Vehicle IDs|ID's de Vehículos]]&lt;br /&gt;
*[[Vehicle Colors|Colores de Vehículos]]&lt;br /&gt;
*[[Vehicle Upgrades|Mejoras de Vehículos]]&lt;br /&gt;
*[[Weapons|Armas]]&lt;br /&gt;
*[[ES/Climas|Climas]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Equipo de Traducción====&lt;br /&gt;
* [mailto:zorrigas@gtagamingchile.com zorrigas@gtagamingchile.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:Brijido_XD@hotmail.com Brijido_XD@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* Benxamix2/The Kid&lt;br /&gt;
* [mailto:matiuno@gmail.com matiuno@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:cesarcastillo4@gmail.com cesarcastillo4@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:alex_firexx@hotmail.com alex_firexx@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:carlos_olivo@msn.com carlos_olivo@msn.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* AlexD&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
'''¡NO ELIMINES CONTENIDO SIN AUTORIZACIÓN!'''&amp;lt;br&amp;gt; Tampoco uses modismos, usa el Castellano (Internacional), y trata de que al traducir todo quede tan claro como puedas, y la ortografía sea la mejor posible.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
{{Languages list|es}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38820</id>
		<title>ES/Página Principal</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/P%C3%A1gina_Principal&amp;diff=38820"/>
		<updated>2014-02-09T19:13:51Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
__NOEDITSECTION__&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding: 10px; height: 140px;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Mtalogo.png|left|100px]]'''&lt;br /&gt;
Bienvenid@ a la Wiki de Multi Theft Auto: San Andreas en español.''' Aquí puedes encontrar mucha información sobre el uso de Multi Theft Auto. &lt;br /&gt;
&lt;br /&gt;
Hay muchas [[ES/Cómo puedes ayudar|cosas que puedes hacer para ayudarnos]] a mejorar MTA - crea un mapa, un modo de juego, escribe códigos de ejemplo, tutoriales, traduce páginas del inglés al español, o simplemente juega y reporta los bugs que encuentres.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:10px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Input-gaming.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== El Juego ===&lt;br /&gt;
&amp;lt;div style=&amp;quot;background: #FFEEAA;&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Go-down.png|link=http://mtasa.com/]] ''' [http://mtasa.com/ Descargar Multi Theft Auto: San Andreas {{Current Version|full}}]'''&amp;lt;/div&amp;gt;&lt;br /&gt;
* [[ES/Manual del Cliente|Manual del Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[ES/Cambios en la versión 1.3|Cambios de la versión 1.3]] [[Image:flag_es.png|En Español|20px]] (Traducción 80%)&lt;br /&gt;
* [[ES/Problemas_Conocidos_-_FAQ|Problemas Conocidos]] [[Image:flag_es.png|En Español|20px]] (Traducción: 10%)&lt;br /&gt;
* [[Upgrading_from_MTA:Race|Cambiando MTA:Race a MTA:SA 1.0.x]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Manual del Servidor|Manual del Servidor]] [[Image:flag_es.png|En Español|20px]] (Traducción: 90%)&lt;br /&gt;
* [[Map_manager|El Resource &amp;quot;Map Manager&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&lt;br /&gt;
====Editor de Mapas====&lt;br /&gt;
*[[ES/Resource:Editor|Manual del Editor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[[Resource:Editor/EDF|EDF: Formato de Definiciones del Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[Resource:Editor/Plugins|Plugins para el Editor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[[ES/Resource:Editor#Preguntas_Frecuentes|Preguntas Frecuentes]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
&lt;br /&gt;
====Bases de Datos====&lt;br /&gt;
* [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Scripts de Cliente|Scripts de Cliente]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Modules| Módulos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-development.png‎‎‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====Desarrollando Multi Theft Auto====&lt;br /&gt;
[[File:Go-down.png|link=http://nightly.mtasa.com/]] [http://nightly.mtasa.com/ Nightly builds]&lt;br /&gt;
* [[Compiling_MTASA|Compilando MTA:SA en Windows]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_Mac_OS_X|Compilando MTA:SA en Mac OS X]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Building_MTASA_Server_on_GNU_Linux|Compilando MTA:SA en GNU/Linux]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Coding guidelines|Guías de Codificación]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://code.google.com/p/mtasa-blue Google Code SVN] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/roadmap_page.php Seguimiento de Versiones] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://bugs.mtasa.com/ Central de Reportes de Bugs] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Applications-office.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
===Wiki - Cómo puedes ayudar===&lt;br /&gt;
* Termina la documentación para [[:Category:Incomplete|funciones incompletas]].&lt;br /&gt;
* [[:Category:Needs_Example|Crea ejemplos para eventos y funciones]].&lt;br /&gt;
* Revisa y verifica [[:Category:Needs Checking|páginas que necesitan revisión]].&lt;br /&gt;
* Escribe tutoriales para ayudar a la gente.&lt;br /&gt;
* Traduce las páginas del wiki.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Internet-group-chat.png‎]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Comunidad ===&lt;br /&gt;
* [http://forum.multitheftauto.com/ Foro] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [http://forum.multitheftauto.com/viewforum.php?f=122&amp;amp;sid=72be1c29dd00c4442f8112cc09818283 Sección en español] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [irc://irc.multitheftauto.com/mta Canal IRC] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://community.mtasa.com/ Comunidad MTA] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [http://www.youtube.com/user/MTAQA Canal de YouTube oficial] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding:4px 8px 8px 8px; margin:10px; text-align:center&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Osi symbol.png|75px|link=http://opensource.org/]]&lt;br /&gt;
'''Multi Theft Auto''' es un '''Proyecto Open Source'''. &lt;br /&gt;
¡Todos podemos contribuir a mejorar Multi Theft Auto!&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| width=&amp;quot;50%&amp;quot; style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:Accessories-text-editor.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Scripting ===&lt;br /&gt;
* [[ES/Resources|Introducción a los Resources]]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
** [[Resource Web Access|Acceso Web con Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[Meta.xml|Sobre el archivo &amp;quot;meta.xml&amp;quot;]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[:Category:Resource|Catálogo de Resources]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
** [[ES/ACL]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Introducción a Lua|Introducción a Lua]] [[Image:flag_es.png|En Español|20px]] (Traducción: 85%)&lt;br /&gt;
** [[ES/Introducción a la Programación de GUI|Introducción al GUI]] [[Image:flag_es.png|En Español|20px]] (Traducción: 40%)&lt;br /&gt;
** [[Debugging|Tutorial de Depuración]] [[Image:flag_us.png|En Inglés|20px]] - Encontrar errores en scripts.&lt;br /&gt;
* [[ES/Useful_Functions| Funciones útiles]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Writing_Gamemodes|Escribiendo Modos de Juego]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
====Ayuda General de Lua====&lt;br /&gt;
*[http://www.lua.org/manual/5.1/es/manual.html Manual de Referencia de Lua 5.1]  [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
*[http://www.lua.org/pil/index.html Manual Programando en Lua]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://lua-users.org/wiki/TutorialDirectory Lua Wiki]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
*[http://nixstaller.berlios.de/manual/0.2/nixstaller_9.html Guía general de Lua de Nixstaller]  [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
====Referencia====&lt;br /&gt;
* [[Client Scripting Functions|Funciones de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[Client Scripting Events|Eventos de Cliente]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
* [[ES/Funciones de Servidor|Funciones de Servidor]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
* [[Server Scripting Events|Eventos de Servidor]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;!-- Incomplete * [[Module functions|Lista de funciones de módulos externos de servidor]] [[Image:flag_us.png|En Inglés]] --&amp;gt;&lt;br /&gt;
* [[ES/Clases MTA| Clases de MTA]] [[Image:flag_es.png|En Español|20px]]&lt;br /&gt;
**[[Element tree| Árbol de Elementos]] [[Image:flag_us.png|En Inglés|20px]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px solid #D8D8D8; padding:4px 8px 8px 8px; margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;float:right; width: 32px;&amp;quot;&amp;gt;[[File:System-file-manager.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
====[[Id|Lista de ID's]]====&lt;br /&gt;
*[[Animations|Animaciones]]&lt;br /&gt;
*[[ES/Skins de Personajes|Skins]]&lt;br /&gt;
*[[CJ_Clothes|Ropa]]&lt;br /&gt;
*[[Garage|Garajes]]&lt;br /&gt;
*[[Interior IDs|Interiores]]&lt;br /&gt;
*[[Projectiles|Proyectiles]]&lt;br /&gt;
*[[Radar Blips|Iconos de Radar]]&lt;br /&gt;
*[[Sounds|Sonidos]]&lt;br /&gt;
*[[Vehicle IDs|ID's de Vehículos]]&lt;br /&gt;
*[[Vehicle Colors|Colores de Vehículos]]&lt;br /&gt;
*[[Vehicle Upgrades|Mejoras de Vehículos]]&lt;br /&gt;
*[[Weapons|Armas]]&lt;br /&gt;
*[[ES/Climas|Climas]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted #AAAAAA;padding:4px 8px 8px 8px;margin:10px;&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Equipo de Traducción====&lt;br /&gt;
* [mailto:zorrigas@gtagamingchile.com zorrigas@gtagamingchile.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:Brijido_XD@hotmail.com Brijido_XD@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* Benxamix2/The Kid&lt;br /&gt;
* [mailto:matiuno@gmail.com matiuno@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:cesarcastillo4@gmail.com cesarcastillo4@gmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:alex_firexx@hotmail.com alex_firexx@hotmail.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* [mailto:carlos_olivo@msn.com carlos_olivo@msn.com]&amp;lt;br&amp;gt;&lt;br /&gt;
* AlexD&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
'''¡NO ELIMINES CONTENIDO SIN AUTORIZACIÓN!'''&amp;lt;br&amp;gt; Tampoco uses modismos, usa el Castellano (Internacional), y trata de que al traducir todo quede tan claro como puedas, y la ortografía sea la mejor posible.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
{{Languages list|es}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38819</id>
		<title>ES/ACL</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/ACL&amp;diff=38819"/>
		<updated>2014-02-09T19:12:56Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: Created page with &amp;quot;MTA includes a complete Access Control List (ACL) that allows you to secure and limit access to the server, its functions and resources in any number of ways.  The key concept of...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;MTA includes a complete Access Control List (ACL) that allows you to secure and limit access to the server, its functions and resources in any number of ways.&lt;br /&gt;
&lt;br /&gt;
The key concept of MTA's ACL (and ACLs in general) is that you're giving a specific object a set of rights. In MTA's case objects are one of two things - resources or users. There are numerous ''rights'' available in MTA - these mainly focus on server-side scripting functions. &lt;br /&gt;
&lt;br /&gt;
What this essentially means is that the ACL allows you to choose exactly what functions a resource or user can perform. This can obviously be invaluable - for example preventing all your server's players from being able to ban each other, or preventing your new untested resources from doing the same. &lt;br /&gt;
&lt;br /&gt;
Of course, ''with great power comes great responsibility'' and it is very easily possible to completely break resources - for example, disabling [[spawnPlayer]] for all resources would be a Bad Thing. Of course, there are situations when you might want to do this - if you want to force all your resources to use a spawn manager resource for example, but even this is somewhat draconian.&lt;br /&gt;
&lt;br /&gt;
==Understanding the ACL==&lt;br /&gt;
There are two major components to the ACL: groups and ACL lists. They appear as '''&amp;lt;group name=&amp;quot;&amp;quot;&amp;gt;''' nodes and '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' nodes. Their purpose is to:&amp;lt;br \&amp;gt;&lt;br /&gt;
'''1.''' Grant users permission to control the server and use resource commands. Examples:''&amp;lt;br \&amp;gt;&lt;br /&gt;
*Allowing only admins to use the giveweapon function of freeroam&lt;br /&gt;
*Allowing all users to start a resource&lt;br /&gt;
'''2.''' Grant resources permission to use script functions and functions of other resources. Examples:&amp;lt;br \&amp;gt;&lt;br /&gt;
*Allowing a resource to use the restartResource function&lt;br /&gt;
*Allowing a resource to use the call function to use exported functions from another script&lt;br /&gt;
&lt;br /&gt;
===Default Groups===&lt;br /&gt;
MTA has provided some default groups with increasing permissions. These groups are:&lt;br /&gt;
*'''Everyone'''&lt;br /&gt;
*'''Moderator'''&lt;br /&gt;
*'''SuperModerator'''&lt;br /&gt;
*'''Admin'''&lt;br /&gt;
*'''Console''' - This controls permissions of people who are using the console through '''&amp;lt;object name=&amp;quot;user.Console&amp;quot; /&amp;gt;'''&lt;br /&gt;
*'''RPC''' - Remote Procedure Call. Specifically grants access to [[callRemote]] only and disables commands of default resources. Check the function for details.&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To explain further, I will use the Everyone group as an example. By default it looks like this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;group name=&amp;quot;Everyone&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.*&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.*&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
You will first notice the acl name inside the group. It defines what permissions the group has. Users and resources in this group will have the permissions specified on the &amp;quot;Default&amp;quot; acl name list. ''Note: You will notice this group is special, in that it includes every user and resource by using a '''wildcard (*)''' where the user or resource name would be.''&lt;br /&gt;
&lt;br /&gt;
Now, scroll further down the ACL and you will see the '''&amp;lt;acl name=&amp;quot;Default&amp;quot; /&amp;gt;''' listing. Note I have trimmed this list dramatically due to its length.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;    &amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.start&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stop&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.stopall&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.executeCommandHandler&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.setPlayerMuted&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.restartResource&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_players&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.tab_resources&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.shout&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.spectate&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;br \&amp;gt;&lt;br /&gt;
*'''Function''' entries are MTA scripting functions. For example, if a resource needed to use restartResource and was only in the 'Everyone' group (with the 'Default' list), it would be denied access to restartResource and fail to work correctly.&lt;br /&gt;
*'''Commands''' are created when a resource uses [[addCommandHandler]]. An example would be typing '''/createvehicle [vehicle]''' in the chatbox for the freeroam resource. This controls whether users in the group using this ACL can use the command. ''Note: commands have no effect on resources within the group. Commands are only related to users.''&lt;br /&gt;
**''General is a custom right name group created by the admin resource but it works on the same principles. The script works with them by using [[hasObjectPermissionTo]]''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will notice some groups such as admin have multiple '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' nodes. An example is the admin group:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;Admin&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Moderator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;SuperModerator&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;Admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;RPC&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.admin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.webadmin&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;user.Ransom&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This gives all the permissions defined in each '''&amp;lt;acl name=&amp;quot;&amp;quot; /&amp;gt;''' node in order of listing. So for example, the admin group makes sure all the permissions are given to admins by using all the lists. If there are any conflicts, the lowest entry wins. For example, pretend these 2 acls were in a group in the following order:&lt;br /&gt;
&lt;br /&gt;
'''1.''' '''&amp;lt;acl name=&amp;quot;Default&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''2.''' '''&amp;lt;acl name=&amp;quot;Admin&amp;quot;&amp;gt;''' sets &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt; &amp;lt;br\&amp;gt;&lt;br /&gt;
'''3.''' For all users and resources in group admin: &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&amp;lt;br\&amp;gt;&lt;br /&gt;
&amp;lt;br\&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Resource Groups and ACLs ===&lt;br /&gt;
You will notice there are some other groups that came with MTA. These were defined by resources that came with MTA. If a resource wants to designate specific ACL rights not provided by the default MTA groups, it can create its own ACL name and a group to use it. I will show AMX's entry as an example. AMX is designed to emulate SA-MP scripts and it needs a certain set of permissions that doesn't fit the default groups well. It is shown below:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;group name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;acl name=&amp;quot;AMX&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;object name=&amp;quot;resource.amx&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/group&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;acl name=&amp;quot;AMX&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.ModifyOtherObjects&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.startResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;function.stopResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;general.adminpanel&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.kick&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.freeze&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        &amp;lt;right name=&amp;quot;command.mute&amp;quot; access=&amp;quot;false&amp;quot; /&amp;gt;&lt;br /&gt;
        ...etc etc...&lt;br /&gt;
    &amp;lt;/acl&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Modifying the ACL==&lt;br /&gt;
There are three ways you can modify the ACL - how you do it depends who you are.&lt;br /&gt;
&lt;br /&gt;
===HTTP Interface===&lt;br /&gt;
You can use the [[Resource/webadmin|webadmin]] http interface to modify the ACL in your web browser. This is by far the easiest way to do so. Just make sure the ''webadmin'' resource is started on your server and visit ''&amp;lt;nowiki&amp;gt;http://ServerIP:HttpPort/&amp;lt;/nowiki&amp;gt;''. You can then use the two sections - ACLs and Groups. ACLs allows you to create your Access Control Lists - lists of rights. Groups allow you to group together collections of users and assign ACLs to them. For example, the ACLs section allows you to specify that the Admin ACL has access to the ''start'' console command. You can the go to the Groups section and create an Admin ''group'' that has access to your Admin ''acl''. You can then add users to your Admin ''group''.&lt;br /&gt;
&lt;br /&gt;
===XML file===&lt;br /&gt;
You can modify the ACL.xml file manually. This has a fairly straightforward syntax, but it can get a bit confusing at times. If you do it while the server is running, don't forget to call the scripting function [[aclReload]] (&amp;quot;start runcode&amp;quot;, &amp;quot;run aclReload()&amp;quot;) so the new ACL is loaded, or otherwise stop your server before modifying. This also prevents your changes from being accidentally overwritten by the server.&lt;br /&gt;
&lt;br /&gt;
===Scripting functions===&lt;br /&gt;
You can use a large number of ACL scripting functions to modify the ACL on the fly. Of course, you can (and really should!) limit access to the ACL functions with the ACL. Note that the '''admin resource''' that comes with MTA can be used to manage the ACL from the resources tab. You must be setup as admin to use the admin panel. [http://wiki.multitheftauto.com/wiki/Admin Click here for admin setup instructions].&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{ACL functions}}&lt;br /&gt;
[[Category:Scripting Concepts]]&lt;br /&gt;
[[ru:Access Control List]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Talk:Tutorial:_How_To_Create_DX_Window&amp;diff=38811</id>
		<title>Talk:Tutorial: How To Create DX Window</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Talk:Tutorial:_How_To_Create_DX_Window&amp;diff=38811"/>
		<updated>2014-02-05T19:16:25Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Is this necessary? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=User:Renkon&amp;diff=38810</id>
		<title>User:Renkon</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=User:Renkon&amp;diff=38810"/>
		<updated>2014-02-05T19:14:56Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Who am I==&lt;br /&gt;
&lt;br /&gt;
I'm a 18 year-old boy from Argentina who fancies playing Multi Theft Auto. I started playing SA-MP back in 2007 and moved to MTA in late 2009. Since then I have never left the community (although I got registered in 2010). I'm currently active in Drunk Drivers Club community and the forum itself.&lt;br /&gt;
&lt;br /&gt;
==Services==&lt;br /&gt;
&lt;br /&gt;
At the moment I offer my scripting services for MTA:SA. If you are interested please go to http://forum.mtasa.com/viewtopic.php?f=5&amp;amp;t=68603 (my service's forum thread)&lt;br /&gt;
&lt;br /&gt;
==Feedback==&lt;br /&gt;
&lt;br /&gt;
*Alexs_Steel approves this guy&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38502</id>
		<title>TakeWeapon</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38502"/>
		<updated>2014-01-18T17:15:00Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server  function}}&lt;br /&gt;
This function removes a specified weapon or ammo from a certain player's inventory.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool takeWeapon ( player thePlayer, int weaponId [, int ammo ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''thePlayer''': A player object referencing the specified player.&lt;br /&gt;
*'''weaponId''': An integer that refers to a [[weapon]] that you wish to remove.&lt;br /&gt;
&lt;br /&gt;
===Optional Arguments===&lt;br /&gt;
*'''ammo''': If used, this amount of ammo will be taken instead and the weapon will not be removed.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a ''true'' if the weapon/ammo was removed successfully, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example removes teargas from player.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler( 'rtear',&lt;br /&gt;
  function( thePlayer )&lt;br /&gt;
    takeWeapon( thePlayer, 17 )&lt;br /&gt;
  end&lt;br /&gt;
)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Weapon functions}}&lt;br /&gt;
[[ru:takeWeapon]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38501</id>
		<title>TakeWeapon</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38501"/>
		<updated>2014-01-18T17:14:35Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server  function}}&lt;br /&gt;
This function removes a specified weapon or ammo from a certain player's inventory.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool takeWeapon ( player thePlayer, int weaponId [, int ammo ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''thePlayer''': A player object referencing the specified player.&lt;br /&gt;
*'''weaponId''': An integer that refers to a [[weapon]] that you wish to remove.&lt;br /&gt;
&lt;br /&gt;
===Optional Arguments===&lt;br /&gt;
*'''ammo''': If used, this amount of ammo will be taken instead and the weapon will not be removed.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a ''true'' if the weapon/ammo was removed successfully, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example removes weapon 28 from player.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler( 'rtear',&lt;br /&gt;
  function( thePlayer )&lt;br /&gt;
    takeWeapon( thePlayer, 17 )&lt;br /&gt;
  end&lt;br /&gt;
)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Weapon functions}}&lt;br /&gt;
[[ru:takeWeapon]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38500</id>
		<title>TakeWeapon</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38500"/>
		<updated>2014-01-18T17:14:20Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server  function}}&lt;br /&gt;
This function removes a specified weapon or ammo from a certain player's inventory.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool takeWeapon ( player thePlayer, int weaponId [, int ammo ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''thePlayer''': A player object referencing the specified player.&lt;br /&gt;
*'''weaponId''': An integer that refers to a [[weapon]] that you wish to remove.&lt;br /&gt;
&lt;br /&gt;
===Optional Arguments===&lt;br /&gt;
*'''ammo''': If used, this amount of ammo will be taken instead and the weapon will not be removed.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a ''true'' if the weapon/ammo was removed successfully, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example removes weapon 28 from player.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler( 'rtear',&lt;br /&gt;
  function( thePlayer )&lt;br /&gt;
    takeWeapon( thePlayer, 17 )&lt;br /&gt;
  end&lt;br /&gt;
)[/lua]&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Weapon functions}}&lt;br /&gt;
[[ru:takeWeapon]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38499</id>
		<title>TakeWeapon</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=TakeWeapon&amp;diff=38499"/>
		<updated>2014-01-18T17:13:33Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Server  function}}&lt;br /&gt;
This function removes a specified weapon or ammo from a certain player's inventory.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool takeWeapon ( player thePlayer, int weaponId [, int ammo ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''thePlayer''': A player object referencing the specified player.&lt;br /&gt;
*'''weaponId''': An integer that refers to a [[weapon]] that you wish to remove.&lt;br /&gt;
&lt;br /&gt;
===Optional Arguments===&lt;br /&gt;
*'''ammo''': If used, this amount of ammo will be taken instead and the weapon will not be removed.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a ''true'' if the weapon/ammo was removed successfully, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example removes weapon 28 from player.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addCommandHandler( 'rtear',&lt;br /&gt;
  function( thePlayer )&lt;br /&gt;
    takeWeapon( thePlayer, 17 )&lt;br /&gt;
  end&lt;br /&gt;
)/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Weapon functions}}&lt;br /&gt;
[[ru:takeWeapon]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=AR/%D9%85%D9%82%D8%AF%D9%85%D9%87_%D9%81%D9%8A_%D8%A7%D9%84%D8%A8%D8%B1%D9%85%D8%AC%D9%87&amp;diff=38450</id>
		<title>AR/مقدمه في البرمجه</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=AR/%D9%85%D9%82%D8%AF%D9%85%D9%87_%D9%81%D9%8A_%D8%A7%D9%84%D8%A8%D8%B1%D9%85%D8%AC%D9%87&amp;diff=38450"/>
		<updated>2014-01-16T23:24:16Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: Reverse&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p align=&amp;quot;right&amp;quot;&amp;gt;  &lt;br /&gt;
السكربتات جزء أساسي في تشغيل MTA فتستطيع بإستخدامهم إنشاء تطبيقات لتحسين اللعب ، تختلف أنواع السكربتات فمنها خريطة أو وضع للعب &amp;quot; freeroam , race , deathmatch &amp;quot; وغيرها ..&lt;br /&gt;
&lt;br /&gt;
برمجة السكربتات تعتمد على لغة البرمجة (Lua) [www.lua.org] .&lt;br /&gt;
لغة البرمجة تعتمد إعتماداً كلياً على اللغة الإنجليزية , فيجب أن تكون لديك خلفية في اللغة الإنجليزية قبل المتابعة.&lt;br /&gt;
لبرمجة سكربت ما تحتاج لمحرر .. ويفضل إستخدام محرر إحترافي لكي يسهل عليك البرمجة مثل :&lt;br /&gt;
*Notepad++ [http://notepad-plus-plus.org/download]&lt;br /&gt;
*Lua Edit [http://luaedit.sourceforge.net/ LuaEdit]&lt;br /&gt;
لكن يفضل إستخدام برنامج MTASE فهو يسهل عملية إنشاء السكربتات وبرمجتها :&lt;br /&gt;
* [[MTASE|MTA Script Editor]].'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==إنشاء سكربت ==&lt;br /&gt;
سوف نتعلم كيف نقوم بإنشاء سكربت يدخل اللاعب إلى اللعبة .. خطوة بحطوة&lt;br /&gt;
===أين مسار كل البرامج النصية (السكريبتات أو المودات)؟===&lt;br /&gt;
الان نتعرف على مجلد المودات أو السكربتات.&lt;br /&gt;
اذهب إلى مجلد Multi Theft Auto واتبع المسار التالي:&lt;br /&gt;
&lt;br /&gt;
	/Your MTA Server/mods/deathmatch/resources/&lt;br /&gt;
&lt;br /&gt;
سترى الكثير من الملفات. ربما ترى مجلدات صيغتها .zip أو مجلد عادي , وجميعها يقبله الـ MTA ..&lt;br /&gt;
ولإنشاء المودات الخاصة بك: قم بعمل مجلد جديد واجعل اسمه كما تريد فمثلاً قم بتسميته &amp;quot;myserver&amp;quot; وهو الذي سنستخدمه بالبرنامج التعليمي&lt;br /&gt;
والان يجب أن يكون مسار المجلد الذي قمت بعمله هذا:&lt;br /&gt;
&lt;br /&gt;
	/Your MTA Server/mods/deathmatch/resources/myserver/&lt;br /&gt;
&lt;br /&gt;
* myserver: اسم المجلد الذي قمت بتسميته&lt;br /&gt;
&lt;br /&gt;
===تعريف السكربت (إضافة ملف meta.xml)===&lt;br /&gt;
حتى يستطيع السيرفر من معرفة المودات, يجب علينا إنشاء ملف meta.xml &lt;br /&gt;
&amp;quot; ويكون بداخل مجلد السكربت الذي قمنا بإنشائه وهو &amp;quot;myserver&amp;quot; &lt;br /&gt;
ولإنشاء ملف meta.xml : أفتح ملف نصي جديد وقم بتسميته meta.xml وافتحه باستخدام المفكرة =)&lt;br /&gt;
ولا تنسى ان يكون بداخل مجلد السكربت .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
أدخل الكود التالي في ملف ''meta.xml'':&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
     &amp;lt;info author=&amp;quot;إسمك&amp;quot; type=&amp;quot;gamemode&amp;quot; name=&amp;quot;إسم السكربت&amp;quot; description=&amp;quot;وصف بسيط للسكربت&amp;quot; /&amp;gt;&lt;br /&gt;
     &amp;lt;script src=&amp;quot;script.lua&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
هنا يتم تعريف أجزاء السكربت فمثلاً :&lt;br /&gt;
* &amp;lt;info ..&amp;gt;&lt;br /&gt;
تضع فيه بيانات السكربت .. مثل الإسم والنوع والوصف&lt;br /&gt;
* type=&amp;quot;gamemode&amp;quot;&lt;br /&gt;
تعني أن نوع السكربت هو مود لعب وتوجد أنواع عديدة مثل :&lt;br /&gt;
**gamemode&lt;br /&gt;
**map&lt;br /&gt;
**script&lt;br /&gt;
&lt;br /&gt;
===إنشاء ملف السكربت Lua===&lt;br /&gt;
قمنا بوضع هذا السطر في :&lt;br /&gt;
*meta.xml&lt;br /&gt;
:&lt;br /&gt;
		&amp;lt;script src=&amp;quot;script.lua&amp;quot; /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
الآن نقوم بإنشاء ملف نصي بنفس الإسم&lt;br /&gt;
**script.lua&lt;br /&gt;
بإستخدام برنامج التحرير لديك .. نقوم بإنشاء الكود&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function joinHandler() -- الوظيفة .. وبعدها نقوم بكتابة الإسم&lt;br /&gt;
	local x = 1959.55 -- تعريف x&lt;br /&gt;
	local y = -1714.46 -- تعريف y&lt;br /&gt;
	local z = 10 -- تعريف z&lt;br /&gt;
	spawnPlayer(source, x, y, z) -- نقوم بإستخدام هذه الوظيفة لإنتاج اللاعب ونقوم بتحديد اللاعب وهو المصدر : source&lt;br /&gt;
	fadeCamera(source, true) -- نقوم بعمل fade للكاميرا&lt;br /&gt;
	setCameraTarget(source, source) -- نجعل هدف الكاميرا هو اللاعب &lt;br /&gt;
	outputChatBox(&amp;quot;مرحباً بك في السيرفر&amp;quot;, source) -- نقوم بإخراج نص في الدردشة&lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerJoin&amp;quot;, getRootElement(), joinHandler) -- نقوم بإضافة المعالج حيث سيتم تشغيله بعد الحدث المحدد وهو عند دخول اللا&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
وصف وشرح الكود اعلاه : &lt;br /&gt;
	سيقوم السكربت بوضع اللاعب في الاحداثيات (x,y,z) المحدده اعلاه, عند دخوله الى السيرفر&lt;br /&gt;
	لاحظ انه يجب استخدام  وظيفة [ ''fadeCamera'' ] ستكون الشاشة سوداء وأيضاً يجب تعيين الكاميرا ( setTargetCamera ) ..&lt;br /&gt;
&lt;br /&gt;
نرى أن '''source''' هو المصدر وهو اللاعب الذي يقوم بالدخول &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
أيضاً لو رأينا في المعالج &lt;br /&gt;
*[[addEventHandler]] - إضافة معالج للحدث&lt;br /&gt;
نرى 3 أشياء&lt;br /&gt;
*: onPlayerJoin - عند دخول اللاعب&lt;br /&gt;
وهو الحدث .. حيث يحدد متى يتم تشغيل المعالج - في هذه الحالة عند دخول اللاعب&lt;br /&gt;
*getRootElement() - جلب العنصر الحالي&lt;br /&gt;
هذا يقوم بتعيين العنصر الذي يقوم بتشغيل الحدث &lt;br /&gt;
*joinHandler &lt;br /&gt;
وهو إسم الوظيفة التي قمنا بصناعتها &lt;br /&gt;
&lt;br /&gt;
يمكنك التوسع أكثر في : [[addEventHandler]]&lt;br /&gt;
&lt;br /&gt;
===تشغيل السكربت===&lt;br /&gt;
بعد أن تقوم بحفظ أجزاء السكربت في ملف واحد ويمكن حفظه في الملفات التالية :&lt;br /&gt;
* مجلد&lt;br /&gt;
* أرشيف .zip&lt;br /&gt;
ونقوم بنسخه إلى مجلد السكربتات داخل سيرفرك ونقوم بتشغيله بالطريقة العادية.&lt;br /&gt;
&lt;br /&gt;
الآن إنتهينا من صنع السكربت .. بعد هذا سنقوم بصنع سكربت مع أمر &lt;br /&gt;
* command&lt;br /&gt;
يمكنك المتابعة أو الذهاب إلى دورة صناعة النوافذ&lt;br /&gt;
*[[Introduction to Scripting GUI]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==صناعة أمر بسيط==&lt;br /&gt;
لنعد الآن إلى ملف&lt;br /&gt;
*script.lua&lt;br /&gt;
ونقوم بتعديله قليلاً لإنشاء أمر بسيط يقوم بإنشاء سيارة بجانب اللاعب&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- في البداية نقوم بكتب وظيفة إنشاء السيارة&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
   -- هنا نقوم بكتابة وظيفة إنشاء السيارة كـ&lt;br /&gt;
   -- createVehicle&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- نقوم بإضافة الأمر&lt;br /&gt;
addCommandHandler(&amp;quot;createvehicle&amp;quot;, createVehicleForPlayer) &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
''ملاحظة: يمكنك الضغط على الوظائف والتعمق فيها بداخل الويكي.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== الوظيفة ==&lt;br /&gt;
الوظيفة هي شيء يسمى&lt;br /&gt;
&lt;br /&gt;
function&lt;br /&gt;
&lt;br /&gt;
الوظيفة هي الشيء التي يتكون عليها الحدث&lt;br /&gt;
&lt;br /&gt;
يمكنك ان تسمي الوظيفة كما شئت ويمكنك أيضاً عدم وضع اسم للوظيفة&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''مثال لـ وظيفة لها إسم'''&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function arabs( ) -- الوظيفة&lt;br /&gt;
    outputChatBox(&amp;quot;مرحباً بك&amp;quot;) --s  ستلاحظ بـ أن كلمة &amp;quot; مرحباً بك &amp;quot; ظهرت في الشات عند دخول الاعب &lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerJoin&amp;quot;, root, arabs) -- .الحدث مع اسم الوظيفة&lt;br /&gt;
-- root = getRootElement()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''مثال لـ وظيفة ليس لها إسم'''&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerWasted&amp;quot;, root,&lt;br /&gt;
function(_,killer)&lt;br /&gt;
    outputChatBox( killer .. &amp;quot; من قبل&amp;quot; .. getPlayerName(source) .. &amp;quot; لقد قُتل الاعب&amp;quot; )&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
كما تلاحظ ووضع قوس قريباً من&lt;br /&gt;
&lt;br /&gt;
end)&lt;br /&gt;
&lt;br /&gt;
هذا القوس يكمل القوس الآخر كما نلاحظ في الحدث &lt;br /&gt;
&lt;br /&gt;
addEventHandler(&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== الحدث ==&lt;br /&gt;
الحدث هو شيء يسمى&lt;br /&gt;
&lt;br /&gt;
event&lt;br /&gt;
&lt;br /&gt;
الحدث هو الذي يتكون على بناء الوظيفة&lt;br /&gt;
فـ اذا رجعنا الى الامثلة التي في الاعلى سوف نرى عدة احداث ومنها&lt;br /&gt;
&lt;br /&gt;
[[onPlayerWasted]]&lt;br /&gt;
&lt;br /&gt;
الحدث ببساطة يحدد متى سوف تحدث او كيف سوف تحدث الوظائف التي ادخلتها&lt;br /&gt;
&lt;br /&gt;
onPlayerWasted&lt;br /&gt;
&lt;br /&gt;
عند موت الاعب&lt;br /&gt;
&lt;br /&gt;
'''مثال للحدث'''&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function onJoin()&lt;br /&gt;
    x, y, z = getElementPosition(source) -- s يآتي بمكان الاعب x, y, z&lt;br /&gt;
	    local theVehicle = createVehicle(445, x, y, z) -- s السيارة التي سـ تصنع بمكان الاعب الذي تم تحديده مسبقاً&lt;br /&gt;
		    warpPedIntoVehicle(source, theVehicle) -- s يجعل الاعب داخل السيارة&lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerJoin&amp;quot;, root, onJoin) -- s الحدث&lt;br /&gt;
-- root = getRootElement()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
هذه الوظيفة مع هذا الحدث سوف يعطون الاعب سيارة عند دخوله السيرفر&lt;br /&gt;
&lt;br /&gt;
ملاحظة الحدث ليس دائم على الوظيفة فـ أيصاً يمكنك تكوين هذه الوظيفة على حدث آخر&lt;br /&gt;
&lt;br /&gt;
'''مثال'''&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function onJoin()&lt;br /&gt;
    x, y, z = getElementPosition(source)&lt;br /&gt;
	    local theVehicle = createVehicle(445, x, y, z)&lt;br /&gt;
		    warpPedIntoVehicle(source, theVehicle)&lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerLogin&amp;quot;, root, onJoin)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
هذا سوف يعطي الاعب سيارة لاكن ليس عند دخوله السيرفر , إنما عند دخوله حسابه&lt;br /&gt;
&lt;br /&gt;
'''Edit'''&lt;br /&gt;
&lt;br /&gt;
مثال آخر&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onVehicleExplode&amp;quot;,root, -- نضيف حدث عند إنفجار اي سيارة&lt;br /&gt;
    function() -- الوظيفة&lt;br /&gt;
        setTimer(destroyElement,5000,1,source) -- يخفي السيارة بعد 5 ثواني من انفاجرها &lt;br /&gt;
    end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
يمكنك ان تجد&lt;br /&gt;
الاحداث&lt;br /&gt;
والوظائف &lt;br /&gt;
كلنت وسيرفر&lt;br /&gt;
هنا&lt;br /&gt;
&lt;br /&gt;
كلنت:&lt;br /&gt;
&lt;br /&gt;
'''وظائف كلنت'''&lt;br /&gt;
&lt;br /&gt;
http://wiki.multitheftauto.com/wiki/Client_Scripting_Functions&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''احداث كلنت'''&lt;br /&gt;
&lt;br /&gt;
http://wiki.multitheftauto.com/wiki/Client_Scripting_Events&lt;br /&gt;
&lt;br /&gt;
سيرفر:&lt;br /&gt;
&lt;br /&gt;
'''وظائف سيرفر'''&lt;br /&gt;
&lt;br /&gt;
http://wiki.multitheftauto.com/wiki/Server_Scripting_Functions&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''احداث سيرفر'''&lt;br /&gt;
&lt;br /&gt;
http://wiki.multitheftauto.com/wiki/Server_Scripting_Events&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== String الـ ==&lt;br /&gt;
السترنج هو شيء يوجد في بعض الوظايف التي توجد داخل الام تي اي&lt;br /&gt;
&lt;br /&gt;
مثلاً&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onResourceStart&amp;quot;,resourceRoot, -- الايفنت هنا يجب ان تكون بين سترنق كما الموضح هنا&lt;br /&gt;
    function()&lt;br /&gt;
        outputChatBox(&amp;quot;تم بدء السكربت&amp;quot;) -- s هنا سوف يظهر رسالة بالشات &amp;quot; تم بدء السكربت &amp;quot; عند بدء السكربت ويجب ان تكون سترنق&lt;br /&gt;
    end&lt;br /&gt;
) -- نهاية قوس الحدث&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
السترنق له عدة أشكال , فيمكن ان يكون كالآتي&lt;br /&gt;
&lt;br /&gt;
&amp;quot;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
أو&lt;br /&gt;
&lt;br /&gt;
' '&lt;br /&gt;
&lt;br /&gt;
أو&lt;br /&gt;
&lt;br /&gt;
[[]]&lt;br /&gt;
&lt;br /&gt;
فمثلاً اذا نريد ان نخرج رسالة بعلبة الشات&lt;br /&gt;
&lt;br /&gt;
يمكن ان تكون كذلك &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
outputChatBox([[مرحباً]])&lt;br /&gt;
&lt;br /&gt;
-- أو كذلك&lt;br /&gt;
outputChatBox('مرحباً')&lt;br /&gt;
&lt;br /&gt;
-- أو كذلك&lt;br /&gt;
&lt;br /&gt;
outputChatBox(&amp;quot;مرحباً&amp;quot;)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Command handlerعن الـ====&lt;br /&gt;
.(`) أو زر F8 التي يمكن للاعب ان يعرضها باستخدام زر Consoleهو اسم الامر الذي يمكن للاعب ان يدخله في الـ [[addCommandHandler]] في argument أول&lt;br /&gt;
&lt;br /&gt;
.&amp;quot;createVehicleForPlayer&amp;quot;هي وظيفة تُنفذ عند كتابة اللاعب الامر في هذه الحالة لـ [[addCommandHandler]] في argument ثاني&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
:اذا كنت متمرس في البرمجة, ستعرف انك ستحتاج ان تنفذ وظيفة مثل&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
functionName(argument1, argument2, argument3, ..)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
functionName(thePlayer, commandName, argument3, ..)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
If we have a closer look on the lower example above, we can see argument1 is thePlayer and argument2 the commandName. thePlayer is simply the one who typed the command, so whatever you call it, the variable will contain the player who activated the command. commandName is simply the command they typed. So if they typed &amp;quot;/greet&amp;quot;, this argument will contain &amp;quot;greet&amp;quot;. Argument 3 is something extra the player typed, you'll learn it a little bit further in the tutorial. Never forget that the first 2 arguments are standard arguments, but you can name them to anything you want.&lt;br /&gt;
&lt;br /&gt;
We called the [[addCommandHandler]] function this way already and since ''createVehicleForPlayer'' is a function too, it can be called that way as well. But we are using a command handler for that, which calls it in a similiar manner, internally.&lt;br /&gt;
&lt;br /&gt;
For example: Someone types &amp;quot;createvehicle 468&amp;quot; ingame in the console to spawn a Sanchez, the command handler calls the createVehicleForPlayer function, as '''if''' we would have this line of code in the script:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
createVehicleForPlayer(thePlayer,&amp;quot;createvehicle&amp;quot;,&amp;quot;468&amp;quot;) -- thePlayer is the player element of the player who entered the command&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
As we can see, it provides several parameters: the player who called the command, the command he entered and whatever text he had after that, in this case &amp;quot;468&amp;quot; as vehicle id for the Sanchez. The first two parameters are the same with all command handlers, which you can read on the [[addEventHandler]] page. For this fact, you always have to define at least those two parameters to use any after that (for example to process text that was entered after the command, like in our example the vehicle model id).&lt;br /&gt;
&lt;br /&gt;
''Note: You have to add the command handler AFTER you defined the handler function, else it can't find it. The order of execution matters.''&lt;br /&gt;
&lt;br /&gt;
====Writing the function====&lt;br /&gt;
In order to fill the function we created, we need to think about what we have to do:&lt;br /&gt;
* Get the players position, so we know where to spawn the vehicle (we want it to appear right beside the player)&lt;br /&gt;
* Calculate the position we want to spawn the vehicle at (we don't want it to appear in the player)&lt;br /&gt;
* Spawn the vehicle&lt;br /&gt;
* Check if it has been spawned successfully, or output a message&lt;br /&gt;
&lt;br /&gt;
In order to achieve our goals, we have to use several functions. To find function we need to use, we should visit the [[Scripting Functions|Server Functions List]]. First we need a function to get the players position. Since players are Elements, we first jump to the '''Element functions''' where we find the [[getElementPosition]] function. By clicking on the function name in the list, you get to the function description. There we can see the syntax, what it returns and usually an example. The syntax shows us what arguments we can or have to submit.&lt;br /&gt;
&lt;br /&gt;
For [[getElementPosition]], the syntax is:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementPosition ( element theElement )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The three ''float'' in front of the function name are the return type. In this case it means the function returns three floating point numbers. (x, y and z) Within the parentheses, you can see what arguments you have to submit. In this case only the element whose position you want to get, which is the player in our example.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	-- get the position and put it in the x,y,z variables&lt;br /&gt;
	-- (local means, the variables only exist in the current scope, in this case, the function)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Next we want to ensure that the vehicle won't spawn directly in the player, so we add a few units to the ''x'' variable, which will make it spawn east from the player.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer) -- get the position of the player&lt;br /&gt;
	x = x + 5 -- add 5 units to the x position&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now we need another function, one to spawn a vehicle. We once again search for it on the [[Scripting Functions|Server Functions List]], this time - since we are talking about vehicles - in the '''Vehicle functions''' section, where we will choose [[createVehicle]]. In this function's syntax, we only have one return type (which is more common), a vehicle element that points to the vehicle we just created. Also, we see that some arguments are enclosed within [ ] which means that those are optional.&lt;br /&gt;
&lt;br /&gt;
We already have all arguments we need for [[createVehicle]] in our function: The position we just calculated in the ''x,y,z'' variables and the model id that we provided through the command (&amp;quot;createvehicle 468&amp;quot;) and can access in the function as ''vehicleModel'' variable.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer) -- get the position of the player&lt;br /&gt;
	x = x + 5 -- add 5 units to the x position&lt;br /&gt;
	-- create the vehicle and store the returned vehicle element in the ''createdVehicle'' variable&lt;br /&gt;
	local createdVehicle = createVehicle(tonumber(vehicleModel),x,y,z)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Of course this code can be improved in many ways, but at least we want to add a check whether the vehicle was created successfully or not. As we can read on the [[createVehicle]] page under '''Returns''', the function returns ''false'' when it was unable to create the vehicle. Thus, we check the value of the ''createVehicle'' variable.&lt;br /&gt;
&lt;br /&gt;
Now we have our complete script:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer) -- get the position of the player&lt;br /&gt;
	x = x + 5 -- add 5 units to the x position&lt;br /&gt;
	local createdVehicle = createVehicle(tonumber(vehicleModel),x,y,z)&lt;br /&gt;
	-- check if the return value was ''false''&lt;br /&gt;
	if (createdVehicle == false) then&lt;br /&gt;
		-- if so, output a message to the chatbox, but only to this player.&lt;br /&gt;
		outputChatBox(&amp;quot;Failed to create vehicle.&amp;quot;,thePlayer)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;createvehicle&amp;quot;, createVehicleForPlayer)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, we introduced another function with [[outputChatBox]]. By now, you should be able to explore the function's documentation page yourself. For more advanced scripting, please check out the [[Map manager|Map Manager]].&lt;br /&gt;
&lt;br /&gt;
==What you need to know==&lt;br /&gt;
You already read some things about resources, command handlers and finding functions in the documentation in the first paragraph, but there is much more to learn. This section will give you a rather short overview over some of these things, while linking to related pages if possible.&lt;br /&gt;
===Clientside and Serverside scripts===&lt;br /&gt;
You may have already noticed these or similiar terms (Server/Client) somewhere on this wiki, mostly in conjunction with functions. MTA not only supports scripts that run on the server and provide commands (like the one we wrote above) or other features, but also scripts that run on the MTA client the players use to connect to the server. The reason for this is, that some features MTA provides have to be clientside (like a GUI - Graphical User Interface), others should be because they work better and still others are better off to be serverside or just don't work clientside.&lt;br /&gt;
&lt;br /&gt;
Most scripts you will make (gamemodes, maps) will probably be serverside, like the one we wrote in the first section. If you run into something that can't be solved serverside, you will probably have to make it clientside. For a clientside script for example, you would create a ordinary script file (for example called ''client.lua'') and specify it in the meta.xml, like this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;script src=&amp;quot;client.lua&amp;quot; type=&amp;quot;client&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
The ''type'' attribute defaults to 'server', so you only need to specify it for clientside scripts. When you do this, the clientside script will be downloaded to the player's computer once he connects to the server. Read more about [[Client side scripts]].&lt;br /&gt;
&lt;br /&gt;
===More complex resources===&lt;br /&gt;
The previous section showed briefly how to add clientside scripts to the resource, but there is also much more possible. As mentioned at the very top of this page, resources can be pretty much everything. Their purpose is defined by what they do. Let's have some theoretical resources, by looking at the files it contains, the ''meta.xml'' and what they might do:&lt;br /&gt;
&lt;br /&gt;
====First example - A utility script====&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
/admin_commands&lt;br /&gt;
	/meta.xml&lt;br /&gt;
	/commands.lua&lt;br /&gt;
	/client.lua&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
	&amp;lt;info author=&amp;quot;Someguy&amp;quot; description=&amp;quot;admin commands&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;commands.lua&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;client.lua&amp;quot; type=&amp;quot;client&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The ''commands.lua'' provides some admin commands, like banning a player, muting or something else that can be used to admin the server&lt;br /&gt;
* The ''client.lua'' provides a GUI to be able to perform the mentioned actions easily&lt;br /&gt;
&lt;br /&gt;
This example might be running all the time (maybe even auto-started when the server starts) as it's useful during the whole gaming experience and also wont interfere with the gameplay, unless an admin decides to take some action of course.&lt;br /&gt;
&lt;br /&gt;
====Second example - A gamemode====&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
/counterstrike&lt;br /&gt;
	/meta.xml&lt;br /&gt;
	/counterstrike.lua&lt;br /&gt;
	/buymenu.lua&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
	&amp;lt;info author=&amp;quot;Someguy&amp;quot; description=&amp;quot;Counterstrike remake&amp;quot; type=&amp;quot;gamemode&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;counterstrike.lua&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;buymenu.lua&amp;quot; type=&amp;quot;client&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The ''counterstrike.lua'' contains similiar to the following features:&lt;br /&gt;
** Let players choose their team and spawn them&lt;br /&gt;
** Provide them with weapons, targets and instructions (maybe read from a Map, see below)&lt;br /&gt;
** Define the game's rules, e.g. when does the round end, what happens when a player dies&lt;br /&gt;
** .. and maybe some more&lt;br /&gt;
* The ''buymenu.lua'' is a clientside script and creates a menu to buy weapons&lt;br /&gt;
&lt;br /&gt;
This example can be called a gamemode, since it not only intereferes with the gameplay, but actually defines the rules of it. The ''type'' attribute indicates that this example works with the [[Map manager]], yet another resource that was written by the QA Team to manage gamemodes and map loading. It is highly recommended that you base your gamemodes on the techniques it provides.&lt;br /&gt;
&lt;br /&gt;
This also means that the gamemode probably won't run without a map. Gamemodes should always be as generic as possible. An example for a map is stated in the next example.&lt;br /&gt;
&lt;br /&gt;
====Third example - A Map====&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
/cs-airport&lt;br /&gt;
	/meta.xml&lt;br /&gt;
	/airport.map&lt;br /&gt;
	/airport.lua&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
	&amp;lt;info author=&amp;quot;Someguy&amp;quot; description=&amp;quot;Counterstrike airport map&amp;quot; type=&amp;quot;map&amp;quot; gamemodes=&amp;quot;counterstrike&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;map src=&amp;quot;airport.map&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;airport.lua&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The ''airport.map'' in a XML file that provides information about the map to the gamemode, these may include:&lt;br /&gt;
** Where the players should spawn, with what weapons, what teams there are&lt;br /&gt;
** What the targets are&lt;br /&gt;
** Weather, World Time, Timelimit&lt;br /&gt;
** Provide vehicles&lt;br /&gt;
* The ''airport.lua'' might contain map-specific features, that may include:&lt;br /&gt;
** Opening some door/make something explode when something specific happens&lt;br /&gt;
** Create or move some custom objects, or manipulate objects that are created through the .map file&lt;br /&gt;
** .. anything else map-specific you can think of&lt;br /&gt;
&lt;br /&gt;
As you can see, the ''type'' attribute changed to 'map', telling the [[Map manager]] that this resource is a map, while the ''gamemodes'' attribute tells it for which gamemodes this map is valid, in this case the gamemode from the above example.&lt;br /&gt;
What may come as a surprise is that there is also a script in the Map resource. Of course this is not necessarily needed in a map, but opens a wide range of possibilities for map makers to create their own world within the rules of the gamemode they create it for.&lt;br /&gt;
&lt;br /&gt;
The ''airport.map'' file might look similiar to this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;map mode=&amp;quot;deathmatch&amp;quot; version=&amp;quot;1.0&amp;quot;&amp;gt;&lt;br /&gt;
	&amp;lt;terrorists&amp;gt;&lt;br /&gt;
		&amp;lt;spawnpoint posX=&amp;quot;2332.23&amp;quot; posY=&amp;quot;-12232.33&amp;quot; posZ=&amp;quot;4.42223&amp;quot; skins=&amp;quot;23-40&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;/terrorists&amp;gt;&lt;br /&gt;
	&amp;lt;counterterrorists&amp;gt;&lt;br /&gt;
		&amp;lt;spawnpoint posX=&amp;quot;2334.23443&amp;quot; posY=&amp;quot;-12300.233&amp;quot; posZ=&amp;quot;10.2344&amp;quot; skins=&amp;quot;40-50&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;/counterterrorists&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;bomb posX=&amp;quot;23342.23&amp;quot; posY=&amp;quot;&amp;quot; posZ=&amp;quot;&amp;quot; /&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	&amp;lt;vehicle posX=&amp;quot;&amp;quot; posY=&amp;quot;&amp;quot; posZ=&amp;quot;&amp;quot; model=&amp;quot;602&amp;quot; /&amp;gt;	&lt;br /&gt;
	&amp;lt;vehicle posX=&amp;quot;&amp;quot; posY=&amp;quot;&amp;quot; posZ=&amp;quot;&amp;quot; model=&amp;quot;603&amp;quot; /&amp;gt;	&lt;br /&gt;
&amp;lt;/map&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When a gamemode is started with a map, the map resources is automatically started by the mapmanager and the information it contains can be read by the gamemode resource. When the map changes, the current map resource is stopped and the next map resource is started. For a more in-depth explanation and examples of how map resources are utilized in the main script, please visit the [[Writing Gamemodes]] page.&lt;br /&gt;
&lt;br /&gt;
===Events===&lt;br /&gt;
Events are the way MTA tells scripts about things that happen. For example when a player dies, the [[onPlayerWasted]] event is triggered. In order to perform any actions when a player dies, you have to prepare yourself similiar to adding a command handler, as shown in [[#Writing_the_script|the first chapter]].&lt;br /&gt;
&lt;br /&gt;
This example will output a message with the name of the player who died:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function playerDied(totalAmmo, killer, killerWeapon, bodypart)&lt;br /&gt;
	outputChatBox(getPlayerName(source)..&amp;quot; died!&amp;quot;)&lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerWasted&amp;quot;,getRootElement(),playerDied)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Instead of showing what arguments are needed, the documentation page for Events shows what parameters are passed to the handler function, similiar to the way a [[#About_command_handlers|command handler]] does, just that it is different from event to event. Another important point is the ''source'' variable, that exists in handler functions. It doesn't have to be added to the parameter list of the function, but it still exists. It has a different value from event to event, for player events (as in the example above) it is the player element. As another example, you can take a look at the basic spawning player script in the first section to get an idea how ''source'' is used.&lt;br /&gt;
&lt;br /&gt;
==Where to go from here==&lt;br /&gt;
You should now be familiar with the most basic aspects of MTA scripting and also a bit with the documentation. The [[Main Page]] provides you with links to more information, Tutorials and References that allow a deeper look into the topics you desire to learn about.&lt;br /&gt;
&lt;br /&gt;
From here we recommend reading the [[debugging]] tutorial. Good debugging skills are an absolute necessity when you are making scripts.&lt;br /&gt;
&lt;br /&gt;
[[ru:Scripting Introduction]]&lt;br /&gt;
[[it:Introduzione allo scripting]]&lt;br /&gt;
[[es:Introducción a la Programación]]&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=User_talk:TheBest12&amp;diff=38449</id>
		<title>User talk:TheBest12</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=User_talk:TheBest12&amp;diff=38449"/>
		<updated>2014-01-16T23:22:46Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: ;)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== bam ==&lt;br /&gt;
&lt;br /&gt;
ban this idiot&lt;br /&gt;
&lt;br /&gt;
== Comments ==&lt;br /&gt;
&lt;br /&gt;
Alexs_Steel: +1&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Introduction_to_Scripting_the_GUI&amp;diff=38448</id>
		<title>Introduction to Scripting the GUI</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Introduction_to_Scripting_the_GUI&amp;diff=38448"/>
		<updated>2014-01-16T23:20:57Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: *facepalm* &amp;quot;hack&amp;quot; solved&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;!-- place holder --&amp;gt;&lt;br /&gt;
One important feature in MTA:SA is the ability to script customized GUI (Graphic User Interface). The GUI consists of windows, button, edit boxes, check boxes... Almost every standard form components in graphical environments. They can be displayed while the user is in game, and used for inputs and outputs in place of traditional commands. &lt;br /&gt;
&lt;br /&gt;
[[Image:AdminGUI.png|thumb|Admin Console GUI]]&lt;br /&gt;
&lt;br /&gt;
==A tutorial to make a login window==&lt;br /&gt;
In this tutorial we'll make a simple login window, with two input boxes and a button. The window appears when the player joins the game, and once the button is clicked, the player is spawned. The tutorial will continue the gamemode we made in [[Scripting Introduction|Introduction to Scripting]] ''(If you have used the [[Scripting Introduction|Introduction to Scripting]], you will need to remove or comment the [[spawnPlayer]] line in the &amp;quot;joinHandler&amp;quot; function in your code, as we will be replacing it with a gui alternative in this tutorial)''. We'll also take a look at client-side scripting. &lt;br /&gt;
&lt;br /&gt;
===Draw the window===&lt;br /&gt;
All the GUI must be made client side. It is also a good practice to keep all the client scripts in a separate folder. &lt;br /&gt;
&lt;br /&gt;
Browse to /Your MTA Server/mods/deathmatch/resources/myserver/ directory, and create a folder named &amp;quot;client&amp;quot;. Under /client/ directory, create a text file and name it &amp;quot;gui.lua&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
In this file we will write a funtion that draws the window. To create a window we will use [[guiCreateWindow]]:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createLoginWindow()&lt;br /&gt;
	-- define the X and Y positions of the window&lt;br /&gt;
	local X = 0.375&lt;br /&gt;
	local Y = 0.375&lt;br /&gt;
	-- define the width and height of the window&lt;br /&gt;
	local Width = 0.25&lt;br /&gt;
	local Height = 0.25&lt;br /&gt;
	-- create the window and save its element value into the variable 'wdwLogin'&lt;br /&gt;
	-- click on the function's name to read its documentation&lt;br /&gt;
	wdwLogin = guiCreateWindow(X, Y, Width, Height, &amp;quot;Please Log In&amp;quot;, true)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Relative and Absolute===&lt;br /&gt;
Note that the final argument passed to guiCreateWindow in the above example is ''true''. This indicates that the coordinates and dimensions of the window are '''relative''', meaning they are a ''percentage'' of the total screen size. This means that if the far left side of the screen is 0, and the far right is 1, an X position of 0.5 would represent the centre point of the screen. Similarly, if the top of the screen is 0 and the bottom is 1, a Y position of 0.2 would be 20% of the way down the screen. The same principles apply to both Width and Height as well (with a Width value of 0.5 meaning the window will be half as wide as the screen).&lt;br /&gt;
&lt;br /&gt;
The alternative to using relative values is using '''absolute''' (by passing ''false'' instead of true to guiCreateWindow). Absolute values are calculated as the total number of pixels from the top-left corner of the parent (if no gui element parent is specified, the parent is the screen itself). If we assume a screen resolution of 1920x1200, the far left side of the screen being 0 pixels and the far right being 1920 pixels, an X position of 960 will represent the centre point of the screen. Similarly, if the top of the screen is 0 pixels and the bottom is 1200, a Y position of 20 would be 20 pixels down from the top of the screen. The same principles apply to both Width and Height as well (with a Width value of 50 meaning the window will be 50 pixels wide). ''You can use [[guiGetScreenSize]] and a little maths to calculate certain absolute positions.''&lt;br /&gt;
&lt;br /&gt;
The differences between using relative and absolute values is quite simple; gui created using absolute values will always remain exactly the same pixel size and position, while gui created using relative values will always be a percentage of its parent's size.&lt;br /&gt;
&lt;br /&gt;
Absolute is generally easier to maintain when editing code by hand, however your choice of type depends on the situation you are using it for.&lt;br /&gt;
&lt;br /&gt;
For the purposes of this introduction we will be using relative values.&lt;br /&gt;
&lt;br /&gt;
===Adding the components===&lt;br /&gt;
Next, we'll add the text labels (saying &amp;quot;username:&amp;quot; and &amp;quot;password:&amp;quot;), edit boxes (for entering your data) and a button to log in.&lt;br /&gt;
&lt;br /&gt;
To create buttons we use [[guiCreateButton]] and to create edit boxes use [[guiCreateEdit]]:&lt;br /&gt;
&lt;br /&gt;
'''Note that we are now writing more code for our existing 'createLoginWindow' function. This is not a new function and is meant to replace what you already have.''' &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createLoginWindow()&lt;br /&gt;
	local X = 0.375&lt;br /&gt;
	local Y = 0.375&lt;br /&gt;
	local Width = 0.25&lt;br /&gt;
	local Height = 0.25&lt;br /&gt;
	wdwLogin = guiCreateWindow(X, Y, Width, Height, &amp;quot;Please Log In&amp;quot;, true)&lt;br /&gt;
	&lt;br /&gt;
	-- define new X and Y positions for the first label&lt;br /&gt;
	X = 0.0825&lt;br /&gt;
	Y = 0.2&lt;br /&gt;
	-- define new Width and Height values for the first label&lt;br /&gt;
	Width = 0.25&lt;br /&gt;
	Height = 0.25&lt;br /&gt;
	-- create the first label, note the final argument passed is 'wdwLogin' meaning the window&lt;br /&gt;
	-- we created above is the parent of this label (so all the position and size values are now relative to the position of that window)&lt;br /&gt;
	guiCreateLabel(X, Y, Width, Height, &amp;quot;Username&amp;quot;, true, wdwLogin)&lt;br /&gt;
	-- alter the Y value, so the second label is slightly below the first&lt;br /&gt;
	Y = 0.5&lt;br /&gt;
	guiCreateLabel(X, Y, Width, Height, &amp;quot;Password&amp;quot;, true, wdwLogin)&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
	X = 0.415&lt;br /&gt;
	Y = 0.2&lt;br /&gt;
	Width = 0.5&lt;br /&gt;
	Height = 0.15&lt;br /&gt;
	edtUser = guiCreateEdit(X, Y, Width, Height, &amp;quot;&amp;quot;, true, wdwLogin)&lt;br /&gt;
	Y = 0.5&lt;br /&gt;
	edtPass = guiCreateEdit(X, Y, Width, Height, &amp;quot;&amp;quot;, true, wdwLogin)&lt;br /&gt;
	-- set the maximum character length for the username and password fields to 50&lt;br /&gt;
	guiEditSetMaxLength(edtUser, 50)&lt;br /&gt;
	guiEditSetMaxLength(edtPass, 50)&lt;br /&gt;
	&lt;br /&gt;
	X = 0.415&lt;br /&gt;
	Y = 0.7&lt;br /&gt;
	Width = 0.25&lt;br /&gt;
	Height = 0.2&lt;br /&gt;
	btnLogin = guiCreateButton(X, Y, Width, Height, &amp;quot;Log In&amp;quot;, true, wdwLogin)&lt;br /&gt;
	&lt;br /&gt;
	-- make the window invisible&lt;br /&gt;
	guiSetVisible(wdwLogin, false)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Note that every GUI component created is a child of the window, this is done by specifying the parent element (wdwLogin, in this case) when creating the component. &lt;br /&gt;
&lt;br /&gt;
This is very useful because not only does it mean that all the components are attached to the window and will move with it, but also that any changes done to the parent window will be applied down the tree to these child components. For example, we can now hide all of the GUI we just created by simply hiding the window:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
guiSetVisible(wdwLogin, false) --hides all the GUI we made so we can show them to the player at the appropriate moment. &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Using the function we wrote===&lt;br /&gt;
The createLoginWindow function is now complete, but it won't do anything until we call it. It is recommended to create all GUI when the client resource starts, hide them, and show them to the player later when needed. Therefore, we'll write an event handler for &amp;quot;[[onClientResourceStart]]&amp;quot; to create the window:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- attach the event handler to the root element of the resource&lt;br /&gt;
-- this means it will only trigger when its own resource is started&lt;br /&gt;
addEventHandler(&amp;quot;onClientResourceStart&amp;quot;, getResourceRootElement(getThisResource()), &lt;br /&gt;
	function ()&lt;br /&gt;
		createLoginWindow()&lt;br /&gt;
	end&lt;br /&gt;
)	&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As this is a log in window, we now need to show the window when the player joins the game. &lt;br /&gt;
This can be done using the same event, &amp;quot;[[onClientResourceStart]]&amp;quot;, so we can modify the above code to include showing the window:&lt;br /&gt;
&lt;br /&gt;
'''Note that we are now writing more code for our existing 'onClientResourceStart' handler. This is not a new event handler and is meant to replace what you already have.''' &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler(&amp;quot;onClientResourceStart&amp;quot;, getResourceRootElement(getThisResource()), &lt;br /&gt;
	function ()&lt;br /&gt;
		-- create the log in window and its components&lt;br /&gt;
		createLoginWindow()&lt;br /&gt;
&lt;br /&gt;
		-- output a brief welcome message to the player&lt;br /&gt;
                outputChatBox(&amp;quot;Welcome to My MTA:SA Server, please log in.&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
		-- if the GUI was successfully created, then show the GUI to the player&lt;br /&gt;
	        if (wdwLogin ~= nil) then&lt;br /&gt;
			guiSetVisible(wdwLogin, true)&lt;br /&gt;
		else&lt;br /&gt;
			-- if the GUI hasnt been properly created, tell the player&lt;br /&gt;
			outputChatBox(&amp;quot;An unexpected error has occurred and the log in GUI has not been created.&amp;quot;)&lt;br /&gt;
	        end &lt;br /&gt;
&lt;br /&gt;
		-- enable the players cursor (so they can select and click on the components)&lt;br /&gt;
	        showCursor(true)&lt;br /&gt;
		-- set the input focus onto the GUI, allowing players (for example) to press 'T' without the chatbox opening&lt;br /&gt;
	        guiSetInputEnabled(true)&lt;br /&gt;
	end&lt;br /&gt;
)	&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that we have a simple security check before making the window visible, so in the unlikely event that the window has not been created, meaning wdwLogin is not a valid element, we don't get an error and just inform the player what has happened. &lt;br /&gt;
In the next step, we will create the button functionality for the log in button.&lt;br /&gt;
&lt;br /&gt;
==Scripting the button==&lt;br /&gt;
Now that we have created our GUI and shown it to the player, we need to make it work. &lt;br /&gt;
&lt;br /&gt;
===Detecting the click===&lt;br /&gt;
When the player clicks on any part of the GUI, the event &amp;quot;[[onClientGUIClick]]&amp;quot; will be triggered for the GUI component you clicked on. This allows us to easily detect any clicks on the GUI elements we want to use.&lt;br /&gt;
For example, we can attach the event to the btnLogin button to catch any clicks on it:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- attach the event onClientGUIClick to btnLogin and set it to trigger the 'clientSubmitLogin' function&lt;br /&gt;
addEventHandler(&amp;quot;onClientGUIClick&amp;quot;, btnLogin, clientSubmitLogin, false)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
'''Note the final argument passed is &amp;quot;false&amp;quot;. This indicates that the event will only trigger directly on btnLogin, not if the event has propagated up or down the tree. Setting this to &amp;quot;true&amp;quot; while attaching to gui elements will mean that clicking on any element in the same branch will trigger this event.'''&lt;br /&gt;
&lt;br /&gt;
This line of code can now be added inside the createLoginWindow function. It is a common mistake to try and attach events to non-existant GUI elements, so make sure you always attach your events '''after''' the gui element (in this case, the button) has been created:&lt;br /&gt;
&lt;br /&gt;
'''Note that we are now writing more code for our existing 'createLoginWindow' function.''' &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createLoginWindow()&lt;br /&gt;
	-- create all our GUI elements&lt;br /&gt;
	...&lt;br /&gt;
&lt;br /&gt;
	-- now add our onClientGUIClick event to the button we just created&lt;br /&gt;
	addEventHandler(&amp;quot;onClientGUIClick&amp;quot;, btnLogin, clientSubmitLogin, false)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Managing the click===&lt;br /&gt;
Now that we can detect when the player clicks on the button, we need to write code to manage what happens when they do.&lt;br /&gt;
In our [[onClientGUIClick]] event handle, we told it to call the function clientSubmitLogin whenever btnLogin is clicked.&lt;br /&gt;
Therefore, we can now use the function clientSubmitLogin to control what happens when the button is clicked:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- create the function and define the 'button' and 'state' parameters&lt;br /&gt;
-- (these are passed automatically by onClientGUIClick)&lt;br /&gt;
function clientSubmitLogin(button,state)&lt;br /&gt;
	-- if our login button was clicked with the left mouse button, and the state of the mouse button is up&lt;br /&gt;
	if button == &amp;quot;left&amp;quot; and state == &amp;quot;up&amp;quot; then&lt;br /&gt;
		-- move the input focus back onto the game (allowing players to move around, open the chatbox, etc)&lt;br /&gt;
		guiSetInputEnabled(false)&lt;br /&gt;
		-- hide the window and all the components&lt;br /&gt;
		guiSetVisible(wdwLogin, false)&lt;br /&gt;
		-- hide the mouse cursor&lt;br /&gt;
		showCursor(false)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Now, when the button is clicked, the window will be hidden and all controls will be returned to the player. Next, we will tell the server to allow the player to spawn.&lt;br /&gt;
&lt;br /&gt;
===Triggering the server===&lt;br /&gt;
Triggering the server can be done using [[triggerServerEvent]]. This allows you to trigger a specified event on the server from the client. The same can be done in reverse using [[triggerClientEvent]].&lt;br /&gt;
Here, we use the [[triggerServerEvent]] function to call our own custom event on the server, named &amp;quot;submitLogin&amp;quot;, which will then control the spawning of the player serverside.&lt;br /&gt;
&lt;br /&gt;
'''Note that we are now writing more code for our existing 'clientSubmitLogin' function. This is not a new function and is meant to replace what you already have.''' &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function clientSubmitLogin(button,state)&lt;br /&gt;
	if button == &amp;quot;left&amp;quot; and state == &amp;quot;up&amp;quot; then&lt;br /&gt;
		-- get the text entered in the 'username' field&lt;br /&gt;
		local username = guiGetText(edtUser)&lt;br /&gt;
		-- get the text entered in the 'password' field&lt;br /&gt;
		local password = guiGetText(edtPass)&lt;br /&gt;
&lt;br /&gt;
		-- if the username and password both exist&lt;br /&gt;
		if username and password then&lt;br /&gt;
			-- trigger the server event 'submitLogin' and pass the username and password to it&lt;br /&gt;
			triggerServerEvent(&amp;quot;submitLogin&amp;quot;, getRootElement(), username, password)&lt;br /&gt;
&lt;br /&gt;
			-- hide the gui, hide the cursor and return control to the player&lt;br /&gt;
			guiSetInputEnabled(false)&lt;br /&gt;
			guiSetVisible(wdwLogin, false)&lt;br /&gt;
			showCursor(false)&lt;br /&gt;
		else&lt;br /&gt;
			-- otherwise, output a message to the player, do not trigger the server&lt;br /&gt;
			-- and do not hide the gui&lt;br /&gt;
			outputChatBox(&amp;quot;Please enter a username and password.&amp;quot;)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Creating the serverside event===&lt;br /&gt;
At this point we now have all the code needed on the client side, so open up your serverside 'script.lua' file (from the [[Scripting Introduction|Introduction to Scripting]]) or another suitable serverside file to work with.&lt;br /&gt;
&lt;br /&gt;
On the server side, recall that we are spawning the player as soon as they login.&lt;br /&gt;
So, first of all, we will need to define the custom event that we used before on the client. This can be done using [[addEvent]] and [[addEventHandler]].&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- create our loginHandler function, with username and password parameters (passed from the client gui)&lt;br /&gt;
function loginHandler(username,password)&lt;br /&gt;
&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- define our custom event, and allow it to be triggered from the client ('true')&lt;br /&gt;
addEvent(&amp;quot;submitLogin&amp;quot;,true)&lt;br /&gt;
-- add an event handler so that when submitLogin is triggered, the function loginHandler is called&lt;br /&gt;
addEventHandler(&amp;quot;submitLogin&amp;quot;,root,loginHandler)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Logging in===&lt;br /&gt;
Now we have a function that is called through the custom event 'submitLogin', we can start to work on logging in and spawning the player, using our 'loginHandler' function:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function loginHandler(username,password)&lt;br /&gt;
	-- check that the username and password are correct&lt;br /&gt;
	if username == &amp;quot;user&amp;quot; and password == &amp;quot;apple&amp;quot; then&lt;br /&gt;
		-- the player has successfully logged in, so spawn them&lt;br /&gt;
		if (client) then&lt;br /&gt;
			spawnPlayer(client, 1959.55, -1714.46, 10)&lt;br /&gt;
			fadeCamera(client, true)&lt;br /&gt;
                        setCameraTarget(client, client)&lt;br /&gt;
			outputChatBox(&amp;quot;Welcome to My Server.&amp;quot;, client)&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		-- if the username or password are not correct, output a message to the player&lt;br /&gt;
		outputChatBox(&amp;quot;Invalid username and password. Please re-connect and try again.&amp;quot;,client)&lt;br /&gt;
        end			&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addEvent(&amp;quot;submitLogin&amp;quot;,true)&lt;br /&gt;
addEventHandler(&amp;quot;submitLogin&amp;quot;,root,loginHandler)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
'''For the purposes of this tutorial, a very basic username and password system is shown. For a more comprehensive alternative, you can use the Account System or a MySQL database.'''&lt;br /&gt;
&lt;br /&gt;
Also note the use of the variable &amp;quot;client&amp;quot;, it's an internal variable used by MTA to identify the player who triggered the event. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, do not forget to include the new gui.lua file in the meta.xml of the main resource, and label it as a client script:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;script src=&amp;quot;client/gui.lua&amp;quot; type=&amp;quot;client&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
At this point, we now have a basic login window that checks the player's username and password when the login button is clicked. If they are correct, the player is automatically spawned.&lt;br /&gt;
&lt;br /&gt;
For further help with GUI, see the [[:Category:GUI_Tutorials|GUI tutorials]].&lt;br /&gt;
&lt;br /&gt;
[[Category:GUI_Tutorials]]&lt;br /&gt;
[[it:Introduzione_allo_scripting_della_GUI]]&lt;br /&gt;
[[ru:Introduction to Scripting the GUI]]&lt;br /&gt;
[[es:Introducción a la Programación de GUI]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Scripting_Introduction&amp;diff=38447</id>
		<title>Scripting Introduction</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Scripting_Introduction&amp;diff=38447"/>
		<updated>2014-01-16T23:17:07Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Resources are a key part of MTA. A resource is essentially a folder or zip file that contains a collection of files, plus a meta file that describes to the server how the resource should be loaded and what files it does contain. A resource can be seen as being partly equivalent to a program running in an operating system - it can be started and stopped, and multiple resources can run at once.&lt;br /&gt;
&lt;br /&gt;
Everything that has to do with scripting happens in resources, what a resource does defines if it is a gamemode, a map or anything else. MTA comes with resources that you can optionally use in your gamemodes, such as maplimits to keep playings within a playing area or deathpickups to create weapon pickups.&lt;br /&gt;
{{tip|Your first step to begin Lua scripting should be using an Lua editor. This makes scripting much easier. We recommend [http://www.sublimetext.com/ Sublime Text], [http://notepad-plus.sourceforge.net/uk/site.htm Notepad++] or [http://luaedit.sourceforge.net/ LuaEdit]. There is also an unofficial [[MTASE|MTA Script Editor]] (in work-in-progress state) that you can test out.}}&lt;br /&gt;
&lt;br /&gt;
==Creating a working script==&lt;br /&gt;
We will first learn how to make a basic script that lets the player walk around in the city, step by step.&lt;br /&gt;
===Where are all the scripts?===&lt;br /&gt;
Let's take a look at the script's file structure. Go to your MTA Server folder, and follow the path below:&lt;br /&gt;
&lt;br /&gt;
	server/mods/deathmatch/resources/&lt;br /&gt;
&lt;br /&gt;
You will see a lot of .zip files, which are the packaged sample scripts shipped with MTA. Each file is a &amp;quot;resource&amp;quot;, and they will all be unzipped and loaded by the server when it starts. To create your own resource, simply make a folder with your preferred name. We'll use &amp;quot;myserver&amp;quot; for this tutorial.&lt;br /&gt;
&lt;br /&gt;
Now you should be under this directory: &lt;br /&gt;
&lt;br /&gt;
	server/mods/deathmatch/resources/myserver/&lt;br /&gt;
&lt;br /&gt;
===Identifying your resource===&lt;br /&gt;
In order to let the server know what's in the resource, a ''meta.xml'' file must be created to list the resource's content. It must be located in the resource's root directory, which is the &amp;quot;myserver&amp;quot; folder in our case. So create a text file and name it &amp;quot;meta.xml&amp;quot;, and open it with notepad.&lt;br /&gt;
&lt;br /&gt;
Enter the following codes in the ''meta.xml'' file:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
     &amp;lt;info author=&amp;quot;YourName&amp;quot; type=&amp;quot;gamemode&amp;quot; name=&amp;quot;My Server&amp;quot; description=&amp;quot;My first MTA server&amp;quot; /&amp;gt;&lt;br /&gt;
     &amp;lt;script src=&amp;quot;script.lua&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
In the ''&amp;lt;info /&amp;gt;'' tag, there's a &amp;quot;type&amp;quot; field which indicates that the resource is a ''gamemode'' instead of a regular include or a ''map'', which will be explained later. A gamemode is what you need to make a stand-alone server. &lt;br /&gt;
&lt;br /&gt;
The ''&amp;lt;script /&amp;gt;'' tag indicates the script files contained in the resource, which we will create next.&lt;br /&gt;
===Creating a simple script===&lt;br /&gt;
Note that in the ''&amp;lt;script /&amp;gt;'' tag above, the .lua file is not under another directory. Therefore we'll create the file in the same folder as meta.xml. Now you can copy and paste the following code into script.lua:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local spawnX, spawnY, spawnZ = 1959.55, -1714.46, 10&lt;br /&gt;
function joinHandler()&lt;br /&gt;
	spawnPlayer(source, spawnX, spawnY, spawnZ)&lt;br /&gt;
	fadeCamera(source, true)&lt;br /&gt;
	setCameraTarget(source, source)&lt;br /&gt;
	outputChatBox(&amp;quot;Welcome to My Server&amp;quot;, source)&lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerJoin&amp;quot;, getRootElement(), joinHandler)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
The script will spawn you at the coordinate (x, y, z) specified above, when you join the game. Note that the ''fadeCamera'' function must be used or the screen will be black. Also, in releases after DP2, you need to set the camera target (otherwise all the player will see is blue sky).&lt;br /&gt;
&lt;br /&gt;
The '''source''' variable indicates who triggered the event. Since a player has joined when the code is triggered, you use this variable to look which has joined. So it'll spawn that player instead of everyone or a random person.&lt;br /&gt;
&lt;br /&gt;
If we have a closer look on [[addEventHandler]], you can see 3 things: 'onPlayerJoin', which indicates when it's triggered. getRootElement(), which shows by what/who it can be triggered. (getRootElement() is everything/everyone) And joinHandler, which indicates the function that has to be triggered after the event is triggered. Other details will be explained later in another example, now let's just run the server and try it out!&lt;br /&gt;
&lt;br /&gt;
===Running the script===&lt;br /&gt;
To get the server started, simply run the executable under the server/ directory. A list of server stats will be shown first; note the port number, which you'll need when joining the game. Then the server loads all the resources under the mods/deathmatch/resources/ directory, and then &amp;quot;ready to accept connections!&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Before you connect to the server, you must run the gamemode. Type &amp;quot;start myserver&amp;quot; and press Enter. The server will start the gamemode you just created, and will also show any errors and warnings from this point on. Now you can start the MTA client, and &amp;quot;Quick Connect&amp;quot; using the IP address of your server and the port number you saw earlier. If all goes well, after a few seconds your character will be walking on the streets of Los Santos.&lt;br /&gt;
&lt;br /&gt;
Next we'll add a command to your script that players can use to spawn a vehicle beside their position. You may skip it and check out more advanced scripting with the [[Map manager|Map Manager]], which continues this tutorial. Another branch from this tutorial is [[Introduction to Scripting GUI]], you may follow it to see how Graphical User Interface in MTA is drawn and scripted.&lt;br /&gt;
&lt;br /&gt;
==Creating a simple command==&lt;br /&gt;
Let's go back to the content of the ''script.lua'' file. As mentioned above, we want to provide a command to create a vehicle beside your current position in the game. Firstly we need to create a function we want to call and a command handler that creates the command the player will be able to enter in the console.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- create the function the command handler calls, with the arguments: thePlayer, command, vehicleModel&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
   -- create a vehicle and stuff&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- create a command handler&lt;br /&gt;
addCommandHandler(&amp;quot;createvehicle&amp;quot;, createVehicleForPlayer)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
''Note: Function names are clickable in code examples on the wiki and linked to the functions' documentation.''&lt;br /&gt;
&lt;br /&gt;
====About command handlers====&lt;br /&gt;
The first argument of [[addCommandHandler]] is the name of the command the player will be able to enter, the second argument is the function this will call, in this case ''createVehicleForPlayer''.&lt;br /&gt;
&lt;br /&gt;
If you have already experience in scripting, you will know that you call a function like this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
functionName(argument1, argument2, argument3, ..)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
functionName(thePlayer, commandName, argument3, ..)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
If we have a closer look on the lower example above, we can see argument1 is thePlayer and argument2 the commandName. thePlayer is simply the one who typed the command, so whatever you call it, the variable will contain the player who activated the command. commandName is simply the command they typed. So if they typed &amp;quot;/greet&amp;quot;, this argument will contain &amp;quot;greet&amp;quot;. Argument 3 is something extra the player typed, you'll learn it a little bit further in the tutorial. Never forget that the first 2 arguments are standard arguments, but you can name them to anything you want.&lt;br /&gt;
&lt;br /&gt;
We called the [[addCommandHandler]] function this way already and since ''createVehicleForPlayer'' is a function too, it can be called that way as well. But we are using a command handler for that, which calls it in a similiar manner, internally.&lt;br /&gt;
&lt;br /&gt;
For example: Someone types &amp;quot;createvehicle 468&amp;quot; ingame in the console to spawn a Sanchez, the command handler calls the createVehicleForPlayer function, as '''if''' we would have this line of code in the script:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
createVehicleForPlayer(thePlayer,&amp;quot;createvehicle&amp;quot;,&amp;quot;468&amp;quot;) -- thePlayer is the player element of the player who entered the command&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
As we can see, it provides several parameters: the player who called the command, the command he entered and whatever text he had after that, in this case &amp;quot;468&amp;quot; as vehicle id for the Sanchez. The first two parameters are the same with all command handlers, which you can read on the [[addEventHandler]] page. For this fact, you always have to define at least those two parameters to use any after that (for example to process text that was entered after the command, like in our example the vehicle model id).&lt;br /&gt;
&lt;br /&gt;
''Note: You have to add the command handler AFTER you defined the handler function, else it can't find it. The order of execution matters.''&lt;br /&gt;
&lt;br /&gt;
====Writing the function====&lt;br /&gt;
In order to fill the function we created, we need to think about what we have to do:&lt;br /&gt;
* Get the players position, so we know where to spawn the vehicle (we want it to appear right beside the player)&lt;br /&gt;
* Calculate the position we want to spawn the vehicle at (we don't want it to appear in the player)&lt;br /&gt;
* Spawn the vehicle&lt;br /&gt;
* Check if it has been spawned successfully, or output a message&lt;br /&gt;
&lt;br /&gt;
In order to achieve our goals, we have to use several functions. To find function we need to use, we should visit the [[Scripting Functions|Server Functions List]]. First we need a function to get the players position. Since players are Elements, we first jump to the '''Element functions''' where we find the [[getElementPosition]] function. By clicking on the function name in the list, you get to the function description. There we can see the syntax, what it returns and usually an example. The syntax shows us what arguments we can or have to submit.&lt;br /&gt;
&lt;br /&gt;
For [[getElementPosition]], the syntax is:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementPosition ( element theElement )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The three ''float'' in front of the function name are the return type. In this case it means the function returns three floating point numbers. (x, y and z) Within the parentheses, you can see what arguments you have to submit. In this case only the element whose position you want to get, which is the player in our example.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	-- get the position and put it in the x,y,z variables&lt;br /&gt;
	-- (local means, the variables only exist in the current scope, in this case, the function)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Next we want to ensure that the vehicle won't spawn directly in the player, so we add a few units to the ''x'' variable, which will make it spawn east from the player.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer) -- get the position of the player&lt;br /&gt;
	x = x + 5 -- add 5 units to the x position&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now we need another function, one to spawn a vehicle. We once again search for it on the [[Scripting Functions|Server Functions List]], this time - since we are talking about vehicles - in the '''Vehicle functions''' section, where we will choose [[createVehicle]]. In this function's syntax, we only have one return type (which is more common), a vehicle element that points to the vehicle we just created. Also, we see that some arguments are enclosed within [ ] which means that those are optional.&lt;br /&gt;
&lt;br /&gt;
We already have all arguments we need for [[createVehicle]] in our function: The position we just calculated in the ''x,y,z'' variables and the model id that we provided through the command (&amp;quot;createvehicle 468&amp;quot;) and can access in the function as ''vehicleModel'' variable.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer) -- get the position of the player&lt;br /&gt;
	x = x + 5 -- add 5 units to the x position&lt;br /&gt;
	-- create the vehicle and store the returned vehicle element in the ''createdVehicle'' variable&lt;br /&gt;
	local createdVehicle = createVehicle(tonumber(vehicleModel),x,y,z)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Of course this code can be improved in many ways, but at least we want to add a check whether the vehicle was created successfully or not. As we can read on the [[createVehicle]] page under '''Returns''', the function returns ''false'' when it was unable to create the vehicle. Thus, we check the value of the ''createVehicle'' variable.&lt;br /&gt;
&lt;br /&gt;
Now we have our complete script:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function createVehicleForPlayer(thePlayer, command, vehicleModel)&lt;br /&gt;
	local x,y,z = getElementPosition(thePlayer) -- get the position of the player&lt;br /&gt;
	x = x + 5 -- add 5 units to the x position&lt;br /&gt;
	local createdVehicle = createVehicle(tonumber(vehicleModel),x,y,z)&lt;br /&gt;
	-- check if the return value was ''false''&lt;br /&gt;
	if (createdVehicle == false) then&lt;br /&gt;
		-- if so, output a message to the chatbox, but only to this player.&lt;br /&gt;
		outputChatBox(&amp;quot;Failed to create vehicle.&amp;quot;,thePlayer)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;createvehicle&amp;quot;, createVehicleForPlayer)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, we introduced another function with [[outputChatBox]]. By now, you should be able to explore the function's documentation page yourself. For more advanced scripting, please check out the [[Map manager|Map Manager]].&lt;br /&gt;
&lt;br /&gt;
==What you need to know==&lt;br /&gt;
You already read some things about resources, command handlers and finding functions in the documentation in the first paragraph, but there is much more to learn. This section will give you a rather short overview over some of these things, while linking to related pages if possible.&lt;br /&gt;
===Clientside and Serverside scripts===&lt;br /&gt;
You may have already noticed these or similiar terms (Server/Client) somewhere on this wiki, mostly in conjunction with functions. MTA not only supports scripts that run on the server and provide commands (like the one we wrote above) or other features, but also scripts that run on the MTA client the players use to connect to the server. The reason for this is, that some features MTA provides have to be clientside (like a GUI - Graphical User Interface), others should be because they work better and still others are better off to be serverside or just don't work clientside.&lt;br /&gt;
&lt;br /&gt;
Most scripts you will make (gamemodes, maps) will probably be serverside, like the one we wrote in the first section. If you run into something that can't be solved serverside, you will probably have to make it clientside. For a clientside script for example, you would create a ordinary script file (for example called ''client.lua'') and specify it in the meta.xml, like this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;script src=&amp;quot;client.lua&amp;quot; type=&amp;quot;client&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
The ''type'' attribute defaults to 'server', so you only need to specify it for clientside scripts. When you do this, the clientside script will be downloaded to the player's computer once he connects to the server. Read more about [[Client side scripts]].&lt;br /&gt;
&lt;br /&gt;
===More complex resources===&lt;br /&gt;
The previous section showed briefly how to add clientside scripts to the resource, but there is also much more possible. As mentioned at the very top of this page, resources can be pretty much everything. Their purpose is defined by what they do. Let's have some theoretical resources, by looking at the files it contains, the ''meta.xml'' and what they might do:&lt;br /&gt;
&lt;br /&gt;
====First example - A utility script====&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
/admin_commands&lt;br /&gt;
	/meta.xml&lt;br /&gt;
	/commands.lua&lt;br /&gt;
	/client.lua&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
	&amp;lt;info author=&amp;quot;Someguy&amp;quot; description=&amp;quot;admin commands&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;commands.lua&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;client.lua&amp;quot; type=&amp;quot;client&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The ''commands.lua'' provides some admin commands, like banning a player, muting or something else that can be used to admin the server&lt;br /&gt;
* The ''client.lua'' provides a GUI to be able to perform the mentioned actions easily&lt;br /&gt;
&lt;br /&gt;
This example might be running all the time (maybe even auto-started when the server starts) as it's useful during the whole gaming experience and also wont interfere with the gameplay, unless an admin decides to take some action of course.&lt;br /&gt;
&lt;br /&gt;
====Second example - A gamemode====&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
/counterstrike&lt;br /&gt;
	/meta.xml&lt;br /&gt;
	/counterstrike.lua&lt;br /&gt;
	/buymenu.lua&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
	&amp;lt;info author=&amp;quot;Someguy&amp;quot; description=&amp;quot;Counterstrike remake&amp;quot; type=&amp;quot;gamemode&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;counterstrike.lua&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;buymenu.lua&amp;quot; type=&amp;quot;client&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The ''counterstrike.lua'' contains similiar to the following features:&lt;br /&gt;
** Let players choose their team and spawn them&lt;br /&gt;
** Provide them with weapons, targets and instructions (maybe read from a Map, see below)&lt;br /&gt;
** Define the game's rules, e.g. when does the round end, what happens when a player dies&lt;br /&gt;
** .. and maybe some more&lt;br /&gt;
* The ''buymenu.lua'' is a clientside script and creates a menu to buy weapons&lt;br /&gt;
&lt;br /&gt;
This example can be called a gamemode, since it not only intereferes with the gameplay, but actually defines the rules of it. The ''type'' attribute indicates that this example works with the [[Map manager]], yet another resource that was written by the QA Team to manage gamemodes and map loading. It is highly recommended that you base your gamemodes on the techniques it provides.&lt;br /&gt;
&lt;br /&gt;
This also means that the gamemode probably won't run without a map. Gamemodes should always be as generic as possible. An example for a map is stated in the next example.&lt;br /&gt;
&lt;br /&gt;
====Third example - A Map====&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
/cs-airport&lt;br /&gt;
	/meta.xml&lt;br /&gt;
	/airport.map&lt;br /&gt;
	/airport.lua&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
	&amp;lt;info author=&amp;quot;Someguy&amp;quot; description=&amp;quot;Counterstrike airport map&amp;quot; type=&amp;quot;map&amp;quot; gamemodes=&amp;quot;counterstrike&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;map src=&amp;quot;airport.map&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;script src=&amp;quot;airport.lua&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The ''airport.map'' in a XML file that provides information about the map to the gamemode, these may include:&lt;br /&gt;
** Where the players should spawn, with what weapons, what teams there are&lt;br /&gt;
** What the targets are&lt;br /&gt;
** Weather, World Time, Timelimit&lt;br /&gt;
** Provide vehicles&lt;br /&gt;
* The ''airport.lua'' might contain map-specific features, that may include:&lt;br /&gt;
** Opening some door/make something explode when something specific happens&lt;br /&gt;
** Create or move some custom objects, or manipulate objects that are created through the .map file&lt;br /&gt;
** .. anything else map-specific you can think of&lt;br /&gt;
&lt;br /&gt;
As you can see, the ''type'' attribute changed to 'map', telling the [[Map manager]] that this resource is a map, while the ''gamemodes'' attribute tells it for which gamemodes this map is valid, in this case the gamemode from the above example.&lt;br /&gt;
What may come as a surprise is that there is also a script in the Map resource. Of course this is not necessarily needed in a map, but opens a wide range of possibilities for map makers to create their own world within the rules of the gamemode they create it for.&lt;br /&gt;
&lt;br /&gt;
The ''airport.map'' file might look similiar to this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;map mode=&amp;quot;deathmatch&amp;quot; version=&amp;quot;1.0&amp;quot;&amp;gt;&lt;br /&gt;
	&amp;lt;terrorists&amp;gt;&lt;br /&gt;
		&amp;lt;spawnpoint posX=&amp;quot;2332.23&amp;quot; posY=&amp;quot;-12232.33&amp;quot; posZ=&amp;quot;4.42223&amp;quot; skins=&amp;quot;23-40&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;/terrorists&amp;gt;&lt;br /&gt;
	&amp;lt;counterterrorists&amp;gt;&lt;br /&gt;
		&amp;lt;spawnpoint posX=&amp;quot;2334.23443&amp;quot; posY=&amp;quot;-12300.233&amp;quot; posZ=&amp;quot;10.2344&amp;quot; skins=&amp;quot;40-50&amp;quot; /&amp;gt;&lt;br /&gt;
	&amp;lt;/counterterrorists&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;bomb posX=&amp;quot;23342.23&amp;quot; posY=&amp;quot;&amp;quot; posZ=&amp;quot;&amp;quot; /&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	&amp;lt;vehicle posX=&amp;quot;&amp;quot; posY=&amp;quot;&amp;quot; posZ=&amp;quot;&amp;quot; model=&amp;quot;602&amp;quot; /&amp;gt;	&lt;br /&gt;
	&amp;lt;vehicle posX=&amp;quot;&amp;quot; posY=&amp;quot;&amp;quot; posZ=&amp;quot;&amp;quot; model=&amp;quot;603&amp;quot; /&amp;gt;	&lt;br /&gt;
&amp;lt;/map&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When a gamemode is started with a map, the map resources is automatically started by the mapmanager and the information it contains can be read by the gamemode resource. When the map changes, the current map resource is stopped and the next map resource is started. For a more in-depth explanation and examples of how map resources are utilized in the main script, please visit the [[Writing Gamemodes]] page.&lt;br /&gt;
&lt;br /&gt;
===Events===&lt;br /&gt;
Events are the way MTA tells scripts about things that happen. For example when a player dies, the [[onPlayerWasted]] event is triggered. In order to perform any actions when a player dies, you have to prepare yourself similiar to adding a command handler, as shown in [[#Writing_the_script|the first chapter]].&lt;br /&gt;
&lt;br /&gt;
This example will output a message with the name of the player who died:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function playerDied(totalAmmo, killer, killerWeapon, bodypart)&lt;br /&gt;
	outputChatBox(getPlayerName(source)..&amp;quot; died!&amp;quot;)&lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onPlayerWasted&amp;quot;,getRootElement(),playerDied)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Instead of showing what arguments are needed, the documentation page for Events shows what parameters are passed to the handler function, similiar to the way a [[#About_command_handlers|command handler]] does, just that it is different from event to event. Another important point is the ''source'' variable, that exists in handler functions. It doesn't have to be added to the parameter list of the function, but it still exists. It has a different value from event to event, for player events (as in the example above) it is the player element. As another example, you can take a look at the basic spawning player script in the first section to get an idea how ''source'' is used.&lt;br /&gt;
&lt;br /&gt;
==Where to go from here==&lt;br /&gt;
You should now be familiar with the most basic aspects of MTA scripting and also a bit with the documentation. The [[Main Page]] provides you with links to more information, Tutorials and References that allow a deeper look into the topics you desire to learn about.&lt;br /&gt;
{{note|From here we recommend reading the [[debugging]] tutorial. Good debugging skills are an absolute necessity when you are making scripts. We also recommend you to use the [[predefined variables list]] to help you with certain tasks and make scripting easier and faster.}}&lt;br /&gt;
'''See also:'''&lt;br /&gt;
* [[Advanced Topics]]&lt;br /&gt;
[[es:Introducción a la Programación]]&lt;br /&gt;
[[it:Introduzione allo scripting]]&lt;br /&gt;
[[nl:Scripting_introductie]]&lt;br /&gt;
[[pt-br:Introdução ao Scripting]]&lt;br /&gt;
[[ru:Scripting Introduction]]&lt;br /&gt;
[[ar:مقدمه_في_البرمجه]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=User:Renkon&amp;diff=37997</id>
		<title>User:Renkon</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=User:Renkon&amp;diff=37997"/>
		<updated>2013-12-24T02:33:22Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: Created page with &amp;quot;http://forum.mtasa.com/viewtopic.php?f=5&amp;amp;t=68603&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;http://forum.mtasa.com/viewtopic.php?f=5&amp;amp;t=68603&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=DxDrawAnimWindow&amp;diff=37987</id>
		<title>DxDrawAnimWindow</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=DxDrawAnimWindow&amp;diff=37987"/>
		<updated>2013-12-22T19:50:04Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Use */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Useful Function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function is for creating and animating a dX Window.&lt;br /&gt;
* '''NOTE:''' This is made to be used clientside!.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool dxDrawAnimWindow ( string text, int alto, int ancho, int color, string element font, string anim)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
* '''text:''' The text of the window&lt;br /&gt;
* '''alto:''' The height of the window&lt;br /&gt;
* '''ancho:''' The width of the window&lt;br /&gt;
* '''color:''' The color of the window&lt;br /&gt;
* '''font:''' A element or string representing the font.&lt;br /&gt;
* '''anim:''' The easing or animation type. See https://wiki.multitheftauto.com/wiki/Easing] For more Types-&lt;br /&gt;
&lt;br /&gt;
==Code==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Clientside script&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function dxDrawAnimWindow(text,alto,ancho,color,font,anim)&lt;br /&gt;
    local x,y = guiGetScreenSize()&lt;br /&gt;
 &lt;br /&gt;
    btAncho = ancho&lt;br /&gt;
    btAlto = alto/20&lt;br /&gt;
 &lt;br /&gt;
    local now = getTickCount()&lt;br /&gt;
    local elapsedTime = now - start&lt;br /&gt;
    local endTime = start + 1500&lt;br /&gt;
    local duration = endTime - start&lt;br /&gt;
    local progress = elapsedTime / duration&lt;br /&gt;
    local x1, y1, z1 = interpolateBetween ( 0, 0, 0, ancho, alto, 255, progress, anim)&lt;br /&gt;
    local x2, y2, z2 = interpolateBetween ( 0, 0, 0, btAncho, btAlto, btAlto/11, progress, anim)&lt;br /&gt;
 &lt;br /&gt;
    posx = (x/2)-(x1/2)&lt;br /&gt;
    posy = (y/2)-(y1/2)&lt;br /&gt;
 &lt;br /&gt;
    dxDrawRectangle ( posx, posy-y2, x2, y2, color )&lt;br /&gt;
    dxDrawRectangle ( posx, posy, x1, y1, tocolor ( 0, 0, 0, 200 ) )&lt;br /&gt;
    dxDrawText ( text, 0, -(y1)-y2, x, y, tocolor ( 255, 255, 255, 255 ), z2,font,&amp;quot;center&amp;quot;,&amp;quot;center&amp;quot;)   &lt;br /&gt;
   &lt;br /&gt;
 &lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Use==&lt;br /&gt;
Always remeber to define the &amp;quot;start&amp;quot; value with getTickCount()&lt;br /&gt;
&amp;lt;section name=&amp;quot;Clientside example&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function start()&lt;br /&gt;
start = getTickCount()&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler(&amp;quot;gettick&amp;quot;,start)&lt;br /&gt;
--&lt;br /&gt;
function dxDrawAnimWindow(text,alto,ancho,color,font,anim)&lt;br /&gt;
    local x,y = guiGetScreenSize()&lt;br /&gt;
 &lt;br /&gt;
    btAncho = ancho&lt;br /&gt;
    btAlto = alto/20&lt;br /&gt;
 &lt;br /&gt;
    local now = getTickCount()&lt;br /&gt;
    local elapsedTime = now - start&lt;br /&gt;
    local endTime = start + 1500&lt;br /&gt;
    local duration = endTime - start&lt;br /&gt;
    local progress = elapsedTime / duration&lt;br /&gt;
    local x1, y1, z1 = interpolateBetween ( 0, 0, 0, ancho, alto, 255, progress, anim)&lt;br /&gt;
    local x2, y2, z2 = interpolateBetween ( 0, 0, 0, btAncho, btAlto, btAlto/11, progress, anim)&lt;br /&gt;
 &lt;br /&gt;
    posx = (x/2)-(x1/2)&lt;br /&gt;
    posy = (y/2)-(y1/2)&lt;br /&gt;
 &lt;br /&gt;
    dxDrawRectangle ( posx, posy-y2, x2, y2, color )&lt;br /&gt;
    dxDrawRectangle ( posx, posy, x1, y1, tocolor ( 0, 0, 0, 200 ) )&lt;br /&gt;
    dxDrawText ( text, 0, -(y1)-y2, x, y, tocolor ( 255, 255, 255, 255 ), z2,font,&amp;quot;center&amp;quot;,&amp;quot;center&amp;quot;)   &lt;br /&gt;
   &lt;br /&gt;
 &lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Author: Bc#&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Useful_Functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=36827</id>
		<title>IsElementMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=36827"/>
		<updated>2013-08-04T23:12:49Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Code */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Useful Function}}&lt;br /&gt;
&amp;lt;lowercasetitle/&amp;gt;&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
This function checks if an element is moving.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; bool isElementMoving( element theElement ) &amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the element is moving, otherwise false.&lt;br /&gt;
&lt;br /&gt;
===Code===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;function isElementMoving(theElement)&lt;br /&gt;
    if isElement(theElement)then --First check if the given argument is an element&lt;br /&gt;
        local x, y, z = getElementVelocity(theElement) --Get the velocity of the element given in our argument&lt;br /&gt;
            return x ~= 0 or y ~= 0 or z ~= 0 --When there is a movement on X, Y or Z return true because our element is moving&lt;br /&gt;
    end&lt;br /&gt;
    return false&lt;br /&gt;
end&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This script tells the moving state to the client on the bottom left of their screen&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local screenWidth, screenHeight = guiGetScreenSize () -- Get the screen resolution (width and height)&lt;br /&gt;
&lt;br /&gt;
function idleCheck ()&lt;br /&gt;
    local state&lt;br /&gt;
    if isElementMoving( getLocalPlayer() ) then --Check if it is the player &amp;quot;strolling&amp;quot;&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    elseif isElementMoving( getPedOccupiedVehicle ( getLocalPlayer() ) ) then --Player is not &amp;quot;Strolling&amp;quot; maybe the player is in a vehicle&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    else --The player not moving on feet or in a vehicle&lt;br /&gt;
        state = &amp;quot;Idling&amp;quot;&lt;br /&gt;
    end&lt;br /&gt;
	--Write our state string to the lower left corner of the screen&lt;br /&gt;
    dxDrawText ( state, 40, screenHeight - 40, screenWidth, screenHeight, tocolor ( 255, 255, 255, 255 ), 1, &amp;quot;default&amp;quot; )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addEventHandler ( &amp;quot;onClientRender&amp;quot;, getRootElement(), idleCheck ) -- keep the text visible with onClientRender.&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Useful_Functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=OnClientChatMessage&amp;diff=36628</id>
		<title>OnClientChatMessage</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=OnClientChatMessage&amp;diff=36628"/>
		<updated>2013-07-11T20:51:48Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Client event}}&lt;br /&gt;
__NOTOC__ &lt;br /&gt;
This event is triggered when any text is output to chatbox, including MTA's hardcoded messages.&lt;br /&gt;
&lt;br /&gt;
==Parameters== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
string text, int r, int g, int b&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
*'''text:''' The text that was output to chatbox&lt;br /&gt;
*'''r:''' The amount of red in the color of the text.&lt;br /&gt;
*'''g:''' The amount of green in the color of the text.&lt;br /&gt;
*'''b:''' The amount of blue in the color of the text.&lt;br /&gt;
&lt;br /&gt;
==Source==&lt;br /&gt;
The [[event system#Event source|source]] of this event is the root element.&lt;br /&gt;
==Cancel effect==&lt;br /&gt;
AS OF 1.3.2&lt;br /&gt;
If this event is [[Event system#Canceling|canceled]], the game's chat system won't deliver the posts. You may use [[outputChatBox]] to send the messages then.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example doesn't output anything to chatbox if it consists only of numbers&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
[lua]&lt;br /&gt;
function onClientChatMessageHandler(text)&lt;br /&gt;
	if string.match(text,&amp;quot;%d+&amp;quot;) --[[string.match searches for pattern &amp;quot;%d+&amp;quot;, means decimals]] == text then -- if string.match and text itself are the same&lt;br /&gt;
		cancelEvent() -- don't output it&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
addEventHandler(&amp;quot;onClientChatMessage&amp;quot;, getRootElement(), onClientChatMessageHandler)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
===Client other events===&lt;br /&gt;
{{Client_other_events}}&lt;br /&gt;
===Client event functions===&lt;br /&gt;
{{Client_event_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=User:AlexsSteel&amp;diff=35742</id>
		<title>User:AlexsSteel</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=User:AlexsSteel&amp;diff=35742"/>
		<updated>2013-05-05T21:50:25Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I Love Cookies :D&lt;br /&gt;
&lt;br /&gt;
[[File:Galleta_del_dibujo_animado_escultura_fotografica-p153432631525827152bfnwk_400.jpg]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=File:Galleta_del_dibujo_animado_escultura_fotografica-p153432631525827152bfnwk_400.jpg&amp;diff=35740</id>
		<title>File:Galleta del dibujo animado escultura fotografica-p153432631525827152bfnwk 400.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=File:Galleta_del_dibujo_animado_escultura_fotografica-p153432631525827152bfnwk_400.jpg&amp;diff=35740"/>
		<updated>2013-05-05T21:50:11Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: :D Cookie!&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;:D Cookie!&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=User:AlexsSteel&amp;diff=35739</id>
		<title>User:AlexsSteel</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=User:AlexsSteel&amp;diff=35739"/>
		<updated>2013-05-05T21:47:36Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: Created page with &amp;quot;I Love Cookies :D  Media:http://rlv.zcache.es/galleta_del_dibujo_animado_escultura_fotografica-p153432631525827152bfnwk_400.jpg&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I Love Cookies :D&lt;br /&gt;
&lt;br /&gt;
[[Media:http://rlv.zcache.es/galleta_del_dibujo_animado_escultura_fotografica-p153432631525827152bfnwk_400.jpg]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Meta.xml&amp;diff=35738</id>
		<title>Meta.xml</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Meta.xml&amp;diff=35738"/>
		<updated>2013-05-05T21:45:53Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Tags */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The ''meta.xml'' file presents MTA with a set of metadata, such as the resource's name, the scripts to include, and which files to precache for sending to clients among other things. It is also the scope of &amp;quot;elements&amp;quot;. It is written in XML, which is based on HTML and is the parent of XHTML.&lt;br /&gt;
&lt;br /&gt;
=Tags=&lt;br /&gt;
XML is a textual data format which is widely used for the representation of data. MTA uses an XML-based language to describe the metadata for resources by using the tags below:&lt;br /&gt;
&lt;br /&gt;
*'''&amp;lt;info /&amp;gt;''' Information about this resource, possible parameters include (any arbitrary parameters can be used and read using [[getResourceInfo]]):&lt;br /&gt;
** '''author:''' The author of this resource&lt;br /&gt;
** '''version:''' The version of this resource&lt;br /&gt;
** '''name:''' The name of this resource&lt;br /&gt;
** '''description:''' A brief description of this resource&lt;br /&gt;
** '''type:''' The type of this resource, that can be &amp;quot;gamemode&amp;quot;, &amp;quot;script&amp;quot;, &amp;quot;map&amp;quot; or &amp;quot;misc&amp;quot;.&lt;br /&gt;
*'''&amp;lt;script /&amp;gt;''' Source code for this resource, possible parameters are:&lt;br /&gt;
** '''src:''' The file name of the source code&lt;br /&gt;
** '''type:''' The type of source code: &amp;quot;client&amp;quot;, &amp;quot;server&amp;quot; or &amp;quot;shared&amp;quot;.&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
** '''protected:''' For client-side scripts, whether this script should or not be saved in the clients hard disk: &amp;quot;true&amp;quot; or &amp;quot;false&amp;quot;. NOTE: [http://bugs.mtasa.com/view.php?id=6831 there might be a bug with this].&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
**'''cache:''' When the script file type is &amp;quot;client&amp;quot;, this setting controls whether the file is saved on the players hard drive. Default is &amp;quot;true&amp;quot;. Using &amp;quot;false&amp;quot; will mean the file is not saved.&lt;br /&gt;
**'''validate:''' If set to &amp;quot;false&amp;quot;, compatibility checks are skipped.&lt;br /&gt;
*'''&amp;lt;map /&amp;gt;''' The map for a gamemode, possible parameters are:&lt;br /&gt;
**'''src:''' .map file name (can be path too eg. &amp;quot;maps/filename.map&amp;quot;)&lt;br /&gt;
**'''dimension:''' Dimension in which the map will be loaded (optional)&lt;br /&gt;
*'''&amp;lt;file /&amp;gt;''' A client-side file. Generally these are images, .txd, .col, .dff or .xml files. They'll be downloaded by clients when the resources is started (or on join)&lt;br /&gt;
**'''src:''' client-side file name (can be path too eg. &amp;quot;images/image.png&amp;quot;)&lt;br /&gt;
**'''download:''' Whether or not to be sent to the client automatically (optional). Default is &amp;quot;true&amp;quot;. Using &amp;quot;false&amp;quot; will mean they are not sent on resource start but could later be used by [[downloadFile]] (from version 1.4)&lt;br /&gt;
*'''&amp;lt;include /&amp;gt;''' Include resources that this resource will use&lt;br /&gt;
**'''resource:''' Resource name that you want to start with this resource&lt;br /&gt;
**'''minversion:''' Minimum version that '''resource''' needs to be (optional)&lt;br /&gt;
**'''maxversion:''' Maximum version that '''resource''' needs to be (optional)&lt;br /&gt;
*'''&amp;lt;config /&amp;gt;''' Config file (.xml) can be accessed by resource, possible parameters are:&lt;br /&gt;
**'''src:''' The file name of the config file&lt;br /&gt;
**'''type:''' The type of the config file: &amp;quot;client&amp;quot; or &amp;quot;server&amp;quot;&lt;br /&gt;
*'''&amp;lt;export /&amp;gt;''' This exports functions from this resource, so other resources can use them with [[call]]&lt;br /&gt;
**'''function:''' The function name&lt;br /&gt;
**'''type''' Whether function is exported server-side or client-side (valid values are: &amp;quot;server&amp;quot; and &amp;quot;client&amp;quot;)&lt;br /&gt;
**'''http:''' Can the function be called via HTTP (true/false)&lt;br /&gt;
*'''&amp;lt;html /&amp;gt;'''&lt;br /&gt;
**'''src:''' The filename for the HTTP file (can be a path)&lt;br /&gt;
**'''default:''' The html file is one that is shown by default when visiting /resourceName/ on the server. Only one html can be default, the rest are ignored. (true/false)&lt;br /&gt;
**'''raw:''' The html file is not parsed by the LUA interpreter and is treated as binary data. Must be used for binary files (images mainly) (true/false)&lt;br /&gt;
*'''&amp;lt;settings&amp;gt; &amp;lt;setting name=&amp;quot;&amp;quot; value=&amp;quot;&amp;quot;/&amp;gt; &amp;lt;/settings&amp;gt;:''' Most gamemodes use [[settings system]] to let server admins to configure it how they like. For instance you could set round time and then use [[get]] and [[set]] to get the value or change it, respectively.&lt;br /&gt;
*'''&amp;lt;min_mta_version /&amp;gt;''' Minimum version requirements for this resource to run correctly. When authoring resources, the minimum version should usually be set to the current released version of MTA:SA (which at the moment is &amp;quot;{{Current Version|full}}&amp;quot;). See example for example.&lt;br /&gt;
**'''client:''' The minimum client version&lt;br /&gt;
**'''server:''' The minimum server version&lt;br /&gt;
*'''&amp;lt;aclrequest /&amp;gt;''' A list of [[Access_Control_List|ACL]] rights this resource will need.&lt;br /&gt;
{{New items|3.0132|1.3.1 r4141|&lt;br /&gt;
*'''&amp;lt;sync_map_element_data /&amp;gt;''' Controls whether map [[Element_data|element data]] such as &amp;quot;PosX&amp;quot; and &amp;quot;DoubleSided&amp;quot; are transferred to the client. This data is usually not required by most gamemodes or resources. (Map Editor and Interiors require this to be not set to false to work). When set in a gamemode meta.xml, the setting will apply to all maps loaded by that resource.&lt;br /&gt;
**'''false:''' Disable transfer of map element data. This can reduce map download times considerably.&lt;br /&gt;
**'''true:''' Enable transfer of map element data (default).&lt;br /&gt;
}}&lt;br /&gt;
{{New items|3.0140|1.4.0 r5313|&lt;br /&gt;
*'''&amp;lt;oop/&amp;gt;''' todo.&lt;br /&gt;
**'''false:''' todo.&lt;br /&gt;
**'''true:''' todo.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
Heres an example of a meta file using some of the tags mentioned:&lt;br /&gt;
{{#tag:code |&lt;br /&gt;
&amp;lt;meta&amp;gt;&lt;br /&gt;
    &amp;lt;info author=&amp;quot;Slothman&amp;quot; type=&amp;quot;gamemode&amp;quot; name=&amp;quot;Stealth&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;config src=&amp;quot;help.xml&amp;quot; type=&amp;quot;client&amp;quot;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;min_mta_version client=&amp;quot;{{Current Version|full}}&amp;quot; server=&amp;quot;{{Current Version|full}}&amp;quot; /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;sync_map_element_data&amp;gt;false&amp;lt;/sync_map_element_data&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;script src=&amp;quot;stealthmain_server.lua&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;noiseblip.lua&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;mission_timer.lua&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;gadgets_server.lua&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;gadgets_client.lua&amp;quot; type=&amp;quot;client&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;stealthmain_client.lua&amp;quot; type=&amp;quot;client&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;noisebar.lua&amp;quot; type=&amp;quot;client&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;spycam.lua&amp;quot; type=&amp;quot;client&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;riemann_z_demonstration.lua&amp;quot; type=&amp;quot;client&amp;quot; cache=&amp;quot;false&amp;quot;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;file src=&amp;quot;riot_shield.txd&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;riot_shield.dff&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;riot_shield.col&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;armor.png&amp;quot; download=&amp;quot;true&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;camera.png&amp;quot; download=&amp;quot;false&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;cloak.png&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;goggles.png&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;mine.png&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;radar.png&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;file src=&amp;quot;shield.png&amp;quot; /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;include resource=&amp;quot;scoreboard&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;include resource=&amp;quot;killmessages&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;include resource=&amp;quot;maplimits&amp;quot; /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;settings&amp;gt;&lt;br /&gt;
         &amp;lt;setting name=&amp;quot;roundlimit&amp;quot; value=&amp;quot;[6]&amp;quot; /&amp;gt; &amp;lt;!-- round length in minutes --&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;teamdamage&amp;quot; value=&amp;quot;[1]&amp;quot; /&amp;gt; &amp;lt;!-- 0 for team protection off, 1 for team protection on --&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;teambalance&amp;quot; value=&amp;quot;[1]&amp;quot; /&amp;gt; &amp;lt;!--  difference limit of amount of players between teams --&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;spazammo&amp;quot; value=&amp;quot;[25]&amp;quot; /&amp;gt; &amp;lt;!-- ammo amounts --&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;m4ammo&amp;quot; value=&amp;quot;[100]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;shotgunammo&amp;quot; value=&amp;quot;[25]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;sniperammo&amp;quot; value=&amp;quot;[20]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;ak47ammo&amp;quot; value=&amp;quot;[120]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;rifleammo&amp;quot; value=&amp;quot;[40]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;deserteagleammo&amp;quot; value=&amp;quot;[45]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;pistolammo&amp;quot; value=&amp;quot;[132]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;uziammo&amp;quot; value=&amp;quot;[150]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;tec9ammo&amp;quot; value=&amp;quot;[150]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;silencedammo&amp;quot; value=&amp;quot;[65]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;grenadeammo&amp;quot; value=&amp;quot;[4]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;satchelammo&amp;quot; value=&amp;quot;[4]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;teargasammo&amp;quot; value=&amp;quot;[4]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;molatovammo&amp;quot; value=&amp;quot;[4]&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;setting name=&amp;quot;isAllowedToShoot&amp;quot; value=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
     &amp;lt;/settings&amp;gt;&lt;br /&gt;
&lt;br /&gt;
     &amp;lt;aclrequest&amp;gt;&lt;br /&gt;
	 &amp;lt;right name=&amp;quot;function.startResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;right name=&amp;quot;function.stopResource&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
	 &amp;lt;right name=&amp;quot;function.setPlayerMuted&amp;quot; access=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
     &amp;lt;/aclrequest&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/meta&amp;gt;&lt;br /&gt;
|lang=&amp;quot;xml&amp;quot;}}&lt;br /&gt;
[[Category:Scripting Concepts]]&lt;br /&gt;
[[cs:Meta.xml]]&lt;br /&gt;
[[de:Meta.xml]]&lt;br /&gt;
[[es:Sobre el archivo &amp;quot;meta.xml&amp;quot;]]&lt;br /&gt;
[[it:Meta.xml]]&lt;br /&gt;
[[pl:Meta.xml]]&lt;br /&gt;
[[ru:Meta.xml]]&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35512</id>
		<title>ES/PlaySound3D</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35512"/>
		<updated>2013-04-21T23:38:05Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Sintaxis */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== playSound3D ==&lt;br /&gt;
&lt;br /&gt;
Crea un elemento de sonido en el ambiente de juego y lo reproduce inmediatamente después de la creación para el jugador local. setElementPosition es utilizable para este elemento.&lt;br /&gt;
&lt;br /&gt;
''Nota'': Los formatos de audio soportados sólo son MP3, WAV, OGG, RIFF, MOD, XM, IT y S3M.&lt;br /&gt;
&lt;br /&gt;
== Sintaxis ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;element playSound3D ( string Archivo, float posX, float posY, float posZ [, bool repeticion = false ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Argumentos Requeridos ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''Archivo''': El archivo a reproducir.&lt;br /&gt;
&lt;br /&gt;
*'''x''': El punto flotante que representa la coordenada X en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''y''': El punto flotante que representa la coordenada Y en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''z''': El punto flotante que representa la coordenada Z en el mapa.&lt;br /&gt;
&lt;br /&gt;
== Argumentos Opcionales ==&lt;br /&gt;
&lt;br /&gt;
*'''Repeticion''': Un boolean representando si el sonido se reproducirá de nuevo al terminar.&lt;br /&gt;
&lt;br /&gt;
== Ejemplos ==&lt;br /&gt;
En este ejemplo se reproduce un archivo de audio en la pizzeria , cerca de de Pier 69 en San Fierro.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( 'onClientResourceStart', resourceRoot,&lt;br /&gt;
	function( )&lt;br /&gt;
		local uSound = playSound3D( 'sonidos/audio23.mp3', 2498, -1659, 12, true ) -- Se utiliza 'true' porque el sonido se repetirá infinidad de veces&lt;br /&gt;
		setSoundMaxDistance( uSound, 100 )&lt;br /&gt;
	end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mira Tambien==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35045</id>
		<title>ES/PlaySound3D</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35045"/>
		<updated>2013-02-25T16:38:21Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Argumentos Opcionales */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== playSound3D ==&lt;br /&gt;
&lt;br /&gt;
Crea un elemento de sonido en el ambiente de juego y lo reproduce inmediatamente después de la creación para el jugador local. setElementPosition es utilizable para este elemento.&lt;br /&gt;
&lt;br /&gt;
''Nota'': Los formatos de audio soportados sólo son MP3, WAV, OGG, RIFF, MOD, XM, IT y S3M.&lt;br /&gt;
&lt;br /&gt;
== Sintaxis ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;element playSound3D ( string Archivo, float posX, float posY, float posZ, [ bool repeticion = false ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Argumentos Requeridos ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''Archivo''': El archivo a reproducir.&lt;br /&gt;
&lt;br /&gt;
*'''x''': El punto flotante que representa la coordenada X en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''y''': El punto flotante que representa la coordenada Y en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''z''': El punto flotante que representa la coordenada Z en el mapa.&lt;br /&gt;
&lt;br /&gt;
== Argumentos Opcionales ==&lt;br /&gt;
&lt;br /&gt;
*'''Repeticion''': Un boolean representando si el sonido se reproducirá de nuevo al terminar.&lt;br /&gt;
&lt;br /&gt;
== Ejemplos ==&lt;br /&gt;
En este ejemplo se reproduce un archivo de audio en la pizzeria , cerca de de Pier 69 en San Fierro.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( 'onClientResourceStart', resourceRoot,&lt;br /&gt;
	function( )&lt;br /&gt;
		local uSound = playSound3D( 'sonidos/audio23.mp3', 2498, -1659, 12, true ) -- Se utiliza 'true' porque el sonido se repetirá infinidad de veces&lt;br /&gt;
		setSoundMaxDistance( uSound, 100 )&lt;br /&gt;
	end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mira Tambien==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35044</id>
		<title>ES/PlaySound3D</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35044"/>
		<updated>2013-02-25T16:37:56Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Argumentos Requeridos */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== playSound3D ==&lt;br /&gt;
&lt;br /&gt;
Crea un elemento de sonido en el ambiente de juego y lo reproduce inmediatamente después de la creación para el jugador local. setElementPosition es utilizable para este elemento.&lt;br /&gt;
&lt;br /&gt;
''Nota'': Los formatos de audio soportados sólo son MP3, WAV, OGG, RIFF, MOD, XM, IT y S3M.&lt;br /&gt;
&lt;br /&gt;
== Sintaxis ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;element playSound3D ( string Archivo, float posX, float posY, float posZ, [ bool repeticion = false ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Argumentos Requeridos ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''Archivo''': El archivo a reproducir.&lt;br /&gt;
&lt;br /&gt;
*'''x''': El punto flotante que representa la coordenada X en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''y''': El punto flotante que representa la coordenada Y en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''z''': El punto flotante que representa la coordenada Z en el mapa.&lt;br /&gt;
&lt;br /&gt;
== Argumentos Opcionales ==&lt;br /&gt;
&lt;br /&gt;
*'''Repeticion''': Un boolean representando si el sonido se reproducirá de nuevo al terminar.&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Ejemplos ==&lt;br /&gt;
En este ejemplo se reproduce un archivo de audio en la pizzeria , cerca de de Pier 69 en San Fierro.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( 'onClientResourceStart', resourceRoot,&lt;br /&gt;
	function( )&lt;br /&gt;
		local uSound = playSound3D( 'sonidos/audio23.mp3', 2498, -1659, 12, true ) -- Se utiliza 'true' porque el sonido se repetirá infinidad de veces&lt;br /&gt;
		setSoundMaxDistance( uSound, 100 )&lt;br /&gt;
	end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mira Tambien==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35043</id>
		<title>ES/PlaySound3D</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35043"/>
		<updated>2013-02-25T16:37:37Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Argumentos Opcionales */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== playSound3D ==&lt;br /&gt;
&lt;br /&gt;
Crea un elemento de sonido en el ambiente de juego y lo reproduce inmediatamente después de la creación para el jugador local. setElementPosition es utilizable para este elemento.&lt;br /&gt;
&lt;br /&gt;
''Nota'': Los formatos de audio soportados sólo son MP3, WAV, OGG, RIFF, MOD, XM, IT y S3M.&lt;br /&gt;
&lt;br /&gt;
== Sintaxis ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;element playSound3D ( string Archivo, float posX, float posY, float posZ, [ bool repeticion = false ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Argumentos Requeridos ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''Archivo''': El archivo a reproducir.&lt;br /&gt;
&lt;br /&gt;
*'''x''': El punto flotante que representa la coordenada X en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''y''': El punto flotante que representa la coordenada Y en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''z''': El punto flotante que representa la coordenada Z en el mapa.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Argumentos Opcionales ==&lt;br /&gt;
&lt;br /&gt;
*'''Repeticion''': Un boolean representando si el sonido se reproducirá de nuevo al terminar.&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Ejemplos ==&lt;br /&gt;
En este ejemplo se reproduce un archivo de audio en la pizzeria , cerca de de Pier 69 en San Fierro.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( 'onClientResourceStart', resourceRoot,&lt;br /&gt;
	function( )&lt;br /&gt;
		local uSound = playSound3D( 'sonidos/audio23.mp3', 2498, -1659, 12, true ) -- Se utiliza 'true' porque el sonido se repetirá infinidad de veces&lt;br /&gt;
		setSoundMaxDistance( uSound, 100 )&lt;br /&gt;
	end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mira Tambien==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35042</id>
		<title>ES/PlaySound3D</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35042"/>
		<updated>2013-02-25T16:36:33Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Argumentos Requeridos */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== playSound3D ==&lt;br /&gt;
&lt;br /&gt;
Crea un elemento de sonido en el ambiente de juego y lo reproduce inmediatamente después de la creación para el jugador local. setElementPosition es utilizable para este elemento.&lt;br /&gt;
&lt;br /&gt;
''Nota'': Los formatos de audio soportados sólo son MP3, WAV, OGG, RIFF, MOD, XM, IT y S3M.&lt;br /&gt;
&lt;br /&gt;
== Sintaxis ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;element playSound3D ( string Archivo, float posX, float posY, float posZ, [ bool repeticion = false ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Argumentos Requeridos ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''Archivo''': El archivo a reproducir.&lt;br /&gt;
&lt;br /&gt;
*'''x''': El punto flotante que representa la coordenada X en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''y''': El punto flotante que representa la coordenada Y en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''z''': El punto flotante que representa la coordenada Z en el mapa.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Argumentos Opcionales ==&lt;br /&gt;
&lt;br /&gt;
*'''Bucle''': El bucle representa si el sonido se reproducirá de nuevo o No. De caso contrario usar false.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Ejemplos ==&lt;br /&gt;
En este ejemplo se reproduce un archivo de audio en la pizzeria , cerca de de Pier 69 en San Fierro.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( 'onClientResourceStart', resourceRoot,&lt;br /&gt;
	function( )&lt;br /&gt;
		local uSound = playSound3D( 'sonidos/audio23.mp3', 2498, -1659, 12, true ) -- Se utiliza 'true' porque el sonido se repetirá infinidad de veces&lt;br /&gt;
		setSoundMaxDistance( uSound, 100 )&lt;br /&gt;
	end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mira Tambien==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35041</id>
		<title>ES/PlaySound3D</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35041"/>
		<updated>2013-02-25T16:26:57Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Sintaxis */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== playSound3D ==&lt;br /&gt;
&lt;br /&gt;
Crea un elemento de sonido en el ambiente de juego y lo reproduce inmediatamente después de la creación para el jugador local. setElementPosition es utilizable para este elemento.&lt;br /&gt;
&lt;br /&gt;
''Nota'': Los formatos de audio soportados sólo son MP3, WAV, OGG, RIFF, MOD, XM, IT y S3M.&lt;br /&gt;
&lt;br /&gt;
== Sintaxis ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;element playSound3D ( string Archivo, float posX, float posY, float posZ, [ bool repeticion = false ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Argumentos Requeridos ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''El audio''': El archivo de audio que quieres reproducir. (agregar el tag &amp;lt;file&amp;gt; &amp;lt;/file&amp;gt; en el archivo meta.xml).&lt;br /&gt;
&lt;br /&gt;
*'''x''': El punto flotante que representa la coordenada X en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''y''': El punto flotante que representa la coordenada Y en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''z''': El punto flotante que representa la coordenada Z en el mapa.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Argumentos Opcionales ==&lt;br /&gt;
&lt;br /&gt;
*'''Bucle''': El bucle representa si el sonido se reproducirá de nuevo o No. De caso contrario usar false.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Ejemplos ==&lt;br /&gt;
En este ejemplo se reproduce un archivo de audio en la pizzeria , cerca de de Pier 69 en San Fierro.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( 'onClientResourceStart', resourceRoot,&lt;br /&gt;
	function( )&lt;br /&gt;
		local uSound = playSound3D( 'sonidos/audio23.mp3', 2498, -1659, 12, true ) -- Se utiliza 'true' porque el sonido se repetirá infinidad de veces&lt;br /&gt;
		setSoundMaxDistance( uSound, 100 )&lt;br /&gt;
	end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mira Tambien==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35040</id>
		<title>ES/PlaySound3D</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=ES/PlaySound3D&amp;diff=35040"/>
		<updated>2013-02-25T16:26:12Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* playSound3D */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== playSound3D ==&lt;br /&gt;
&lt;br /&gt;
Crea un elemento de sonido en el ambiente de juego y lo reproduce inmediatamente después de la creación para el jugador local. setElementPosition es utilizable para este elemento.&lt;br /&gt;
&lt;br /&gt;
''Nota'': Los formatos de audio soportados sólo son MP3, WAV, OGG, RIFF, MOD, XM, IT y S3M.&lt;br /&gt;
&lt;br /&gt;
== Sintaxis ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;elemento playSound3D ( string el archivo de audio, posX, posY, posZ, [ bool bucle = false ] )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Argumentos Requeridos ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''El audio''': El archivo de audio que quieres reproducir. (agregar el tag &amp;lt;file&amp;gt; &amp;lt;/file&amp;gt; en el archivo meta.xml).&lt;br /&gt;
&lt;br /&gt;
*'''x''': El punto flotante que representa la coordenada X en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''y''': El punto flotante que representa la coordenada Y en el mapa.&lt;br /&gt;
&lt;br /&gt;
*'''z''': El punto flotante que representa la coordenada Z en el mapa.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Argumentos Opcionales ==&lt;br /&gt;
&lt;br /&gt;
*'''Bucle''': El bucle representa si el sonido se reproducirá de nuevo o No. De caso contrario usar false.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Ejemplos ==&lt;br /&gt;
En este ejemplo se reproduce un archivo de audio en la pizzeria , cerca de de Pier 69 en San Fierro.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( 'onClientResourceStart', resourceRoot,&lt;br /&gt;
	function( )&lt;br /&gt;
		local uSound = playSound3D( 'sonidos/audio23.mp3', 2498, -1659, 12, true ) -- Se utiliza 'true' porque el sonido se repetirá infinidad de veces&lt;br /&gt;
		setSoundMaxDistance( uSound, 100 )&lt;br /&gt;
	end&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mira Tambien==&lt;br /&gt;
{{Client_audio_functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=34885</id>
		<title>IsElementMoving</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=IsElementMoving&amp;diff=34885"/>
		<updated>2013-02-15T03:02:56Z</updated>

		<summary type="html">&lt;p&gt;AlexsSteel: /* Code */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Useful Function}}&lt;br /&gt;
&amp;lt;lowercasetitle/&amp;gt;&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
This function checks if an element is moving.&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; bool isElementMoving( element theElement ) &amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true if the element is moving, otherwise false.&lt;br /&gt;
&lt;br /&gt;
===Code===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;function isElementMoving(theElement)&lt;br /&gt;
    if isElement(theElement)then --First check if the given argument is an element&lt;br /&gt;
        local x, y, z = getElementVelocity(theElement) --Get the velocity of the element given in our argument&lt;br /&gt;
        if x ~= 0 and y ~= 0 and z ~= 0 then --When there is a movement on X, Y or Z return true because our element is moving&lt;br /&gt;
            return true&lt;br /&gt;
        else return false&lt;br /&gt;
        end&lt;br /&gt;
    else return false&lt;br /&gt;
    end&lt;br /&gt;
end&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This piece of client side code writes the moving state to the client his screen&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local screenWidth, screenHeight = guiGetScreenSize () -- Get the screen resolution (width and height)&lt;br /&gt;
&lt;br /&gt;
function idleCheck ()&lt;br /&gt;
    if isElementMoving( getLocalPlayer() ) then --Check if it is the player &amp;quot;strolling&amp;quot;&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    elseif isElementMoving( getPedOccupiedVehicle ( getLocalPlayer() ) ) then --Player is not &amp;quot;Strolling&amp;quot; maybe the player is in a vehicle&lt;br /&gt;
        state = &amp;quot;Moving&amp;quot;&lt;br /&gt;
    else --The player not moving on feet or in a vehicle&lt;br /&gt;
        state = &amp;quot;Idling&amp;quot;&lt;br /&gt;
    end&lt;br /&gt;
	--Write our state string to the lower left corner of the screen&lt;br /&gt;
    dxDrawText ( state, 40, screenHeight - 40, screenWidth, screenHeight, tocolor ( 255, 255, 255, 255 ), 1, &amp;quot;default&amp;quot; )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addEventHandler ( &amp;quot;onClientRender&amp;quot;, getRootElement(), idleCheck ) -- keep the text visible with onClientRender.&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Useful_Functions}}&lt;/div&gt;</summary>
		<author><name>AlexsSteel</name></author>
	</entry>
</feed>