Saturday, November 10, 2012

Editor is ALPHA READY!

YES! So, with a coding frenzy and some help from my fellow coders-in-arms Brendan, David, and Paige the editor is now Alpha-Ready! Dave had a great thought of how to handle layers in the game, which also lended itself to a handy implementation in the editor. He also got the Magic Ground Finder (codename: MGF) working, which picks out what sort of tile you have placed where and builds an optimized hull from that.
I modified the editor to use the naming convention to automatically find all tile sheets and make them available in the editor. I'm using a sort of modified MVVM model to handle going from UI to actual data and it seems to work remarkably well. The ViewModel for the editor, for instance, exposes a 'SelectedBrush' object. This can be set to anything. When the user clicks within the actual editor window a small chunk of code decides what to do with the current brush (if it's a sprite, set the cell in the CurrentLayer; if it's a template, build a new object to place in the level).
This also made it very easy to add extra items that can be added such as the player spawn point or your trusty robot head sidekick. It also provides an easy way to handle future expansion - WIN!
I feel pretty comfortable handing the editor to our artists to start trying. I'm sure they'll find plenty of improvements they would like to make, and that's a good thing! I can't wait to see how this tool evolves over the course of the next few months.

Tuesday, October 30, 2012

More Editor

This week was again quite productive. I took the level editor from a rough concept to a fully functional alpha. Today I showed Becky the progress and she had some excellent feedback - she wants to be able to 'paint' a texture over a large area and have the editor automatically infer the ground mesh from the tiles placed.
This means I'll need some way to take each individual tile's bounding box (which might be square, rectangular, triangular or some other shape) and merge all of the adjacent vertices. I'm thinking I may use the algorithm here to handle simplifying all of the individual squares into larger sections.
Other small tasks for this week are cut, copy, paste, and duplicate support (to easily make many copies of a single object) and a toolbox (which will be needed for the 'paint' support above). I believe layers are something we'll need to handle in a future sprint.

Friday, October 26, 2012

Making Progress

The editor is progressing nicely! I have managed to get about 95% of the base functionality in thus far and what it does works pretty darn well. Hooking up loading and saving was a piece of cake thanks to Dave's work on the (de)serization code. Next up is adding horizontal and vertical scrollbars to move around the level, building the Sprite Manager control (would be nice to be able to add new sprites and change existing ones) and fixing the remaining camera issues.

Tuesday, October 23, 2012

Level Editor

Over the weekend I put together a basic level editor to help churn out content for Attraction. It's a Windows Forms app that uses the XNA rendering panel sample (http://xbox.create.msdn.com/en-US/education/catalog/sample/winforms_series_1) for the live level preview. The UI absolutely sucks currently, but it is functionally near-complete. I'm running into some frustrations dealing with PropertyGrid - I miss the DataTemplate functionality from WPF! I suppose I COULD switch to a WPF app but I'm not sure if it would be worth what I would gain.
Over the next week my job is to get the editor to the point that it is usable by the artists on our team. This means a LOT of polish on my part but I'm sure I can get it done. The other engineers are doing their part to get the rest of the game in order and the artists are slaving away on design - I feel lucky to work with such an incredible group of talent.

Saturday, October 20, 2012

A basic editor

Huzzah! I have a (VERY) basic level editor put together using WinForms and the XNA+WinForms sample code. It supports clicking to select and drag-drop operations within the editor pane on the right. Next up is adding a context menu or other method of managing what components are added to a given entity. I'm considering a PropertyGrid - it would give a relatively straightforward way to modify all of the attributes of the existing components and should be easily extensible.
My first priority after getting the basic editor working is a ground editor. We've decided to store the collision box for the ground separately, so I need to have support to somehow edit this collision mesh. Down the road I also want support for templates, a comprehensive Redo/Undo system (which should be one of the easier things to build), changing grid attributes (on/off, snap on/off, color, spacing, etc).

Thursday, October 18, 2012

Back from the Break

That was a refreshing fall break! Over the past week I re-factored the existing code into the Artemis entity system (which I'm still loving). It was fun to see all of the pieces coming together! I was able to take the pre-existing project (with about a dozen classes) and distill it down to 5 systems and 7 components. That's a significant improvement! Plus, we can now mix/match those 7 components into (potentially) 128 distinct types of objects without involving the coders. I'm sure we'll add more systems and components as we go (fixed magnets are one thing currently missing) but this is COOL!
On Tuesday I committed the code to our git repository and the other engineers have taken it and run with it. I understand that there are a few cool Components in the works. Next up - I need to get moving on the level editor. My first attempt tried to open a Windows Form from the XNA app to add, alter, remove etc entities at run-time. I found that XNA prevents the focus events from firing properly which interferes with a number of controls (notably PropertyGrid). My next attempt will use a Windows Forms application with an XNA rendering window (as described in most tutorials on the subject).

Sunday, October 7, 2012

And then, there were 3

The final 3 have been decided! Time Jump didn't quite make the cut - the panel had some good feedback for us. They felt that the concept would require twice as much art work, level design, and iteration due to the dual nature. They also felt that we didn't differentiate the alternate time - why not just do the same thing in a single time stream? They didn't feel we adequately addressed how the past could affect the future.
I can't be too sad/upset about not being chosen though, because instead I get to work on another awesome game! Attraction is a game about a robot (seriously, what's up with robots?) with a magnetic arm. You can pull toward or push away from magnets in the environment. This simple mechanic can be used to build a wide variety of situations - I really am excited for the possibilities! The game in prototype form is already fun to play through and you already get a feel for where the game might eventually go.

One common piece of feedback from the panel was that none of our concepts felt Indie Enough. Everything seemed fairly mainstream, and there was no mechanic, aesthetic or theme that was far out enough to be indie. We're meeting today to discuss the overall direction for the game. With such an awesome team I'm sure we can come up with some ways to make this work.

I've already volunteered to focus on the tools for the game - I really find the process of acting as a facilitator incredibly gratifying. It's great to be able to build a tool that multiplies the effectiveness of everybody else on the team when it comes to iterating and trying new/different designs.