Over the past few days I’ve invested most of my energy in the design side of the platformer – writing up design docs for bosses and characters, roughing out the design of the game world, etc. Not a whole lot of insights to share in that area yet – most of it is in primordial first draft state, so I have yet to learn any lessons from my work, just apply previously learned ones. So far I’ve been taking a very iterative, loose approach to my design work – laying down extremely rough, simple drafts based on initial concepts and basic design principles, and then fleshing in detail and making adjustments or moving on to other parts of the design. This means that there are lots of gaps left in the design to fill in, but it also means that I can avoid having to set too many details in stone just to rework them later in response to design changes.
Here’s part of the current diagram that represents the layout of the game world:
As you can see, it’s very light on detail – the sizes and shapes of each area are not to any particular scale, and the finer details of each area are not filled in, like where walls and slopes and doors are placed. But it gives a general sense of the shape and flow of each area, along with describing each area, showing how they connect, and showing the general location of each boss.
I also started working on building level editing functionality into my game. I ended up deciding to use WinForms to build the editor UI, but still integrate it into the game itself. After a little hacking and experimenting, I was able to get controls like toolbars and listboxes hosted into the XNA game window without too much fuss. Right now tapping the ~ key opens the editing UI and pauses the game, and then tapping the key again closes it. I only implemented some of the basic UI elements – status bar showing the status of the editor (Whether it’s performing an operation like a load/save) and mouse coordinates, along with a tile picker and basic support for laying down tiles. I still have to figure out how to properly handle editing levels that are built out of variable-sized tiles, since the approach I’m using hasn’t been done very often.
I did encounter a couple problems getting it working, though – WinForms has no way to reparent a control onto another window directly, so I had to use P/Invoke to call SetParent. I also realized that since my tiles were Texture2D objects, there was no straightforward way to render them into a WinForms ListBox. I ended up building a simple tile picker myself instead, using XNA to render everything except the scrollbar. Other than those relatively minor issues, though, it was pretty easy to get up and running, and it builds nicely on top of the support I already had for reloading levels at runtime.





