The Phoenix Protocol RP Development Team released an open-sourced version of FiveM Lua Global functions. This is not a script for FiveM. This is a tool that is able to be used to increase productivity during FiveM development.
Why?
In today’s modern age of IDEs and Intellisense, I found that there was no conclusive list of Lua globals for FiveM.
This library can be included in any IDE that supports workspace globals and it provides:
- Function definitions
- Function signatures
- Function argument types
- Function return types
- Auto-complete and intellisense (results may vary)
- Code warnings and errors
- E.g.: You pass an invalid type to a FiveM function
How?
A script was made to parse all markdown files from: GitHub - citizenfx/natives: GTA V Natives Documentation and GitHub - citizenfx/fivem: The source code for the Cfx.re modification frameworks, such as FiveM, RedM and LibertyM, as well as FXServer..
This script generates Lua files based on these markdown documents (as well as the individual .lua files). These generated Lua files contain the global functions that are required in your FiveM scripts and resources.
Images
Disclaimer
This project is not yet friendly to beginner developers. And is not yet documented thoroughly. It requires knowledge of your IDE and how to add libraries/dependencies for your FiveM plugin development environment to be aware of this library.
Feel free to check out our other open-source projects on GitLab.