Frame 126
stop();
Instance of Symbol 10 MovieClip "ponyD" in Frame 126
onClipEvent (load) {
var DLeft = false;
var DRight = false;
var AButton = false;
var BButton = false;
var runDistance = 5;
var runVelocity = 1;
var gravity = 0;
}
onClipEvent (enterFrame) {
if (Key.isDown(37)) {
DLeft = true;
} else {
DLeft = false;
}
if (Key.isDown(39)) {
DRight = true;
} else {
DRight = false;
}
if (Key.isDown(88)) {
BButton = true;
} else {
BButton = false;
}
if (DLeft or DRight) {
this.gotoAndStop(2);
}
if ((!DLeft) and (!DRight)) {
this.gotoAndStop(1);
}
if (DLeft) {
this._x = this._x - runDistance;
}
if (DRight) {
this._x = this._x + runDistance;
}
if (AButton) {
}
if (BButton and (DRight or DLeft)) {
if (runDistance <= 10) {
runDistance = runDistance + runVelocity;
}
} else if (runDistance >= 5) {
runDistance = runDistance - runVelocity;
}
}
Symbol 10 MovieClip Frame 1
Symbol 10 MovieClip Frame 2