Three years ago, I became familiar with Lua for an interview test task. Before that, I had no experience with it.
So, my first surprise was how easy it was to learn and start using it. Yes, complained a little about the "continue" statement, but it was easy to get used to.
The next time I got to Lua it was when we started to work on CodeCombat Worlds -- Educational Game on the Roblox platform to teach kids programming. So yes, we used Luau. Luau is an extension of Lua with some improvements, such as type-checking and other features. I already have experience with interpreting languages, so getting used to Luau for game development was easy. When I started to use it, I was a little skeptical that we could use it for our ambitious project. I was wrong, and I was happy to be wrong. Lua is an excellent language for game development and scripting. I like its simplicity and straightforwardness.
When I recently decided what game engine to play with, I found that Defold is using Lua. It's an excellent choice for this game engine as it highlights its simplicity. I'm not sure I would use Defold for big projects; however, it's an excellent choice for small projects, especially educational games, because it is easy to make HTML5 games with it (Hello Chromebooks in schools!).
If you are interested in more technical details, I would recommend the article "Lua is so underrated" by Noë Flatreaud, which inspires me to write this post.
Top comments (3)
I can totally relate to this post! When I was a fresher, I joined a CAD-based software company where Lua was their primary language. Like you, that was my first encounter with Lua. I agree that it is easy to understand just by reading the code, and the documentation is indeed well-structured. While it has fewer libraries compared to Python, you are right that it makes up for it by being lightweight and efficient. It is great to see others appreciating Lua's simplicity and effectiveness in game development and scripting.
I think also Luau (roblox lua upgrade) should become Lua 6 as they introduce cool features such as type checking and others without losing performance and simplicity. Type checking is a huge deal when your code base grows more and more.
That’s good to know but we were using Lua 5.2 in my previous experience.