"The Room, starring an 800 pound Gorilla"
"The 800 pound Gorilla"
Both are stupid but the second one makes me chuckle evey single time.
The second constant is far less unique and simply involves giving systems really cool names.
Hence, the MBM, or Multi-layered Behavior Matrix.
In the past week, I've tried to go completely...apeshit (self-referential humor inside of a pun...it never ends) and attempt to rebuild my prototype using Behaviors.
For those who might not know, behaviors are pieces of code which are meant to be modular, meaning you could (in theory) take the movement behavior of your main character and apply it effortlessly to a piece of furniture.
Building your game to be as modular as possible is a lot of work up front as you need to make sure that every single behavior will work as expected under various, hard to predict conditions. Once you have all your basic behaviors in place, though, you can start swapping them around and trying out different versions without damaging your basic game structure. This is not only immensely fun, it also helps to make the game feel a lot more fluid and open-ended.
Using Torque2D's powerful (if a bit clunky) behavior system, I've devised a system for the characters' control schemes.
At the First node of the hierarchical tree, you have either an Input Manager or an AI Manager. These will take player input or AI tactics and send them to another behavior which I call the Move Matrix.
The Move Matrix processes this data every tick and calls on yet another layer of Behaviors, which handle individual components of the movement.
For instance, I have an Horizontal_movement behavior, a Jump behavior, a Falling behavior a Swimming_movement behavior, etc.
In conclusion, I've deconstructed the entire thing and built it back up to the very same point where it was last time. And I managed to say that in 450 characters or so.