Saturday, May 19, 2012

Camera Man

Unit 8
I am very happy with the updates I have made recently. My favorite has to be the camera. I have been posting almost hourly builds on facebook for my friends to try. They all reported pretty much the same problems. The biggest was that I set the game up so that the player runs left. I don't know what I originally made this choice since I know as a gamer I was conditioned to run right for all games. The only thing I can think of is that my original inspiration for my game was Caveman Games for NES, the Pole Vault Event and in that game the player runs to the left. THis was a bad thing for my game because almost everyone reported running to the right and falling off the "world". I could have easily just put a collision wall there to keep them from running right, but then I thought it might be better to place the player character in the center of the environment and put walls on both sides of them so they could either throw over the left or right wall. This worked, except now my camera didn't make sense. I have the camera linked to the player controller. This worked fine if you only went one direction, but it didn't let you see far to the right. I decided to make code that let you see bother directions based on the speed the player is moving. This at first worked, but I noticed that the camera jerked into position making it a bit jarring. After much research I was able to add damping to the camera so it would smoothly switch. I'm patting myself on the back, but please understand this is coming from a non-programmer. It has really made me appreciate programmers, even though I had already thought very highly of them from when I used to work with them.

No comments:

Post a Comment