Sunday, 1 May 2011

AS coding progress


I've been working on a code that will enable the background to scroll and the main character to walk at the same time. It works so that when the character gets so many pixels towards one side of the screen, the background will then move so many pixels to either the left/right (depending on the direction of the characters movement.)
There is also a gotoAndStop code to change the image of my character to match the left/right walking position.

This is a reference I used to help write this code: http://www.8bitrocket.com/2007/9/2/Flash-CS3-Actionscript-3-AS3-Game-Primer-2-Asynchronous-key-detection-for-arcade-games/

No comments:

Post a Comment