Modules: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
m (Added the PT-BR page link following the alphabetic order)
m (Removed "Incomplete" flag)
 
(19 intermediate revisions by 12 users not shown)
Line 1: Line 1:
Modules are extensions for Multi Theft Auto's Lua core, allowing the integration and use of custom Lua functions that have been written in C++, and compiled as a DLL or SO file. Modules are commonly used to create functions for such purposes that Multi Theft Auto lacks, such as sockets. All modules listed hereof are not distributed with Multi Theft Auto, and must be manually installed.
Modules are extensions for Multi Theft Auto's Lua core, allowing the integration and use of custom Lua functions that have been written in C++, and compiled as a DLL or SO file. Modules are commonly used to create functions for such purposes that Multi Theft Auto lacks, such as sockets. All modules listed here are not distributed with Multi Theft Auto, and must be manually installed.


==Modules list==
==Modules list==
You can view a list of all the documented modules in this wiki [[:Category:Modules|here]].
<!-- You can view a list of all the documented modules in this wiki [[:Category:Modules|here]]. -->
You can view a list of all the documented modules here:
{{ModulesList}}


<!--
==Modules SDK==
==Modules SDK==
To be able to create your own modules, you must use the Modules SDK. You can download it from one of the links below - choose a link in accordance with your server's operating system.
To be able to create your own modules, you must use the Modules SDK. You can download it from one of the links below - choose a link in accordance with your server's operating system.
Line 9: Line 12:
* Linux
* Linux
** [http://files.mtasa.com/apps/1.0/dm/ml_devkit.tar.gz Official]
** [http://files.mtasa.com/apps/1.0/dm/ml_devkit.tar.gz Official]
*** (Delete the .d files, and add #include <cstring> to Common.h)
**** (On 64bit add -m32 to CPPFLAGS and LDFLAGS lines in Makefile)
* Microsoft Windows
* Microsoft Windows
** [http://www.mediafire.com/?b8b3asgegn0xkm4 Mirror (Mediafire)]
** [http://www.mediafire.com/?b8b3asgegn0xkm4 Mirror (Mediafire)]
** [https://mega.co.nz/#!nBNGUCgQ!3AHEJt684Heu9bN5de8xwAQ3h-qq5-V6fjUeU7rj5hI Mirror (MEGA)]


===SDK functions===
===SDK Functions===
*Currently in there:
*Currently in there:
**Base:
**Base:
Line 23: Line 29:
***MySQLSafeString
***MySQLSafeString


===Using Lua inside of Linux Modules===
If you want to make use of Lua functions as exported by the MTA Server you have to link against the official deathmatch.so file. Then the export resolution during dlopen of your module will respect the symbol table of deathmatch.so which contains all of the Lua exports. '''Do NOT link against a static version of a freshly-compiled Lua library because that will create code conflicts and potentially crashes in the long run.'''
-->
==How to write modules?==
* [[Modules_Introduction|Part 1]]
<!--* [[Modules_Introduction_2|Part 2]]-->




[[Category:Scripting Concepts]]
[[Category:Scripting Concepts]]
[[Category:Incomplete]]
[[Category:Modules]]
[[Category:Modules]]


[[hu:Modules]]
[[pl:Modules]]
[[pt-br:Módulos]]
[[pt-br:Módulos]]
[[ru:Modules]]
[[ru:Modules]]
[[ro:Module]]

Latest revision as of 17:41, 25 June 2022

Modules are extensions for Multi Theft Auto's Lua core, allowing the integration and use of custom Lua functions that have been written in C++, and compiled as a DLL or SO file. Modules are commonly used to create functions for such purposes that Multi Theft Auto lacks, such as sockets. All modules listed here are not distributed with Multi Theft Auto, and must be manually installed.

Modules list

You can view a list of all the documented modules here:


How to write modules?