Chopper Command: Sprites with Löve

the hard way

In the book Löve for Lua Game Programming I mentioned in my previous post the author shows examples of using external libraries with Löve to control various things, such as animations. The Löve website has a long list of these libraries and they certainly make life easier. But as I wanted to port most of the code to other frameworks, I decided to do things the hard way. So here’s how I created the sprites for the game in Lua.

Read More

Chopper Command: OOP in Lua

take your pick

So Lua and OOP have the same problems as JavaScript and OOP. Namely, too many ways to do it, and none of them as good as the real thing. To be honest I prefer the way Lua handles the hacky side of forcing OOP concepts into it. JavaScript makes everything uglier, somehow. There are two ways I’d recommend using OOP with Lua: Metatables and Patterns. Each one has its time and place.

Read More