Story Added

http://www.youtube.com/watch?v=W1UoC2nKUsE

Attract screens included and parallax background added.

Story

Created a simple story about having to save the world from cyber terrorists who have hacked the global network.  Created an attract screen which cycles through the four story screens that I have created.  Created some really simple graphics in Gimp, which I hope to improve later.

Updated the title screen with a simple title logo that I created with Gimp.  Added logic to the title screen to use the user created world if it exists, or generate the default world if no user created world exists.

Parallax

Added a simple scrolling background to the level.  For now, I just used one of the images that I created for Resistor.  Added a parallax effect by offsetting the background image by the room offset divided by two.  That means the background is scrolling at half speed of the room.  When creating the background image, the grid option in Gimp really helped with placing the background images, which were placed over a blue to black gradient.  I could have set my background image as a pattern and used bucket fill, but that would have been more effort than needed.  My Gimp toolbox kept disappearing for some reason, and getting it to show again with the tool options was really a hassle.  Once I got the background image added to the game, there was a noticeable jump that occurs when the player crosses rooms, which will need to be fixed later.  I’m thinking about copying all of the room data to one huge array, which would solve a lot of problems like that.

Gameplay Changes

Added a check in the draw method of the game screen to determine if the player is facing right.  If so, then the player sprite is flipped horizontally.  This throws off the baked-in lighting, but it is good enough for now.

Modified the player’s jump speed to 10 (pixels per frame) instead of 5, which makes the jumps feel less floaty.  Still need to add some calculations to make jumps more parabolic and less linear.

Realized that the player’s health wasn’t getting re-initialized after dying and starting a new game.  I went ahead and created a newGame method in the game screen class which handles things like that.