Here’s a very techy post about the back-end of Amnesia – the hotspot system. If you’re not interested in geeky stuff, look away now:
Work on codebase is progressing nicely now. I can press a key during the game to flick into the hotpspot editor, which is separate from the map / gameobject editor. There I can place hotpots add special conditions to them and their corresponding scripts, which can do anything from say a line of dialogue, to run a complete program. Hotspots can also be attached to gameobjects, in which case the hotspot moves with it, in case I need any special case monsters or pickup items. To save game all I have to do is save copies of all the non-local variables, as well as the position and states of all game objects.
Hotspots can also be characters in which case they have a bunch more parameters and speech tree editors. I can also edit each room’s scripts, one for init, used for making sure each game object is in the right state and playing the right animation, one for each logic loop, to alter things in general play like lighting effects or simply running a timer.
I can now basically write the whole rest of the game from within the game, with nifty things like code highlighting, and even a basic intellisense. The nice thing is if I ever port it all I need to do is re-write the graphic engine, gameobject engine and script parser and the rest of it is data driven.
I still want to add a more intelligent animation system, and a neat editor for it, so you can place animations like cells with unique positions, and add attachment points and specify hitboxes, but overall I’m excited with the rate of progress! Time to iron out the little bugs and begin the long process of content creation.