How do i make my character jump and crouch in a game?!?!?!?!

I am making a game where a stickman is running and dodging obstacles. How do I make him jump and crouch on command?

PLEASE HELP ME

Here’s an interactive stick figure that can run, jump, crouch. Let me know if this works.

interactiveStickFigure-Nov30-2018-4.34PM.html (828.6 KB)

I cant view the file because I am working from my school computer, can you send me the code?

Here’s the code this project uses. Unfortunately, you also need a clip which is designed for this code for it to work.

function keyDown(key) {
if (key === "RIGHT") {
    this.gotoAndStop("run");
} else if (key === "UP") {
    this.gotoAndStop("jump");
} else if (key === "DOWN") {
    this.gotoAndStop("crouch"); 
}

}

function keyReleased() {
    this.gotoAndStop("idle"); 
}

How can I make this work for my project?