Frame 1
stop();
_quality = "MEDIUM";
Frame 3
stop();
Frame 4
gotoAndStop (2);
Symbol 46 MovieClip [shadow] Frame 1
stop();
Symbol 49 MovieClip Frame 1
stop();
Symbol 97 MovieClip Frame 1
play();
Symbol 97 MovieClip Frame 3
_root.game.f_PunchHit(_parent);
Symbol 97 MovieClip Frame 7
_parent.punching = false;
Symbol 97 MovieClip Frame 10
_parent.gotoAndStop("stand");
Symbol 107 MovieClip Frame 1
play();
_root.game.f_PunchHit(_parent);
Symbol 107 MovieClip Frame 8
_parent.punching = false;
Symbol 107 MovieClip Frame 12
_parent.gotoAndStop("stand");
Symbol 116 MovieClip Frame 1
play();
Symbol 116 MovieClip Frame 3
_root.game.f_PunchHit(_parent);
Symbol 116 MovieClip Frame 7
_parent.punching = false;
Symbol 116 MovieClip Frame 11
_parent.gotoAndStop("stand");
Symbol 130 MovieClip Frame 1
play();
Symbol 130 MovieClip Frame 4
speed = 12;
if (_parent._xscale < 0) {
speed = speed * -1;
}
Symbol 130 MovieClip Frame 5
if (_parent._xscale > 0) {
dust_x = _parent._x + 35;
} else {
dust_x = _parent._x - 35;
}
_root.game.f_FX(dust_x, _parent._y + 5, int(_parent._y) + 5, "dust1", _parent._xscale);
Instance of Symbol 62 MovieClip in Symbol 130 MovieClip Frame 5
onClipEvent (enterFrame) {
_root.game.f_PunchHit(_parent._parent);
_root.game.f_MoveChar(_parent._parent, false, _parent.speed);
if (_parent.speed > 0) {
_parent.speed = _parent.speed - 2;
if (_parent.speed < 1) {
_parent.speed = 1;
}
} else {
_parent.speed = _parent.speed + 2;
if (_parent.speed > -1) {
_parent.speed = -1;
}
}
}
Symbol 130 MovieClip Frame 12
_parent.punching = false;
Symbol 130 MovieClip Frame 19
_parent.gotoAndStop("stand");
Symbol 137 MovieClip Frame 1
play();
Symbol 137 MovieClip Frame 7
_root.game.f_SoundSwing(2);
Symbol 137 MovieClip Frame 9
_root.game.f_PunchHit(_parent);
Symbol 137 MovieClip Frame 13
_parent.punching = false;
Symbol 137 MovieClip Frame 18
_parent.gotoAndStop("stand");
Symbol 146 MovieClip Frame 1
play();
Symbol 146 MovieClip Frame 7
_root.game.f_SoundSwing(2);
Symbol 146 MovieClip Frame 9
_root.game.f_PunchHit(_parent);
Symbol 146 MovieClip Frame 13
_parent.punching = false;
Symbol 146 MovieClip Frame 18
_parent.gotoAndStop("stand");
Symbol 160 MovieClip Frame 1
play();
Symbol 160 MovieClip Frame 10
_root.game.s_Swing1.start(0, 0);
Symbol 160 MovieClip Frame 12
_root.game.f_PunchHit(_parent);
Symbol 160 MovieClip Frame 20
_parent.punching = false;
Symbol 160 MovieClip Frame 22
_parent.gotoAndStop("stand");
Symbol 169 MovieClip Frame 1
play();
Symbol 169 MovieClip Frame 6
_root.game.s_Swing5.start(0, 0);
Symbol 169 MovieClip Frame 7
_root.game.f_PunchHit(_parent);
Symbol 169 MovieClip Frame 13
_parent.punching = false;
Symbol 169 MovieClip Frame 18
_parent.gotoAndStop("stand");
Symbol 176 MovieClip Frame 1
play();
Symbol 176 MovieClip Frame 4
_root.game.s_SwishTriple.start(0, 0);
Symbol 176 MovieClip Frame 12
_root.game.s_Stab.start(0, 0);
_root.game.f_PunchHit(_parent);
Symbol 176 MovieClip Frame 18
_parent.punching = false;
Symbol 176 MovieClip Frame 22
_parent.gotoAndStop("stand");
Symbol 185 MovieClip Frame 1
play();
Symbol 185 MovieClip Frame 3
if (_parent._xscale > 0) {
speed = 6;
} else {
speed = -6;
}
Symbol 185 MovieClip Frame 4
_root.game.f_MoveChar(_parent, false, speed);
Symbol 185 MovieClip Frame 5
_root.game.f_MoveChar(_parent, false, speed);
_parent.hitnohit = true;
Symbol 185 MovieClip Frame 6
_root.game.f_MoveChar(_parent, false, speed);
_root.game.f_PunchHit(_parent);
Symbol 185 MovieClip Frame 7
_root.game.f_PunchHit(_parent);
Symbol 185 MovieClip Frame 8
_parent.hitnohit = false;
Symbol 185 MovieClip Frame 15
_parent.punching = false;
Symbol 185 MovieClip Frame 19
_parent.gotoAndStop("stand");
Symbol 190 MovieClip Frame 1
play();
Symbol 190 MovieClip Frame 2
_parent.hitnohit = true;
Symbol 190 MovieClip Frame 3
_root.game.f_PunchHit(_parent);
Symbol 190 MovieClip Frame 4
_parent.hitnohit = false;
Symbol 190 MovieClip Frame 7
_parent.punching = false;
Symbol 190 MovieClip Frame 11
_parent.gotoAndStop("stand");
Symbol 200 MovieClip Frame 1
play();
Symbol 200 MovieClip Frame 5
_parent.hitnohit = true;
Symbol 200 MovieClip Frame 6
_root.game.f_PunchHit(_parent);
Symbol 200 MovieClip Frame 7
_parent.hitnohit = false;
Symbol 200 MovieClip Frame 18
_parent.punching = false;
Symbol 200 MovieClip Frame 22
_parent.gotoAndStop("stand");
Symbol 208 MovieClip Frame 1
play();
Symbol 208 MovieClip Frame 3
_root.game.f_PunchHit(_parent);
Symbol 208 MovieClip Frame 4
_root.game.f_PunchHit(_parent);
Symbol 208 MovieClip Frame 12
_parent.punching = false;
Symbol 208 MovieClip Frame 16
_parent.gotoAndStop("stand");
Symbol 216 MovieClip Frame 1
play();
Symbol 216 MovieClip Frame 8
_parent.stomping = true;
_root.game.f_PunchHit(_parent);
_parent.stomping = false;
Symbol 216 MovieClip Frame 12
_parent.punching = false;
Symbol 216 MovieClip Frame 15
_parent.gotoAndStop("stand");
Symbol 227 MovieClip Frame 1
play();
Instance of Symbol 62 MovieClip in Symbol 227 MovieClip Frame 1
onClipEvent (enterFrame) {
_root.game.f_PunchHit(_parent._parent);
_root.game.f_MoveChar(_parent._parent, false, _parent._parent.speed_slam);
}
Symbol 227 MovieClip Frame 13
_root.game.s_ground2.start(0, 0);
_parent.stomping = true;
_root.game.f_PunchHit(_parent);
_parent.stomping = false;
Symbol 227 MovieClip Frame 22
_parent.punching = false;
Symbol 227 MovieClip Frame 23
_parent.gotoAndStop("stand");
Symbol 228 MovieClip Frame 1
play();
Instance of Symbol 62 MovieClip in Symbol 228 MovieClip Frame 1
onClipEvent (enterFrame) {
_root.game.f_PunchHit(_parent._parent);
_root.game.f_MoveChar(_parent._parent, false, _parent._parent.speed_slam);
if ((_parent._parent.speed_slam % 4) == 0) {
_root.game.f_FX(_parent._parent._x, _parent._parent._y + 10, int(_parent._parent._y) + 4, "dust1", _parent._parent._xscale);
}
if (_parent._parent.speed_slam > 0) {
_parent._parent.speed_slam = _parent._parent.speed_slam - 1;
if (_parent._parent.speed_slam < 1) {
_parent._parent.speed_slam = 1;
}
} else {
_parent._parent.speed_slam = _parent._parent.speed_slam + 1;
if (_parent._parent.speed_slam > -1) {
_parent._parent.speed_slam = -1;
}
}
}
Symbol 228 MovieClip Frame 4
_root.game.f_SoundSwing(2);
Symbol 228 MovieClip Frame 7
_parent.punching = false;
Symbol 228 MovieClip Frame 15
_parent.gotoAndStop("stand");
Symbol 235 MovieClip Frame 1
play();
Symbol 235 MovieClip Frame 3
speed_y = -16;
if (_parent._xscale > 0) {
speed_x = 10;
} else {
speed_x = -10;
}
Symbol 235 MovieClip Frame 4
_root.game.f_SoundSwing(2);
play();
_root.game.f_PunchHit(_parent);
Instance of Symbol 62 MovieClip in Symbol 235 MovieClip Frame 4
onClipEvent (enterFrame) {
_parent._y = _parent._y + _parent.speed_y;
_root.game.f_MoveChar(_parent._parent, false, _parent.speed_x);
if (_parent._y > 0) {
_parent._parent.punching = false;
_parent._parent.gotoAndStop("stand");
} else {
_parent.speed_y = _parent.speed_y + _root.game.gravity;
}
}
Symbol 235 MovieClip Frame 6
_root.game.f_PunchHit(_parent);
Symbol 235 MovieClip Frame 8
_root.game.f_PunchHit(_parent);
Symbol 235 MovieClip Frame 10
_root.game.f_PunchHit(_parent);
Symbol 235 MovieClip Frame 11
_parent.punching = false;
Symbol 235 MovieClip Frame 14
if (_y < 0) {
gotoAndPlay ("hitloop");
} else {
_parent.gotoAndStop("stand");
}
Symbol 242 MovieClip Frame 1
_parent._parent.upperbody._y = _parent._parent.body_y;
_parent._parent.grab_pointer.body._y = _parent._parent.kid_y + 2;
Symbol 242 MovieClip Frame 2
_parent._parent.grab_pointer.body._y = _parent._parent.kid_y;
Symbol 242 MovieClip Frame 3
_parent._parent.upperbody._y = _parent._parent.body_y - 2;
_parent._parent.grab_pointer.body._y = _parent._parent.kid_y - 1;
Symbol 242 MovieClip Frame 4
_parent._parent.upperbody._y = _parent._parent.body_y - 3;
_parent._parent.grab_pointer.body._y = _parent._parent.kid_y - 2;
Symbol 242 MovieClip Frame 7
_parent._parent.upperbody._y = _parent._parent.body_y - 2;
_parent._parent.grab_pointer.body._y = _parent._parent.kid_y - 2;
Symbol 242 MovieClip Frame 8
_parent._parent.upperbody._y = _parent._parent.body_y;
_parent._parent.grab_pointer.body._y = _parent._parent.kid_y + 1;
Symbol 242 MovieClip Frame 9
_parent._parent.upperbody._y = _parent._parent.body_y + 2;
_parent._parent.grab_pointer.body._y = _parent._parent.kid_y + 4;
Symbol 243 MovieClip Frame 1
stop();
Symbol 246 MovieClip Frame 10
stop();
Symbol 254 MovieClip Frame 7
_root.game.f_KidThrown(_parent);
Symbol 254 MovieClip Frame 13
_parent.gotoAndStop("stand");
Symbol 259 MovieClip Frame 1
play();
Symbol 259 MovieClip Frame 6
_root.game.f_KidThrownFierce(_parent);
Symbol 259 MovieClip Frame 16
_parent.gotoAndStop("stand");
Symbol 264 MovieClip Frame 6
_root.game.f_GrabSpark(_parent);
_root.game.f_KidHeadbutted(_parent);
Symbol 264 MovieClip Frame 16
_parent.gotoAndStop("grab");
Symbol 272 MovieClip Frame 7
_root.game.f_GrabSpark(_parent);
_root.game.f_KidHeadbutted(_parent);
Symbol 272 MovieClip Frame 17
if (_parent.grab_counter > 3) {
_parent.gotoAndStop("stand");
} else {
_parent.gotoAndStop("grab");
}
Symbol 284 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else {
stop();
}
Instance of Symbol 62 MovieClip in Symbol 284 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_parent._parent.onfire > 1) {
gotoAndStop(_parent._parent.onfire);
}
}
Symbol 287 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else {
stop();
}
Symbol 290 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else {
stop();
}
Symbol 295 MovieClip Frame 19
_root.game.f_CheckDead(_parent);
Symbol 295 MovieClip Frame 21
_parent.gotoAndStop("stand");
Symbol 298 MovieClip Frame 8
_parent.gotoAndStop("carry");
Symbol 301 MovieClip Frame 5
_parent.gotoAndStop("stand");
Symbol 304 MovieClip Frame 10
_parent.gotoAndStop("stand");
Symbol 316 MovieClip Frame 14
_root.game.s_Punch3.start(0, 0);
Symbol 316 MovieClip Frame 60
_parent.gotoAndStop("stand");
Symbol 317 MovieClip Frame 39
_root.game.f_SunChipsFrenzied(_parent);
Symbol 328 MovieClip Frame 1
_root.game.s_Thunder.start(0, 0);
Symbol 328 MovieClip Frame 18
_parent.gotoAndStop("stand");
Symbol 369 MovieClip Frame 24
stopAllSounds();
Symbol 369 MovieClip Frame 25
_root.game.f_Explosion(_parent);
_root.game.s_explosion5.start(0, 0);
Symbol 369 MovieClip Frame 27
_root.game.f_RemoveChar(_parent.shadow_pt);
Symbol 369 MovieClip Frame 97
stopAllSounds();
_root.game.f_GameOver();
stop();
Symbol 370 MovieClip [dude] Frame 1
_root.game.f_StandSettings(this);
Instance of Symbol 62 MovieClip in Symbol 370 MovieClip [dude] Frame 1
onClipEvent (enterFrame) {
_root.game.f_Character(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 370 MovieClip [dude] Frame 4
onClipEvent (enterFrame) {
_root.game.f_Turn(_parent);
_root.game.f_Punch(_parent);
}
Symbol 370 MovieClip [dude] Frame 21
hold_delay = 8;
body_y = upperbody._y;
kid_y = grab_pointer.body._y;
Instance of Symbol 62 MovieClip in Symbol 370 MovieClip [dude] Frame 21
onClipEvent (enterFrame) {
_root.game.f_HoldWalk(_parent);
_root.game.f_Throw(_parent);
}
Symbol 370 MovieClip [dude] Frame 22
hold_delay = 2;
body_y = upperbody._y;
kid_y = grab_pointer.body._y;
Instance of Symbol 62 MovieClip in Symbol 370 MovieClip [dude] Frame 22
onClipEvent (enterFrame) {
_root.game.f_HoldWalk(_parent);
_root.game.f_ThrowItem(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 370 MovieClip [dude] Frame 28
onClipEvent (enterFrame) {
_root.game.f_KidToss(_parent);
}
Symbol 370 MovieClip [dude] Frame 31
onground = true;
Symbol 400 MovieClip Frame 1
play();
Symbol 400 MovieClip Frame 14
_parent.gotoAndStop("walk");
Symbol 403 MovieClip Frame 1
play();
Symbol 403 MovieClip Frame 16
_parent.gotoAndStop("walk");
Symbol 406 MovieClip Frame 1
play();
Symbol 406 MovieClip Frame 17
_parent.gotoAndStop("walk");
Symbol 409 MovieClip Frame 1
play();
Symbol 409 MovieClip Frame 17
_parent.gotoAndStop("walk");
Symbol 426 MovieClip Frame 6
stop();
Symbol 427 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else if (_parent._parent._parent.onfire > 1) {
gotoAndStop(_parent._parent._parent.onfire);
} else {
stop();
}
Instance of Symbol 62 MovieClip in Symbol 427 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_parent._parent.onfire > 1) {
gotoAndStop(_parent._parent.onfire);
} else if (_parent._parent._parent._parent.onfire > 1) {
gotoAndStop(_parent._parent._parent._parent.onfire);
}
}
Symbol 432 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else {
stop();
}
Symbol 439 MovieClip Frame 9
if (_parent.health <= 0) {
_parent.alive = false;
gotoAndPlay ("die");
}
Instance of Symbol 249 MovieClip in Symbol 439 MovieClip Frame 10
onClipEvent (enterFrame) {
_root.game.f_SunChipsUp(_parent._parent);
}
Symbol 439 MovieClip Frame 15
_parent.gotoAndStop("walk");
Symbol 439 MovieClip Frame 16
_root.game.s_SunChipsDie.start(0, 0);
_root.game.f_KillKids();
play();
Symbol 439 MovieClip Frame 41
_root.ending_fader.gotoAndPlay(2);
_root.game.f_KidDie(_parent);
stop();
Symbol 441 MovieClip Frame 1
_root.game.f_Skin(this);
Symbol 501 MovieClip Frame 1
_root.game.f_Shirt(this);
stop();
Symbol 529 MovieClip Frame 1
_root.game.f_Hat(this);
stop();
Symbol 531 MovieClip Frame 3
stop();
Symbol 533 MovieClip Frame 1
_root.game.f_Skin(this);
Symbol 536 MovieClip Frame 1
play();
Symbol 536 MovieClip Frame 16
_parent.gotoAndStop("grabbed");
Symbol 539 MovieClip Frame 1
_root.game.f_Skin(this);
Symbol 542 MovieClip Frame 1
play();
Symbol 542 MovieClip Frame 17
_parent.gotoAndStop("grabbed");
Symbol 552 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else {
_root.game.f_Skin(skin);
stop();
}
Symbol 553 MovieClip Frame 4
stop();
Symbol 557 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else {
_root.game.f_Skin(skin);
stop();
}
Symbol 558 MovieClip Frame 3
stop();
Symbol 571 MovieClip Frame 3
_root.game.s_SunChipsGrunt.start(0, 0);
Symbol 571 MovieClip Frame 10
_root.game.s_Swing1.start(0, 0);
_root.game.f_Boss1UppercutHit(_parent);
Symbol 571 MovieClip Frame 13
_root.game.s_Swing2.start(0, 0);
Symbol 571 MovieClip Frame 15
_root.game.s_Swing3.start(0, 0);
Symbol 571 MovieClip Frame 18
_root.game.s_Swing4.start(0, 0);
Symbol 571 MovieClip Frame 22
_root.game.s_Swing5.start(0, 0);
Symbol 571 MovieClip Frame 33
_parent.gotoAndStop("stand");
Instance of Symbol 249 MovieClip in Symbol 579 MovieClip Frame 1
onClipEvent (enterFrame) {
_root.game.f_SunChipsSlide(_parent._parent);
}
Symbol 579 MovieClip Frame 2
_root.game.s_SunChipsGrunt.start(0, 0);
Symbol 579 MovieClip Frame 5
_parent.nohit = true;
_root.game.s_Swing4.start(0, 0);
Symbol 579 MovieClip Frame 6
_root.game.f_Boss1UppercutHit(_parent);
Symbol 579 MovieClip Frame 15
_parent.nohit = false;
Symbol 579 MovieClip Frame 17
_parent.gotoAndStop("stand");
Symbol 589 MovieClip Frame 11
_root.game.s_GunShot.start(0, 0);
_root.game.f_GunShot(_parent);
Symbol 589 MovieClip Frame 24
_parent.ammo--;
if (_parent.ammo > 0) {
_parent.gotoAndStop("stand");
} else {
_parent.ammo = 6;
_parent.gotoAndStop("reload");
}
Symbol 602 MovieClip Frame 2
_root.game.s_Swing2.start(0, 0);
Symbol 602 MovieClip Frame 4
_root.game.s_Swing4.start(0, 0);
Symbol 602 MovieClip Frame 5
_root.game.f_Boss1ElboHit(_parent);
Symbol 602 MovieClip Frame 14
_parent.gotoAndStop("stand");
Symbol 603 MovieClip Frame 1
_root.game.s_Swing4.start(0, 0);
Symbol 603 MovieClip Frame 4
_root.game.s_Swing5.start(0, 0);
Symbol 603 MovieClip Frame 6
_root.game.s_Swing6.start(0, 0);
Symbol 612 MovieClip Frame 1
_root.game.s_HardPunch2.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 5);
Symbol 612 MovieClip Frame 10
_root.game.s_HardPunch1.start(0, 0);
Symbol 612 MovieClip Frame 14
_root.game.s_HardPunch1.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 2);
Symbol 612 MovieClip Frame 18
_root.game.s_HardPunch1.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 2);
Symbol 612 MovieClip Frame 22
_root.game.s_HardPunch1.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 2);
Symbol 612 MovieClip Frame 26
_root.game.s_HardPunch1.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 2);
Symbol 612 MovieClip Frame 30
_root.game.s_HardPunch1.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 2);
Symbol 612 MovieClip Frame 34
_root.game.s_HardPunch1.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 2);
Symbol 612 MovieClip Frame 38
_root.game.s_HardPunch1.start(0, 0);
_root.game.f_Damage(_root.game.dude1, 2);
Symbol 612 MovieClip Frame 40
_root.game.s_HardPunch3.start(0, 0);
Symbol 612 MovieClip Frame 49
_root.game.f_SunChipsStopCrazy(_parent);
Symbol 619 MovieClip Frame 1
_root.game.s_Swing6.start(0, 0);
Symbol 619 MovieClip Frame 11
_root.game.s_Reload.start(0, 0);
Symbol 619 MovieClip Frame 20
_parent.gotoAndStop("walk");
Symbol 620 MovieClip Frame 1
if ((_parent._x + _parent._parent._x) < 770) {
_root.game.pause = true;
_root.game.f_SunchipsMusic();
gotoAndPlay ("intro");
}
Symbol 620 MovieClip Frame 2
gotoAndPlay (1);
Symbol 620 MovieClip Frame 3
play();
Instance of Symbol 249 MovieClip in Symbol 620 MovieClip Frame 3
onClipEvent (enterFrame) {
_root.game.f_Boss1Scroll(_parent._parent);
}
Symbol 620 MovieClip Frame 47
_root.game.f_KidGroup10();
Symbol 620 MovieClip Frame 57
_root.game.s_Reload.start(0, 0);
Instance of Symbol 249 MovieClip in Symbol 620 MovieClip Frame 65
onClipEvent (enterFrame) {
_root.game.f_Boss1Scroll2(_root.game.dude1);
}
Symbol 620 MovieClip Frame 85
_root.game.pause = false;
_parent.gotoAndStop("walk");
Symbol 621 MovieClip [sunchips] Frame 1
stop();
Instance of Symbol 62 MovieClip in Symbol 621 MovieClip [sunchips] Frame 1
onClipEvent (enterFrame) {
_root.game.f_Boss1PunchClock(_parent);
}
Symbol 621 MovieClip [sunchips] Frame 2
gotoAndStop ("walk");
Symbol 621 MovieClip [sunchips] Frame 3
_root.game.f_KidSettings(this);
stop();
Instance of Symbol 62 MovieClip in Symbol 621 MovieClip [sunchips] Frame 3
onClipEvent (enterFrame) {
if (!_root.game.f_SunChipsAttack(_parent)) {
_root.game.f_JamesRun(_parent);
}
}
Instance of Symbol 62 MovieClip in Symbol 621 MovieClip [sunchips] Frame 8
onClipEvent (enterFrame) {
_root.game.f_KidToss(_parent);
}
Symbol 621 MovieClip [sunchips] Frame 11
onground = true;
Instance of Symbol 62 MovieClip in Symbol 621 MovieClip [sunchips] Frame 24
onClipEvent (enterFrame) {
_root.game.f_SunChipsCrazy(_parent);
}
Symbol 621 MovieClip [sunchips] Frame 28
_root.game.f_KidReset(this);
Symbol 640 MovieClip Frame 1
play();
Symbol 640 MovieClip Frame 14
_parent.gotoAndStop("walk");
Symbol 643 MovieClip Frame 1
play();
Symbol 643 MovieClip Frame 18
_parent.gotoAndStop("walk");
Symbol 646 MovieClip Frame 1
play();
Symbol 646 MovieClip Frame 14
_parent.gotoAndStop("walk");
Symbol 653 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else if (_parent._parent._parent.onfire > 1) {
gotoAndStop(_parent._parent._parent.onfire);
} else {
stop();
}
Instance of Symbol 62 MovieClip in Symbol 653 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_parent._parent.onfire > 1) {
gotoAndStop(_parent._parent.onfire);
} else if (_parent._parent._parent._parent.onfire > 1) {
gotoAndStop(_parent._parent._parent._parent.onfire);
}
}
Symbol 658 MovieClip Frame 1
if (_parent.onfire > 1) {
gotoAndStop(_parent.onfire);
} else {
stop();
}
Symbol 665 MovieClip Frame 7
if (_parent.health <= 0) {
_parent.alive = false;
gotoAndPlay ("die");
}
Symbol 665 MovieClip Frame 15
_parent.gotoAndStop("walk");
Symbol 665 MovieClip Frame 16
play();
Symbol 665 MovieClip Frame 41
_root.game.f_MusicLight();
_root.game.f_KidDie(_parent);
stop();
Symbol 672 MovieClip Frame 2
_root.game.s_Swing2.start(0, 0);
Symbol 672 MovieClip Frame 5
_root.game.s_Swing4.start(0, 0);
Symbol 672 MovieClip Frame 6
_root.game.f_Boss1PunchHit(_parent);
Symbol 672 MovieClip Frame 14
_parent.gotoAndStop("stand");
Symbol 679 MovieClip Frame 5
_root.game.s_Swing4.start(0, 0);
Symbol 679 MovieClip Frame 6
_root.game.f_Boss1UppercutHit(_parent);
Symbol 679 MovieClip Frame 13
_parent.gotoAndStop("stand");
Symbol 687 MovieClip Frame 2
_root.game.s_Swing2.start(0, 0);
Symbol 687 MovieClip Frame 6
_root.game.s_Swing4.start(0, 0);
Symbol 687 MovieClip Frame 7
_root.game.f_Boss1PunchHit(_parent);
Symbol 687 MovieClip Frame 14
_parent.gotoAndStop("stand");
Symbol 688 MovieClip Frame 1
_root.game.f_Boss1Intro(_parent);
Symbol 688 MovieClip Frame 2
gotoAndPlay (1);
Symbol 688 MovieClip Frame 3
play();
Instance of Symbol 249 MovieClip in Symbol 688 MovieClip Frame 3
onClipEvent (enterFrame) {
_root.game.f_Boss1Scroll(_parent._parent);
}
Symbol 688 MovieClip Frame 14
_root.game.f_HardPunchSound();
_root.game.boss1fodder.gotoAndStop("hit1");
attack_pow = int(_root.game.boss1fodder.health_max * 0.3);
_root.game.f_Damage(_root.game.boss1fodder, attack_pow);
Symbol 688 MovieClip Frame 26
_root.game.f_HardPunchSound();
_root.game.boss1fodder.gotoAndStop("hit2");
_root.game.f_Damage(_root.game.boss1fodder, attack_pow);
Symbol 688 MovieClip Frame 36
_root.game.f_HardPunchSound();
_root.game.boss1fodder.gotoAndStop("hit3");
_root.game.f_Damage(_root.game.boss1fodder, attack_pow);
Symbol 688 MovieClip Frame 48
_root.game.f_HardPunchSound();
_root.game.f_Damage(_root.game.boss1fodder, attack_pow);
_root.game.boss1fodder.speed_toss_y = -(random(5) + 12);
_root.game.boss1fodder.speed_toss_x = random(5) + 15;
_root.game.f_CallJuggle1(_root.game.boss1fodder);
Instance of Symbol 249 MovieClip in Symbol 688 MovieClip Frame 48
onClipEvent (enterFrame) {
_root.game.f_Boss1Scroll2(_root.game.dude1);
}
Symbol 688 MovieClip Frame 68
_root.game.pause = false;
_parent.gotoAndStop("walk");
Symbol 689 MovieClip [boss1] Frame 1
stop();
Instance of Symbol 62 MovieClip in Symbol 689 MovieClip [boss1] Frame 1
onClipEvent (enterFrame) {
_root.game.f_Boss1PunchClock(_parent);
}
Symbol 689 MovieClip [boss1] Frame 2
gotoAndStop ("walk");
Symbol 689 MovieClip [boss1] Frame 3
_root.game.f_KidSettings(this);
stop();
Instance of Symbol 62 MovieClip in Symbol 689 MovieClip [boss1] Frame 3
onClipEvent (enterFrame) {
_root.game.f_Boss1Run(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 689 MovieClip [boss1] Frame 8
onClipEvent (enterFrame) {
_root.game.f_KidToss(_parent);
}
Symbol 689 MovieClip [boss1] Frame 11
onground = true;
Symbol 689 MovieClip [boss1] Frame 26
_root.game.f_KidReset(this);
Symbol 710 MovieClip Frame 1
Symbol 711 MovieClip Frame 1
_root.game.f_Skin(kid);
Symbol 712 MovieClip Frame 1
play();
Symbol 712 MovieClip Frame 14
_parent.gotoAndStop("walk");
Symbol 718 MovieClip Frame 1
_root.game.f_Skin(skin);
_root.game.f_Skin(arm);
Symbol 719 MovieClip Frame 1
play();
Symbol 719 MovieClip Frame 18
_parent.gotoAndStop("walk");
Symbol 723 MovieClip Frame 1
_root.game.f_Skin(skin);
Symbol 724 MovieClip Frame 1
play();
Symbol 724 MovieClip Frame 14
_parent.gotoAndStop("walk");
Symbol 732 MovieClip Frame 1
_root.game.f_Skin(this);
Symbol 736 MovieClip Frame 1
play();
Symbol 736 MovieClip Frame 33
_parent.gotoAndStop("walk");
Symbol 742 MovieClip Frame 1
_root.game.f_Skin(skin);
_root.game.f_Skin(arm);
if (_parent._parent.onfire > 1) {
gotoAndStop(_parent._parent.onfire);
} else {
stop();
}
Instance of Symbol 62 MovieClip in Symbol 742 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_parent._parent._parent.onfire > 1) {
_parent.gotoAndStop(_parent._parent._parent.onfire);
}
}
Symbol 745 MovieClip Frame 1
_root.game.f_Skin(this);
Symbol 747 MovieClip Frame 1
_root.game.f_Skin(this);
Symbol 748 MovieClip Frame 5
if (_parent.health <= 0) {
_parent.alive = false;
gotoAndPlay ("die");
}
Symbol 748 MovieClip Frame 34
_parent.gotoAndStop("walk");
Symbol 748 MovieClip Frame 35
play();
Symbol 748 MovieClip Frame 62
_root.game.f_KidDie(_parent);
stop();
Symbol 751 MovieClip Frame 1
play();
Symbol 751 MovieClip Frame 7
_parent.gotoAndStop("walk");
Symbol 754 MovieClip Frame 1
speed = 7;
play();
Instance of Symbol 62 MovieClip in Symbol 754 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_PushKid(_parent._parent, _parent.speed);
_parent.speed--;
}
Symbol 754 MovieClip Frame 20
_parent.gotoAndStop("walk");
Symbol 777 MovieClip Frame 16
_root.game.f_JamesShoot(_parent);
Symbol 777 MovieClip Frame 24
_parent.gotoAndStop("walk");
Symbol 783 MovieClip Frame 23
gotoAndPlay (1);
Symbol 809 MovieClip Frame 1
_root.game.s_Swing6.start(0, 0);
Symbol 809 MovieClip Frame 4
_root.game.s_Swing6.start(0, 0);
Symbol 809 MovieClip Frame 7
_root.game.s_Swing6.start(0, 0);
Symbol 809 MovieClip Frame 9
gotoAndPlay (1);
Symbol 815 MovieClip [kid] Frame 1
_root.game.f_Skin(kid.kid);
Symbol 815 MovieClip [kid] Frame 2
_root.game.f_KidSettings(this);
if (health >= 0) {
if (kid_type == 1) {
_root.game.f_Skin(kid.kid);
} else if (kid_type == 2) {
gotoAndStop ("JamesWalk");
} else if (kid_type == 3) {
gotoAndStop ("SoccerWalk");
} else if (kid_type == 4) {
gotoAndStop ("NinjaWalk");
} else if (kid_type == 5) {
gotoAndStop ("HelmetWalk");
}
}
stop();
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 2
onClipEvent (enterFrame) {
_root.game.f_KidRun(_parent);
}
Symbol 815 MovieClip [kid] Frame 3
_root.game.f_Skin(kid.kid);
stop();
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 3
onClipEvent (enterFrame) {
_root.game.f_JamesRun(_parent);
}
Symbol 815 MovieClip [kid] Frame 4
_root.game.f_KidSettings(this);
_root.game.f_Skin(kid.kid);
stop();
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 4
onClipEvent (enterFrame) {
_root.game.f_SoccerRun(_parent);
}
Symbol 815 MovieClip [kid] Frame 5
_root.game.f_Skin(kid.kid);
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 5
onClipEvent (enterFrame) {
if (!_root.game.f_NinjaAttack(_parent)) {
_root.game.f_KidRun(_parent);
}
}
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 6
onClipEvent (enterFrame) {
if (!_root.game.f_HelmetAttack(_parent)) {
_root.game.f_KidRun(_parent);
}
}
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 11
onClipEvent (enterFrame) {
_root.game.f_KidToss(_parent);
}
Symbol 815 MovieClip [kid] Frame 14
onground = true;
Symbol 815 MovieClip [kid] Frame 23
_root.game.f_KidSettings(this);
_root.game.f_Skin(kid.kid);
Symbol 815 MovieClip [kid] Frame 24
_root.game.f_KidSettings(this);
_root.game.f_Skin(kid.kid);
stop();
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 24
onClipEvent (enterFrame) {
_root.game.f_SoccerRun(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 26
onClipEvent (enterFrame) {
_root.game.f_CheckSandbox(_parent);
}
Symbol 815 MovieClip [kid] Frame 29
_root.game.f_Skin(kid.kid);
_root.game.f_Skin(kid.kidarm);
s_atvengine = new Sound(this);
s_atvengine.attachSound("sound_atv_engine3.wav");
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 29
onClipEvent (enterFrame) {
_root.game.f_ATV(_parent);
}
Symbol 815 MovieClip [kid] Frame 30
_root.game.f_Skin(kid.body.kid);
_root.game.f_Skin(kid.body.foot);
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 30
onClipEvent (enterFrame) {
_root.game.f_SoccerSlide(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 31
onClipEvent (enterFrame) {
_root.game.f_NinjaKick(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 32
onClipEvent (enterFrame) {
_root.game.f_NinjaJump(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 815 MovieClip [kid] Frame 34
onClipEvent (enterFrame) {
_root.game.f_SoccerSlide(_parent);
}
Symbol 815 MovieClip [kid] Frame 36
_root.game.f_KidReset(this);
Symbol 816 MovieClip Frame 1
play();
Symbol 816 MovieClip Frame 5
_parent.gotoAndStop("remove");
Symbol 821 MovieClip Frame 1
play();
Symbol 821 MovieClip Frame 5
_parent.gotoAndStop("remove");
Symbol 822 MovieClip Frame 1
play();
Symbol 822 MovieClip Frame 5
_parent.gotoAndStop("remove");
Symbol 830 MovieClip Frame 1
play();
Symbol 830 MovieClip Frame 19
_parent.gotoAndStop("remove");
Symbol 840 MovieClip Frame 1
play();
Symbol 840 MovieClip Frame 24
_parent.gotoAndStop("remove");
Symbol 841 MovieClip Frame 1
play();
Symbol 841 MovieClip Frame 14
_parent.gotoAndStop("remove");
Symbol 849 MovieClip Frame 1
play();
Symbol 849 MovieClip Frame 12
_parent.gotoAndStop("remove");
Symbol 850 MovieClip Frame 25
_parent.gotoAndStop("remove");
Symbol 866 MovieClip Frame 35
_parent.gotoAndStop("remove");
Symbol 897 MovieClip Frame 84
_parent.gotoAndStop("remove");
stop();
Symbol 902 MovieClip Frame 84
_parent.gotoAndStop("remove");
stop();
Symbol 911 MovieClip Frame 1
play();
Symbol 911 MovieClip Frame 15
_parent.gotoAndStop("remove");
Symbol 912 MovieClip Frame 1
play();
Symbol 912 MovieClip Frame 5
_parent.gotoAndStop("remove");
Symbol 915 MovieClip Frame 1
body.gotoAndStop(_root.game.SunChipsFrame);
Symbol 915 MovieClip Frame 45
_parent.gotoAndStop("remove");
Symbol 918 MovieClip Frame 11
_parent.gotoAndStop("remove");
Symbol 923 MovieClip Frame 8
_parent.gotoAndStop("remove");
Symbol 924 MovieClip [fx] Frame 1
stop();
Symbol 924 MovieClip [fx] Frame 15
if (_xscale > 0) {
speed_x = 16;
} else {
speed_x = -16;
}
speed_y = -3;
Instance of Symbol 62 MovieClip in Symbol 924 MovieClip [fx] Frame 15
onClipEvent (enterFrame) {
_root.game.f_DartAction(_parent);
}
Symbol 924 MovieClip [fx] Frame 19
Symbol 1017 MovieClip Frame 1
stop();
Symbol 1017 MovieClip Frame 10
stop();
Symbol 1017 MovieClip Frame 18
gotoAndStop (1);
Symbol 1018 Button
on (rollOver) {
tellTarget ("visit") {
gotoAndPlay ("over");
};
}
on (rollOut) {
tellTarget ("visit") {
gotoAndPlay ("off");
};
}
on (press) {
getURL ("http://www.alienhominid.com", (target = "_blank"));
}
Symbol 1023 Button
on (press) {
getURL ("http://www.alienhominid.com/toys", (target = "_blank"));
}
Symbol 1036 MovieClip Frame 1
stop();
Symbol 1036 MovieClip Frame 6
stop();
Symbol 1036 MovieClip Frame 16
gotoAndStop (1);
Symbol 1037 Button
on (rollOver) {
tellTarget ("pb_ng") {
gotoAndPlay ("over");
};
}
on (rollOut) {
tellTarget ("pb_ng") {
gotoAndPlay ("off");
};
}
on (press) {
getURL ("http://www.newgrounds.com", (target = "_blank"));
}
Symbol 1043 MovieClip Frame 8
stop();
Symbol 1053 MovieClip Frame 15
stop();
Symbol 1058 MovieClip Frame 1
stop();
Symbol 1058 MovieClip Frame 8
stop();
Symbol 1058 MovieClip Frame 13
gotoAndStop (1);
Symbol 1059 Button
on (rollOver) {
tellTarget ("play") {
gotoAndPlay ("over");
};
}
on (rollOut) {
tellTarget ("play") {
gotoAndPlay ("off");
};
}
on (press) {
play();
}
Instance of Symbol 249 MovieClip in Symbol 1061 MovieClip Frame 1
onClipEvent (load) {
timer = 0;
}
onClipEvent (enterFrame) {
timer++;
PercentLoaded = (_root.getBytesLoaded() / _root.getBytesTotal()) * 100;
if (PercentLoaded != 100) {
_parent.gotoAndStop(PercentLoaded);
} else if (timer < 2) {
_parent.gotoAndPlay("go2");
} else {
_parent.gotoAndPlay("go");
}
}
Symbol 1061 MovieClip Frame 140
stop();
Symbol 1061 MovieClip Frame 190
tellTarget (_root) {
nextFrame();
};
Symbol 1071 Button
on (press) {
gotoAndPlay ("impatience");
}
Symbol 1105 MovieClip Frame 5
stop();
Symbol 1146 MovieClip Frame 14
stop();
Symbol 1177 MovieClip Frame 22
stop();
gotoAndPlay ("loop");
Symbol 1189 MovieClip Frame 1
stop();
Symbol 1190 MovieClip Frame 50
stop();
Symbol 1192 MovieClip Frame 50
stop();
Symbol 1194 MovieClip Frame 35
stop();
Symbol 1201 MovieClip Frame 17
stop();
Symbol 1217 MovieClip Frame 1
stop();
Symbol 1217 MovieClip Frame 10
stop();
Symbol 1217 MovieClip Frame 20
gotoAndStop (1);
Symbol 1220 MovieClip Frame 1
stop();
Symbol 1220 MovieClip Frame 8
stop();
Symbol 1220 MovieClip Frame 14
gotoAndStop (1);
Symbol 1221 Button
on (rollOver) {
tellTarget ("start") {
gotoAndPlay ("over");
};
}
on (rollOut) {
tellTarget ("start") {
gotoAndPlay ("off");
};
}
on (press) {
tellTarget ("game_on") {
play();
};
}
Symbol 1222 Button
on (rollOver) {
tellTarget ("instructions") {
gotoAndPlay ("over");
};
}
on (rollOut) {
tellTarget ("instructions") {
gotoAndPlay ("off");
};
}
on (press) {
tellTarget ("demo") {
play();
};
}
Symbol 1271 MovieClip Frame 14
stop();
Symbol 1307 MovieClip Frame 100
stop();
Symbol 1308 MovieClip Frame 100
stop();
Symbol 1328 MovieClip Frame 75
stop();
Symbol 1337 MovieClip Frame 26
stop();
Symbol 1352 MovieClip Frame 29
stop();
Symbol 1384 MovieClip Frame 1
stop();
Symbol 1392 MovieClip Frame 1
stop();
Instance of Symbol 1359 MovieClip "bar" in Symbol 1392 MovieClip Frame 752
onClipEvent (enterFrame) {
_parent.f_HealthBar();
}
Instance of Symbol 1359 MovieClip "ragebar" in Symbol 1392 MovieClip Frame 752
onClipEvent (enterFrame) {
_parent.f_HealthBar();
}
Symbol 1393 MovieClip Frame 1
stop();
Symbol 1393 MovieClip Frame 2
stopAllSounds();
Symbol 1393 MovieClip Frame 47
_root.gotoAndStop("level1");
Symbol 1396 MovieClip Frame 810
stop();
Symbol 1400 MovieClip Frame 1
stop();
Symbol 1400 MovieClip Frame 60
stop();
Symbol 1412 MovieClip Frame 1
stop();
Symbol 1415 MovieClip Frame 1
stop();
Symbol 1415 MovieClip Frame 2
_root.game.car_distance = 10;
_root.game.s_Engine.start(0, 5000);
_root.game.f_EngineVolume();
body.body.body.gotoAndStop(_root.game.current_vehicle);
play();
Instance of Symbol 249 MovieClip in Symbol 1415 MovieClip Frame 3
onClipEvent (enterFrame) {
_root.game.car_distance = _root.game.car_distance + 0.5;
_root.game.f_EngineVolume();
}
Symbol 1415 MovieClip Frame 21
_parent.car2.gotoAndPlay(2);
stop();
Symbol 1425 MovieClip Frame 1
if (!init) {
default_y = _y;
init = true;
}
stop();
Symbol 1425 MovieClip Frame 2
body.body.body.gotoAndStop(_root.game.current_vehicle);
play();
Instance of Symbol 249 MovieClip in Symbol 1425 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.car_distance = _root.game.car_distance + 0.5;
_root.game.f_EngineVolume();
}
Symbol 1425 MovieClip Frame 51
_root.game.ups1.gotoAndPlay(2);
_root.game.ups1.body.body.body.gotoAndStop(_root.game.current_vehicle);
stop();
Symbol 1457 MovieClip Frame 1
stop();
Symbol 1457 MovieClip Frame 2
body.body.body.gotoAndStop(_root.game.current_vehicle);
play();
Instance of Symbol 249 MovieClip in Symbol 1457 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.car_distance = _root.game.car_distance + 3;
_root.game.f_EngineVolume();
}
Symbol 1457 MovieClip Frame 21
_root.game.ups2._y = _root.game.ups2.default_y;
_root.game.ups2._xscale = 100;
_root.game.ups2._yscale = 100;
_root.game.ups2.speed_y = 10;
_root.game.ups2.gotoAndStop(2);
_root.game.ups2.body.body.body.gotoAndStop(_root.game.current_vehicle);
stop();
Symbol 1558 MovieClip Frame 1
if (_parent.ball == 2) {
gotoAndStop (2);
} else if (_parent._parent.ball == 2) {
gotoAndStop (2);
} else if (_parent._parent._parent.ball == 2) {
gotoAndStop (2);
} else {
stop();
}
Symbol 1559 MovieClip Frame 13
gotoAndPlay (1);
Symbol 1562 MovieClip Frame 1
stop();
Symbol 1562 MovieClip Frame 2
play();
Symbol 1562 MovieClip Frame 4
_root.game.s_Bounce.start(0, 0);
Symbol 1562 MovieClip Frame 11
_root.game.s_Swoosh.start(0, 0);
Symbol 1562 MovieClip Frame 16
_root.game.bball.body_y = _root.game.bballhoop.goal._y + 145;
new_x = _root.game.bballhoop.x + _root.game.bballhoop.goal._x;
new_y = _root.game.bballhoop.y - 2;
_root.game.f_SetXY(_root.game.bball, new_x, new_y);
Symbol 1562 MovieClip Frame 17
_root.game.bball.speed_toss_x = 0;
_root.game.bball.speed_toss_y = 15;
_root.game.bball.gotoAndStop("release");
_root.game.bball.body._y = _root.game.bball.body_y;
Symbol 1563 MovieClip Frame 1
stop();
Symbol 1564 MovieClip Frame 1
stop();
Instance of Symbol 249 MovieClip in Symbol 1564 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_CheckHoop(_parent);
}
Symbol 1576 MovieClip Frame 1
stop();
Symbol 1576 MovieClip Frame 2
play();
Symbol 1576 MovieClip Frame 28
stop();
Symbol 1591 MovieClip Frame 1
stop();
Symbol 1591 MovieClip Frame 2
play();
Symbol 1591 MovieClip Frame 4
_root.game.s_HardPunch1.start(0, 0);
Symbol 1591 MovieClip Frame 5
dad.gotoAndPlay(2);
Symbol 1591 MovieClip Frame 8
_root.game.s_Ground3.start(0, 0);
Symbol 1591 MovieClip Frame 23
_root.game.s_HardPunch2.start(0, 0);
Symbol 1591 MovieClip Frame 34
_root.game.f_SpawnPlayer(70, 385);
_root.game.dude1.gotoAndStop("knuckles");
stop();
Symbol 1596 MovieClip Frame 1
speed = 19;
s_CarIdle = new Sound(this);
s_CarIdle.attachSound("sound_trucks_idle");
s_CarDrive = new Sound(this);
s_CarDrive.attachSound("sound_trucks_moving");
s_CarDrive.start(0, 1000);
Instance of Symbol 62 MovieClip in Symbol 1596 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_Scroll(_parent.speed, false);
_parent.car.car.tire1._rotation = _parent.car.car.tire1._rotation + _parent.speed;
_parent.car.car.tire2._rotation = _parent.car.car.tire2._rotation + _parent.speed;
_parent.speed = _parent.speed - 0.1;
}
Symbol 1596 MovieClip Frame 45
_root.game.s_Smack1.start(0, 0);
Symbol 1596 MovieClip Frame 100
s_CarDrive.stop();
s_CarIdle.start(0, 1000);
Symbol 1596 MovieClip Frame 115
car.car.car.gotoAndPlay("door");
_root.game.limit_topleft.x = -_root.game._x;
_root.game.limit_topleft._x = _root.game.limit_topleft.x;
Symbol 1596 MovieClip Frame 146
speed = 2;
volume = 100;
pan = 0;
Symbol 1596 MovieClip Frame 147
s_CarIdle.stop();
s_CarDrive.start(0, 1000);
Instance of Symbol 62 MovieClip in Symbol 1596 MovieClip Frame 147
onClipEvent (enterFrame) {
_parent.car.car.tire1._rotation = _parent.car.car.tire1._rotation + _parent.speed;
_parent.car.car.tire2._rotation = _parent.car.car.tire2._rotation + _parent.speed;
_parent.speed = _parent.speed + 0.1;
}
Instance of Symbol 62 MovieClip in Symbol 1596 MovieClip Frame 160
onClipEvent (enterFrame) {
_parent.pan = _parent.pan + 2;
if (_parent.pan > 100) {
_parent.pan = 100;
}
_parent.s_CarDrive.setPan(_parent.pan);
}
Symbol 1596 MovieClip Frame 201
_root.game.f_KidGroup1();
_root.go_arrow.gotoAndPlay(2);
Instance of Symbol 62 MovieClip in Symbol 1596 MovieClip Frame 202
onClipEvent (enterFrame) {
_parent.volume = _parent.volume - 2;
if (_parent.volume < 0) {
_parent.volume = 0;
}
_parent.s_CarDrive.setVolume(_parent.volume);
}
Symbol 1596 MovieClip Frame 251
s_CarDrive.stop();
stop();
Symbol 1612 MovieClip Frame 1
stop();
Instance of Symbol 249 MovieClip in Symbol 1612 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_StartSoccer(_parent);
}
Instance of Symbol 249 MovieClip in Symbol 1612 MovieClip Frame 3
onClipEvent (enterFrame) {
_root.game.f_SoccerGame(_parent);
}
Symbol 1634 MovieClip Frame 1
stop();
Symbol 1634 MovieClip Frame 2
play();
Symbol 1634 MovieClip Frame 12
gotoAndStop (1);
Symbol 1635 MovieClip Frame 1
stop();
Symbol 1642 MovieClip Frame 1
gotoAndStop(_parent._parent.animal);
Symbol 1644 MovieClip Frame 1
play();
Symbol 1644 MovieClip Frame 60
stop();
Symbol 1645 MovieClip Frame 1
if (!init) {
init = true;
animal = random(7) + 1;
}
stop();
Symbol 1655 MovieClip Frame 1
if (_parent.object_type > 0) {
gotoAndStop(_parent.object_type);
} else if (_parent._parent.object_type > 0) {
gotoAndStop(_parent._parent.object_type);
} else if (_parent._parent._parent.object_type > 0) {
gotoAndStop(_parent._parent._parent.object_type);
} else {
stop();
}
Symbol 1656 MovieClip Frame 1
play();
Symbol 1656 MovieClip Frame 7
_parent.gotoAndStop("stand");
Symbol 1657 MovieClip Frame 8
stop();
Symbol 1663 MovieClip Frame 1
stop();
Instance of Symbol 62 MovieClip in Symbol 1663 MovieClip Frame 4
onClipEvent (enterFrame) {
_root.game.f_KidToss(_parent);
}
Symbol 1663 MovieClip Frame 7
_root.game.f_ObjectSettings(this);
Symbol 1670 MovieClip Frame 1
stop();
Instance of Symbol 62 MovieClip in Symbol 1670 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_SwingCheck(_parent);
}
Symbol 1670 MovieClip Frame 3
play();
Instance of Symbol 62 MovieClip in Symbol 1670 MovieClip Frame 26
onClipEvent (enterFrame) {
_root.game.f_SwingCheck(_parent);
}
Symbol 1670 MovieClip Frame 48
gotoAndStop ("on");
Symbol 1703 MovieClip Frame 15
stop();
Symbol 1704 MovieClip Frame 1
stop();
Instance of Symbol 249 MovieClip in Symbol 1704 MovieClip Frame 1
onClipEvent (enterFrame) {
_root.game.f_Sandbox(_parent);
}
Symbol 1714 MovieClip Frame 13
gotoAndPlay (1);
Symbol 1715 MovieClip Frame 27
gotoAndPlay ("loop");
Symbol 1716 MovieClip Frame 1
stop();
Symbol 1717 MovieClip Frame 1
stop();
Instance of Symbol 249 MovieClip in Symbol 1717 MovieClip Frame 1
onClipEvent (enterFrame) {
_root.game.f_SeekOwner(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 1717 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_KidToss(_parent);
}
Symbol 1717 MovieClip Frame 5
_root.game.f_ObjectSettings(this);
speed_toss_x = speed_toss_x / 2;
speed_toss_y = (-speed_toss_x) / 2;
Instance of Symbol 249 MovieClip in Symbol 1717 MovieClip Frame 5
onClipEvent (enterFrame) {
_root.game.f_Roll(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 1717 MovieClip Frame 9
onClipEvent (enterFrame) {
_root.game.f_SoccerBall(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 1717 MovieClip Frame 10
onClipEvent (enterFrame) {
_root.game.f_KidToss(_parent);
}
Instance of Symbol 62 MovieClip in Symbol 1717 MovieClip Frame 11
onClipEvent (enterFrame) {
_root.game.f_SeakHoop(_parent);
}
Symbol 1730 MovieClip Frame 7
stop();
Instance of Symbol 249 MovieClip in Symbol 1731 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_MedPickup(_parent);
}
Symbol 1732 MovieClip Frame 1
if (!init) {
default_y = _y;
init = true;
}
stop();
Instance of Symbol 62 MovieClip in Symbol 1732 MovieClip Frame 2
onClipEvent (enterFrame) {
_root.game.f_CarDrive(_parent);
}
Symbol 1745 MovieClip Frame 1
function f_SetXY(zone, new_x, new_y) {
zone.x = new_x;
zone.y = new_y;
zone._x = zone.x;
zone._y = zone.y;
f_Depth(zone, zone.y);
if (zone.item) {
f_MoveItem(zone, zone.item, speed);
}
zone.shadow_pt._x = zone.x;
zone.shadow_pt._y = zone.y;
f_Mask(zone);
}
function f_rad2deg(radian) {
return(57.2957795130823 * radian);
}
function f_FlipChar(u_flipchar) {
u_flipchar._xscale = u_flipchar._xscale * -1;
f_Mask(u_flipchar);
}
function f_FlipSame(u_flipchar, u_flipsource) {
if ((u_flipchar._xscale > 0) and (u_flipsource._xscale < 0)) {
f_FlipChar(u_flipchar);
} else if ((u_flipchar._xscale < 0) and (u_flipsource._xscale > 0)) {
f_FlipChar(u_flipchar);
}
}
function f_FlipInverse(u_flipchar, u_flipsource) {
if ((u_flipchar._xscale > 0) and (u_flipsource._xscale > 0)) {
f_FlipChar(u_flipchar);
} else if ((u_flipchar._xscale < 0) and (u_flipsource._xscale < 0)) {
f_FlipChar(u_flipchar);
}
}
function f_ClearGrabPointer(u_ClearPointer) {
u_ClearPointer.grab_pointer = undefined;
}
function f_SwingsOn() {
swing2.gotoAndStop("on");
swing3.gotoAndStop("on");
}
function f_SwingsOff() {
swing2.gotoAndStop("off");
swing3.gotoAndStop("off");
}
function f_KidDie(zone) {
zone.alive = false;
zone.shadow_pt.gotoAndStop("off");
kills++;
if (kills >= kills_goal) {
kills_goal = 0;
checkpoint++;
if (checkpoint == 1) {
limit_bottomright.x = limit_bottomright.x + 1370;
new_limit_topleft = limit_bottomright.x - 1400;
f_KidGroup2();
} else if (checkpoint == 2) {
limit_bottomright.x = limit_bottomright.x + 550;
new_limit_topleft = limit_bottomright.x - 640;
f_SwingsOn();
f_KidSwing();
} else if (checkpoint == 3) {
limit_bottomright.x = limit_bottomright.x + 1150;
new_limit_topleft = limit_bottomright.x - 1250;
f_KidGroupSoccer();
soccerfield.gotoAndStop("startsoccer");
} else if (checkpoint == 4) {
f_CarScene1();
f_KidGroup5();
limit_bottomright.x = limit_bottomright.x + 1100;
new_limit_topleft = limit_bottomright.x - 1200;
} else if (checkpoint == 5) {
limit_bottomright.x = limit_bottomright.x + 700;
new_limit_topleft = limit_bottomright.x - 1900;
} else if (checkpoint == 6) {
limit_bottomright.x = limit_bottomright.x + 1200;
new_limit_topleft = limit_bottomright.x - 1200;
f_KidGroup6();
bballhoop.gotoAndStop("on");
} else if (checkpoint == 7) {
limit_bottomright.x = limit_bottomright.x + 1000;
new_limit_topleft = limit_bottomright.x - 1000;
} else if (checkpoint == 8) {
limit_bottomright.x = limit_bottomright.x + 2000;
new_limit_topleft = limit_bottomright.x - 1300;
f_KidGroup8();
} else if (checkpoint == 9) {
limit_bottomright.x = limit_bottomright.x + 2000;
new_limit_topleft = limit_bottomright.x - 1500;
} else if (checkpoint == 10) {
limit_bottomright.x = limit_bottomright.x + 1600;
new_limit_topleft = limit_bottomright.x - 1800;
med1.gotoAndStop("on");
f_SpawnSunchips();
kills_goal = kills_goal + 3;
}
limit_bottomright._x = limit_bottomright.x;
if (limit_topleft.x < new_limit_topleft) {
limit_topleft.x = -game_x;
limit_topleft._x = limit_topleft.x;
}
f_StaticRange();
kills = 0;
if (checkpoint < 11) {
s_Advance.start(0, 0);
_root.go_arrow.gotoAndPlay(2);
_root.center.gotoAndPlay(2);
}
}
f_RemoveChar(zone);
}
function f_CheckHold(u_kid) {
if (u_kid == dude1.grab_pointer) {
f_ClearGrabPointer(dude1);
dude1.gotoAndStop("stand");
}
}
function f_CarCheckHit(zone, u_hit) {
var _local3 = false;
if (u_hit.y < zone.y) {
if (u_hit.y > (zone.y - 100)) {
if (Math.abs(zone.x - u_hit.x) < (zone._width / 2)) {
if (u_hit.health > 0) {
_local3 = true;
f_Damage(u_hit, 3);
if (((u_hit.x < zone.x) and (u_hit._xscale < 0)) or ((u_hit.x >= zone.x) and (u_hit._xscale > 0))) {
f_FlipChar(u_hit);
}
u_hit.speed_toss_y = -(random(10) + 10);
u_hit.speed_toss_x = random(8) + 12;
f_FX(u_hit.x, u_hit.body._y + u_hit.y, int(u_hit.y) + 7, "impact1");
f_CheckHold(u_hit);
f_CallJuggle1(u_hit);
}
}
}
}
return(_local3);
}
function f_DropItem(u_drop) {
if (u_drop.grab_pointer != undefined) {
f_FlipSame(u_drop.grab_pointer, u_drop);
u_drop.grab_pointer.speed_toss_y = -(random(10) + 10);
u_drop.grab_pointer.speed_toss_x = random(8) + 12;
f_CallJuggle1(u_drop.grab_pointer);
f_ClearGrabPointer(u_drop);
}
if (u_drop.item != eval("NULL")) {
u_drop.item.gotoAndStop("stand");
u_drop.item.owner = eval("NULL");
u_drop.item = eval("NULL");
}
}
function f_CarScene1() {
bg2.car1.gotoAndPlay(2);
}
function f_StopCarScene1() {
bg2.car1.gotoAndStop(1);
bg2.car2.gotoAndStop(1);
ups1.gotoAndStop(1);
ups2.gotoAndStop(1);
}
function f_CarDrive(zone) {
zone._y = zone._y + zone.speed_y;
zone.y = zone._y;
zone.x = zone._x;
zone.speed_y++;
zone._xscale = zone._xscale + (zone.speed_y / 12);
zone._yscale = zone._yscale + (zone.speed_y / 12);
zone.depth_mod = 990;
f_Depth(zone, zone.y);
f_EngineVolume();
if (zone.y > (limit_bottomright.y + zone._height)) {
current_vehicle++;
if (current_vehicle > total_vehicles) {
current_vehicle = 1;
}
s_Engine.stop();
bg2.car1.gotoAndPlay(2);
zone.gotoAndStop(1);
} else {
if (zone.y > ((limit_bottomright.y + zone._height) - 300)) {
car_distance = car_distance - 15;
} else {
car_distance = car_distance + 4;
}
var _local4 = false;
i = 1;
while (i <= total_kids) {
var _local2 = this["kid" + i];
if (_local2.alive) {
if (f_CarCheckHit(zone, _local2)) {
_local4 = true;
}
}
i++;
}
i = 1;
while (i <= total_objects) {
var _local2 = this["object_pt" + i];
if (f_CarCheckHit(zone, _local2)) {
_local4 = true;
}
i++;
}
var _local2 = dude1;
if (_local2.y < zone.y) {
if (_local2.y > (zone.y - 100)) {
if (Math.abs(zone.x - _local2.x) < (zone._width / 2)) {
if (!_local2.nohit) {
_local4 = true;
f_Damage(_local2, 10);
if (((_local2.x < zone.x) and (_local2._xscale < 0)) or ((_local2.x >= zone.x) and (_local2._xscale > 0))) {
f_FlipChar(_local2);
}
f_DropItem(_local2);
_local2.speed_toss_y = -(random(10) + 10);
_local2.speed_toss_x = random(8) + 12;
f_FX(_local2.x, _local2.body._y + _local2.y, int(_local2.y) + 7, "impact1");
f_CallJuggle1(_local2);
}
}
}
}
if (_local4) {
f_HardPunchSound();
}
}
}
function f_KillKids() {
i = 1;
while (i <= total_kids) {
var _local2 = this["kid" + i];
if (_local2.alive) {
_local2.health = 0;
_local2.gotoAndStop("hitground1");
}
i++;
}
}
function f_ExplosionCheckHit(zone, u_hit) {
var _local2 = false;
if (Math.abs(u_hit.y - zone.y) < 30) {
if (Math.abs(zone.x - u_hit.x) < 150) {
_local2 = true;
u_hit.onfire = 2;
f_Damage(u_hit, 6);
if (u_hit.grab) {
if (((u_hit.x < zone.x) and (u_hit._xscale < 0)) or ((u_hit.x >= zone.x) and (u_hit._xscale > 0))) {
f_FlipChar(u_hit);
}
} else {
u_hit.explosion = true;
u_hit.punch_function(u_hit);
}
u_hit.speed_toss_y = -(random(15) + 25);
u_hit.speed_toss_x = random(16) + 1;
f_FX(u_hit.x, u_hit.body._y + u_hit.y, int(u_hit.y) + 7, "impact1");
f_CheckHold(u_hit);
f_CallJuggle1(u_hit);
}
}
return(_local2);
}
function f_Explosion(zone) {
var _local4 = false;
i = 1;
while (i <= total_kids) {
var _local2 = this["kid" + i];
if (_local2.alive) {
if (f_ExplosionCheckHit(zone, _local2)) {
_local4 = true;
}
}
i++;
}
i = 1;
while (i <= total_objects) {
var _local2 = this["object_pt" + i];
if (_local2.active) {
if (f_ExplosionCheckHit(zone, _local2)) {
_local4 = true;
}
}
i++;
}
var _local2 = dude1;
if (Math.abs(_local2.y - zone.y) < 30) {
if (Math.abs(zone.x - _local2.x) < 150) {
if (_local2.health > 0) {
_local4 = true;
_local2.onfire = 2;
f_Damage(_local2, 4);
if (((_local2.x < zone.x) and (_local2._xscale < 0)) or ((_local2.x >= zone.x) and (_local2._xscale > 0))) {
f_FlipChar(_local2);
}
f_DropItem(_local2);
_local2.speed_toss_y = -(random(10) + 30);
_local2.speed_toss_x = random(8) + 8;
f_FX(_local2.x, _local2.body._y + _local2.y, int(_local2.y) + 7, "impact1");
f_CallJuggle1(_local2);
}
}
}
}
function f_ObjectSettings(zone) {
zone.onfire = 1;
}
function f_KidSettings(zone) {
zone.nohit = false;
zone.falling = false;
zone.onground = false;
zone.onfire = 1;
zone.bounces = 0;
zone.toss_clock = 0;
zone.root = true;
if (zone.health <= 0) {
s_Ground3.start(0, 0);
zone.gotoAndStop("hitground1");
}
}
function f_Juggle1Setup(u_kid) {
if (u_kid.item != eval("NULL")) {
u_kid.item.gotoAndStop("stand");
u_kid.item.owner = eval("NULL");
u_kid.item = eval("NULL");
}
u_kid.nohit = true;
u_kid.bounces = 0;
}
function f_CallJuggle1(u_kid) {
f_Juggle1Setup(u_kid);
u_kid.gotoAndStop("juggle1");
}
function f_Collide(zone) {
if (zone.collide.body._y >= -10) {
if (zone.collide.grab) {
f_FlipSame(zone.collide, zone);
zone.collide.speed_toss_y = -6;
zone.collide.speed_toss_x = (-random(6)) + 10;
f_CallJuggle1(zone.collide);
f_PunchSound();
f_FX(zone.x, zone.body._y + zone.y, int(zone.y) + 15, "impact1");
} else if (zone.collide.punch) {
zone.collide.punch_function(zone.collide);
} else {
f_PunchSound();
f_FX(zone.x, zone.body._y + zone.y, int(zone.y) + 15, "impact1");
}
}
}
function f_KidToss(zone) {
if (zone == dude1) {
zone.collide = eval("NULL");
if (zone._xscale > 0) {
f_MoveChar(zone, false, -zone.speed_toss_x);
} else {
f_MoveChar(zone, false, zone.speed_toss_x);
}
if (zone.bounds) {
f_FlipChar(zone);
}
} else {
if (zone._xscale > 0) {
f_MoveKid(zone, false, -zone.speed_toss_x);
} else {
f_MoveKid(zone, false, zone.speed_toss_x);
}
if (zone.bounds) {
f_FlipChar(zone);
}
}
if (zone.hitwall) {
f_Collide(zone);
zone.hitwall = false;
f_FlipChar(zone);
f_Damage(zone, 5);
zone.speed_toss_x = zone.speed_toss_x * 0.5;
}
zone.body._y = zone.body._y + zone.speed_toss_y;
zone.toss_clock++;
if (zone.onfire == 2) {
if ((zone.toss_clock % 2) == 0) {
var _local3 = random(20) + 80;
f_FX((zone.x + random(20)) - 10, ((zone.body._y + zone.y) + random(20)) - 40, zone.y - 1, "fire1", _local3, _local3);
}
} else if (zone.onfire == 3) {
if ((zone.toss_clock % 2) == 0) {
var _local3 = random(20) + 120;
f_FX((zone.x + random(20)) - 10, ((zone.body._y + zone.y) + random(20)) - 40, zone.y - 1, "ragesmoke", _local3, _local3);
}
}
if (zone.weight > 0) {
zone.body.body._rotation = zone.body.body._rotation - Math.abs(zone.speed_toss_y);
} else {
zone.body.body._rotation = zone.body.body._rotation + Math.abs(zone.speed_toss_y);
}
f_KidHitKids(zone);
zone.speed_toss_y = zone.speed_toss_y + (gravity + zone.gravity);
if (zone.speed_toss_y > 0) {
zone.falling = true;
} else {
zone.falling = false;
}
if (zone.body._y > 0) {
zone.body._y = 0;
zone.shadow_pt._xscale = 100;
zone.shadow_pt._yscale = 100;
if (zone.explode) {
f_RemoveChar(zone.shadow_pt);
s_explosion6.start(0, 0);
f_Explosion(zone);
zone.active = false;
zone.grab = false;
zone.punch = false;
f_StaticRange();
f_SpawnMask(zone);
zone.gotoAndStop("explode");
} else {
zone.bounces++;
if (zone.bounces == 1) {
f_FX(zone.x, zone.y + 10, int(zone.y) + 1, "dust1", zone._xscale);
if (zone != dude1) {
if (zone.speed_toss_y > 40) {
f_Damage(zone, 7);
} else if (zone.speed_toss_x > 15) {
f_Damage(zone, 7);
}
}
}
if (zone.speed_toss_y > 10) {
if (zone.speed_toss_y > 40) {
s_Ground3.start(0, 0);
f_FX(zone.x, zone.y, 1, "shockwave", u_temp._xscale);
} else if (zone.speed_toss_y > 20) {
s_Ground4.start(0, 0);
} else {
s_Ground5.start(0, 0);
}
zone.speed_toss_y = int(zone.speed_toss_y * -0.35);
if ((zone.bounces % 2) == 0) {
var _local4 = zone.body.body._rotation;
zone.gotoAndStop("bounce2");
zone.body.body._rotation = _local4;
} else {
var _local4 = zone.body.body._rotation;
zone.gotoAndStop("bounce1");
zone.body.body._rotation = _local4;
}
} else {
s_Ground6.start(0, 0);
zone.nohit = true;
zone.bounces = 0;
f_FX(zone.x, zone.y + 10, int(zone.y) + 1, "dust1", zone._xscale);
zone.gotoAndStop("hitground1");
}
}
} else {
var _local2 = 100 + (zone.body._y * 0.25);
if (_local2 < 10) {
_local2 = 10;
}
zone.shadow_pt._xscale = _local2;
zone.shadow_pt._yscale = _local2;
}
}
function f_KidHitKids(zone) {
if ((zone.speed_toss_y > 40) or (zone.speed_toss_x > 14)) {
if (zone.body._y > -150) {
var _local4 = false;
i = 1;
while (i <= total_kids) {
var _local3 = this["kid" + i];
if (((!_local3.nohit) and (_local3 != zone)) and _local3.alive) {
if ((zone == dude1) and _local3.atv) {
} else if (Math.abs(_local3.y - zone.y) < 15) {
if (Math.abs(_local3.x - zone.x) < 40) {
f_Damage(zone, 1);
f_Damage(_local3, 3);
_local4 = true;
f_FlipSame(_local3, zone);
_local3.speed_toss_y = -(random(10) + 10);
_local3.speed_toss_x = zone.speed_toss_x * 0.75;
f_CheckHold(_local3);
f_CallJuggle1(_local3);
_local3.body._y = -50;
}
}
}
i++;
}
if (zone.weight > 0) {
var _local3 = dude1;
if ((!_local3.nohit) and (_local3 != zone)) {
if (Math.abs(_local3.y - zone.y) < 15) {
if (Math.abs(_local3.x - zone.x) < 40) {
_local4 = true;
f_FlipSame(_local3, zone);
_local3.speed_toss_y = -(random(10) + 10);
_local3.speed_toss_x = zone.speed_toss_x * 0.75;
f_DropItem(_local3);
f_CallJuggle1(_local3);
_local3.body._y = -50;
}
}
}
}
if (_local4) {
f_PunchSound();
f_FX(zone.x, zone.body._y + zone.y, int(zone.y) + 15, "impact1");
}
}
}
}
function f_CreateFX() {
i = 1;
while (i <= total_fx) {
var _local4 = "fx" + i;
fx_dm_current = fx_dm_current + 1;
var _local2 = fx_dm_current + fx_dm_default;
var _local3 = f_DepthVal(_local2, 0);
attachMovie("fx", _local4, _local3);
var _local5 = this["fx" + i];
_local5.depth_mod = _local2;
i++;
}
}
function f_FX(fx_x, fx_y, fx_depth, fx_type, fx_xscale, fx_yscale) {
var _local2 = this["fx" + current_fx];
_local2._x = fx_x;
_local2._y = fx_y;
if (fx_xscale != undefined) {
_local2._xscale = fx_xscale;
} else {
_local2._xscale = 100;
}
if (fx_yscale != undefined) {
_local2._yscale = fx_yscale;
} else {
_local2._yscale = 100;
}
f_Depth(_local2, fx_depth);
_local2.gotoAndStop(fx_type);
_local2.x = fx_x;
_local2.y = fx_depth;
f_SpawnMask(_local2);
current_fx++;
if (current_fx > total_fx) {
current_fx = 1;
}
return(_local2);
}
function f_KidThrownFierce(zone) {
u_temp = zone.grab_pointer;
f_FlipInverse(u_temp, zone);
if (zone._xscale > 0) {
f_MoveKid(u_temp, false, 50);
} else {
f_MoveKid(u_temp, false, -50);
}
u_temp.y = zone.y + 1;
u_temp._y = u_temp.y;
if (Key.isDown(38)) {
u_temp.speed_toss_y = -40;
u_temp.speed_toss_x = 2;
} else {
u_temp.speed_toss_y = -16;
u_temp.speed_toss_x = 20;
}
f_CallJuggle1(u_temp);
u_temp.body._y = (zone.y - 50) - u_temp.y;
f_ClearGrabPointer(zone);
}
function f_KidThrown(zone) {
u_temp = zone.grab_pointer;
f_FlipInverse(u_temp, zone);
if (zone._xscale > 0) {
f_MoveKid(u_temp, false, 70);
var _local2 = zone.x + 100;
} else {
f_MoveKid(u_temp, false, -70);
var _local2 = zone.x - 100;
}
u_temp._x = u_temp.x;
u_temp.y = zone.y + 1;
u_temp._y = u_temp.y;
u_temp.speed_toss_y = 60;
u_temp.speed_toss_x = 10;
f_CallJuggle1(u_temp);
u_temp.body._y = (zone.y - 25) - u_temp.y;
f_FX(u_temp.x, zone.y + 15, int(zone.y) + 15, "impact3", -u_temp._xscale);
f_FX(_local2, zone.y + 15, int(zone.y) + 14, "blood1", -u_temp._xscale);
f_ClearGrabPointer(zone);
}
function f_KidHeadbutted(zone) {
f_Damage(zone.grab_pointer, zone.punch_pow_low);
if (zone.grab_counter > 3) {
u_temp = zone.grab_pointer;
f_FlipInverse(u_temp, zone);
if (zone._xscale > 0) {
u_temp.x = zone.x + 50;
} else {
u_temp.x = zone.x - 50;
}
u_temp._x = u_temp.x;
u_temp.y = zone.y + 1;
u_temp._y = u_temp.y;
u_temp.speed_toss_y = -2;
u_temp.speed_toss_x = 20;
f_CallJuggle1(u_temp);
u_temp.body._y = (zone.y - 50) - u_temp.y;
f_ClearGrabPointer(zone);
}
}
function f_GrabSpark(zone) {
if (zone._xscale > 0) {
var _local2 = zone.x + 50;
} else {
var _local2 = zone.x - 50;
}
if ((zone.grab_counter == 1) or (zone.grab_counter == 3)) {
f_PunchSound();
if (zone.rage >= zone.rage_goal) {
var _local3 = "rageimpact";
} else {
var _local3 = "impact2";
}
f_FX(_local2, zone.y - 80, int(zone.y) + 10, _local3);
} else if (zone.grab_counter == 2) {
f_PunchSound();
if (zone.rage >= zone.rage_goal) {
var _local3 = "rageimpact";
} else {
var _local3 = "impact1";
}
f_FX(_local2, zone.y - 80, int(zone.y) + 10, _local3);
f_FX(_local2, zone.y - 80, int(zone.y) + 9, "blood1");
} else {
f_HardPunchSound();
if (zone.rage >= zone.rage_goal) {
var _local3 = "rageimpact";
} else {
var _local3 = "impact3";
}
f_FX(_local2, zone.y - 80, int(zone.y) + 10, _local3);
f_FX(_local2, zone.y - 80, int(zone.y) + 9, "blood2");
}
}
function f_ThrowItem(zone) {
var _local2 = false;
if (Key.isDown(zone.button_punch1)) {
if (!zone.punched) {
zone.punched = true;
_local2 = true;
u_temp = zone.grab_pointer;
u_temp.speed_toss_y = -4;
u_temp.speed_toss_x = 15;
f_CallJuggle1(u_temp);
u_temp.body._y = (zone.y - 150) - u_temp.y;
f_ClearGrabPointer(zone);
f_ClearGrabPointer(zone);
f_DashReset(zone);
zone.gotoAndStop("throw_item");
}
} else {
zone.punched = false;
}
if (Key.isDown(zone.button_punch2)) {
if ((!zone.punched2) and (!_local2)) {
zone.punched2 = true;
u_temp = zone.grab_pointer;
if (Key.isDown(zone.button_up)) {
u_temp.speed_toss_y = -(26 + random(5));
u_temp.speed_toss_x = 2 + random(3);
} else {
u_temp.speed_toss_y = -9;
u_temp.speed_toss_x = 17;
}
f_CallJuggle1(u_temp);
u_temp.body._y = (zone.y - 150) - u_temp.y;
f_ClearGrabPointer(zone);
f_ClearGrabPointer(zone);
f_DashReset(zone);
s_swing1.start(0, 0);
zone.gotoAndStop("throw_item");
}
} else {
zone.punched2 = false;
}
}
function f_Throw(zone) {
if (Key.isDown(zone.button_punch1)) {
if (!zone.punched) {
if (Key.isDown(zone.button_left) or Key.isDown(zone.button_right)) {
f_SoundSwing(2);
zone.grab_pointer.gotoAndStop("thrown");
f_SetXY(zone.grab_pointer, zone.x, zone.grab_pointer.y);
zone.gotoAndStop("throw");
return(undefined);
}
zone.grab_counter++;
if ((zone.grab_counter == 1) or (zone.grab_counter == 3)) {
zone.grab_pointer.gotoAndStop("grabhit1");
zone.gotoAndStop("grabhit1");
} else {
zone.grab_pointer.gotoAndStop("grabhit2");
zone.gotoAndStop("grabhit2");
}
}
} else {
zone.punched = false;
}
if (Key.isDown(zone.button_punch2)) {
if (!zone.punched2) {
if ((Key.isDown(zone.button_left) or Key.isDown(zone.button_right)) or Key.isDown(zone.button_up)) {
f_SoundSwing(4);
zone.grab_pointer.gotoAndStop("thrown2");
f_SetXY(zone.grab_pointer, zone.x, zone.grab_pointer.y);
zone.gotoAndStop("throw2");
} else {
zone.grab_counter++;
if ((zone.grab_counter == 1) or (zone.grab_counter == 3)) {
zone.grab_pointer.gotoAndStop("grabhit1");
zone.gotoAndStop("grabhit1");
} else {
zone.grab_pointer.gotoAndStop("grabhit2");
zone.gotoAndStop("grabhit2");
}
}
}
} else {
zone.punched2 = false;
}
}
function f_SkeletonRip(zone) {
f_KidDie(zone.grab_pointer);
f_ClearGrabPointer(zone);
}
function f_KidReset(zone) {
f_MoveKid(zone, false, 10000);
}
function f_KidGrabbed(u_dude) {
if (u_dude.grab_pointer != undefined) {
f_FlipInverse(u_dude.grab_pointer, u_dude);
if (u_dude._xscale > 0) {
u_dude.grab_pointer.x = u_dude.x + u_dude.grab_pointer.distance;
} else {
u_dude.grab_pointer.x = u_dude.x - u_dude.grab_pointer.distance;
}
u_dude.grab_pointer.y = u_dude.y + 3;
f_SetXY(u_dude.grab_pointer, u_dude.grab_pointer.x, u_dude.grab_pointer.y);
f_ShareMask(u_dude, u_dude.grab_pointer);
}
}
function f_Grab(zone) {
var _local5 = false;
var _local4 = false;
if (zone.item == eval("NULL")) {
i = 1;
while (i <= total_kids) {
var _local2 = this["kid" + i];
if (((!_local2.nohit) and _local2.alive) and _local2.grab) {
if (Math.abs(_local2.y - zone.y) < 10) {
if (Math.abs(_local2.x - zone.x) < 30) {
if (!_local2.atv) {
if (zone.dashing) {
_local5 = true;
f_FlipInverse(_local2, zone);
_local2.speed_toss_y = -12;
_local2.speed_toss_x = 8;
f_Damage(_local2, zone.punch_pow_low);
f_CallJuggle1(_local2);
_local2.body._y = (zone.y - 50) - _local2.y;
} else {
zone.grab_pointer = _local2;
zone.grab_pointer.distance = 55;
zone.grab_counter = 0;
f_KidGrabbed(zone);
if (_local2.item != eval("NULL")) {
_local2.item.gotoAndStop("stand");
_local2.item.owner = eval("NULL");
_local2.item = eval("NULL");
}
_local2.gotoAndStop("grabbed");
i = total_kids + 1;
_local4 = true;
zone.gotoAndStop("grab");
}
}
}
}
}
i++;
}
if (_local5) {
f_PunchSound();
if (zone.rage >= zone.rage_goal) {
var _local6 = "rageimpact";
} else {
var _local6 = "impact3";
}
f_FX(zone.x, zone.y - 50, int(zone.y) + 30, _local6);
}
}
return(_local4);
}
function f_SoundSwing(power) {
this["s_Swing" + ((random(3) + power) - 1)].start(0, 0);
}
function f_PunchSound() {
this["s_Punch" + (random(3) + 1)].start(0, 0);
}
function f_HardPunchSound() {
this["s_HardPunch" + (random(3) + 1)].start(0, 0);
}
function f_UppercutHit(u_kid, u_y) {
u_kid.speed_toss_y = -(random(10) + 20);
u_kid.speed_toss_x = 0;
f_CallJuggle1(u_kid);
u_kid.body._y = u_y - u_kid.y;
}
function f_PunchHit(zone) {
var _local6 = zone.x;
var _local10 = zone.y;
u_point.x = 0;
u_point.y = 0;
zone.body.punch_pt.localToGlobal(u_point);
var _local5 = u_point.x - game_x;
var _local4 = u_point.y - game_y;
var _local9 = false;
var _local8;
var _local7 = 0;
i = 1;
while (i <= total_kids) {
var _local2 = this["kid" + i];
if (_local2.alive) {
if (Math.abs(_local2.y - _local10) < 20) {
if ((((_local2.x > _local6) and (_local2.x < _local5)) or ((_local2.x > _local5) and (_local2.x < _local6))) or (zone.stomping and (Math.abs(_local2.x - zone.x) < 40))) {
if (((!_local2.nohit) or zone.hitnohit) or (zone.stomping and _local2.onground)) {
_local9 = true;
if (zone.rage >= zone.rage_goal) {
_local2.onfire = 3;
}
if (_local2.y > _local7) {
_local8 = _local2.x;
_local7 = _local2.y;
}
if ((_local5 > _local6) and (_local2._xscale > 0)) {
f_FlipChar(_local2);
} else if ((_local5 < _local6) and (_local2._xscale < 0)) {
f_FlipChar(_local2);
}
if (zone.stomping and _local2.onground) {
_local2.speed_toss_y = 20;
_local2.speed_toss_x = random(6) + 7;
f_CallJuggle1(_local2);
f_Damage(_local2, zone.punch_pow_low);
} else if (zone.punch_group == 1) {
if (zone.punch_num == 1) {
_local2.gotoAndStop("hit1");
_local2.body.gotoAndPlay(1);
f_Damage(_local2, zone.punch_pow_low);
} else if (zone.punch_num == 2) {
_local2.gotoAndStop("hit2");
_local2.body.gotoAndPlay(1);
f_Damage(_local2, zone.punch_pow_low);
} else if (zone.punch_num == 3) {
_local2.gotoAndStop("hit3");
_local2.body.gotoAndPlay(1);
f_Damage(_local2, zone.punch_pow_low);
} else if (zone.punch_num == 4) {
_local2.speed_toss_y = -9;
_local2.speed_toss_x = 4;
f_CallJuggle1(_local2);
_local2.body._y = _local4 - _local2.y;
f_Damage(_local2, zone.punch_pow_medium);
}
} else if (zone.punch_group == 2) {
if (zone.punch_num == 1) {
_local2.gotoAndStop("hit1");
_local2.body.gotoAndPlay(1);
f_Damage(_local2, zone.punch_pow_medium);
} else if (zone.punch_num == 2) {
_local2.gotoAndStop("hit2");
_local2.body.gotoAndPlay(1);
f_Damage(_local2, zone.punch_pow_medium);
} else if (zone.punch_num == 3) {
_local2.speed_toss_y = 70;
_local2.speed_toss_x = 1;
f_CallJuggle1(_local2);
f_Damage(_local2, zone.punch_pow_high);
} else if (zone.punch_num == 20) {
_local2.speed_toss_y = -16;
_local2.speed_toss_x = 0;
f_CallJuggle1(_local2);
_local2.body._y = _local4 - _local2.y;
f_Damage(_local2, zone.punch_pow_medium);
} else if (zone.punch_num == 21) {
_local2.speed_toss_y = -14;
_local2.speed_toss_x = 0;
f_CallJuggle1(_local2);
_local2.body._y = _local4 - _local2.y;
f_Damage(_local2, zone.punch_pow_high);
} else if (zone.punch_num == 22) {
_local2.speed_toss_y = -26;
_local2.speed_toss_x = -8;
f_CallJuggle1(_local2);
_local2.body._y = _local4 - _local2.y;
f_Damage(_local2, zone.punch_pow_high);
}
} else if (zone.punch_group == 3) {
f_UppercutHit(_local2, _local4);
f_Damage(_local2, zone.punch_pow_low);
} else if (zone.punch_group == 4) {
if (zone.punch_num == 1) {
_local2.speed_toss_y = -8;
_local2.speed_toss_x = random(6) + 10;
f_CallJuggle1(_local2);
f_Damage(_local2, zone.punch_pow_low);
} else if (zone.punch_num == 2) {
_local2.speed_toss_y = -26;
_local2.speed_toss_x = 10;
f_CallJuggle1(_local2);
f_Damage(_local2, zone.punch_pow_low);
} else if (zone.punch_num == 3) {
_local2.speed_toss_y = -16;
_local2.speed_toss_x = 10;
f_CallJuggle1(_local2);
f_Damage(_local2, zone.punch_pow_low);
}
} else if (zone.punch_group == 5) {
_local2.gotoAndStop("hit1");
_local2.body.gotoAndPlay(1);
f_Damage(_local2, zone.punch_pow_low);
} else {
zone.punch_group = 1;
zone.punch_num = 1;
_local2.gotoAndStop("hit1");
_local2.body.gotoAndPlay(1);
f_Damage(_local2, zone.punch_pow_low);
}
} else if (((_local2.body._y + _local2.y) > _local4) and (_local2.body._y < 0)) {
if ((zone.punch_num < 3) or (zone.punch_group == 4)) {
_local9 = true;
if (zone.rage >= zone.rage_goal) {
_local2.onfire = 3;
}
if ((zone.punch_group < 4) or ((zone.punch_group == 4) and (zone.punch_num == 3))) {
f_Damage(_local2, zone.punch_pow_low);
}
if (_local2.y > _local7) {
_local8 = _local2.x;
_local7 = _local2.y;
}
if ((_local5 > _local6) and (_local2._xscale > 0)) {
f_FlipChar(_local2);
} else if ((_local5 < _local6) and (_local2._xscale < 0)) {
f_FlipChar(_local2);
}
if ((zone.punch_group == 3) and (zone.punch_num == 1)) {
f_UppercutHit(_local2, _local4);
} else if (zone.punch_group == 4) {
if (zone.punch_num == 2) {
f_Damage(_local2, int(zone.punch_pow_low / 2));
_local2.speed_toss_y = -(random(10) + 20);
_local2.speed_toss_x = random(6) + 7;
f_CallJuggle1(_local2);
} else if (zone.punch_num == 3) {
_local2.speed_toss_y = -16;
_local2.speed_toss_x = 10;
f_CallJuggle1(_local2);
}
} else {
_local2.speed_toss_y = -9;
_local2.speed_toss_x = 12;
f_CallJuggle1(_local2);
}
}
}
}
}
}
i++;
}
i = 1;
while (i <= total_objects) {
var _local2 = this["object_pt" + i];
if (_local2.punch) {
if (Math.abs(_local2.y - _local10) < 20) {
if (((_local2.x > _local6) and (_local2.x < _local5)) or ((_local2.x > _local5) and (_local2.x < _local6))) {
if (_local2.body._y > -150) {
if (zone.rage >= zone.rage_goal) {
_local2.onfire = 3;
}
if (_local2.grab) {
f_FlipInverse(_local2, dude1);
if (zone.punch_group == 3) {
_local2.speed_toss_y = -(random(10) + 30);
_local2.speed_toss_x = 0;
f_CallJuggle1(_local2);
_local2.body._y = _local4 - _local2.y;
} else {
_local2.speed_toss_y = -6;
_local2.speed_toss_x = (-random(6)) + 10;
f_CallJuggle1(_local2);
}
_local9 = true;
if (_local2.y > _local7) {
_local8 = _local2.x;
_local7 = _local2.y;
}
} else {
_local2.punch_function(_local2);
}
}
}
}
}
i++;
}
if (_local9) {
if (zone.punch_group == 1) {
if (zone.punch_num == 1) {
f_PunchSound();
} else if (zone.punch_num == 2) {
f_PunchSound();
} else if (zone.punch_num == 3) {
f_PunchSound();
} else if (zone.punch_num == 4) {
f_HardPunchSound();
}
f_RageUp(zone, int(zone.rage_goal / 10));
} else if (zone.punch_group == 2) {
if (((zone.punch_num == 1) or (zone.punch_num == 2)) or (zone.punch_num == 3)) {
f_HardPunchSound();
} else if (((zone.punch_num == 20) or (zone.punch_num == 21)) or (zone.punch_num == 22)) {
s_Smack1.start(0, 0);
}
f_RageUp(zone, int(zone.rage_goal / 10));
} else if (zone.punch_group == 3) {
f_HardPunchSound();
f_RageUp(zone, int(zone.rage_goal / 10));
} else {
f_PunchSound();
f_RageUp(zone, int(zone.rage_goal / 60));
}
if (_local10 > _local7) {
_local7 = _local10;
}
var _local11 = _local7 + 2;
if ((zone.punch_group == 1) and (zone.punch_num == 3)) {
if (zone.rage >= zone.rage_goal) {
var _local12 = "rageimpact";
} else {
var _local12 = "impact2";
}
f_FX(_local8, _local4, _local11, _local12);
} else if (((zone.punch_group == 1) and (zone.punch_num == 4)) or ((zone.punch_group == 2) and (zone.punch_num == 22))) {
if (zone.rage >= zone.rage_goal) {
var _local12 = "rageimpact";
} else {
var _local12 = "impact3";
}
f_FX(_local8, _local4, _local11, _local12);
} else {
if (zone.rage >= zone.rage_goal) {
var _local12 = "rageimpact";
} else {
var _local12 = "impact1";
}
f_FX(_local8, _local4, _local11, _local12);
}
if ((zone.punch_group == 2) and (zone.punch_num >= 20)) {
f_FX(_local8, _local4, _local11 - 1, "blood1");
}
} else if ((zone.punch_num == 2) and (zone.punch_group < 3)) {
zone.punch_num = 0;
}
return(_local9);
}
function f_RageUp(zone, u_rageup) {
zone.rage = zone.rage + u_rageup;
if (zone.rage >= zone.rage_goal) {
if ((zone.rage - u_rageup) < zone.rage_goal) {
i = 1;
while (i <= total_kids) {
var _local2 = this["kid" + i];
if (_local2.alive) {
_local2.speed_toss_y = -(random(10) + 40);
_local2.speed_toss_x = random(2) + 6;
f_CheckHold(_local2);
f_CallJuggle1(_local2);
_local2.nohit = true;
}
i++;
}
zone.rage = zone.rage + (zone.rage_goal / 2);
f_CheckHold(zone);
f_DropItem(zone);
f_PunchReset(zone);
zone.gotoAndStop("powerup");
}
if (zone.rage > (zone.rage_goal * 2)) {
zone.rage = zone.rage_goal * 2;
}
}
}
function f_PushKid(zone, speed) {
if (!zone.nohit) {
if (zone._xscale > 0) {
f_MoveKid(zone, false, -speed);
} else {
f_MoveKid(zone, false, speed);
}
}
}
function f_Turn(zone) {
if (!zone.punching) {
if (Key.isDown(zone.button_left) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
if (Key.isDown(zone.button_right) and (zone._xscale < 0)) {
f_FlipChar(zone);
}
f_KidGrabbed(zone);
}
}
function f_Walk(zone) {
zone.walking = false;
zone.dashing = false;
if (Key.isDown(zone.button_left)) {
if (zone.left_timer <= 0) {
zone.left_last2 = zone.left_timer;
zone.left_timer = 1;
} else {
zone.left_timer++;
}
} else if (zone.left_timer > 0) {
zone.left_last = zone.left_timer;
zone.left_timer = 0;
} else {
zone.left_timer--;
}
if (Key.isDown(zone.button_right)) {
if (zone.right_timer <= 0) {
zone.right_last2 = zone.right_timer;
zone.right_timer = 1;
} else {
zone.right_timer++;
}
} else if (zone.right_timer > 0) {
zone.right_last = zone.right_timer;
zone.right_timer = 0;
} else {
zone.right_timer--;
}
if ((zone.left_timer > 0) and (zone.left_timer > zone.right_timer)) {
if (zone._xscale > 0) {
f_FlipChar(zone);
}
if (zone.holding) {
var _local2 = zone.speed_x / 2;
} else if ((zone.left_last < g_dash_timer) and (zone.left_last2 < g_dash_timer)) {
var _local2 = zone.speed_x * 2;
zone.dashing = true;
} else {
var _local2 = zone.speed_x;
}
if (zone.rage >= zone.rage_goal) {
var _local2 = _local2 * 1.5;
}
f_MoveChar(zone, false, -_local2);
if (zone.diagonalhit) {
f_MoveChar(zone, true, -_local2);
}
zone.walking = true;
}
if ((zone.right_timer > 0) and (zone.right_timer > zone.left_timer)) {
if (zone._xscale < 0) {
f_FlipChar(zone);
}
if (zone.holding) {
var _local2 = zone.speed_x / 2;
} else if ((zone.right_last < g_dash_timer) and (zone.right_last2 < g_dash_timer)) {
var _local2 = zone.speed_x * 2;
zone.dashing = true;
} else {
var _local2 = zone.speed_x;
}
if (zone.rage >= zone.rage_goal) {
var _local2 = _local2 * 1.5;
}
f_MoveChar(zone, false, _local2);
if (zone.diagonalhit) {
f_MoveChar(zone, true, _local2);
}
zone.walking = true;
}
if (Key.isDown(zone.button_up)) {
zone.up_timer++;
} else {
zone.up_timer = 0;
}
if (Key.isDown(zone.button_down)) {
zone.down_timer++;
} else {
zone.down_timer = 0;
}
if (zone.holding) {
var _local2 = zone.speed_y / 2;
} else {
var _local2 = zone.speed_y;
}
if ((zone.up_timer > 0) and (zone.up_timer > zone.down_timer)) {
if (zone.rage >= zone.rage_goal) {
var _local2 = _local2 * 1.5;
}
f_MoveChar(zone, true, -_local2);
if (zone.diagonalhit) {
f_MoveChar(zone, false, -_local2);
}
zone.walking = true;
}
if ((zone.down_timer > 0) and (zone.down_timer > zone.up_timer)) {
if (zone.rage >= zone.rage_goal) {
var _local2 = _local2 * 1.5;
}
f_MoveChar(zone, true, _local2);
if (zone.diagonalhit) {
f_MoveChar(zone, false, _local2);
}
zone.walking = true;
}
if (zone.insand) {
if (zone.walking) {
if (sandbox.sand_timer <= 0) {
sandbox.sand_timer = 5;
f_FX(zone.x, zone.y + 10, int(zone.y) + 1, "sand", zone._xscale);
}
}
}
}
function f_HoldWalk(zone) {
if (zone.hold_delay > 0) {
zone.hold_delay--;
f_Turn(zone);
} else {
zone.holding = true;
f_Walk(zone);
zone.holding = false;
f_KidGrabbed(zone);
if (zone.walking) {
zone.legs.gotoAndStop("walk");
} else {
zone.legs.gotoAndStop("stand");
}
}
}
function f_ToggleQuality() {
if (key.isDown(81)) {
if (pressed_q == false) {
pressed_q = true;
if (quality_low) {
quality_low = false;
_quality = "medium";
} else {
quality_low = true;
_quality = "low";
}
}
} else {
pressed_q = false;
}
}
function f_Character(zone) {
f_ToggleQuality();
if (!pause) {
if (!f_Grab(zone)) {
f_Walk(zone);
if (zone.dashing) {
zone.dashing_timer++;
if ((zone.dashing_timer == 1) or ((zone.dashing_timer % 10) == 0)) {
if (zone.insand) {
f_FX(zone.x, zone.y + 10, int(zone.y) + 1, "sand", zone._xscale);
} else {
f_FX(zone.x, zone.y + 10, int(zone.y) + 1, "dust1", zone._xscale);
}
}
zone.gotoAndStop("dash");
} else {
zone.dashing_timer = 0;
if (zone.walking) {
zone.gotoAndStop("walk");
} else {
zone.gotoAndStop("stand");
}
}
f_Punch(zone);
}
} else {
zone.gotoAndStop("stand");
}
}
function f_OnScreen(u_char) {
var _local2 = u_char.x + game_x;
var _local1 = u_char._width;
if (((_local2 + _local1) > 0) and ((_local2 - _local1) < screen_width)) {
return(true);
}
return(false);
}
function f_AutoTake(zone, u_object, vert, speed) {
var _local4 = false;
if (u_object.autotake) {
_local4 = true;
u_get = false;
if (zone.grab_pointer == undefined) {
if (zone.item == eval("NULL")) {
if (!zone.nohit) {
if (zone.health > 0) {
if (zone.body._y >= 0) {
u_object.owner = zone;
zone.item = u_object;
u_object.autoaction(u_object);
u_get = true;
}
}
}
}
}
if (u_get == false) {
if (!vert) {
if ((speed > 0) and (u_object._xscale > 0)) {
f_FlipChar(u_object);
} else if ((speed < 0) and (u_object._xscale < 0)) {
f_FlipChar(u_object);
}
}
if (!f_MoveKid(u_object, vert, speed)) {
f_MoveKid(u_object, vert, -speed);
}
if (u_object._xscale > 0) {
u_object.body.body._rotation = u_object.body.body._rotation + speed;
} else {
u_object.body.body._rotation = u_object.body.body._rotation - speed;
}
if (!vert) {
u_object.speed_toss_x = Math.abs(speed);
u_object.gotoAndStop("hitground1");
}
}
}
return(_local4);
}
function f_Mask(zone) {
var _local4 = zone.mask_pt.range._height;
var _local5 = zone.mask_pt.range._width;
var _local2 = 100 / Math.abs(zone._xscale);
var _local3 = 100 / zone._yscale;
_local2 = 1;
_local3 = 1;
zone.mask._yscale = 100 * _local3;
if (zone._xscale < 0) {
zone.mask._xscale = -(100 * _local2);
zone.mask._x = (zone.x - zone.mask_pt.x) * _local2;
zone.mask._y = (zone.mask_pt.y - zone._y) * _local3;
} else if (zone._xscale > 0) {
zone.mask._xscale = 100 * _local2;
zone.mask._x = (zone.mask_pt.x - zone.x) * _local2;
zone.mask._y = (zone.mask_pt.y - zone._y) * _local3;
}
}
function f_CheckMask(zone, u_compare) {
if (zone.mask_pt == u_compare) {
zone.mask_pt = undefined;
zone.mask.gotoAndStop(1);
}
}
function f_SpawnMask(zone) {
var _local4 = statics_min;
while (_local4 <= total_statics) {
var _local2 = this["static" + _local4];
if (_local2.mask > 0) {
var _local7 = _local2.x + _local2.zone._x;
var _local5 = _local2.y + _local2.zone._y;
var _local6 = _local2.zone._height * (_local2._yscale / 100);
var _local12 = (_local2.zone._width / 2) * (Math.abs(_local2._xscale) / 100);
if (Math.abs(zone._x - _local7) < _local12) {
if ((zone._y > (_local5 - _local6)) and (zone._y < _local5)) {
var _local8 = _local7 + _local2.left._x;
var _local9 = _local7 + _local2.right._x;
_local12 = Math.abs(_local8 - _local9);
_local6 = Math.abs(_local2.left._y - _local2.right._y);
var _local10 = 1 - ((_local5 - zone.y) / _local6);
var _local11 = _local8 + (_local12 * _local10);
if (zone.x > _local11) {
zone.mask_pt = _local2;
zone.mask.gotoAndStop(_local2.mask);
f_Mask(zone);
}
}
}
}
_local4++;
}
}
function f_HitWallGroup(zone, vert, speed, group_total, group_min, group_name) {
var _local11 = false;
i = group_min;
while (i <= group_total) {
var _local3 = this[group_name + i];
var _local15 = Math.abs(_local3._xscale) / 100;
var _local14 = Math.abs(_local3._yscale) / 100;
var _local6 = _local3.x + _local3.zone._x;
var _local5 = (_local3.y + _local3.zone._y) + 2;
var _local10 = _local3.zone._height * _local14;
var _local9 = (_local3.zone._width / 2) * _local15;
if (vert) {
if (Math.abs(zone.x - _local6) < _local9) {
if (_local3.diagonal) {
if (((zone.y + speed) >= (_local5 - _local10)) and ((zone.y + speed) <= (_local5 + 150))) {
var _local13 = (_local3.x2 - zone.x) / _local3.w;
var _local7 = _local5 - (_local3.h * _local13);
if (_local3.mask > 0) {
if (zone.y < _local7) {
zone.mask_pt = _local3;
zone.mask.gotoAndStop(_local3.mask);
} else {
f_CheckMask(zone, _local3);
}
}
if (Math.abs(zone.x - _local6) < (_local3.w / 2)) {
if ((((speed > 0) and (zone.y <= _local7)) and ((zone.y + speed) >= (_local7 - _local3.h2))) or (((speed < 0) and (zone.y >= _local7)) and ((zone.y + speed) <= (_local7 + _local3.h2)))) {
if (speed > 0) {
zone.diagonal_speed = (_local7 - _local3.h2) - zone.y;
} else {
zone.diagonal_speed = (_local7 + _local3.h2) - zone.y;
}
zone.collide = _local3;
zone.diagonalhit = true;
_local11 = true;
}
}
} else {
f_CheckMask(zone, _local3);
}
} else if ((zone.y < (_local5 - _local10)) and ((zone.y + speed) >= (_local5 - _local10))) {
if (f_AutoTake(zone, _local3, vert, speed) == false) {
_local11 = true;
}
} else if ((zone.y > _local5) and ((zone.y + speed) <= _local5)) {
if (f_AutoTake(zone, _local3, vert, speed) == false) {
_local11 = true;
}
}
} else {
f_CheckMask(zone, _local3);
}
} else if ((zone.y > (_local5 - _local10)) and (zone.y < _local5)) {
if (_local3.diagonal) {
if (((zone.x + speed) > (_local6 - _local9)) and ((zone.x + speed) < (_local6 + _local9))) {
var _local13 = 1 - ((_local5 - zone.y) / _local3.h);
var _local8 = _local3.x1 + (_local3.w * _local13);
if (_local3.mask > 0) {
if (zone.x > _local8) {
zone.mask_pt = _local3;
zone.mask.gotoAndStop(_local3.mask);
} else {
f_CheckMask(zone, _local3);
}
}
if ((zone.y > (_local5 - _local3.h)) and (zone.y < _local5)) {
if ((((speed > 0) and (zone.x <= _local8)) and ((zone.x + speed) >= (_local8 - _local3.w2))) or (((speed < 0) and (zone.x >= _local8)) and ((zone.x + speed) <= (_local8 + _local3.w2)))) {
if (zone.body._y > (_local3.zone._y - _local3.zone._height)) {
if (speed > 0) {
zone.diagonal_speed = (_local8 - _local3.w2) - zone.x;
} else {
zone.diagonal_speed = (_local8 + _local3.w2) - zone.x;
}
zone.collide = _local3;
zone.diagonalhit = true;
_local11 = true;
}
}
}
} else {
f_CheckMask(zone, _local3);
}
} else if (((zone.x < (_local6 - _local9)) and ((zone.x + speed) >= (_local6 - _local9))) or ((zone.x > (_local6 + _local9)) and ((zone.x + speed) <= (_local6 + _local9)))) {
if ((zone.body._y + zone.y) > (_local5 - (_local3._height + 20))) {
if (f_AutoTake(zone, _local3, vert, speed) == false) {
zone.collide = _local3;
_local11 = true;
}
}
}
} else {
f_CheckMask(zone, _local3);
}
i++;
}
return(_local11);
}
function f_HitWall(zone, vert, speed) {
var _local1 = false;
if (f_HitWallGroup(zone, vert, speed, total_objects, 1, "object_pt")) {
_local1 = true;
} else if (f_HitWallGroup(zone, vert, speed, total_statics, statics_min, "static")) {
_local1 = true;
}
zone.hitwall = _local1;
return(_local1);
}
function f_CheckSpawnObject(zone, u_object) {
var _local5 = u_object.x + u_object.zone._x;
var _local2 = u_object.y + u_object.zone._y;
var _local4 = u_object.zone._height * (u_object._yscale / 100);
var _local6 = (u_object.zone._width / 2) * (u_object._xscale / 100);
if (Math.abs(zone.x - _local5) < _local6) {
if (zone.y < _local2) {
if (zone.y > (_local2 - _local4)) {
f_SetXY(zone, zone.x, _local2 + 2);
}
}
}
}
function f_CheckSpawn(zone) {
i = 1;
while (i <= total_objects) {
var _local2 = this["object_pt" + i];
f_CheckSpawnObject(zone, _local2);
i++;
}
i = statics_min;
while (i <= total_statics) {
var _local2 = this["static" + i];
f_CheckSpawnObject(zone, _local2);
i++;
}
}
function f_SoccerBall(zone) {
if (zone.moving) {
zone.moving = false;
zone.body.gotoAndStop("roll");
} else {
zone.body.gotoAndStop("idle");
}
}
function f_ShareMask(u_source, u_slave) {
u_slave.mask_pt = u_source.mask_pt;
if (u_slave.mask_pt == undefined) {
u_slave.mask.gotoAndStop(1);
} else {
u_slave.mask.gotoAndStop(u_slave.mask_pt.mask);
}
f_Mask(u_slave);
}
function f_MoveItem(u_owner, u_item, u_speed) {
if (u_owner._xscale > 0) {
u_item.x = u_owner.x + 25;
} else {
u_item.x = u_owner.x - 25;
}
f_FlipSame(u_item, u_owner);
u_item.y = u_owner.y + 1;
u_item._x = u_item.x;
u_item._y = u_item.y;
u_item.shadow_pt._x = u_item.x;
u_item.shadow_pt._y = u_item.y;
u_item.moving = true;
f_Depth(u_item, u_item.y);
f_ShareMask(u_owner, u_item);
}
function f_MoveChar(zone, vert, speed) {
zone.bounds = false;
zone.diagonalhit = false;
if (vert) {
if ((zone.y + speed) > limit_bottomright.y) {
speed = (limit_bottomright.y - zone.y) + speed;
} else if ((zone.y + speed) < limit_topleft.y) {
speed = (limit_topleft.y - zone.y) + speed;
}
if (f_HitWall(zone, vert, speed)) {
if (zone.diagonalhit) {
speed = zone.diagonal_speed;
} else {
speed = 0;
}
}
zone.y = zone.y + speed;
f_Depth(zone, zone.y);
} else {
if (f_HitWall(zone, vert, speed)) {
if (zone.diagonalhit) {
speed = zone.diagonal_speed;
} else {
speed = 0;
}
}
if (((zone.x + speed) < limit_bottomright.x) and ((zone.x + speed) > limit_topleft.x)) {
zone.x = zone.x + speed;
} else {
zone.bounds = true;
speed = 0;
}
}
zone._x = zone.x;
zone._y = zone.y;
if (zone.mask_pt != undefined) {
f_Mask(zone);
}
if (zone.item) {
f_MoveItem(zone, zone.item, speed);
}
if (zone.scroller) {
if (vert) {
if (((speed > 0) and ((zone.y + game_y) < (screen_height / 2))) or ((speed < 0) and ((zone.y + game_y) > (screen_height / 2)))) {
speed = speed * (((screen_height / 2) - Math.abs((zone.y + game_y) - (screen_height / 2))) / (screen_height / 2));
}
} else if (((speed > 0) and ((zone.x + game_x) < (screen_width / 2))) or ((speed < 0) and ((zone.x + game_x) > (screen_width / 2)))) {
speed = speed * (((screen_width / 2) - Math.abs((zone.x + game_x) - (screen_width / 2))) / (screen_width / 2));
}
f_Scroll(speed, vert);
}
zone.shadow_pt._x = zone.x;
zone.shadow_pt._y = zone.y;
}
function f_DepthVal(u_depth_mod, u_depth) {
return((u_depth * 1000) + u_depth_mod);
}
function f_Depth(u_char, u_depth) {
if (u_char.depth_mod == undefined) {
trace("NO DEPTH: " + u_char);
}
u_char.current_depth = (u_depth * 1000) + u_char.depth_mod;
u_char.swapDepths(u_char.current_depth);
}
function f_CompareDepths_Set(u_char, u_compare) {
if (u_char != u_compare) {
if (u_char.current_depth == u_compare.current_depth) {
trace((u_char + " has overwritten ") + u_compare);
}
}
}
function f_SetDepths() {
if (dude1 != eval("NULL")) {
f_Depth(dude1, dude1.y);
}
i = 1;
while (i <= total_kids) {
var _local4 = this["kid" + i];
if (_local4 != eval("NULL")) {
f_Depth(_local4, _local4.y);
}
i++;
}
i = 1;
while (i <= object_index) {
var _local2 = this["object" + i];
_local2.x = _local2._x;
_local2.y = _local2._y;
_local2.depth_y = _local2.y;
f_Depth(_local2, _local2.y);
i++;
}
i = 1;
while (i <= static_index) {
var _local3 = this["static" + i];
static_dm_current = static_dm_current + 2;
_local3.depth_mod = static_dm_current + static_dm_default;
_local3.depth_y = _local3.y;
f_Depth(_local3, _local3.y);
i++;
}
}
function f_SpawnKids() {
i = 1;
while (i <= total_kids) {
u_temp = this["kid" + i];
if (u_temp.alive == false) {
u_temp.x = ((screen_width - _x) + 100) + random(150);
u_temp._x = u_temp.x;
u_temp.y = limit_topleft.y + random(screen_height);
u_temp._y = u_temp.y;
f_KidInit(u_temp);
u_temp.shadow_pt._x = u_temp.x;
u_temp.shadow_pt._y = u_temp.y;
u_temp.shadow_pt.gotoAndStop("on");
u_temp.gotoAndStop("walk");
}
i++;
}
}
function f_Scroll(speed, vert) {
if (vert) {
if (((limit_topleft.y - speed) + game_y) < (screen_height - 100)) {
if (((limit_bottomright.y - speed) + game_y) > screen_height) {
game_y = game_y - speed;
_y = game_y;
bg0._y = bg0._y - (speed * 0.25);
bg1._y = bg1._y + (speed / 2);
bg2._y = bg2._y + (speed * 0.65);
}
}
} else if (((limit_topleft.x - speed) + game_x) < 0) {
if (((limit_bottomright.x - speed) + game_x) > screen_width) {
game_x = game_x - speed;
_x = game_x;
bg0._x = bg0._x - (speed * 0.25);
bg1._x = bg1._x + (speed / 2);
bg2._x = bg2._x + (speed * 0.65);
} else if (checkpoint_x != limit_bottomright.x) {
checkpoint_x = limit_bottomright.x;
f_StaticRange();
if (checkpoint == 1) {
} else if (checkpoint == 2) {
f_KidGroup3();
} else if (checkpoint == 3) {
} else if (checkpoint == 5) {
f_KidGroup4();
} else if (checkpoint == 6) {
f_StopCarScene1();
} else if (checkpoint == 7) {
f_KidGroup7();
bballhoop.gotoAndStop("off");
} else if (checkpoint == 8) {
f_KidGroup11();
} else if (checkpoint == 9) {
f_KidGroup9();
} else if (checkpoint == 10) {
}
}
if ((limit_topleft.x + game_x) < 0) {
if (limit_topleft.x < new_limit_topleft) {
limit_topleft.x = -game_x;
limit_topleft._x = limit_topleft.x;
}
}
}
}
function f_ComboTimer() {
combo_timer--;
if (combo_timer <= 0) {
combo_count = 0;
}
}
function f_UpdateHUD(u_hud, u_zone) {
u_hud.root = true;
u_hud.shirt_type = u_zone.shirt_type;
u_hud.hat_type = u_zone.hat_type;
u_hud.skin_type = u_zone.skin_type;
u_hud.gotoAndPlay(2);
u_hud.name.gotoAndStop(u_zone.name);
f_Skin(u_hud.name.kid.kid);
}
function f_Damage(damage_zone, damage_pow) {
damage_zone.health = damage_zone.health - damage_pow;
f_DropItem(damage_zone);
combo_count++;
combo_timer = 30;
if (combo_count >= 3) {
_root.combo_counter.gotoAndPlay(2);
}
if (damage_zone.lifebar) {
if (damage_zone.atv) {
damage_zone.s_atvengine.stop();
s_explosion6.start(0, 0);
f_FX(damage_zone.x, damage_zone.y, int(damage_zone.y) + 2, "atv_explode", damage_zone._xscale, damage_zone._yscale);
damage_zone.atv = false;
f_KidSettings(damage_zone);
damage_zone.onfire = 2;
damage_zone.shadow_pt._xscale = 100;
damage_zone.speed_toss_y = -(random(10) + 20);
damage_zone.speed_toss_x = random(2) + 1;
f_CheckHold(damage_zone);
f_CallJuggle1(damage_zone);
}
var _local4 = false;
j = 1;
while (j <= total_huds) {
var _local3 = _root["hud" + j];
if ((_local3.kid_pointer == damage_zone) and (!_local3.ready)) {
f_UpdateHUD(_local3, damage_zone);
_local4 = true;
j = total_huds + 1;
}
j++;
}
if (!_local4) {
j = 1;
while (j <= total_huds) {
var _local3 = _root["hud" + j];
if (_local3.ready) {
_local3.ready = false;
_local3.kid_pointer = damage_zone;
f_UpdateHUD(_local3, damage_zone);
j = total_huds + 1;
}
j++;
}
}
} else if (damage_zone == dude1) {
f_RageDown(int(dude1.rage_goal / 2));
_root.hud.f_HealthBar();
}
}
function f_KidInit(zone) {
zone.lifebar = true;
zone.health_max = 60;
zone.health = zone.health_max;
zone.alive = true;
zone.speed_x = random(5) + 5;
zone.speed_y = random(3) + 3;
zone.weight = 0;
if (zone._xscale < 0) {
zone.speed_x = zone.speed_x * -1;
}
if (random(2) == 1) {
zone.speed_y = zone.speed_y * -1;
}
zone.speed_x = zone.speed_x * 0.5;
zone.speed_y = zone.speed_y * 0.5;
zone.grab = true;
}
function f_MoveKid(zone, vert, speed) {
return_val = true;
zone.bounds = false;
if (f_HitWall(zone, vert, speed)) {
speed = 0;
return_val = false;
}
if (vert) {
zone.y = zone.y + speed;
f_Depth(zone, zone.y);
zone._y = zone.y;
} else {
zone.x = zone.x + speed;
zone._x = zone.x;
if (zone.x > limit_bottomright.x) {
if (speed > 0) {
zone.bounds = true;
}
} else if (zone.x < limit_topleft.x) {
if (speed < 0) {
zone.bounds = true;
}
}
}
if (zone.mask_pt != undefined) {
f_Mask(zone);
}
zone.shadow_pt._x = zone.x;
zone.shadow_pt._y = zone.y;
if (zone.item) {
f_MoveItem(zone, zone.item, speed);
}
return(return_val);
}
function f_KidRun(zone) {
if ((zone.speed_x > 0) and (zone._xscale < 0)) {
f_FlipChar(zone);
} else if ((zone.speed_x < 0) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
if (!f_MoveKid(zone, false, zone.speed_x)) {
zone.speed_x = zone.speed_x * -1;
}
if (!f_MoveKid(zone, true, zone.speed_y)) {
zone.speed_y = zone.speed_y * -1;
}
if ((zone.y > limit_bottomright.y) and (zone.speed_y > 0)) {
zone.speed_y = zone.speed_y * -1;
} else if ((zone.y < limit_topleft.y) and (zone.speed_y < 0)) {
zone.speed_y = zone.speed_y * -1;
}
if ((zone.x > limit_bottomright.x) and (zone.speed_x > 0)) {
zone.speed_x = zone.speed_x * -1;
} else if ((zone.x < limit_topleft.x) and (zone.speed_x < 0)) {
zone.speed_x = zone.speed_x * -1;
}
}
function f_DashReset(zone) {
zone.right_last = 100;
zone.right_last2 = 0;
zone.left_last = 100;
zone.left_last2 = 0;
}
function f_PunchReset(zone) {
zone.punch_group = 0;
zone.punch_num = 0;
zone.punching = false;
}
function f_GrabReset(zone) {
u_ClearPointer.grab_pointer = undefined;
}
function f_StandSettings(zone) {
f_PunchReset(zone);
f_GrabReset(zone);
zone.nohit = false;
zone.onfire = 1;
zone.onground = false;
f_CheckDead(zone);
}
function f_StompRange(zone) {
var _local4 = false;
var _local5 = false;
i = 1;
while (i <= total_kids) {
var _local2 = this["kid" + i];
if (_local2.alive) {
if (Math.abs(_local2.x - zone.x) < 40) {
if (Math.abs(_local2.y - zone.y) < 20) {
if (_local2.onground) {
_local5 = true;
} else {
_local4 = true;
i = total_kids + 1;
}
}
}
}
i++;
}
if ((_local4 == false) and _local5) {
return(true);
}
return(false);
}
function f_PickupRange(zone) {
var _local3 = false;
i = 1;
while (i <= total_objects) {
u_temp = this["object_pt" + i];
if (u_temp.grab) {
if (Math.abs(u_temp.y - zone.y) < 20) {
if (Math.abs(u_temp.x - zone.x) < ((u_temp._width / 2) + 20)) {
if ((((zone.x < u_temp.x) and (zone._xscale > 0)) or ((zone.x > u_temp.x) and (zone._xscale < 0))) or (Math.abs(u_temp.x - zone.x) < ((u_temp._width / 2) - 10))) {
if (u_temp.body._y >= -10) {
_local3 = true;
zone.punched = true;
i = total_objects + 1;
zone.grab_pointer = u_temp;
zone.grab_pointer.distance = 0;
zone.grab_counter = 0;
f_KidGrabbed(zone);
u_temp.gotoAndStop("pickup_item");
zone.gotoAndStop("pickup_item");
}
}
}
}
}
i++;
}
return(_local3);
}
function f_Punch(zone) {
if (zone.item != eval("NULL")) {
var _local3 = false;
if (Key.isDown(zone.button_punch1)) {
zone.punched = true;
_local3 = true;
} else if (Key.isDown(zone.button_punch2)) {
zone.punched2 = true;
_local3 = true;
}
if (_local3) {
f_SoundSwing(4);
if (zone.item == soccerball) {
zone.punch_group = 1;
zone.punch_num = 4;
var _local2 = 1;
} else if (Key.isDown(zone.button_up)) {
zone.punch_group = 3;
zone.punch_num = 1;
var _local2 = 3;
} else {
zone.punch_group = 1;
zone.punch_num = 3;
var _local2 = 2;
}
f_FlipInverse(zone.item, zone);
f_SetXY(zone.item, zone.x, zone.item.y);
if (_local2 == 3) {
f_HoopShot(zone.item);
} else {
zone.item.speed_toss_y = -3;
zone.item.speed_toss_x = 30;
zone.item.gotoAndStop("release");
}
zone.item.owner = eval("NULL");
zone.item = eval("NULL");
if (_local2 == 1) {
f_PunchSound();
zone.gotoAndStop("punch1_4");
zone.body.gotoAndPlay(4);
} else if (_local2 == 2) {
zone.gotoAndStop("punch1_3");
} else if (_local2 == 3) {
zone.gotoAndStop("uppercut");
}
}
} else if ((((Key.isDown(zone.button_punch1) and Key.isDown(zone.button_punch2)) and (!zone.punching)) and (!zone.punched)) and (!zone.punched2)) {
zone.punched = true;
zone.punched2 = true;
zone.punching = true;
f_SoundSwing(3);
zone.punch_group = 3;
zone.punch_num = 1;
zone.gotoAndStop("uppercut");
} else {
if (Key.isDown(zone.button_punch1)) {
if ((!zone.punched) and (!zone.punching)) {
zone.punched = true;
zone.punching = true;
if (f_PickupRange(zone)) {
return(undefined);
}
if (zone.dashing) {
if (zone._xscale > 0) {
zone.speed_slam = 15;
} else {
zone.speed_slam = -15;
}
zone.punch_group = 4;
zone.punch_num = 1;
f_DashReset(zone);
zone.dashing = false;
zone.gotoAndStop("dashslam");
} else if (f_StompRange(zone) and (zone.body._y > -3)) {
zone.gotoAndStop("stomp");
} else if ((zone.punch_group == 5) and (zone.punch_num == 1)) {
zone.punch_num = 2;
zone.gotoAndStop("knife2");
} else if (zone.punch_group == 1) {
if (zone.punch_num == 1) {
f_SoundSwing(4);
zone.punch_num = 2;
zone.gotoAndStop("punch1_2");
} else if (zone.punch_num == 2) {
f_SoundSwing(4);
zone.punch_num = 3;
zone.gotoAndStop("punch1_3");
} else if (zone.punch_num == 3) {
f_SoundSwing(2);
zone.punch_num = 4;
zone.gotoAndStop("punch1_4");
} else {
f_SoundSwing(5);
zone.punch_num = 1;
zone.gotoAndStop("punch1_1");
}
} else {
f_SoundSwing(5);
zone.punch_group = 1;
zone.punch_num = 1;
zone.gotoAndStop("punch1_1");
}
}
} else {
zone.punched = false;
}
if (Key.isDown(zone.button_punch2)) {
if ((!zone.punched2) and (!zone.punching)) {
zone.punched2 = true;
zone.punching = true;
if (zone.dashing) {
if (zone._xscale > 0) {
zone.speed_slam = 18;
} else {
zone.speed_slam = -18;
}
zone.punch_group = 4;
zone.punch_num = 2;
f_DashReset(zone);
zone.dashing = false;
zone.gotoAndStop("dashpunch");
} else if (f_StompRange(zone)) {
zone.gotoAndStop("stomp");
} else if ((zone.punch_group == 1) and (zone.punch_num == 1)) {
zone.punch_group = 5;
zone.punch_num = 1;
zone.gotoAndStop("knife1");
} else if ((zone.punch_group == 1) and (zone.punch_num == 4)) {
zone.punch_group = 2;
zone.punch_num = 20;
zone.gotoAndStop("jugglehit1");
} else if ((zone.punch_group == 4) and (zone.punch_num == 2)) {
zone.punch_num = 3;
zone.gotoAndStop("crazy");
zone.body.gotoAndPlay(1);
} else if ((zone.punch_group == 4) and (zone.punch_num == 3)) {
zone.gotoAndStop("crazy");
zone.body.speed_y = zone.body.speed_y - 20;
zone.body.gotoAndPlay("hitloop");
} else {
zone.punch_group = 2;
if (zone.punch_num == 1) {
zone.punch_num = 2;
zone.gotoAndStop("punch2_2");
} else if (zone.punch_num == 2) {
zone.punch_num = 3;
zone.gotoAndStop("punch2_3");
} else if (zone.punch_num == 20) {
zone.punch_num = 21;
zone.gotoAndStop("jugglehit2");
} else if (zone.punch_num == 21) {
zone.punch_num = 22;
zone.gotoAndStop("jugglehit3");
} else {
zone.punch_num = 1;
zone.gotoAndStop("punch2_1");
}
}
}
} else {
zone.punched2 = false;
}
}
}
function f_Boss1Scroll(zone) {
var _local1 = (zone.x + _x) - 440;
if (_local1 > 10) {
var _local2 = 1 + (_local1 * 0.05);
f_Scroll(_local2, false);
}
}
function f_Boss1Scroll2(zone) {
var _local1 = (zone.x + _x) - 220;
if (_local1 < -10) {
var _local2 = 1 + (_local1 * 0.05);
f_Scroll(_local2, false);
}
}
function f_Boss1ElboHit(zone) {
if (Math.abs(zone.x - dude1.x) < 101) {
if (Math.abs(zone.y - dude1.y) <= 10) {
if (dude1.health > 0) {
u_impact = true;
f_Damage(dude1, 10);
if (((dude1.x < zone.x) and (dude1._xscale < 0)) or ((dude1.x >= zone.x) and (dude1._xscale > 0))) {
f_FlipChar(dude1);
}
f_DropItem(dude1);
dude1.speed_toss_x = 25;
dude1.speed_toss_y = -40;
f_FX(dude1.x, dude1.body._y + dude1.y, int(dude1.y) + 7, "impact1");
f_CallJuggle1(dude1);
s_Punch3.start(0, 0);
}
}
}
}
function f_Boss1PunchHit(zone) {
if (Math.abs(zone.x - dude1.x) < 101) {
if (Math.abs(zone.y - dude1.y) <= 10) {
if (dude1.health > 0) {
u_impact = true;
f_Damage(dude1, 10);
if (((dude1.x < zone.x) and (dude1._xscale < 0)) or ((dude1.x >= zone.x) and (dude1._xscale > 0))) {
f_FlipChar(dude1);
}
f_DropItem(dude1);
dude1.speed_toss_y = -(random(10) + 10);
dude1.speed_toss_x = random(8) + 12;
f_FX(dude1.x, dude1.body._y + dude1.y, int(dude1.y) + 7, "impact1");
f_CallJuggle1(dude1);
s_Punch3.start(0, 0);
}
}
}
}
function f_Boss1UppercutHit(zone) {
if (Math.abs(zone.x - dude1.x) <= 61) {
if (Math.abs(zone.y - dude1.y) <= 10) {
if (dude1.health > 0) {
u_impact = true;
f_Damage(dude1, 10);
if (((dude1.x < zone.x) and (dude1._xscale < 0)) or ((dude1.x >= zone.x) and (dude1._xscale > 0))) {
f_FlipChar(dude1);
}
f_DropItem(dude1);
dude1.speed_toss_y = -(random(10) + 30);
dude1.speed_toss_x = random(2) + 0;
f_FX(dude1.x, dude1.body._y + dude1.y, int(dude1.y) + 7, "impact1");
f_CallJuggle1(dude1);
s_Punch3.start(0, 0);
}
}
}
}
function f_Boss1Run(zone) {
if (zone.success_y) {
if ((zone.x < dude1.x) and (zone._xscale < 0)) {
f_FlipChar(zone);
} else if ((zone.x > dude1.x) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
}
if (zone.success_x) {
if ((zone.y < dude1.y) and zone.north) {
zone.north = false;
} else if ((zone.y > dude1.y) and (!zone.north)) {
zone.north = true;
}
}
if (zone.success_y == false) {
if (zone._xscale > 0) {
var _local6 = dude1.x + 300;
} else {
var _local6 = dude1.x - 300;
}
} else if (zone.x < dude1.x) {
var _local6 = dude1.x - 90;
} else {
var _local6 = dude1.x + 90;
}
if (zone.success_x == false) {
if (zone.north) {
var _local7 = dude1.y - 300;
} else {
var _local7 = dude1.y + 300;
}
} else {
var _local7 = dude1.y + 2;
}
var _local5 = f_rad2deg(Math.atan2(zone.y - _local7, zone.x - _local6));
var _local3 = -4 * Math.cos(PI * _local5);
var _local2 = -4 * Math.sin(PI * _local5);
zone.last_x = _local3;
zone.last_y = _local2;
zone.success_x = f_MoveKid(zone, false, _local3);
zone.success_y = f_MoveKid(zone, true, _local2);
if (!zone.success_x) {
zone.success_x = f_MoveKid(zone, false, _local3);
if (!zone.success_y) {
zone.success_y = f_MoveKid(zone, true, _local2);
}
}
if ((zone.y >= dude1.y) and (zone.y < (dude1.y + 5))) {
if (dude1.body._y > -50) {
if (!dude1.nohit) {
if (Math.abs(zone.x - dude1.x) < 91) {
var _local4 = false;
if (zone.punch_clock < 60) {
zone.punch_count++;
if (zone.punch_count > 3) {
zone.punch_count = 0;
_local4 = true;
zone.gotoAndStop("punch4");
}
} else {
zone.punch_count = 0;
}
zone.punch_clock = 0;
if (_local4 == false) {
if (Math.abs(zone.x - dude1.x) < 61) {
zone.gotoAndStop("punch2");
} else if (zone.lastpunch == 1) {
zone.lastpunch = 3;
zone.gotoAndStop("punch3");
} else {
zone.lastpunch = 1;
zone.gotoAndStop("punch1");
}
}
}
}
}
}
}
function f_Boss1PunchClock(zone) {
zone.punch_clock++;
}
function f_SpawnBoss1() {
total_kids++;
var _local6 = "kid" + total_kids;
var _local5 = "shadow" + current_shadow;
var _local4 = dude1.y + (total_kids * 5);
kid_dm_current = kid_dm_current + 2;
var _local3 = kid_dm_current + kid_dm_default;
attachMovie("boss1", _local6, f_DepthVal(_local3, _local4));
attachMovie("shadow", _local5, total_kids - 200);
var _local2 = this["kid" + total_kids];
_local2.depth_mod = _local3;
_local2.x = limit_bottomright.x - 250;
_local2.y = limit_topleft.y + 100;
_local2._x = _local2.x;
_local2._y = _local2.y;
_local2.shadow_pt = this["shadow" + current_shadow];
current_shadow++;
_local2.shadow_pt._x = _local2.x;
_local2.shadow_pt._y = _local2.y;
f_Depth(_local2, _local2.y);
_local2.health_max = 200;
_local2.health = _local2.health_max;
_local2.alive = true;
_local2.speed_x = 3;
_local2.speed_y = 2;
_local2.name = 100;
_local2.weight = 10;
_local2.grab = false;
_local2.lifebar = true;
_local2.punch_clock = 0;
_local2.punch_count = 0;
f_FlipChar(_local2);
f_KidSettings(_local2);
_local2.gotoAndStop("intro");
_local2.nohit = true;
f_SetXY(boss1fodder, _local2.x - 100, _local2.y);
f_FlipChar(boss1fodder);
boss1fodder.nohit = true;
}
function f_Boss1Intro(zone) {
if ((zone._x + _x) < 770) {
pause = true;
f_MusicHeavy();
zone.body.gotoAndPlay("intro");
}
}
function f_MusicHeavy() {
s_Music1.setVolume(0);
s_Music2.setVolume(master_volume);
}
function f_MusicLight() {
s_Music1.setVolume(master_volume);
s_Music2.setVolume(0);
}
function f_SunchipsMusic() {
s_Music1.stop();
s_SunchipsMusic.start(0, 0);
}
function f_SpawnSunChips() {
total_kids++;
var _local6 = "kid" + total_kids;
var _local5 = "shadow" + current_shadow;
var _local4 = dude1.y + (total_kids * 5);
kid_dm_current = kid_dm_current + 2;
var _local3 = kid_dm_current + kid_dm_default;
attachMovie("sunchips", _local6, f_DepthVal(_local3, _local4));
attachMovie("shadow", _local5, total_kids - 200);
var _local2 = this["kid" + total_kids];
_local2.depth_mod = _local3;
_local2.x = limit_bottomright.x - 300;
_local2.y = limit_topleft.y + 200;
_local2._x = _local2.x;
_local2._y = _local2.y;
_local2.shadow_pt = this["shadow" + current_shadow];
current_shadow++;
_local2.shadow_pt._x = _local2.x;
_local2.shadow_pt._y = _local2.y;
f_Depth(_local2, _local2.y);
_local2.health_max = 400;
_local2.health = _local2.health_max;
_local2.alive = true;
_local2.speed_x = 3;
_local2.speed_y = 2;
_local2.name = 101;
_local2.weight = 10;
_local2.grab = false;
_local2.lifebar = true;
_local2.punch_clock = 0;
_local2.punch_count = 0;
_local2.ammo = 2;
f_FlipChar(_local2);
f_KidSettings(_local2);
_local2.gotoAndStop("intro");
}
function f_DartAction(zone) {
if (zone.hit) {
zone._x = zone._x + zone.speed_x;
zone.shadow_pt._x = zone._x;
zone.dart._y = zone.dart._y + zone.speed_y;
zone.speed_y = zone.speed_y + 1;
zone.dart._rotation = zone.dart._rotation + zone.rotation_speed;
var _local2 = 90 + (zone.dart._y / 2);
if (_local2 < 10) {
_local2 = 10;
}
zone.shadow_pt._xscale = _local2;
zone.shadow_pt._yscale = _local2;
if (zone.dart._y > 0) {
if (zone.bounces > 1) {
zone.bounces--;
zone.dart._y = 0;
zone.speed_y = -4 * zone.bounces;
} else {
f_RemoveChar(zone.shadow_pt);
zone.gotoAndStop("remove");
}
}
} else {
zone._x = zone._x + zone.speed_x;
zone.shadow_pt._x = zone._x;
zone.dart._y = zone.dart._y + zone.speed_y;
zone.speed_y = zone.speed_y + 0.2;
zone.dart._rotation = zone.dart._rotation + 0.2;
var _local2 = 90 + (zone.dart._y / 2);
if (_local2 < 10) {
_local2 = 10;
}
zone.shadow_pt._xscale = _local2;
zone.shadow_pt._yscale = _local2;
if (zone.dart._y > 0) {
zone.hit = true;
zone.bounces = 3;
zone.speed_y = -6;
zone.rotation_speed = 10;
} else if (Math.abs(zone._y - dude1._y) < 5) {
if (Math.abs(zone._x - dude1._x) < 40) {
f_Damage(dude1, 5);
f_DropItem(dude1);
if (dude1.health <= 0) {
dude1.speed_toss_y = -(random(6) + 6);
dude1.speed_toss_x = random(8) + 6;
f_CallJuggle1(dude1);
} else {
dude1.gotoAndStop("flinch1");
}
f_FX(zone._x, zone.dart._y + zone._y, int(dude1.y) + 1, "impact1");
s_Smack1.start(0, 0);
zone.hit = true;
zone.bounces = 3;
zone.speed_x = zone.speed_x * -0.25;
zone.speed_y = -9;
zone.rotation_speed = -10;
}
}
}
}
function f_JamesShoot(zone) {
if (zone._xscale > 0) {
var _local4 = zone.x + 50;
} else {
var _local4 = zone.x - 50;
}
var _local2 = f_FX(_local4, zone.y, zone.y - 1, "dart", zone._xscale, zone._yscale);
var _local5 = "shadow" + current_shadow;
attachMovie("shadow", _local5, -1000 - current_shadow);
_local2.shadow_pt = this["shadow" + current_shadow];
_local2.shadow_pt._x = _local2._x;
_local2.shadow_pt._y = _local2._y;
current_shadow++;
s_DartShoot.start(0, 0);
}
function f_JamesRun(zone) {
if (zone.success_y) {
if ((zone.x < dude1.x) and (zone._xscale < 0)) {
f_FlipChar(zone);
} else if ((zone.x > dude1.x) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
}
if (zone.success_x) {
if ((zone.y < dude1.y) and zone.north) {
zone.north = false;
} else if ((zone.y > dude1.y) and (!zone.north)) {
zone.north = true;
}
}
if (zone.success_y == false) {
if (zone._xscale > 0) {
var _local5 = dude1.x + 600;
} else {
var _local5 = dude1.x - 600;
}
} else if (((zone.x <= dude1.x) and ((dude1.x + game_x) > 310)) or ((zone.x > dude1.x) and ((dude1.x + game_x) > (screen_width - 310)))) {
var _local5 = dude1.x - 300;
} else {
var _local5 = dude1.x + 300;
}
if (zone.success_x == false) {
if (zone.north) {
var _local6 = dude1.y - 600;
} else {
var _local6 = dude1.y + 600;
}
} else {
var _local6 = dude1.y + 2;
}
var _local4 = f_rad2deg(Math.atan2(zone.y - _local6, zone.x - _local5));
var _local3 = -4 * Math.cos(PI * _local4);
var _local2 = -4 * Math.sin(PI * _local4);
zone.last_x = _local3;
zone.last_y = _local2;
zone.success_x = f_MoveKid(zone, false, _local3);
zone.success_y = f_MoveKid(zone, true, _local2);
if (!zone.success_x) {
zone.success_x = f_MoveKid(zone, false, _local3);
if (!zone.success_y) {
zone.success_y = f_MoveKid(zone, true, _local2);
}
}
if (Math.abs(zone.y - dude1.y) < 5) {
if (dude1.body._y > -50) {
if (Math.abs(zone.x - dude1.x) > 180) {
if (((zone.x + game_x) > 0) and ((zone.x + game_x) < (screen_width - 0))) {
s_Swing6.start(0, 0);
zone.gotoAndStop("jamesshoot");
}
}
}
}
}
function f_CheckGunHit(zone, u_char) {
if (u_char.health > 0) {
if (Math.abs(zone.y - u_char.y) < 10) {
if (((zone._xscale > 0) and (zone.x < u_char.x)) or ((zone._xscale < 0) and (zone.x > u_char.x))) {
if (u_char.health > 0) {
f_Damage(u_char, 10);
if (((u_char.x < zone.x) and (u_char._xscale < 0)) or ((u_char.x >= zone.x) and (u_char._xscale > 0))) {
f_FlipChar(u_char);
}
u_char.speed_toss_y = -(random(6) + 5);
u_char.speed_toss_x = random(8) + 12;
u_blood = "blood" + (random(2) + 1);
f_FX(u_char.x, u_char.body._y + u_char.y, int(u_char.y) + 7, u_blood);
f_CheckHold(u_char);
f_DropItem(u_char);
f_CallJuggle1(u_char);
}
}
}
}
}
function f_GunShot(zone) {
f_CheckGunHit(zone, dude1);
var _local2 = 1;
while (_local2 <= total_kids) {
u_char = this["kid" + _local2];
f_CheckGunHit(zone, u_char);
_local2++;
}
}
function f_SunChipsFrenzied(zone) {
zone.speed_toss_y = -(random(10) + 30);
zone.speed_toss_x = random(2) + 0;
f_CallJuggle1(zone);
zone.body._y = zone.body._y - 150;
}
function f_SunChipsSlide(zone) {
if (zone._xscale > 0) {
f_MoveKid(zone, false, zone.slide_speed);
} else {
f_MoveKid(zone, false, -zone.slide_speed);
}
if (((zone.slide_speed % 4) == 0) and (zone.slide_speed > 3)) {
f_FX(zone.x, zone.y + 10, int(zone.y) + 1, "dust1", zone._xscale);
}
zone.slide_speed--;
if (zone.slide_speed < 0) {
zone.slide_speed = 0;
}
}
function f_SunChipsAttack(zone) {
var _local2 = false;
zone.uppercut_timer--;
zone.crazy_timer--;
zone.shot_timer--;
if ((zone.crazy_timer <= 0) and (zone.health < (zone.health_max * 0.4))) {
zone.nohit = true;
f_SunChipsGoCrazy(zone);
} else if (zone.uppercut_timer <= 0) {
if (Math.abs(zone.y - dude1.y) < 10) {
if (dude1.body._y > -50) {
var _local3 = Math.abs(zone.x - dude1.x);
if (_local3 < 200) {
_local2 = true;
zone.uppercut_timer = 60;
zone.slide_speed = int(_local3 / 8);
zone.gotoAndStop("punch2");
}
}
}
}
return(_local2);
}
function f_SunChipsCrazy(zone) {
if ((zone.crazy_speed_x > 0) and (zone._xscale < 0)) {
f_FlipChar(zone);
} else if ((zone.crazy_speed_x < 0) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
if (!f_MoveKid(zone, false, zone.crazy_speed_x)) {
zone.crazy_speed_x = zone.crazy_speed_x * -1;
}
if (!f_MoveKid(zone, true, zone.crazy_speed_y)) {
zone.crazy_speed_y = zone.crazy_speed_y * -1;
}
if (((zone.y + _y) > 480) and (zone.crazy_speed_y > 0)) {
zone.crazy_speed_y = zone.crazy_speed_y * -1;
} else if ((((zone.y + _y) < 0) or (zone.y < limit_topleft.y)) and (zone.crazy_speed_y < 0)) {
zone.crazy_speed_y = zone.crazy_speed_y * -1;
}
if (((zone.x + _x) > 640) and (zone.crazy_speed_x > 0)) {
zone.crazy_speed_x = zone.crazy_speed_x * -1;
} else if (((zone.x + _x) < 0) and (zone.crazy_speed_x < 0)) {
zone.crazy_speed_x = zone.crazy_speed_x * -1;
}
zone.crazy_timer--;
if ((zone.crazy_timer % 6) == 0) {
SunChipsFrame++;
if (SunChipsFrame > 12) {
SunChipsFrame = 1;
}
f_FX(zone.x, zone.y, int(zone.y) - 1, "sunchips");
}
if (zone.crazy_timer <= 0) {
f_SunChipsStopCrazy(zone);
} else if (Math.abs(zone.y - dude1.y) < 16) {
if (dude1.body._y > -50) {
if (Math.abs(zone.x - dude1.x) < 120) {
f_DropItem(dude1);
f_MoveChar(dude1, false, zone.x - dude1.x);
f_MoveChar(dude1, true, (zone.y - dude1.y) + 1);
dude1.gotoAndStop("frenzied");
zone.gotoAndStop("frenzy");
}
}
}
}
function f_SunChipsStopCrazy(zone) {
zone.nohit = false;
zone.crazy_timer = 200;
zone.gotoAndStop("walk");
}
function f_SunChipsGoCrazy(zone) {
zone.SunChipsFrame = 0;
zone.crazy_speed_x = 10;
zone.crazy_speed_y = 6;
zone.crazy_timer = 120;
zone.gotoAndStop("crazy");
}
function f_SunChipsUp(zone) {
var _local1 = false;
if (Math.abs(zone.y - dude1.y) < 20) {
if (dude1.body._y > -50) {
if (Math.abs(zone.x - dude1.x) < 71) {
if (dude1.health > 0) {
s_HardPunch1.start(0, 0);
f_Damage(dude1, 5);
dude1.speed_toss_y = -(random(10) + 30);
dude1.speed_toss_x = random(2) + 2;
f_FX(dude1.x, dude1.body._y + dude1.y, int(dude1.y) + 7, "impact1");
f_CheckHold(dude1);
f_CallJuggle1(dude1);
zone.gotoAndStop("punch1");
}
}
}
}
return(_local1);
}
function f_GameOver() {
var _local3 = 1;
while (_local3 <= total_kids) {
u_char = this["kid" + _local3];
f_RemoveChar(u_char);
_local3++;
}
f_RemoveChar(dude1);
_root.gotoAndStop("gameover");
}
function f_Ending() {
var _local3 = 1;
while (_local3 <= total_kids) {
u_char = this["kid" + _local3];
f_RemoveChar(u_char);
_local3++;
}
f_RemoveChar(dude1);
_root.gotoAndStop("ending");
}
function f_CheckDead(zone) {
if (zone.health <= 0) {
var _local2 = 1;
while (_local2 <= total_kids) {
u_char = this["kid" + _local2];
if (!u_char.atv) {
if (!u_char.nohit) {
u_char.gotoAndStop("wait");
}
}
_local2++;
}
zone.alive = false;
zone.nohit = true;
zone.gotoAndStop("die");
}
}
function f_RemoveChar(u_char) {
u_char.swapDepths(1);
removeMovieClip(u_char);
}
function f_SetPropaine(zone) {
zone.punch = true;
zone.grab = true;
zone.has_shadow = true;
zone.bounces = 0;
zone.weight = 3;
zone.explode = true;
zone.object_type = 5;
zone.body.gotoAndStop(5);
zone.active = true;
}
function f_SetMower(zone) {
zone.punch = true;
zone.grab = true;
zone.has_shadow = true;
zone.bounces = 0;
zone.weight = 3;
zone.explode = true;
zone.object_type = 6;
zone.body.gotoAndStop(6);
zone.active = true;
}
function f_HorseKid_OLD(u_horse) {
total_kids++;
var _local7 = "kid" + total_kids;
var _local6 = "shadow" + current_shadow;
var _local4 = u_horse.y + 1;
kid_dm_current = kid_dm_current + 2;
var _local5 = kid_dm_current + kid_dm_default;
attachMovie("kid", _local7, f_DepthVal(_local5, _local4));
attachMovie("shadow", _local6, total_kids - 200);
var _local2 = this["kid" + total_kids];
_local2.depth_mod = _local5;
_local2.x = u_horse.x;
_local2.y = _local4;
_local2._x = _local2.x;
_local2._y = _local2.y;
_local2.shadow_pt = this["shadow" + current_shadow];
current_shadow++;
_local2.shadow_pt._x = _local2.x;
_local2.shadow_pt._y = _local2.y;
f_Depth(_local2, _local2.y);
if ((_local2.x > dude1.x) and (_local2._xscale > 0)) {
f_FlipChar(_local2);
} else if ((_local2.x < dude1.x) and (_local2._xscale < 0)) {
f_FlipChar(_local2);
}
_local2.speed_toss_y = -(random(4) + 10);
_local2.speed_toss_x = random(4) + 20;
if (u_horse.onfire > 1) {
_local2.onfire = u_horse.onfire;
u_horse.onfire = 1;
}
f_CallJuggle1(_local2);
}
function f_HorseKid(u_horse) {
var _local1 = f_SpawnKid(u_horse.x, u_horse.y + 1, 10, 1, 9, color_pink);
f_KidSettings(_local1);
if ((_local1.x > dude1.x) and (_local1._xscale > 0)) {
f_FlipChar(_local1);
} else if ((_local1.x < dude1.x) and (_local1._xscale < 0)) {
f_FlipChar(_local1);
}
_local1.speed_toss_y = -(random(4) + 10);
_local1.speed_toss_x = random(4) + 20;
if (u_horse.onfire > 1) {
_local1.onfire = u_horse.onfire;
u_horse.onfire = 1;
}
f_CallJuggle1(_local1);
}
function f_PunchHorse(u_horse) {
var _local2 = random(4) + 1;
if (_local2 == 1) {
s_Smack1.start(0, 0);
} else if (_local2 == 2) {
s_Smack2.start(0, 0);
} else if (_local2 == 3) {
s_HardPunch1.start(0, 0);
} else {
s_HardPunch2.start(0, 0);
}
var _local5 = (u_horse.x - 10) + random(20);
var _local4 = u_horse.y - (50 + random(20));
if (random(2) == 1) {
var _local3 = "impact1";
} else {
var _local3 = "impact3";
}
f_FX(_local5, _local4, int(u_horse.y) + 7, _local3);
u_horse.gotoAndStop("shake");
u_horse.body.gotoAndPlay(2);
u_horse.rider--;
if (u_horse.explosion) {
u_horse.explosion = false;
if (u_horse.rider > 0) {
u_horse.rider = 0;
u_horse.onfire = 2;
}
}
if (u_horse.rider == 0) {
u_horse.body.body.kid.gotoAndStop("blank");
f_HorseKid(u_horse);
} else if (u_horse.rider > 0) {
u_horse.body.body.kid.eye.gotoAndPlay(2);
}
}
function f_SetHorse(zone) {
zone.punch = true;
zone.grab = false;
zone.has_shadow = true;
zone.bounces = 0;
zone.weight = 2;
zone.explode = false;
zone.active = true;
zone.rider = 3;
zone.punch_function = f_PunchHorse;
}
function f_RageDown(u_down) {
dude1.rage = dude1.rage - u_down;
if (dude1.rage < dude1.rage_goal) {
if ((dude1.rage + u_down) >= dude1.rage_goal) {
dude1.rage = 0;
}
}
if (dude1.rage < 0) {
dude1.rage = 0;
}
var _local2 = (dude1.rage / dude1.rage_goal) * 100;
if (_local2 < 0) {
_local2 = 0;
} else if (_local2 > 100) {
_local2 = 100;
}
_root.hud.ragebar._xscale = _local2;
if (_local2 == 100) {
_root.hud.ragebg.gotoAndStop(2);
if ((dude1.rage % 3) == 0) {
var _local3 = random(40) + 100;
if (random(3) == 1) {
var _local4 = dude1.y - 1;
} else {
var _local4 = dude1.y + 1;
}
f_FX((dude1.x + random(40)) - 20, (dude1.y + random(80)) - 100, _local4, "ragesmoke", _local3, _local3);
}
} else {
_root.hud.ragebg.gotoAndStop(1);
}
}
function f_Rage() {
f_RageDown(1);
}
function f_Shirt(zone) {
if (zone._parent._parent.root) {
zone.gotoAndStop(zone._parent._parent.shirt_type);
} else if (zone._parent._parent._parent.root) {
zone.gotoAndStop(zone._parent._parent._parent.shirt_type);
} else if (zone._parent._parent._parent._parent.root) {
zone.gotoAndStop(zone._parent._parent._parent._parent.shirt_type);
} else if (zone._parent.root) {
zone.gotoAndStop(zone._parent.shirt_type);
}
}
function f_Hat(zone) {
if (zone._parent._parent.root) {
zone.gotoAndStop(zone._parent._parent.hat_type);
} else if (zone._parent._parent._parent.root) {
zone.gotoAndStop(zone._parent._parent._parent.hat_type);
} else if (zone._parent._parent._parent._parent.root) {
zone.gotoAndStop(zone._parent._parent._parent._parent.hat_type);
} else if (zone._parent.root) {
zone.gotoAndStop(zone._parent.hat_type);
}
}
function f_Skin(zone) {
if (zone._parent._parent.root) {
f_ColorSwap(zone, zone._parent._parent.skin_type);
} else if (zone._parent._parent._parent.root) {
f_ColorSwap(zone, zone._parent._parent._parent.skin_type);
} else if (zone._parent._parent._parent._parent.root) {
f_ColorSwap(zone, zone._parent._parent._parent._parent.skin_type);
} else if (zone._parent.root) {
f_ColorSwap(zone, zone._parent.skin_type);
}
}
function f_ColorSwap(character, new_color) {
CharacterColor = new Color(character);
CharacterColor.setTransform(new_color);
}
function f_SpawnPlayer(u_x, u_y) {
var _local3 = u_x - game_x;
var _local2 = u_y - game_y;
attachMovie("dude", "dude1", f_DepthVal(1, _local2));
dude1.depth_mod = 2;
dude1.x = _local3;
dude1.y = _local2;
dude1._x = dude1.x;
dude1._y = dude1.y;
dude1.num = 1;
dude1.speed_x = 8;
dude1.speed_y = 5;
dude1.pusher = true;
dude1.scroller = true;
dude1.button_punch1 = 65;
dude1.button_punch2 = 83;
dude1.button_left = 37;
dude1.button_up = 38;
dude1.button_right = 39;
dude1.button_down = 40;
dude1.punch_pow_low = 5;
dude1.punch_pow_medium = 8;
dude1.punch_pow_high = 11;
dude1.punch_pow_max = 15;
dude1.weight = 5;
dude1.rage = 0;
dude1.rage_goal = 1000;
dude1.health_max = 100;
dude1.health = dude1.health_max;
f_DashReset(dude1);
f_Depth(dude1, dude1.y);
attachMovie("shadow", "shadow0", 0);
dude1.shadow_pt = shadow0;
dude1.shadow_pt._x = dude1.x;
dude1.shadow_pt._y = dude1.y;
_root.hud.kid_pointer = dude1;
_root.hud.gotoAndStop(2);
}
function f_SpawnKid(x, y, shirt, hat, name, skin) {
var _local4 = eval("NULL");
var _local2 = 1;
while (_local2 <= total_kids) {
if (this["kid" + _local2] == eval("NULL")) {
_local4 = "kid" + _local2;
var _local5 = _local2;
_local2 = total_kids + 1;
}
_local2++;
}
if (_local4 == eval("NULL")) {
total_kids++;
var _local5 = total_kids;
_local4 = "kid" + total_kids;
}
var _local8 = "shadow" + current_shadow;
var _local6 = y;
kid_dm_current = kid_dm_current + 2;
var _local7 = kid_dm_current + kid_dm_default;
attachMovie("kid", _local4, f_DepthVal(_local7, _local6));
attachMovie("shadow", _local8, _local5 - 200);
var _local3 = this["kid" + _local5];
_local3.depth_mod = _local7;
_local3.x = x;
_local3.y = _local6;
_local3._x = _local3.x;
_local3._y = _local3.y;
_local3.shadow_pt = this["shadow" + current_shadow];
current_shadow++;
_local3.shadow_pt._x = _local3.x;
_local3.shadow_pt._y = _local3.y;
_local3.shirt_type = shirt;
_local3.hat_type = hat;
_local3.skin_type = skin;
_local3.name = name;
_local3.item = eval("NULL");
_local3.kid_type = 1;
if ((_local3.x > dude1.x) and (_local3._xscale > 0)) {
f_FlipChar(_local3);
} else if ((_local3.x < dude1.x) and (_local3._xscale < 0)) {
f_FlipChar(_local3);
}
f_KidInit(_local3);
f_Depth(_local3, _local3.y);
f_CheckSpawn(_local3);
return(_local3);
}
function f_KidGroup1() {
var _local2 = sandbox._y - 25;
var _local3 = sandbox._x - 45;
var _local1 = f_SpawnKid(_local3, _local2, 34, 14, 4, color_pink);
f_KidSettings(_local1);
_local1.gotoAndStop("sandbox");
if (_local1._xscale > 0) {
f_FlipChar(_local1);
}
kills_goal = kills_goal + 1;
}
function f_KidGroup2() {
var _local1 = f_RandomY();
var _local2 = (2000 + random(200)) - game_x;
f_SpawnKid(_local2, _local1, 11, 1, 57, color_pink);
_local1 = f_RandomY();
_local2 = (2000 + random(200)) - game_x;
if (random(2) == 1) {
boss1fodder = f_SpawnKid(_local2, _local1, 54, 1, 69, color_pink);
} else {
boss1fodder = f_SpawnKid(_local2, _local1, 15, 1, 22, color_pink);
}
boss1fodder.gotoAndStop("wait");
f_SpawnBoss1();
kills_goal = kills_goal + 4;
}
function f_KidSwing() {
var _local2 = swing3._y + 1;
var _local3 = swing3._x;
var _local1 = f_SpawnKid(_local3, _local2, 19, 1, 58, color_pink);
f_KidSettings(_local1);
_local1.gotoAndStop("swing");
swing3.rider = _local1;
if (_local1._xscale < 0) {
f_FlipChar(_local1);
}
kills_goal = kills_goal + 3;
}
function f_KidGroup3() {
var _local1 = f_RandomY();
var _local2 = (700 + random(100)) - game_x;
if (random(2) == 1) {
f_SpawnKid(_local2, _local1, 3, 1, 10, color_brown);
} else {
f_SpawnKid(_local2, _local1, 49, 1, 73, color_brown);
}
_local1 = f_RandomY();
_local2 = (700 + random(100)) - game_x;
var _local3 = f_SpawnKid(_local2, _local1, 17, 20, 68, color_pink);
_local3.kid_type = 5;
}
function f_KidGroup4() {
var _local2 = f_RandomY();
var _local3 = (700 + random(100)) - game_x;
if (random(2) == 1) {
f_SpawnKid(_local3, _local2, 20, 1, 51, color_pink);
} else {
f_SpawnKid(_local3, _local2, 24, 1, 29, color_pink);
}
_local2 = f_RandomY();
_local3 = -400 - game_x;
f_SpawnKid(_local3, _local2, 18, 21, 20, color_pink);
_local2 = f_RandomY();
_local3 = (700 + random(100)) - game_x;
if (random(2) == 1) {
f_SpawnKid(_local3, _local2, 16, 1, 48, color_pink);
} else {
f_SpawnKid(_local3, _local2, 28, 19, 59, color_beige);
}
_local2 = f_RandomY();
_local3 = -300 - game_x;
var _local1 = f_SpawnKid(_local3, _local2, 7, 1, 7, color_pink);
_local1.kid_type = 2;
_local1.health_max = _local1.health_max * 1.5;
_local1.health = _local1.health_max;
kills_goal = kills_goal + 4;
}
function f_KidGroup5() {
var _local1;
var _local3 = kidline._x;
var _local2 = kidline._y;
_local1 = f_SpawnKid(_local3, _local2, 2, 13, 13, color_pink);
_local1.gotoAndStop("wait");
_local1._xscale = _local1._xscale * -1;
_local3 = kidline._x - 50;
_local2 = kidline._y + 25;
_local1 = f_SpawnKid(_local3, _local2, 2, 13, 14, color_pink);
_local1.gotoAndStop("wait");
_local1._xscale = _local1._xscale * -1;
_local3 = kidline._x - 100;
_local2 = kidline._y + 75;
_local1 = f_SpawnKid(_local3, _local2, 2, 13, 16, color_brown);
_local1.gotoAndStop("wait");
_local1._xscale = _local1._xscale * -1;
_local3 = kidline._x - 90;
_local2 = kidline._y - 35;
_local1 = f_SpawnKid(_local3, _local2, 2, 13, 15, color_pink);
_local1.gotoAndStop("wait");
_local1._xscale = _local1._xscale * -1;
kills_goal = kills_goal + 4;
}
function f_KidGroup6() {
var _local1 = f_RandomY();
var _local2 = (1600 + random(100)) - game_x;
f_SpawnKid(_local2, _local1, 29, 4, 8, color_brown);
_local1 = f_RandomY();
_local2 = (1500 + random(100)) - game_x;
if (random(2) == 1) {
f_SpawnKid(_local2, _local1, 33, 8, 27, color_brown);
} else {
f_SpawnKid(_local2, _local1, 50, 25, 19, color_pink);
}
_local1 = f_RandomY();
_local2 = (1600 + random(100)) - game_x;
u_temp = f_SpawnKid(_local2, _local1, 31, 3, 60, color_pink);
f_SetXY(bball, limit_bottomright.x - 1, limit_bottomright.y + 100);
f_BallInPlay(bball);
f_StaticRange();
u_temp.item = bball;
bball.owner = u_temp;
kills_goal = kills_goal + 3;
}
function f_KidGroupSoccer() {
var _local5 = soccerfield._y - 75;
var _local6 = soccerfield._x + 100;
var _local4 = f_SpawnKid(_local6, _local5, 9, 3, 66, color_latin);
_local4.kid_type = 3;
_local4.gotoAndStop("wait");
_local4.target_ball = soccerball;
_local4.target_goal = goal_left;
_local4.top = true;
_local4.default_x = soccerfield._x + 140;
_local4.default_y = soccerfield._y - 75;
f_SetXY(soccerball, soccerfield._x, soccerfield._y + 5);
f_StaticRange();
_local5 = soccerfield._y;
_local6 = soccerfield._x + 50;
var _local3 = f_SpawnKid(_local6, _local5, 9, 1, 67, color_brown);
_local3.kid_type = 3;
_local3.gotoAndStop("wait");
_local3.target_ball = soccerball;
_local3.target_goal = goal_left;
_local3.top = false;
_local3.default_x = soccerfield._x + 150;
_local3.default_y = soccerfield._y + 75;
_local5 = soccerfield._y - 70;
_local6 = soccerfield._x - 100;
var _local2 = f_SpawnKid(_local6, _local5, 45, 17, 36, color_beige);
_local2.kid_type = 3;
_local2.gotoAndStop("wait");
_local2._xscale = _local2._xscale * -1;
_local2.target_ball = soccerball;
_local2.target_goal = goal_right;
_local2.top = true;
_local2.default_x = soccerfield._x - 130;
_local2.default_y = soccerfield._y - 75;
_local5 = soccerfield._y + 75;
_local6 = soccerfield._x - 120;
var _local1 = f_SpawnKid(_local6, _local5, 48, 1, 37, color_beige);
_local1.kid_type = 3;
_local1.gotoAndStop("wait");
_local1._xscale = _local1._xscale * -1;
_local1.target_ball = soccerball;
_local1.target_goal = goal_right;
_local1.top = false;
_local1.default_x = soccerfield._x - 160;
_local1.default_y = soccerfield._y + 75;
_local4.partner = _local3;
_local3.partner = _local4;
_local2.partner = _local1;
_local1.partner = _local2;
kills_goal = kills_goal + 4;
}
function f_KidGroup7() {
var _local2 = dude1.y;
var _local3 = -150 - game_x;
var _local1 = f_SpawnKid(_local3, _local2, 37, 6, 61, color_brown);
f_KidSettings(_local1);
_local1.atv_speed = 12;
_local1.atv = true;
_local1.gotoAndStop("atv");
_local1.shadow_pt._xscale = 200;
_local1.atv_delay = 0;
_local1.atv_type = 1;
if (_local1._xscale < 0) {
_local1._xscale = _local1._xscale * -1;
}
_local2 = f_RandomY();
_local3 = 1400 - game_x;
_local1 = f_SpawnKid(_local3, _local2, 14, 9, 30, color_pink);
f_KidSettings(_local1);
_local1.atv_speed = 14;
_local1.atv = true;
_local1.gotoAndStop("atv");
_local1.shadow_pt._xscale = 200;
_local1.atv_delay = 0;
_local1.atv_type = 2;
if (_local1._xscale > 0) {
_local1._xscale = _local1._xscale * -1;
}
kills_goal = kills_goal + 2;
}
function f_KidGroup8() {
var _local1 = f_RandomY();
var _local2 = (1400 + random(100)) - game_x;
if (random(2) == 1) {
f_SpawnKid(_local2, _local1, 21, 1, 28, color_pink);
} else {
f_SpawnKid(_local2, _local1, 32, 1, 25, color_pink);
}
_local1 = f_RandomY();
_local2 = (1700 + random(100)) - game_x;
if (random(2) == 1) {
f_SpawnKid(_local2, _local1, 40, 3, 47, color_brown);
} else {
f_SpawnKid(_local2, _local1, 41, 3, 49, color_brown);
}
_local1 = f_RandomY();
_local2 = (2000 + random(100)) - game_x;
f_SpawnKid(_local2, _local1, 44, 10, 50, color_brown);
kills_goal = kills_goal + 6;
}
function f_KidGroup9() {
var _local2 = dude1.y;
var _local3 = -150 - game_x;
var _local1 = f_SpawnKid(_local3, _local2, 46, 2, 64, color_brown);
f_KidSettings(_local1);
_local1.atv_speed = 20;
_local1.atv = true;
_local1.gotoAndStop("atv");
_local1.shadow_pt._xscale = 200;
_local1.atv_delay = 0;
_local1.atv_type = 1;
_local1.kid_type = 4;
_local1.health_max = _local1.health_max * 1.5;
_local1.health = _local1.health_max;
if (_local1._xscale < 0) {
_local1._xscale = _local1._xscale * -1;
}
_local2 = f_RandomY();
_local3 = (700 + random(100)) - game_x;
_local1 = f_SpawnKid(_local3, _local2, 46, 2, 65, color_brown);
_local1.kid_type = 4;
_local1.health_max = _local1.health_max * 1.5;
_local1.health = _local1.health_max;
_local2 = f_RandomY();
_local3 = (700 + random(100)) - game_x;
f_SpawnKid(_local3, _local2, 39, 12, 43, color_pink);
_local2 = f_RandomY();
_local3 = (1000 + random(100)) - game_x;
f_SpawnKid(_local3, _local2, 52, 16, 74, color_latin);
kills_goal = kills_goal + 4;
}
function f_KidGroup10() {
var _local1 = limit_topleft.y + 100;
var _local2 = (700 + random(100)) - game_x;
f_SpawnKid(_local2, _local1, 23, 1, 46, color_pink);
_local1 = limit_topleft.y + 300;
_local2 = (700 + random(100)) - game_x;
if (random(2) == 1) {
f_SpawnKid(_local2, _local1, 45, 18, 62, color_pink);
} else {
f_SpawnKid(_local2, _local1, 42, 11, 63, color_brown);
}
}
function f_KidGroup11() {
var _local1 = limit_topleft.y + 200;
var _local2 = 700 - game_x;
f_SpawnKid(_local2, _local1, 56, 23, 71, color_pink);
_local1 = limit_topleft.y + 300;
_local2 = 900 - game_x;
f_SpawnKid(_local2, _local1, 55, 22, 70, color_pink);
_local1 = limit_topleft.y + 370;
_local2 = 800 - game_x;
f_SpawnKid(_local2, _local1, 59, 24, 72, color_beige);
}
function f_KidGroup100() {
f_SpawnSunchips();
kills_goal = kills_goal + 1;
}
function f_RandomY() {
var _local1;
if ((limit_topleft.y + _y) < 0) {
_local1 = _y;
} else {
_local1 = limit_topleft.y;
}
var _local2 = 480 - (_local1 + _y);
return(_local1 + random(_local2));
}
function f_ShadowSize(zone) {
var _local1 = 100 + (zone.body._y * 0.25);
if (_local1 < 10) {
_local1 = 10;
}
zone.shadow_pt._xscale = _local1;
zone.shadow_pt._yscale = _local1;
}
function f_HelmetAttack(zone) {
var _local2 = false;
if (zone.health > 0) {
if (zone.attack_timer < 0) {
if (Math.abs(zone.y - dude1.y) < 10) {
if (Math.abs(zone.x - dude1.x) < 200) {
if (((zone.x <= dude1.x) and (zone._xscale > 0)) or ((zone.x >= dude1.x) and (zone._xscale < 0))) {
_local2 = true;
zone.slide_hit = false;
zone.slide_speed = 20;
s_Ground1.start(0, 0);
zone.nohit = true;
zone.hitdude = false;
zone.attack_timer = 30;
zone.gotoAndStop("helmetattack");
}
}
}
} else {
zone.attack_timer--;
}
}
return(_local2);
}
function f_NinjaAttack(zone) {
var _local2 = false;
if (zone.attack_timer < 0) {
if (Math.abs(zone.y - dude1.y) < 10) {
_local2 = true;
zone.kick_delay = 6;
if ((zone.x < dude1.x) and (zone._xscale < 0)) {
f_FlipChar(zone);
} else if ((zone.x > dude1.x) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
zone.body_y = 0;
f_FX(zone.x, zone.y, 1, "shockwave", 80, 80);
S_Ground6.start(0, 0);
zone.nohit = true;
zone.hitdude = false;
zone.attack_timer = 30;
zone.gotoAndStop("ninjajump");
}
} else {
zone.attack_timer--;
}
return(_local2);
}
function f_NinjaJump(zone) {
if (zone.body._y > -200) {
zone.body_y = zone.body_y - 20;
zone.body._y = zone.body_y;
f_ShadowSize(zone);
} else if (zone.kick_delay > 0) {
zone.kick_delay--;
if ((zone.x < dude1.x) and (zone._xscale < 0)) {
f_FlipChar(zone);
} else if ((zone.x > dude1.x) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
zone.gotoAndStop("ninjaspin");
zone.body._y = zone.body_y;
f_ShadowSize(zone);
} else {
var _local2 = f_rad2deg(Math.atan2((zone.y + zone.body_y) - dude1.y, zone.x - dude1.x));
zone.kick_x = -20 * Math.cos(PI * _local2);
zone.kick_y = -20 * Math.sin(PI * _local2);
zone.kick_timer = 4;
s_Swing1.start(0, 0);
zone.gotoAndStop("ninjakick");
zone.body._y = zone.body_y;
f_ShadowSize(zone);
}
}
function f_NinjaHit(zone, u_hit) {
if (Math.abs(zone.y - u_hit.y) < 10) {
if (Math.abs(zone.x - u_hit.x) < 50) {
if (u_hit.health > 0) {
zone.hitdude = true;
f_Damage(u_hit, 2);
if (((u_hit.x < zone.x) and (u_hit._xscale < 0)) or ((u_hit.x >= zone.x) and (u_hit._xscale > 0))) {
f_FlipChar(u_hit);
}
u_hit.speed_toss_y = -(random(10) + 10);
u_hit.speed_toss_x = random(8) + 12;
f_FX(u_hit.x, u_hit.body._y + u_hit.y, int(u_hit.y) + 7, "impact1");
f_CheckHold(u_hit);
f_CallJuggle1(u_hit);
f_PunchSound();
}
}
}
}
function f_NinjaKick(zone) {
if (zone.body._y < 0) {
f_MoveKid(zone, false, zone.kick_x);
zone.body_y = zone.body_y + zone.kick_y;
zone.body._y = zone.body_y;
if (zone.body._y > 0) {
zone.body._y = 0;
}
if (zone.y < (dude1.y - 10)) {
f_MoveKid(zone, true, 10);
} else if (zone.y > (dude1.y + 10)) {
f_MoveKid(zone, true, -10);
}
f_ShadowSize(zone);
if ((zone.kick_timer % 4) == 0) {
var _local2 = f_FX(zone.x, zone.y, int(zone.y) - 1, "ninja", zone._xscale);
_local2.body._y = zone.body_y;
}
zone.kicktimer++;
if (zone.body_y > -100) {
if (zone.hitdude == false) {
f_NinjaHit(zone, dude1);
}
}
} else {
zone.gotoAndStop("walk");
}
}
function f_HoopShot(u_ball) {
var _local2 = bballhoop.goal._x + bballhoop.x;
var _local3 = bballhoop.y - 2;
if (u_ball.x < (_local2 + 10)) {
var _local6 = f_rad2deg(Math.atan2(u_ball.y - _local3, u_ball.x - _local2));
var _local4 = Math.abs(u_ball.x - _local2);
if (Math.abs(u_ball.y - _local3) > _local4) {
_local4 = Math.abs(u_ball.y - _local3);
}
var _local5 = -(_local4 / 20);
u_ball.shot_speed_x = _local5 * Math.cos(PI * _local6);
u_ball.shot_speed_y = _local5 * Math.sin(PI * _local6);
u_ball.frames = int(Math.abs(u_ball.x - _local2) / Math.abs(u_ball.shot_speed_x));
u_ball.current_frame = 1;
var _local7 = Math.abs(bballhoop.goal._y);
u_ball.body_speed_y = -(_local7 / u_ball.frames);
u_ball.gotoAndStop("hoopshot");
} else {
u_ball.speed_toss_y = -(22 + random(8));
u_ball.speed_toss_x = 2 + random(4);
u_ball.gotoAndStop("release");
}
}
function f_SeakHoop(zone) {
var _local3 = bballhoop.goal._x + bballhoop.x;
var _local2 = bballhoop.y - 2;
f_MoveKid(zone, false, zone.shot_speed_x);
f_MoveKid(zone, true, zone.shot_speed_y);
zone.body._y = zone.body._y + zone.body_speed_y;
zone.current_frame++;
if (zone.current_frame == zone.frames) {
bballhoop.hoop.hoop.gotoAndPlay("bap");
zone.gotoAndStop("blank");
}
}
function f_CheckHoop(zone) {
}
function f_StartSoccer(zone) {
if ((soccerball.x + _x) < 800) {
score_team1 = 0;
score_team2 = 0;
f_StaticRange();
f_SwingsOff();
goal_left.x = goal_left._x;
goal_left.y = goal_left._y;
goal_right.x = goal_right._x;
goal_right.y = goal_right._y;
soccerfield.x = soccerfield._x;
soccerfield.y = soccerfield._y;
var _local2 = 1;
while (_local2 <= total_kids) {
var _local3 = this["kid" + _local2];
_local3.gotoAndStop("soccerwalk");
_local2++;
}
zone.gotoAndStop("soccergame");
}
}
function f_SoccerGame(zone) {
if (soccerball.x < soccerfield.x) {
if (score_right) {
score_right = false;
}
} else if (score_left) {
score_left = false;
}
if (Math.abs(soccerball.x - goal_left.x) < 50) {
if (soccerball.y < soccer1.y) {
if (soccerball.y > soccer3.y) {
if (!ball_left) {
if (soccerball.owner == eval("NULL")) {
score_left = true;
ball_left = true;
score_team2++;
}
}
}
}
} else {
ball_left = false;
if (Math.abs(soccerball.x - goal_right.x) < 50) {
if (soccerball.y < soccer4.y) {
if (soccerball.y > soccer6.y) {
if (!ball_right) {
if (soccerball.owner == eval("NULL")) {
score_right = true;
ball_right = true;
score_team1++;
}
}
}
}
} else {
ball_right = false;
}
}
}
function f_SoccerChase(zone) {
if (zone.success_y) {
if ((zone.x < zone.target_x) and (zone._xscale < 0)) {
f_FlipChar(zone);
} else if ((zone.x > zone.target_x) and (zone._xscale > 0)) {
f_FlipChar(zone);
}
}
if (zone.success_x) {
if ((zone.y < zone.target_y) and zone.north) {
zone.north = false;
} else if ((zone.y > zone.target_y) and (!zone.north)) {
zone.north = true;
}
}
if (zone.success_y == false) {
if (zone._xscale > 0) {
var _local6 = zone.target_x + 300;
} else {
var _local6 = zone.target_x - 300;
}
} else {
var _local6 = zone.target_x;
}
if (zone.success_x == false) {
if (zone.north) {
var _local7 = zone.target_y - 300;
} else {
var _local7 = zone.target_y + 300;
}
} else {
var _local7 = zone.target_y;
}
var _local5 = f_rad2deg(Math.atan2(zone.y - _local7, zone.x - _local6));
if (zone.item != eval("NULL")) {
var _local4 = -6;
} else {
var _local4 = -5;
}
var _local3 = _local4 * Math.cos(PI * _local5);
var _local2 = _local4 * Math.sin(PI * _local5);
zone.last_x = _local3;
zone.last_y = _local2;
zone.success_x = f_MoveKid(zone, false, _local3);
zone.success_y = f_MoveKid(zone, true, _local2);
if (!zone.success_x) {
zone.success_x = f_MoveKid(zone, false, _local3);
if (!zone.success_y) {
zone.success_y = f_MoveKid(zone, true, _local2);
}
}
}
function f_SoccerSlide(zone) {
if (zone._xscale > 0) {
f_MoveKid(zone, false, zone.slide_speed);
} else {
f_MoveKid(zone, false, -zone.slide_speed);
}
if (!zone.slide_hit) {
var _local2 = dude1;
if (Math.abs(zone.x - _local2.x) < 40) {
if (Math.abs(zone.y - _local2.y) < 10) {
zone.slide_hit = true;
f_PunchSound();
f_Damage(_local2, 5);
if (((_local2.x < zone.x) and (_local2._xscale < 0)) or ((_local2.x >= zone.x) and (_local2._xscale > 0))) {
f_FlipChar(_local2);
}
if (_local2.item == soccerball) {
zone.item = _local2.item;
_local2.item.owner = zone;
zone.item = eval("NULL");
}
f_DropItem(_local2);
_local2.speed_toss_y = -(random(5) + 5);
_local2.speed_toss_x = random(5) + 8;
f_FX(_local2.x, _local2.body._y + _local2.y, int(_local2.y) + 7, "impact1");
f_CallJuggle1(_local2);
}
}
}
if (((zone.slide_speed % 4) == 0) and (zone.slide_speed > 3)) {
f_FX(zone.x, zone.y + 5, int(zone.y) + 5, "dust1", zone._xscale);
}
zone.slide_speed--;
if (zone.slide_speed <= 0) {
zone.gotoAndStop("walk");
}
}
function f_SoccerKick(zone) {
if (zone.target_goal.x < soccerfield.x) {
if (zone._xscale > 0) {
f_FlipChar(zone);
}
} else if (zone._xscale < 0) {
f_FlipChar(zone);
}
f_SoundSwing(4);
f_FlipInverse(zone.item, zone);
if (zone._xscale > 0) {
f_SetXY(zone.item, zone.x + 50, zone.y + 1);
} else {
f_SetXY(zone.item, zone.x - 50, zone.y + 1);
}
zone.item.speed_toss_y = -3;
zone.item.speed_toss_x = 20;
zone.item.gotoAndStop("release");
zone.item.owner = eval("NULL");
zone.item = eval("NULL");
if (zone.top) {
zone.top = false;
zone.partner.top = true;
} else {
zone.top = true;
zone.partner.top = false;
}
}
function f_HuntBall(zone) {
var _local2 = true;
zone.target_pt = zone.target_ball;
zone.target_x = zone.target_ball.x;
if (zone.target_ball.owner == zone.partner) {
if (zone.y < soccerfield.y) {
zone.target_y = zone.target_ball.y - 100;
} else {
zone.target_y = zone.target_ball.y + 100;
}
} else {
zone.target_y = zone.target_ball.y;
}
if (Math.abs(zone.x - zone.target_x) < 50) {
if (Math.abs(zone.y - zone.target_y) < 10) {
if (zone.target_pt.owner == eval("NULL")) {
zone.target_pt.owner = zone;
zone.item = zone.target_pt;
zone.target_pt.autoaction(zone.target_pt);
} else if (zone.target_pt.owner == dude1) {
_local2 = false;
zone.slide_hit = false;
zone.slide_speed = 16;
s_Ground1.start(0, 0);
zone.gotoAndStop("soccerslide");
} else {
_local2 = false;
zone.gotoAndStop("soccerwait");
}
}
}
if (_local2) {
f_SoccerChase(zone);
zone.gotoAndStop("soccerwalk");
}
}
function f_SoccerFollow(zone) {
var _local2 = false;
if (Math.abs(zone.x - zone.target_ball.x) > 200) {
_local2 = true;
zone.target_x = zone.target_ball.x;
} else {
zone.target_x = zone.x;
}
if (Math.abs(zone.y - zone.target_ball.y) > 100) {
_local2 = true;
zone.target_y = zone.target_ball.y;
} else {
zone.target_y = zone.y;
}
if (_local2) {
f_SoccerChase(zone);
zone.gotoAndStop("soccerwalk");
} else {
zone.gotoAndStop("soccerwait");
}
}
function f_SoccerRun(zone) {
if ((score_left and (zone.target_goal == goal_left)) or (score_right and (zone.target_goal == goal_right))) {
zone.target_x = zone.default_x;
zone.target_y = zone.default_y;
if ((Math.abs(zone.target_x - zone.x) < 50) and (Math.abs(zone.target_y - zone.y) < 50)) {
if (zone.x > soccerfield.x) {
if (zone._xscale > 0) {
f_FlipChar(zone);
}
} else if (zone._xscale < 0) {
f_FlipChar(zone);
}
zone.gotoAndStop("soccerwait");
} else {
f_SoccerChase(zone);
zone.gotoAndStop("soccerwalk");
}
} else if (zone.item == eval("NULL")) {
if (zone.target_ball.y < soccerfield.y) {
if ((zone.top or (!zone.partner.alive)) or (dude1.grab_pointer == zone.partner)) {
f_HuntBall(zone);
} else {
f_SoccerFollow(zone);
}
} else if (((zone.top == false) or (!zone.partner.alive)) or (dude1.grab_pointer == zone.partner)) {
f_HuntBall(zone);
} else {
f_SoccerFollow(zone);
}
} else {
if (zone.target_goal.x < soccerfield.x) {
zone.target_x = zone.target_goal.x + 250;
} else {
zone.target_x = zone.target_goal.x - 250;
}
if (zone.y < soccerfield.y) {
zone.target_y = zone.target_goal.y - 10;
} else {
zone.target_y = zone.target_goal.y + 10;
}
zone.target_pt = zone.target_goal;
f_SoccerChase(zone);
if (Math.abs(zone.x - zone.target_x) < 50) {
if (Math.abs(zone.y - zone.target_y) < 100) {
f_SoccerKick(zone);
}
}
}
}
function f_EngineVolume() {
var _local1 = ups2._x + _x;
var _local3 = (1540 - (_local1 + 450)) / 1540;
var _local4 = int((200 * _local3) - 100) * -1;
s_Engine.setPan(_local4);
var _local2 = 100;
if (_local1 < -350) {
_local2 = 0;
} else if (_local1 < 0) {
_local3 = Math.abs(_local1 + 350) / 350;
_local2 = _local2 * _local3;
} else if (_local1 > 1000) {
_local2 = 0;
} else if (_local1 > 640) {
_local3 = Math.abs(_local1 - 990) / 350;
_local2 = _local2 * _local3;
}
_local2 = _local2 * (car_distance * 0.01);
s_Engine.setVolume(_local2);
}
function f_ATVHit(zone, u_hit) {
if (Math.abs(zone.y - u_hit.y) < 10) {
if (Math.abs(zone.x - u_hit.x) < 75) {
if (!u_hit.nohit) {
var _local3 = false;
if (((u_hit.x > zone.x) and (zone._xscale > 35)) or ((u_hit.x < zone.x) and (zone._xscale < -35))) {
f_Damage(u_hit, 10);
if (((u_hit.x < zone.x) and (u_hit._xscale < 0)) or ((u_hit.x >= zone.x) and (u_hit._xscale > 0))) {
f_FlipChar(u_hit);
}
f_DropItem(u_hit);
u_hit.speed_toss_y = -(random(10) + 10);
u_hit.speed_toss_x = random(8) + 12;
f_FX(u_hit.x, u_hit.body._y + u_hit.y, int(u_hit.y) + 7, "impact1");
f_CallJuggle1(u_hit);
f_HardPunchSound();
u_hit.nohit = true;
}
}
}
}
}
function f_ATVPosition(zone) {
if (zone.atv_type == 1) {
f_SetXY(zone, zone.x, dude1.y);
f_CheckSpawn(zone);
} else {
var _local2 = f_RandomY();
f_SetXY(zone, zone.x, _local2);
f_CheckSpawn(zone);
}
}
function f_ATV(zone) {
if (zone.atv_delay <= 0) {
if (zone._xscale > 0) {
if (!f_MoveKid(zone, false, zone.atv_speed)) {
f_SetXY(zone, zone.x, zone.y + 6);
}
if ((zone.x + _x) > 900) {
f_ATVPosition(zone);
f_FlipChar(zone);
}
} else {
if (!f_MoveKid(zone, false, -zone.atv_speed)) {
f_SetXY(zone, zone.x, zone.y + 6);
}
if ((zone.x + _x) < -250) {
f_ATVPosition(zone);
f_FlipChar(zone);
}
}
f_ATVHit(zone, dude1);
} else {
zone.atv_delay--;
if (zone.atv_delay == 0) {
f_ATVPosition(zone);
}
}
var _local2 = zone.x + _x;
var _local3 = (1150 - (_local2 + 250)) / 1150;
var _local5 = int((200 * _local3) - 100) * -1;
zone.s_atvengine.setPan(_local5);
var _local4 = 100;
if (_local2 < -150) {
_local4 = 0;
} else if (_local2 < 0) {
_local3 = Math.abs(_local2 + 150) / 150;
_local4 = _local4 * _local3;
} else if (_local2 > 800) {
_local4 = 0;
} else if (_local2 > 640) {
_local3 = Math.abs(_local2 - 790) / 150;
_local4 = _local4 * _local3;
}
zone.s_atvengine.setVolume(_local4);
if (!zone.init) {
zone.init = true;
zone.s_atvengine.start(0, 100000);
}
}
function f_CreateKids() {
i = 1;
while (i <= total_kids) {
var _local6 = "kid" + i;
var _local5 = "shadow" + current_shadow;
var _local3 = limit_topleft.y + random(200);
kid_dm_current = kid_dm_current + 2;
var _local4 = kid_dm_current + kid_dm_default;
attachMovie("kid", _local6, f_DepthVal(_local4, _local3));
attachMovie("shadow", _local5, i - 200);
var _local2 = this["kid" + i];
_local2.depth_mod = _local4;
_local2.x = 2000 - game_x;
_local2.y = _local3;
_local2._x = _local2.x;
_local2._y = _local2.y;
_local2.shadow_pt = this["shadow" + current_shadow];
current_shadow++;
_local2.shadow_pt._x = _local2.x;
_local2.shadow_pt._y = _local2.y;
_local2.shirt_type = 37 + random(8);
_local2.hat_type = 3;
_local2.skin_type = color_brown;
i++;
}
}
function f_Dribble(zone) {
if (zone.owner._xscale > 0) {
zone.x = zone.owner.x + 25;
} else {
zone.x = zone.owner.x - 25;
}
zone.y = zone.owner.y + 1;
zone._x = zone.x;
zone._y = zone.y;
zone.shadow_pt._x = zone.x;
zone.shadow_pt._y = zone.y;
f_Depth(zone, zone.y);
}
function f_SwingCheckChar(zone, u_temp) {
var _local4 = false;
if (Math.abs(u_temp.x - zone.x) < 50) {
if (Math.abs(u_temp.y - zone.y) < 10) {
_local4 = true;
if (zone.rider != eval("NULL")) {
if (Math.abs(zone.rider.x - zone.x) < 50) {
if (Math.abs(zone.rider.y - zone.y) < 10) {
var _local1 = zone.rider;
f_Damage(_local1, 1);
if (((_local1.x < zone.x) and (_local1._xscale < 0)) or ((_local1.x >= zone.x) and (_local1._xscale > 0))) {
f_FlipChar(_local1);
}
_local1.speed_toss_y = -(random(2) + 2);
_local1.speed_toss_x = random(2) + 2;
f_CheckHold(_local1);
f_CallJuggle1(_local1);
}
}
zone.rider = eval("NULL");
}
f_FX(u_temp.x, u_temp.y - 50, int(u_temp.y) + 1, "impact1");
s_Smack1.start(0, 0);
zone.gotoAndPlay("move");
}
}
return(_local4);
}
function f_SwingCheck(zone) {
f_SwingCheckChar(zone, dude1);
}
function f_SetTrash(zone) {
zone.punch = true;
zone.grab = true;
zone.has_shadow = true;
zone.bounces = 0;
zone.weight = 2;
zone.explode = false;
zone.object_type = 1;
zone.body.gotoAndStop(1);
zone.active = true;
}
function f_SetTrash2(zone) {
zone.punch = true;
zone.grab = true;
zone.has_shadow = true;
zone.bounces = 0;
zone.weight = 2;
zone.explode = false;
zone.object_type = 2;
zone.body.gotoAndStop(2);
zone.active = true;
}
function f_BallInPlay(zone) {
if (zone.ball == 1) {
zone.gotoAndStop("dribble_bball");
} else if (zone.ball == 2) {
zone.gotoAndStop("dribble_soccer");
}
}
function f_SetBall(zone, u_type) {
zone.punch = true;
zone.has_shadow = true;
zone.bounces = 2;
zone.weight = 0;
zone.explode = false;
zone.object_type = 1;
zone.active = true;
zone.owner = kid1;
zone.gravity = -2;
zone.autotake = true;
zone.ball = u_type;
if (u_type == 1) {
zone.autoaction = f_TakeBasketball;
} else if (u_type == 2) {
zone.autoaction = f_TakeBasketball;
}
}
function f_TakeBasketball(zone) {
f_BallInPlay(zone);
}
function f_CheckSandbox(zone) {
if (sandcastle.crushed) {
zone.gotoAndStop("sandboxcry");
}
}
function f_Sandbox(zone) {
dude1.insand = false;
sandbox.sand_timer--;
if ((zone._x + _x) < -200) {
zone.gotoAndStop(3);
} else {
if (zone._currentframe == 1) {
if (Math.abs(dude1.y - zone.y) < 10) {
if (Math.abs(dude1.x - zone.x) < 80) {
s_Fart.start(0, 0);
zone.crushed = true;
zone.gotoAndStop(2);
}
}
}
var _local10 = zone.topleft._x + zone.x;
var _local2 = zone.bottomleft._x + zone.x;
var _local4 = zone.topleft._y + zone.y;
var _local8 = zone.bottomleft._y + zone.y;
var _local6 = zone.topright._x + zone.x;
var _local3 = zone.bottomright._x + zone.x;
if ((dude1.y > _local4) and (dude1.y < _local8)) {
if ((dude1.x >= _local2) and (dude1.x <= _local6)) {
var _local5 = 1 - ((dude1.y - _local4) / 100);
var _local9 = _local2 + ((_local10 - _local2) * _local5);
var _local7 = _local3 + ((_local6 - _local3) * _local5);
if ((dude1.x >= _local9) and (dude1.x <= _local7)) {
dude1.insand = true;
}
}
}
}
}
function f_Roll(zone) {
if (zone.speed_toss_X > 0) {
if (zone._xscale > 0) {
f_MoveKid(zone, false, -zone.speed_toss_x);
} else {
f_MoveKid(zone, false, zone.speed_toss_x);
}
zone.body.body._rotation = zone.body.body._rotation - zone.speed_toss_x;
if (zone.bounds) {
f_FlipChar(zone);
}
zone.body._y = zone.body._y + zone.speed_toss_y;
if (zone.body._y > 0) {
zone.body._y = 0;
zone.shadow_pt._xscale = 100;
zone.shadow_pt._yscale = 100;
if (zone.speed_toss_y > 3) {
zone.speed_toss_y = int(zone.speed_toss_y * -0.35);
}
} else {
var _local2 = 100 + (zone.body._y * 0.25);
if (_local2 < 10) {
_local2 = 10;
}
zone.shadow_pt._xscale = _local2;
zone.shadow_pt._yscale = _local2;
}
zone.speed_toss_x = zone.speed_toss_x - 0.5;
zone.speed_toss_y++;
} else {
zone.nextFrame();
}
}
function f_MedPickup(zone) {
if (Math.abs(dude1.x - zone._x) < 30) {
if (Math.abs(dude1.y - zone._y) < 10) {
s_DartShoot.start(0, 0);
dude1.health = dude1.health_max;
zone.gotoAndStop("blank");
}
}
}
function f_AddStatic(zone) {
static_index++;
this["static" + static_index] = zone;
zone.x = zone._x;
zone.y = zone._y;
}
function f_AddNeutral(zone) {
static_dm_current = static_dm_current + 2;
zone.depth_mod = static_dm_current + static_dm_default;
zone.x = zone._x;
zone.y = zone._y;
zone.depth_y = zone.y;
f_Depth(zone, zone.y);
}
function f_SetDiagonal(zone) {
var _local3 = Math.abs(zone._xscale) / 100;
var _local2 = Math.abs(zone._yscale) / 100;
var _local4 = zone._x + zone.zone._x;
var _local5 = zone._y + zone.zone._y;
var _local6 = zone.zone._height * _local2;
var _local7 = (zone.zone._width / 2) * _local3;
zone.diagonal = true;
zone.left_x = zone.left._x * _local3;
zone.right_x = zone.right._x * _local3;
zone.left_y = zone.left._y * _local2;
zone.right_y = zone.right._y * _local2;
zone.h = Math.abs(zone.left_y - zone.right_y);
zone.h2 = zone.zone2._height;
zone.w2 = zone.zone2._width;
zone.x1 = _local4 + zone.left_x;
zone.x2 = _local4 + zone.right_x;
zone.w = Math.abs(zone.x1 - zone.x2);
}
function f_StaticRange() {
var _local5 = static_index;
var _local4 = 1;
i = 1;
while (i <= static_index) {
var _local3 = this["static" + i];
if (_local3.x > limit_topleft.x) {
if (_local3.x < limit_bottomright.x) {
if (i < _local5) {
_local5 = i;
}
if (i > _local4) {
_local4 = i;
}
}
}
i++;
}
statics_min = _local5;
total_statics = _local4;
_local5 = object_index;
total_objects = 0;
i = 1;
while (i <= object_index) {
var _local2 = this["object" + i];
if (_local2._x > limit_topleft.x) {
if (_local2._x < limit_bottomright.x) {
if (_local2.active) {
total_objects++;
this["object_pt" + total_objects] = _local2;
}
}
}
i++;
}
}
function f_GameInit() {
_x = 2600;
_y = 150;
game_x = _x;
game_y = _y;
fx_dm_current = 0;
fx_dm_default = 600;
kid_dm_current = 0;
kid_dm_default = 4;
object_dm_current = 0;
object_dm_default = 200;
static_dm_current = 0;
static_dm_default = 400;
screen_width = 640;
screen_height = 480;
limit_bottomright.x = (screen_width - game_x) + 1800;
limit_topleft.x = -game_x;
limit_bottomright._x = limit_bottomright.x;
limit_topleft._x = limit_topleft.x;
limit_bottomright.y = limit_bottomright._y;
limit_topleft.y = limit_topleft._y;
new_limit_topleft = -game_x;
checkpoint = 0;
checkpoint_x = 0;
current_vehicle = 1;
total_vehicles = 4;
total_kids = 3;
total_huds = 6;
combo_count = 0;
combo_timer = 0;
current_shadow = 1;
current_fx = 1;
total_fx = 100;
f_CreateFX();
f_SetTrash(object1);
f_SetPropaine(object2);
f_SetPropaine(object3);
f_SetPropaine(object4);
f_SetHorse(object5);
object6 = bball;
f_SetBall(bball, 1);
object7 = drugmart_trash;
f_SetTrash2(object7);
object8 = soccerball;
f_SetBall(soccerball, 2);
object9 = mower;
f_SetMower(mower);
object10 = propaine4;
f_SetPropaine(object10);
object11 = propaine5;
f_SetPropaine(object11);
object12 = propaine6;
f_SetPropaine(object12);
object_index = 12;
f_SetDiagonal(sign);
sign.mask = 3;
f_SetDiagonal(fence1);
fence1.mask = 2;
f_SetDiagonal(fence2);
fence2.mask = 2;
f_SetDiagonal(wrx_left);
f_SetDiagonal(wrx_right);
f_SetDiagonal(drugmart_left);
f_SetDiagonal(ghetto1_left);
f_SetDiagonal(ghetto2_left);
static_index = 0;
f_AddStatic(sign);
f_AddStatic(sandcastle);
f_AddStatic(pgwall1);
f_AddStatic(pgwall2);
f_AddStatic(swing1);
f_AddStatic(swing2);
f_AddStatic(swing3);
f_AddStatic(swing4);
f_AddStatic(swing5);
f_AddStatic(swing6);
f_AddStatic(soccer1);
f_AddStatic(soccer2);
f_AddStatic(soccer3);
f_AddStatic(soccer4);
f_AddStatic(soccer5);
f_AddStatic(soccer6);
f_AddStatic(bballhoop);
f_AddStatic(fence1);
f_AddStatic(drugmart_left);
f_AddStatic(drugmart);
f_AddStatic(light1);
f_AddStatic(light2);
f_AddStatic(tree1);
f_AddStatic(ghetto1);
f_AddStatic(ghetto1_left);
f_AddStatic(ghetto2);
f_AddStatic(ghetto2_left);
f_AddStatic(ghetto3);
f_AddStatic(stump);
f_AddStatic(light3);
f_AddStatic(wrx_tire);
f_AddStatic(wrx);
f_AddStatic(wrx_right);
f_AddStatic(wrx_left);
f_StaticRange();
f_AddNeutral(drugmart_right);
f_AddNeutral(house2_right1);
f_AddNeutral(house2_right2);
f_AddNeutral(house5_right);
f_AddNeutral(med1);
i = 1;
while (i <= object_index) {
var _local2 = this["object" + i];
object_dm_current = object_dm_current + 2;
_local2.depth_mod = object_dm_current + object_dm_default;
_local2.x = _local2._x;
_local2.y = _local2._y;
if (_local2.has_shadow) {
var _local3 = "shadow" + current_shadow;
attachMovie("shadow", _local3, i - 100);
_local2.shadow_pt = this["shadow" + current_shadow];
current_shadow++;
_local2.shadow_pt._x = _local2.x;
_local2.shadow_pt._y = _local2.y;
}
i++;
}
master_volume = 130;
kills = 0;
kills_goal = 0;
bg0.depth_mod = 999;
f_Depth(bg0, 1000);
_quality = "medium";
f_SetDepths();
}
function main() {
f_Rage();
f_ComboTimer();
}
function startEngine() {
this.onEnterFrame = main;
}
u_point = new Object();
gravity = 3;
g_dash_timer = 6;
var PI = (Math.PI/180);
s_Punch1 = new Sound();
s_Punch1.attachSound("sound_GoodPunch1.wav");
s_Punch2 = new Sound();
s_Punch2.attachSound("sound_GoodPunch2.wav");
s_Punch3 = new Sound();
s_Punch3.attachSound("sound_GoodPunch3.wav");
s_Punch4 = new Sound();
s_Punch4.attachSound("sound_GoodPunch4.wav");
s_Smack1 = new Sound();
s_Smack1.attachSound("sound_GoodSmack1.wav");
s_Smack2 = new Sound();
s_Smack2.attachSound("sound_GoodSmack2.wav");
s_Swing1 = new Sound();
s_Swing1.attachSound("sound_Swing1.wav");
s_Swing2 = new Sound();
s_Swing2.attachSound("sound_Swing2.wav");
s_Swing3 = new Sound();
s_Swing3.attachSound("sound_Swing3.wav");
s_Swing4 = new Sound();
s_Swing4.attachSound("sound_Swing4.wav");
s_Swing5 = new Sound();
s_Swing5.attachSound("sound_Swing5.wav");
s_Swing6 = new Sound();
s_Swing6.attachSound("sound_Swing6.wav");
s_Ground1 = new Sound();
s_Ground1.attachSound("sound_Ground1.wav");
s_Ground2 = new Sound();
s_Ground2.attachSound("sound_Ground2.wav");
s_Ground3 = new Sound();
s_Ground3.attachSound("sound_Ground3.wav");
s_Ground4 = new Sound();
s_Ground4.attachSound("sound_Ground4.wav");
s_Ground5 = new Sound();
s_Ground5.attachSound("sound_Ground5.wav");
s_Ground6 = new Sound();
s_Ground6.attachSound("sound_Ground6.wav");
s_HardPunch1 = new Sound();
s_HardPunch1.attachSound("sound_HardPunch1.wav");
s_HardPunch2 = new Sound();
s_HardPunch2.attachSound("sound_HardPunch2.wav");
s_HardPunch3 = new Sound();
s_HardPunch3.attachSound("sound_HardPunch3.wav");
s_explosion5 = new Sound();
s_explosion5.attachSound("sound_explosion5");
s_explosion6 = new Sound();
s_explosion6.attachSound("sound_explosion6");
s_DartShoot = new Sound();
s_DartShoot.attachSound("sound_corkpop2.wav");
s_GunShot = new Sound();
s_GunShot.attachSound("sound_357mag.wav");
s_Thunder = new Sound();
s_Thunder.attachSound("sound_thunderp.wav");
s_Fart = new Sound();
s_Fart.attachSound("sound_fart_2.wav");
s_Advance = new Sound();
s_Advance.attachSound("sound_RKND16.wav");
s_Reload = new Sound();
s_Reload.attachSound("sound_reload.wav");
s_SunChipsGrunt = new Sound();
s_SunChipsGrunt.attachSound("sound_evilgrunt1.wav");
s_SunChipsDie = new Sound();
s_SunChipsDie.attachSound("sound_evildie.wav");
s_SwishTriple = new Sound();
s_SwishTriple.attachSound("sound_SwishTriple.wav");
s_Stab = new Sound();
s_Stab.attachSound("sound_sword1.wav");
s_Bounce = new Sound();
s_Bounce.attachSound("sound_bball_bounce.wav");
s_Swoosh = new Sound();
s_Swoosh.attachSound("sound_bball_swish.wav");
s_Engine = new Sound(bg2.car1);
s_Engine.attachSound("sound_trucks_moving");
s_Music1 = new Sound(_root.m1);
s_Music1.attachSound("music_Dad n Me.wav");
s_Music2 = new Sound(_root.m2);
s_Music2.attachSound("music_Dad n Me GUITAR.wav");
s_SunchipsMusic = new Sound();
s_SunChipsMusic.attachSound("05 boss.wav");
color_brown = new Object();
color_brown.ra = 100;
color_brown.ga = 100;
color_brown.ba = 100;
color_brown.aa = 100;
color_brown.rb = -61;
color_brown.gb = -56;
color_brown.bb = -121;
color_brown.ab = 0;
color_yellow = new Object();
color_yellow.ra = 100;
color_yellow.ga = 100;
color_yellow.ba = 100;
color_yellow.aa = 100;
color_yellow.rb = -61;
color_yellow.gb = -56;
color_yellow.bb = -121;
color_yellow.ab = 0;
color_pink = new Object();
color_pink.ra = 100;
color_pink.ga = 100;
color_pink.ba = 100;
color_pink.aa = 100;
color_pink.rb = 0;
color_pink.gb = 0;
color_pink.bb = 0;
color_pink.ab = 0;
color_default = new Object();
color_default.ra = 100;
color_default.ga = 100;
color_default.ba = 100;
color_default.aa = 100;
color_default.rb = 0;
color_default.gb = 0;
color_default.bb = 0;
color_default.ab = 0;
color_beige = new Object();
color_beige.ra = 100;
color_beige.ga = 100;
color_beige.ba = 100;
color_beige.aa = 100;
color_beige.rb = -25;
color_beige.gb = 0;
color_beige.bb = -60;
color_beige.ab = 0;
color_latin = new Object();
color_latin.ra = 100;
color_latin.ga = 100;
color_latin.ba = 100;
color_latin.aa = 100;
color_latin.rb = -25;
color_latin.gb = 0;
color_latin.bb = -95;
color_latin.ab = 0;
f_GameInit();
startEngine();
s_Music1.setVolume(master_volume);
s_Music1.start(0, 5000);
s_Music2.setVolume(0);
s_Music2.start(0, 5000);
stop();
stop();
Symbol 1749 MovieClip Frame 4
stop();
Symbol 1752 MovieClip Frame 1
stop();
Symbol 1752 MovieClip Frame 2
play();
Symbol 1840 MovieClip Frame 1
stop();
Symbol 1841 MovieClip Frame 1
ready = true;
stop();
Symbol 1841 MovieClip Frame 2
play();
function f_HealthBar() {
health = (kid_pointer.health / kid_pointer.health_max) * 100;
if (health < 0) {
health = 0;
}
bar._xscale = health;
}
f_HealthBar();
Instance of Symbol 1359 MovieClip "bar" in Symbol 1841 MovieClip Frame 2
onClipEvent (enterFrame) {
_parent.f_HealthBar();
}
Symbol 1841 MovieClip Frame 60
gotoAndStop (1);
Symbol 1842 MovieClip Frame 1
stop();
Symbol 1842 MovieClip Frame 2
function f_HealthBar() {
health = (kid_pointer.health / kid_pointer.health_max) * 100;
if (health < 0) {
health = 0;
}
bar._xscale = health;
}
f_HealthBar();
Instance of Symbol 1359 MovieClip "bar" in Symbol 1842 MovieClip Frame 2
onClipEvent (enterFrame) {
_parent.f_HealthBar();
}
Instance of Symbol 1359 MovieClip "ragebar" in Symbol 1842 MovieClip Frame 2
onClipEvent (enterFrame) {
_parent.f_HealthBar();
}
Symbol 1843 MovieClip Frame 1
stop();
Symbol 1843 MovieClip Frame 2
checked = false;
play();
Symbol 1843 MovieClip Frame 3
distance = (_root.game.dude1.x + _root.game._x) - 220;
if (distance > 10) {
if ((_root.game.dude1._xscale > 0) and (!_root.game.dude1.nohit)) {
speed = 1 + (distance * 0.05);
_root.game.f_Scroll(speed, false);
}
} else {
gotoAndStop (1);
}
Symbol 1843 MovieClip Frame 4
gotoAndPlay (3);
Symbol 1857 MovieClip Frame 1
stop();
Symbol 1857 MovieClip Frame 2
play();
Symbol 1859 MovieClip Frame 11
stop();
Symbol 1862 MovieClip Frame 1
music_volume = 100;
stop();
Instance of Symbol 249 MovieClip in Symbol 1862 MovieClip Frame 2
onClipEvent (enterFrame) {
_parent.music_volume--;
_root.game.s_SunChipsMusic.setVolume(_parent.music_volume);
}
Symbol 1862 MovieClip Frame 71
_root.game.s_SunChipsMusic.setVolume(100);
stopAllSounds();
_root.game.f_Ending();
stop();
Symbol 1866 MovieClip Frame 1
stop();
Symbol 1866 MovieClip Frame 91
_root.gotoAndStop("intro");
Symbol 1877 MovieClip Frame 19
stop();
Symbol 1878 MovieClip Frame 1
stop();
Symbol 1898 MovieClip Frame 6
stop();
Symbol 1970 MovieClip Frame 18
stop();
Symbol 1977 MovieClip Frame 1
stop();
Symbol 1977 MovieClip Frame 7
stop();
Symbol 1977 MovieClip Frame 15
gotoAndStop (1);
Symbol 1983 Button
on (press) {
stopAllSounds();
tellTarget (_root.end) {
play();
};
}
Symbol 1987 Button
on (rollOver) {
tellTarget ("tank") {
gotoAndPlay ("bang");
};
}
on (rollOut) {
tellTarget ("tank") {
gotoAndPlay ("awww");
};
}
on (press) {
getURL ("http://www.newgrounds.com", _blank);
}
Symbol 1990 MovieClip Frame 351
stopAllSounds();
Symbol 1990 MovieClip Frame 388
stopAllSounds();
Symbol 1990 MovieClip Frame 845
stop();
Symbol 1990 MovieClip Frame 957
stopAllSounds();
_root.gotoAndStop("level1");
Symbol 2002 MovieClip Frame 11
stop();
Symbol 2041 MovieClip Frame 1
stop();
Symbol 2041 MovieClip Frame 6
stop();
Symbol 2041 MovieClip Frame 12
gotoAndStop (1);
Symbol 2042 Button
on (rollOver) {
tellTarget ("again") {
gotoAndPlay ("over");
};
}
on (rollOut) {
tellTarget ("again") {
gotoAndPlay ("off");
};
}
on (press) {
tellTarget (_root.over) {
play();
};
}
Symbol 2043 Button
on (press) {
getURL ("http://www.synj.net", _blank);
}
Symbol 2044 Button
on (press) {
getURL ("http://www.newgrounds.com", _blank);
}
Symbol 2045 Button
on (press) {
getURL ("http://www.cookiedoughrecords.com", _blank);
}
Symbol 2054 MovieClip Frame 7
stop();
Symbol 2074 MovieClip Frame 31
stop();
Symbol 2094 MovieClip Frame 5
stop();
Symbol 2105 MovieClip Frame 41
stop();
Symbol 2106 MovieClip Frame 105
stop();
Symbol 2106 MovieClip Frame 127
stopAllSounds();
Symbol 2106 MovieClip Frame 217
stopAllSounds();
_root.gotoAndStop("level1");