Entity Tutorial 0: Tools Setup
In order to compile your LUA code, you will need two programs.
Windows Lua 5.1
NOTE - You must use the lua compiler for windows, even if you are on another platform, due to the VM expecting windows formatted LUA. Wine/wineconsole works quite well for emulating it on other platforms.
The Luac command will created a compiled lua program, however, we need to insert this program into our mod JSON. In order to do this, we will base64 encode the resulting program.
Windows does not include a base64 command line utility. The easiest solution is to use the Notepad++ text editor along with the MIME tools plugin. The plugin is usually installed, but if not, install it via the plugin manager. Then you can open the file, select all text, and Plugins -> MIME Tools -> Base64 encode.
Other options are available as well, such as command line options. However, some of these include newline characters which will need to be manually deleted.
Mac OSX and Linux
These operating systems already include a base64 command line utility
See this page to see a video demonstrating the setup steps on Windows.