Instance of Symbol 7 MovieClip in Frame 1
onClipEvent (load) {
percent = 0;
}
onClipEvent (enterFrame) {
loading = _parent.getBytesLoaded();
total = _parent.getBytesTotal();
percent = percent - ((percent - ((loading / total) * 100)) * 0.25);
per = int(percent);
percentage = per + "%";
loadBar._width = per;
if (percent > 99) {
_parent.gotoAndPlay("start");
}
trace(percent);
}
Frame 4
stop();
Instance of Symbol 40 MovieClip in Frame 5
onClipEvent (load) {
this.gotoAndPlay("bgm01");
}
Frame 8
stop();
Frame 9
_global.jump = false;
_global.a = -1.5;
_global.vy = 0;
Instance of Symbol 92 MovieClip "bg02" in Frame 9
onClipEvent (enterFrame) {
this._x = _parent.bg._x;
this._y = _parent.bg._y;
}
Instance of Symbol 40 MovieClip in Frame 9
onClipEvent (load) {
this.gotoAndPlay("bgm02");
}
Frame 13
stop();
Frame 14
trace(_global.gameOver);
trace(_global.win);
if (_global.gameOver == true) {
this.gotoAndStop("lose");
} else if (_global.win == true) {
this.gotoAndStop("win");
}
Instance of Symbol 40 MovieClip in Frame 14
onClipEvent (load) {
this.gotoAndPlay("bgm01");
}
Frame 15
_root.scoretable.filename = "scores/sugeh.sco";
_root.scoretable.scoresize = 10;
_root.scoretable.action = "VIEW";
_root.scoretable.viewtype = "FLASH";
_root.scoretable.winname = _global.name;
_root.scoretable.winscore = _global.score;
_root.scoretable.loadVariables("scores.php", "GET");
Frame 24
stop();
Frame 25
_root.scoretable.filename = "scores/sugeh.sco";
_root.scoretable.scoresize = 10;
_root.scoretable.action = "INSERT";
_root.scoretable.viewtype = "FLASH";
_root.scoretable.winname = _global.name;
_root.scoretable.winscore = _global.score;
_root.scoretable.loadVariables("scores.php", "GET");
Frame 34
stop();
Symbol 7 MovieClip Frame 1
stop();
Symbol 31 Button
on (release) {
_global.name = inputName.text;
_parent.gotoAndStop("game");
}
Symbol 37 MovieClip Frame 1
stop();
Symbol 40 MovieClip Frame 1
stopAllSounds();
Symbol 40 MovieClip Frame 9
stop();
Symbol 40 MovieClip Frame 10
stopAllSounds();
Symbol 40 MovieClip Frame 20
stop();
Symbol 47 MovieClip Frame 1
groundOn = function () {
var _local1 = _global;
var _local2 = _parent;
if ((_local1.v < 0) or (_local1.v == undefined)) {
if (this.hitTest(_local2._parent._parent.ball.foot)) {
_local1.hit = true;
_local2._parent._y = _root.ball._y - _local2._y;
_local1.fall = false;
_local1.jump = false;
this.onEnterFrame = groundOff;
}
}
};
groundOff = function () {
var _local1 = _global;
var _local2 = this;
if (_local2.hitTest(_parent._parent._parent.ball.foot) == false) {
if (_local1.jump == true) {
_local1.hit = false;
_local2.onEnterFrame = groundOn;
} else if (_local1.jump == false) {
_local1.hit = false;
_local1.fall = true;
_local1.v = 0;
_local2.onEnterFrame = groundOn;
}
}
};
this.onEnterFrame = groundOn;
Symbol 57 MovieClip Frame 45
gotoAndPlay (1);
Symbol 57 MovieClip Frame 51
stop();
Symbol 58 MovieClip Frame 1
groundOn = function () {
var _local1 = _parent;
var _local2 = _global;
if ((_local2.v < 0) or (_local2.v == undefined)) {
if (this.hitTest(_local1._parent._parent.ball.foot)) {
_local2.hit = true;
_local1._parent._y = _root.ball._y - _local1._y;
_local2.fall = false;
_local2.jump = false;
this.onEnterFrame = groundOff;
_local1.leaf._rotation = 30;
_local1.leaf.gotoAndPlay("still");
}
}
};
groundOff = function () {
var _local1 = _global;
var _local2 = _parent;
var _local3 = this;
if (_local3.hitTest(_local2._parent._parent.ball.foot) == false) {
if (_local1.jump == true) {
_local1.hit = false;
_local2.leaf._rotation = 0;
_local2.leaf.gotoAndPlay(1);
_local3.onEnterFrame = groundOn;
} else if (_local1.jump == false) {
_local1.hit = false;
_local1.fall = true;
_local1.v = 0;
_local2.leaf._rotation = 0;
_local2.leaf.gotoAndPlay(1);
_local3.onEnterFrame = groundOn;
}
}
};
this.onEnterFrame = groundOn;
Instance of Symbol 57 MovieClip "leaf" in Symbol 59 MovieClip Frame 1
/* no clip actions */
Symbol 62 MovieClip Frame 1
groundOn = function () {
var _local1 = _global;
var _local2 = this;
if ((_local1.v < 0) or (_local1.v == undefined)) {
if (_local2.hitTest(_parent._parent.ball.foot)) {
_local1.hit = true;
_parent._y = _root.ball._y - _local2._y;
_local1.fall = false;
_local1.jump = false;
_local2.onEnterFrame = groundOff;
}
}
};
groundOff = function () {
var _local1 = _global;
var _local2 = this;
if (_local2.hitTest(_parent._parent.ball.foot) == false) {
if (_local1.jump == true) {
_local1.hit = false;
_local2.onEnterFrame = groundOn;
} else if (_local1.jump == false) {
_local1.hit = false;
_local1.fall = true;
_local1.v = 0;
_local2.onEnterFrame = groundOn;
}
}
};
this.onEnterFrame = groundOn;
Symbol 63 MovieClip Frame 1
wining = function () {
var _local1 = _global;
var _local2 = _parent;
var _local3 = this;
if ((_local1.v < 0) or (_local1.v == undefined)) {
if (_local3.hitTest(_local2._parent.ball.foot)) {
_local1.hit = true;
_local2._y = _root.ball._y - _local3._y;
_local2._x = _root.ball._x - _local3._x;
_local1.fall = false;
_local1.jump = false;
_local1.win = true;
_root.ball.onEnterFrame = standStill;
}
}
};
groundOff = function () {
var _local1 = _global;
var _local2 = this;
if (_local2.hitTest(_parent._parent.ball.foot) == false) {
if (_local1.jump == true) {
_local1.hit = false;
_local2.onEnterFrame = groundOn;
} else if (_local1.jump == false) {
_local1.hit = false;
_local1.fall = true;
_local1.v = 0;
_local2.onEnterFrame = groundOn;
}
}
};
standStill = function () {
};
this.onEnterFrame = wining;
Symbol 89 MovieClip Frame 1
this.onEnterFrame = function () {
var _local1 = _global;
var _local2 = _parent;
var _local3 = this;
if ((_local1.jump == true) or (_local1.fall == true)) {
_local2.bg._y = _local2.bg._y + _local1.v;
_local2.bg_moutain._y = _local2.bg_moutain._y + (_local1.v / 10);
_local1.v = (_local1.v + _local1.a) - _local1.windDir_y;
}
if ((_local1.movex == true) && ((_local2.bg._x >= -1200) && (_local2.bg._x <= 1300))) {
_local2.bg._x = (_local2.bg._x + _local1.vy) - _local1.windDir_x;
_local2.bg_moutain._x = _local2.bg_moutain._x + ((_local1.vy - _local1.windDir_x) / 10);
}
if ((_local1.movex == false) && ((_local2.bg._x >= -1200) && (_local2.bg._x <= 1300))) {
_local2.bg._x = (_local2.bg._x + _local1.vy) - _local1.windDir_x;
_local2.bg_moutain._x = _local2.bg_moutain._x + ((_local1.vy - _local1.windDir_x) / 10);
if (_local1.vy > 0) {
_local1.vy = _local1.vy / 1.5;
} else if (_local1.vy < 0) {
_local1.vy = _local1.vy / 1.5;
}
}
if (Key.isDown(39) && (_local2.bg._x >= -1100)) {
_local1.movex = true;
_local1.characDir = "r";
if (_local1.vy > -10) {
_local1.vy = _local1.vy - 1;
}
} else if (Key.isDown(37) && (_local2.bg._x <= 1200)) {
_local1.movex = true;
_local1.characDir = "l";
if (_local1.vy < 10) {
_local1.vy = _local1.vy + 1;
}
} else {
_local1.movex = false;
}
if (Key.isDown(32)) {
if ((_local1.jump == false) && (_local1.hit == true)) {
_local1.v = 20;
_local1.jump = true;
}
}
if (Key.isDown(65)) {
if (((_local1.jump == true) or (_local1.fall == true)) && (_local2.fly_meter.fly_meter_bar._xscale > 5)) {
_local2.fly_meter.fly_meter_bar._xscale = _local2.fly_meter.fly_meter_bar._xscale - 2;
if (_local1.flyReady == true) {
_local1.fly = true;
} else {
_local1.fly = false;
}
} else {
_local1.fly = false;
}
} else {
_local1.fly = false;
}
if ((_local1.hit == true) && (_local1.movex == false)) {
_local3.gotoAndStop("stand_" + _local1.characDir);
} else if ((_local1.hit == true) && (_local1.movex == true)) {
_local3.gotoAndStop("run_" + _local1.characDir);
} else if (((_local1.jump == true) && (_local1.fly == false)) && (_local1.v >= 0)) {
_local3.gotoAndStop("jump_" + _local1.characDir);
} else if (((_local1.jump == true) && (_local1.fly == false)) && (_local1.v < 0)) {
_local3.gotoAndStop("fall_" + _local1.characDir);
} else if (((_local1.fall == true) && (_local1.fly == false)) && (_local1.v < 0)) {
_local3.gotoAndStop("fall_" + _local1.characDir);
} else if (_local1.fly == true) {
_local3.gotoAndStop("fly_" + _local1.characDir);
}
};
_global.characDir = "r";
stop();
Symbol 96 MovieClip Frame 1
stop();
Symbol 96 MovieClip Frame 4
stop();
Symbol 96 MovieClip Frame 5
stop();
Symbol 96 MovieClip Frame 10
stop();
Symbol 97 MovieClip Frame 1
arrow.gotoAndStop("nowind");
_global.windDir_x = 0;
_global.windDir_y = 0;
windBlow = function () {
var _local1 = _global;
if (windDirRan == 1) {
_local1.windDir_x = 0;
_local1.windDir_y = 1.2 * (-windpower);
arrow.gotoAndStop("wind");
arrow._rotation = 0;
old_windDirRan = windDirRan;
} else if (windDirRan == 2) {
_local1.windDir_x = 2 * windpower;
_local1.windDir_y = -windpower;
arrow.gotoAndStop("wind");
arrow._rotation = 45;
old_windDirRan = windDirRan;
} else if (windDirRan == 3) {
_local1.windDir_x = 3 * windpower;
_local1.windDir_y = 0;
arrow.gotoAndStop("wind");
arrow._rotation = 90;
old_windDirRan = windDirRan;
} else if (windDirRan == 4) {
_local1.windDir_x = 2 * windpower;
_local1.windDir_y = windpower;
arrow.gotoAndStop("wind");
arrow._rotation = 135;
old_windDirRan = windDirRan;
} else if (windDirRan == 5) {
_local1.windDir_x = 0;
_local1.windDir_y = 1.2 * windpower;
arrow.gotoAndStop("wind");
arrow._rotation = 180;
old_windDirRan = windDirRan;
} else if (windDirRan == 6) {
_local1.windDir_x = -2 * windpower;
_local1.windDir_y = windpower;
arrow.gotoAndStop("wind");
arrow._rotation = 235;
old_windDirRan = windDirRan;
} else if (windDirRan == 7) {
_local1.windDir_x = -3 * windpower;
_local1.windDir_y = 0;
arrow.gotoAndStop("wind");
arrow._rotation = 270;
old_windDirRan = windDirRan;
} else if (windDirRan == 8) {
_local1.windDir_x = -2 * windpower;
_local1.windDir_y = -windpower;
arrow.gotoAndStop("wind");
arrow._rotation = 315;
old_windDirRan = windDirRan;
} else if (windDirRan == 0) {
_local1.windDir_x = 0;
_local1.windDir_y = 0;
arrow.gotoAndStop("nowind");
arrow._rotation = 0;
old_windDirRan = windDirRan;
}
};
onEnterFrame = function () {
var _local1 = _global;
if ((_local1.hit == true) && (_local1.fly == false)) {
_local1.a = -1.5;
windpower = 0.2;
} else if ((_local1.hit == false) && (_local1.fly == false)) {
_local1.a = -1.5;
windpower = 0.5;
} else if ((_local1.fly == true) && (_local1.hit == false)) {
windpower = 1;
if (_local1.windDir_y == 0) {
if (_local1.v < 0) {
_local1.a = -0.5;
_local1.v = -7;
}
} else if (_local1.windDir_y < 0) {
if (_local1.v < 0) {
_local1.v = -6 - _local1.windDir_y;
_local1.a = -1.5;
} else {
windpower = 1;
_local1.a = -1.5;
}
} else if (_local1.windDir_y > 0) {
if (_local1.v < 0) {
_local1.v = -26 + _local1.windDir_y;
_local1.a = -1.5;
} else {
_local1.a = -1.5;
}
}
} else {
_local1.a = -1.5;
}
windDirRan = random(800);
if (windDirRan <= 8) {
windBlow();
} else {
windDirRan = old_windDirRan;
windBlow();
trace(windDirRan);
}
};
stop();
Symbol 101 MovieClip Frame 4
stop();
Symbol 101 MovieClip Frame 10
gotoAndPlay ("alert");
Symbol 103 MovieClip Frame 1
onEnterFrame = function () {
var _local1 = _global;
if ((_local1.fly == false) && ((fly_meter_bar._xscale < 100) && (fly_meter_bar._xscale > 0))) {
fly_meter_bar._xscale = fly_meter_bar._xscale + 1;
}
if (fly_meter_bar._xscale < 30) {
fly_meter_bar.gotoAndPlay("alert");
_local1.flyReady = false;
} else {
fly_meter_bar.gotoAndPlay("normal");
_local1.flyReady = true;
}
};
Instance of Symbol 101 MovieClip "fly_meter_bar" in Symbol 103 MovieClip Frame 1
/* no clip actions */
Symbol 109 MovieClip Frame 1
stop();
Symbol 109 MovieClip Frame 9
stop();
Symbol 109 MovieClip Frame 15
stop();
Symbol 112 MovieClip Frame 1
_global.score = 2000;
trackScore = function () {
_parent.gotoAndPlay("end");
trace(_global.score);
};
countDown = function () {
var _local1 = _global;
_local1.score = _local1.score - 1;
time_counter_bar._xscale = (100 * _local1.score) / 2000;
if ((time_counter_bar._xscale <= 20) && (time_counter_bar._xscale > 10)) {
time_counter_bar.gotoAndStop("alert01");
} else if ((time_counter_bar._xscale <= 10) && (time_counter_bar._xscale >= 0)) {
time_counter_bar.gotoAndStop("alert02");
} else if (time_counter_bar._xscale < 0) {
time_counter_bar._xscale = 0;
_local1.win = false;
_local1.gameOver = true;
}
if ((_local1.gameOver == true) or (_local1.win == true)) {
this.onEnterFrame = trackScore;
}
};
onEnterFrame = countDown;
Symbol 141 Button
on (release) {
_global.gameOver = undefined;
_global.win = undefined;
_root.gotoAndPlay("start");
}