I just found this forum and thought that it would perfectly match my current development stuff.
Current architecture: - Cache: The cache is accessible by everyone, it manages stacks and their entries (via id). e.g. models, levels, objects are hosted there.
- Engine: The logical level, engine loads levels, manages the objects and calls the compositor - Engine.Hitmap: The hitmap with simple true/false entries.
- Compositor: Translates Objects (Tilegrid Coords & Sizes) to Pixel-based ones (if 2D) or to the 2.5D or 3D coordinates. Can be switched anytime (maybe compositing scheme?).
- Renderer: Uses different technologies to render. Same structure required for all renderers. Currently an HTML-generating renderer, but maybe Canvas or WebGL later.
My current challenge: The Quest and Player- or NPC-logic. I currently implemented a simple Engine.Character Class that creates a character instance per object. I now have the problem for using quests or other "global interface interactions" that may influence the characters or NPCs.
Imagine you have an NPC walking around until you talk to him. Then he wants you to follow to a given position. After you followed, he wants to show you how the game works (e.g. fighting and stuff). You get points, upgrades and stuff - or quests you will have to solve. These quests are in my opinion something like attached events for objects. E.g. "destroy object with id bla" will be triggered if the object was destroyed. The callback function attached on it will now be called and upgrades the questmap. ...well, or something like that.
Please have in mind that the underlying DOM (Document Object Model) in web browsers is heavily slow - compared to other environments. That's why I built the structure in that way.
...I want to thank for any idea or opinion on that!
Your editor is the coolest thing you've got. That's awesome. Are you just relying on animated gifs to do animation? I am thinking of doing image sets for animation so I can control which animation is playing depending on user interaction. Perhaps a set of animated gifs for different animations and swapping the images? Not sure the best way to do baked animation.
My intention is to create a new game prototype each week.. The first prototype is a work in progress that will be completed this Saturday. I'm trying to learn collision detection and basic physics - see it here: http://cedarrapidscl.../tyler/messing/
I like your overhead tile based game it's got a very rpg like feel to it and reminds me of the original Zelda.
As far as game engine design and architecture, at this point why worry about it? Make the thing work and if it's an ugly mess, you can clean it up on your next version. When I first started trying to make my physics engine, I was trying to take everything into consideration and create an object hierarchy for linking and such and I just decided and getting nothing visible done, I figured TO HELL WITH IT and just to make SOMETHING work - at least that way I know right away if my game idea has any potential and is worth porting and developing into a full game.
After I get an idea that's amazing and will make me quite rich, I'll spend the time perfecting the engine (and converting it to a platform where I can charge - an app store)
I would have converted it to <canvas> before posting this. Using the DOM like you're doing isn't advised and flickers in Firefox 4b9. I mean it wasn't recommended when people tried to make games in it when it came out. Good start though. Try not to use copyrighted images. There are free sprite libraries online. (Many people have very strong feelings toward copyrighted content).