How To: Make your game character jump with Flash CS4

Make your game character jump with Flash CS4

One of the first daunting tasks that confronts most aspiring gamemakers is a simple one: making a character jump and land predictably. If you're gotten to this point and wonder what to do, you're in the right place. This video will teach you how to use Actionscript 3 in Flash CS4 to make your character jump like Mario (or Sonic if you prefer) making your game much closer to being the playable, fun entity that it will soon be.

Download the AS3 files used in the video here.

It’s Black Friday week on WonderHowTo! Don’t miss out on all of the big sales in the Gadget Hacks and Null Byte shops. And if you’ve been wanting to take some classes without going into debt, check out our best deals on online courses for a variety of skill sets. Don’t miss out on these huge discounts:

See Gadget Hacks’s top 10 BF sales on online courses (up to 99% off) >

See Null Byte’s top 13 BF sales on online courses (up to 99% off) >

Our Best Phone Hacks

Gadget Hacks' tips — delivered daily.


how do u make the character jump once for every pressed key? like say the jump key?

var inFlight:Boolean=false;

//in character function of movements

if(event.keyCode==38//up arrow key//{
//make var for height//heightvar+=20;

now your character will move up by 20 pixels and wont be able to jump a second time while still "above", or simply put: until inFlight==true, hero=/=inFlight

Share Your Thoughts

  • Hot
  • Latest