lito88 wrote:Hi
How many custom classes did you end up writing to put this beast of a game together?
We wrote more than 500 custom classes.
Would you call yourself a procedural or object-oriented programmer?
It depends on the situation, for this game we use OO programing.
Did you employ an open-source framework/toolkit like PBE(Push Button Engine) or did you roll your own?
Nope, we create our custom tower defense engine, we use only 2 or 3 classes , one for Ellipse calculations, a singleton for Sound Management (we modified this class a bit) and a really great class for PNG transparency called interactivePNG
I noticed that the game employs a mixture of vector and bitmap elements; why not go bitmap all the way?
Because sometimes the vectors don't decrease the performance(considerable), and Bitmaps always increase the size in bytes of the swf. So it depends on the situation, want to keep the game under 20 MB.
Have you ever tried forgoing the Display List in favor of using a rendering system that refreshes a BitmapData instance instead?
Yes, but sometimes the improve you gain in performance is not worth it.
Our suggestion: Read a lot and test, test and TEST different solutions to see what works in every situation, like when to use Object Pooling, when bitmaps, when vectors, etc...etc etc.
Got some follow up questions for you. I hope you don't mind answering them.
1. 500 classes! That's sounds like a lot. What aspect of the project demanded the bulk of those classes? Game logic, asset management, or something else.
2. OOP. Cool. Aside from Singletons and Factories do you employ any other kinds of design patterns? And if so which ones have proven most useful to you in the course of game development.
3. So you rolled your own. Nice. I imagine that you start out with the basic mechanics of a TD game and build from there. However, do you spend a lot of time pre-planning your classes and their relationships before typing any code? If so, do you use UML or other diagrams.