This week I've been working on getting the basic game control framework in place. If you've played Creatures & Castles on the iPhone or iPad (and if not, why not - go and buy it immediately!) you'll have noticed that the character is controlled by tracing the character's route using the player's finger to lay a path of magical footprints.
Touching and dragging is a natural operation on the touch-sensitive screen of the iDevices. The most direct way to translate this across to the HTML5 version would be to have the player click and drag the path. However in practice it's a colossal pain in the ass, so I decided to implement a different system for controlling the main character. I'm in the process of prototyping a simple system where left-clicking will create a path between the character and the position of the cursor - as long as there isn't an intervening wall. Holding down the right mouse button undoes the path, which removes the need for a separate undo button as in the iDevice version.
It's not quite perfect, and I still have some tweaks and experimentation to perform before I'm 100% happy with it, and after that the core game will be in place. Then it will be time to start fleshing out some of the in-game enemies and the scoring system. From there, I'll work my way out to the supporting features such as the title screen, level select screens and other ancillary features. In fact, the reasons behind my choices to develop the game from the inside out would make a good topic for my next post.