Sunday, February 13, 2011

Annnnnd ... action!

I have the very basics of the game finished: user can move boards (platforms) around and then pour water to melt the witch. There is definitely some refining to do. However, I need to start building the "game" - the levels/scenes/etc. So I'm going to start learning Director class. I'm still not sure of all that it does, but from reading the forum or it, it seems like a good backbone for building a game. You use it to define

I assume the name "Director" is just something that the developer (Ricardo Rauber Pereira) decided to call it. I also assume that class is specific to either Lua, Corona, or more likely, programming in general. So let me search the Great Big InterWeb to see what I kind find for the definition. Be right back.

Okay, "class" has at least two possible meanings. In OOP (object-oriented programming), a class is a category of objects. The example the Web dictionary had was a class named "shape", and in that class you have objects (along with their properties) of circles, rectangles, squares, and so on. In .NET languages (no idea what these are, has something to do with Microsoft), a class is a template.

The Director class in Corona seems more like a template, but you also define your objects. I think classes in Corona are APIs on steroids, containing functions and object descriptions.

No comments:

Post a Comment