Flash: Make a Platform Racing Game PART 1

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
21,990
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Aug 11, 2009

Code for char:

onClipEvent(load) {

//LOOK AT THE CODE!!! WHEREVER YOU READ -GREATER THAN SIGN- OR -LESS THAN SIGN-, REPLACE THE WORDS WITH THE ACTUAL SIGN.

falling=false;
hitting=false;
gravity=10;
speed=6;
jump=0;
jumping=false;
}

onClipEvent(load) {
falling=false;
hitting=false;
gravity=10;
speed=6;
jump=0;
jumping=false;
}
onClipEvent(enterFrame) {
if(!_root.ground.hitTest(this._x, this._y, true) && !jumping) {
_y+=gravity;
gravity=10;
falling=true;
}
if(Key.isDown(Key.UP) && jumping==false) {
jumping=true;
}
if(Key.isDown(Key.DOWN) && jumping==true) {
_root.char._y+=10
}
if(jumping) {
this.gotoAndStop("jump")
this._y-=jump;
jump-=.5;
if(jump GREATER THAN 0) {
falling=true;
}
if(jump LESS THAN -15) {
jump=-15;
}
}
if(_root.ground.hitTest(this._x, this._y, true) && falling) {
jump=12;
jumping=false;
falling=false;
}
}

Category:

Education

Tags:

License:

Standard YouTube License

  • likes, 7 dislikes

Link to this comment:

Share to:

Uploader Comments (PivotyPivoty)

  • Uh no it doesn't, I think would know after trying ten times

  • I don't mean to complain but why does like every put "less than sign" instead of the actual less than sign to make it less complicated??

  • because youtube doesn't let you put it those signs

see all

All Comments (76)

Sign In or Sign Up now to post a comment!
  • what is this program?

  • @PivotyPivoty What is it? as1? as2? as3? please tell me.

  • I did it and it said I has like a thousand errors!!!?

  • What regerstation do i put the charicter as

  • the code for char isn't good it said 'encountered  }

  • every time i test it, my character falls through the ground. PLEASE HELP.

  • @djdum434 I meant what part of the code

  • Learn how to use vcam, i used it with this tutorial, than you can make the levels giant and make the camera (vcam - virtual camera) follow the char

  • @JsKingBoo change the code.

  • How do you make him jump lower?

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more