March 20, 2004
Developing an AS2 framework
For the last two months, I've been working on a huge AS2 framework, as part of a two year long project that includes the development of about two hundred games, apart from an e-learning platform.
This framework will be the base to develop those flash games. In fact, we are developing some simple games, with simple physics, in four ours.
We are basing our development in design patterns, mostly the state pattern, and also a lot of MVC, Singleton, Decorator and Facade patterns. We also are implementing all our backend in webservices.
I didn't find easy to adapt my coding practices and knowledge from my pure scripting background to such an abstract way of coding. But now, I must admit that not only the code will be really easy to maintain, but the development proccess is shorter and easier.
And, also, I've found that, apart from some problems with the compiler, the flash player ( or virtual machine ) has proved to be very reliable. Some of the games we've developed yet involve more than 200 classes, and the player has been managing them perfectly.
So, in fact, learning OOP is worth the effort ( and, at the end, this is flash, so there always comes the moment when you must / can apply all the things that really make me love this language: the flexibility, the ability to modify some of its core poperties, the procedural animations,....... ;P )
Posted by Cesar Tardaguila Date: March 20, 2004 02:13 AMProcedural animations!!! d00d, the dark-side...
Posted by: JesterXL en: March 20, 2004 03:13 AMCome on...show us the framework..carn so we can all rip..err learn off you ;)
I'd be interested to see how your framework comes together. I myself have been working on an MVP style framework modeled off an existing Coldfusion Framework (our work) made called BatFink.
Posted by: Scott Barnes en: March 20, 2004 03:32 AMUhhhmmmm, if I show you my framework, I'll probably have to kill you... ;)
Thanks for the interest, anyway. I'll try to post some parts of it...
Posted by: Cesar Tardaguila en: March 20, 2004 10:26 AMThanx, i'd be glad to check some parts of it too.
I'm working on a big framework too (www.atomicboarder.com), more than 90 classes at this time (i use patterns too : decorator, bridge, singleton, factory, mvc ...), and i'll post soon some docs.
I just did some googling on mvc, patterns, decorator, bridge, singleton, factory, frameworks etc, and I'm wondering: question for all you "Pro Flashers" (it's just my hobby):
When did you start learning about all this, is this something you get thaught when studying programmation (or whatever it is you studied ;-)), or did you just pick that up from a book/ online, or did you have to start using this because of the place you work in uses it etc..?
From which "usage level" of Flash on does it become interesting/necessary/obligatory to know about/use these techniques?
Do you use this in all of your projects?
If some of you answer, would you mind me publishing a news entry about his topic on my site?
Thanks for your attention.
I think that nothing is obligatory. Just write your code the way you're confortable with it.
But, when you have to code big applications, with thousands of lines of code, and when you are not the only coder, then it's when OOP, design patterns, and software engineering in general como to help you.
I've had to learn a lot by myself ( my degree is in physics ), so I've read a lot of books, and a lot of tutorials. Probably google is the best place to find useful information..
Hope this helps
Posted by: Cesar Tardaguila en: March 21, 2004 05:01 PM