Monster Racer Rush
Select between 5 monster racers, upgrade your monster skill and win the competition!
4.23 / 5.00 3,881 ViewsBuild and Base
Build most powerful forces, unleash hordes of monster and control your soldiers!
3.93 / 5.00 4,634 ViewsYuo need to use a callback function. Every physical key has a "keyCode", for A it is 65. So you could write something like this:
stage.addEventListener(KeyboardEvent.KEY_DOWN, pressHandler);
function pressHandler(e:KeyboardEvent):void {
if (e.keyCode == 65) {
gotoAndPlay(2);
}
} You need to use a callback function. Every physical key has a keyCode, for A it is 65. So you could write something like this:
stage.addEventListener(KeyboardEvent.KEY_DOWN, pressHandler);
function pressHandler(e:KeyboardEvent):void {
if (e.keyCode == 65) {
gotoAndPlay(2);
}
}