Sandblaster 1.5
January 3, 2009. I spent the last couple days of my New Year holiday implementing some major features for this next release. I knew that soon I'd be heading back to work, and I was afraid I wouldn't have the time or energy to work on anything significant, so I wanted to make sure I put out a really strong release before it was too late.
The main feature I worked on was saving and loading of "snapshots." This allowed the same drawings to be preserved across different invocations of the application, as well as across zoom levels and orientation changes. I tried to make this feature a little fancy by generating and displaying thumbnails of each snapshot when browsing them. This feature was a lot of work, because I had to learn how to use more of Android's UI toolkit.
I also changed how zooming in or out worked. In previous releases, changing the zoom level actually cleared and generated a new level. In this release, all levels became the same resolution, but the zoom level allowed you to make the particles larger or smaller. By default, the scale would be appropriate to fit the entire level on the screen, and I picked a level resolution that would allow a reasonable frame rate for most drawings.
This release had a few other little finishing touches, like icons for menu items, panning with the trackball, etc.
Sandblaster 1.6

January 12, 2009. Right now this is the latest version I've released. This was the first release since returning to work, and came nine days later than the previous one. Fortunately I was still finding time and energy on weekends to get some significant work done.
I spent a lot of time during this release cleaning up and reorganizing my code. This had become necessary just to be able to proceed with some of the features I wanted to add. Despite the distraction of work and the overhead of refactoring, I somehow found time to work on several major features, too.
The first feature I implemented was a simple play/pause button. I then decided an undo button would go along quite nicely. This, however, required implementing a faster method of saving and loading more complete snapshots, so I basically rewrote all that code to use Java data streams instead of XML. The undo feature worked by having a new snapshot pushed onto a stack every time the user performed an undoable action (drawing or pressing the play/pause button). Pressing the undo button would pop the latest snapshot and recreate the sandbox in its previous state.
After implementing playback control and undo, I looked into optimizing performance again. I made physics a little faster, and rendering a lot faster. While I was at it, I also changed how density worked and added viscosity. In previous releases, elements always sank or floated through other elements as quickly as possible. I changed it so that the rate depended more on how different the two elements' densities were. This made things appear more buoyant, natural, and interesting. The addition of viscosity allowed some variation in how steeply things pile up (or how rapidly they flatten out).
Finally, to wrap up this release, I added an eraser, a larger (but still fixed) pen size for drawing thicker lines, and a new demo. For the demo, I harnessed my ASCII art skills to create an hourglass. However, I was afraid people might think it was just the game's loading screen, so I added some dynamic branding.
The Future

I'm getting very close to releasing the next version of Sandblaster, which will be 1.7. I've been experimenting with a few changes that haven't really panned out, but now I'm concentrating on providing better drawing options. I'd like to make it so you can select between "pen", "spray", "spout", and "line" modes, and change the size of the pen with a slider. You can see a rough draft to the left. Once I fix a bunch of bugs, create some icons, and polish the interface, this will be ready for release!


No comments:
Post a Comment