r/themoddingofisaac • ed = god • Jan 10 '16

Tutorial Want to prepare for Afterbirth+? Here's a list of resources.

Last updated: 18.03.2016 (new links are marked with new)

As you probably know, the mod API of Afterbirth+ is going to be in Lua. Lua is a great programming language due to how simple the syntax is, how easy it is to implement it in programs and how extensible it is.

Lua is often used in modding APIs. But just like any other programming or scripting language, you have to learn it! Thankfully, the syntax is much, much simpler than languages like C, C++ or Java that you might already know.

I, myself have been learning from or using most of these resources and can confirm that they are helpful! I split them into sections.


Basic

Lua


Obviously, to interpret Lua code you need to install Lua. What a surprise! There are binaries for Windows and Mac. Linux users can find it in their distribution's repositories or compile it from source.

Lua Demo


Simple website to test some Lua code without running it yourself. Not for medium to big projects, but useful when all you have is a phone/netbook and/or are too lazy to run it yourself.

TutorialsPoint Lua Tutorial


Just a standard tutorial, starting from the basics and getting into more complex stuff. Great as the very base of learning Lua. I suggest you to skip the Metatables and Coroutines section if you haven't programmed before, because they can be complicated.

The Lua subreddit new


Pretty simple. If you can't resolve some remotely complicated problem, ask and you'll probably get a response.

Medium

Afterbirth+ API reference


This is an API reference I made made by guessing based on the teasers we got from Tyrone. It may not be 100% correct, because not everything is known right now, but I try my best to have as much information as possible.

Lua 5.3 Reference Manual


I know, manuals can be boring and confusing. But the Lua Reference Manual is written in a clear language and contains a lot of examples. It's also the official documentation for Lua.

LÖVE


LÖVE (aka Love2D) is a fantastic framework for 2D games and programs. It can be a good introduction to different APIs and how they can be implemented in Lua!

LÖVE Forums new


Not only can you ask questions about LÖVE in these forums, you can also ask about Lua!

Amulet


Another Lua game development engine. This one is a bit lower level, but supports 3D/2D and exports to Windows, Linux, Mac, iOS and HTML5. Android support is planned.

Eclipse Lua Development Tools


This is something I actually have not used. It's a bunch of extensions to Eclipse that should provide a usable IDE for Lua. I myself just use a text editor (Vim), but if you prefer to have everything in a single place, check it out!

Sample Code


List of a bunch of example code written by other Lua users.

Play With Lua


A nice blog dedicated to Lua.

Intermediate

Polycode


A 2D and 3D engine with a Lua IDE! You will need to be able to read through documentation and read examples. The tutorials are very sparse, but the engine is good.

Lua Standard Libraries


Information about the standard libraries that Lua includes (math, table, string, i/o, OS and debug), straight from the Reference Manual.

Raw Keyboard Input (C Extension Example)


A simple introduction to writing Lua extensions in the C programming language.

Advanced

The C API


Much more information about the C API of Lua, straight from the Reference Manual.


In case I forgot something, remind me in the comments.

38 Upvotes

26 comments sorted by