Frame 1
Instance of Symbol 57 MovieClip "char" in Frame 1
onClipEvent (mouseMove) {
_x = _root._xmouse;
_y = _root._ymouse;
}
onClipEvent (load) {
Mouse.hide();
}
Frame 2
score.text = 0;
stop();
function Vector(x, y) {
this.x = x;
this.y = y;
this.length = Math.sqrt((x * x) + (y * y));
}
function constrain(p0, p1, l) {
var _local2 = 0.025;
var _local9 = p1._x - p0._x;
var _local8 = p1._y - p0._y;
var _local1 = new Vector(_local9, _local8);
var _local3 = (_local1.length - l) / _local1.length;
var _local7 = (_local1.x * 0.5) * _local3;
var _local6 = (_local1.y * 0.5) * _local3;
p1._x = p1._x - (_local7 - _local2);
p1._y = p1._y - _local6;
p0._x = p0._x + (_local7 + _local2);
p0._y = p0._y + _local6;
}
function update() {
var _local3;
var _local2 = 0;
while (_local2 < joints.length) {
this[joints[_local2]].update();
_local2++;
}
}
function collisions() {
var _local3;
var _local6;
var _local5;
var _local4 = false;
var _local2 = 0;
while (_local2 < joints.length) {
_local3 = this[joints[_local2]];
if (_local3.collisions()) {
_local4 = true;
_local6 = _local3._x;
_local5 = _local3._y;
}
_local2++;
}
if (_local4) {
if (!soundplaying) {
var _local7 = new Sound(this);
_local7.onSoundComplete = function () {
soundplaying = false;
};
var _local8 = random(3);
var _local9 = -100 + ((head._x * 200) / 445);
_local7.attachSound("break" + _local8);
_local7.start(0, 0);
_local7.setVolume(75);
_local7.setPan(_local9);
soundplaying = true;
}
drawblood(_local6, _local5);
}
}
function constraints() {
var _local1 = 0;
while (_local1 < 2) {
constrain(lhand, lelbow, 12);
constrain(lelbow, neck, 12);
constrain(rhand, relbow, 12);
constrain(relbow, neck, 12);
constrain(neck, waist, 20);
constrain(lknee, waist, 20);
constrain(lfoot, lknee, 20);
constrain(rknee, waist, 20);
constrain(rfoot, rknee, 20);
constrain(head, neck, 3.5);
_local1++;
}
}
function setup() {
constraints();
var _local2;
var _local3 = 0;
while (_local3 < joints.length) {
_local2 = this[joints[_local3]];
_local2.lx = _local2._x;
_local2.ly = _local2._y;
_local3++;
}
}
function drawblood(x, y) {
var _local2;
var _local1 = 0;
while (_local1 <= (random(30) + 3)) {
_local2 = attachMovie("Blood", "Blood" + blooddepth, blooddepth++);
_local2._x = x;
_local2._y = y;
_local1++;
}
}
function drawhead(col) {
var _local4 = 0;
var _local3 = 0;
var _local2 = 7;
head.beginFill(((col == undefined) ? 0 : (col)), 100);
head.moveTo(_local4 + _local2, _local3);
var _local1 = 0;
while (_local1 <= (Math.PI*2)) {
head.lineTo(_local4 + (Math.cos(_local1) * _local2), _local3 + (Math.sin(_local1) * _local2));
_local1 = _local1 + 0.0698131700797732;
}
head.endFill();
}
function draw(col) {
clear();
lineStyle(5, ((col == undefined) ? 0 : (col)), 100);
moveTo(lhand._x, lhand._y);
lineTo(lelbow._x, lelbow._y);
lineTo(neck._x, neck._y);
lineTo(relbow._x, relbow._y);
lineTo(rhand._x, rhand._y);
moveTo(neck._x, neck._y);
lineTo(waist._x, waist._y);
lineTo(lknee._x, lknee._y);
lineTo(lfoot._x, lfoot._y);
moveTo(waist._x, waist._y);
lineTo(rknee._x, rknee._y);
lineTo(rfoot._x, rfoot._y);
var _local2 = neck._x - head._x;
var _local1 = neck._y - head._y;
head._rotation = (Math.atan2(_local1, _local2) * 45) / Math.PI;
}
function onEnterFrame() {
update();
constraints();
collisions();
draw();
}
stop();
MovieClip.prototype.useHandCursor = false;
var dragging = null;
var blooddepth = 0;
var soundplaying = false;
var ragdollcolor = 0;
var joints = new Array("lhand", "lelbow", "rhand", "relbow", "neck", "waist", "lknee", "lfoot", "rknee", "rfoot", "head");
drawhead(ragdollcolor);
setup();
stop();
bounce = 50;
current = 0;
currentplus = 0.5;
currentdecrease = 0.5;
Instance of Symbol 92 MovieClip in Frame 2
onClipEvent (enterFrame) {
if (this.hitTest(_root.char)) {
_root.health.text = 0;
}
}
Instance of Symbol 92 MovieClip in Frame 2
onClipEvent (enterFrame) {
if (this.hitTest(_root.char)) {
_root.score.text = 0;
}
}
Instance of Symbol 96 MovieClip in Frame 2
onClipEvent (enterFrame) {
if (this.hitTest(_root.head)) {
_root.health.text++;
}
}
Instance of Symbol 99 MovieClip in Frame 2
onClipEvent (enterFrame) {
if (this.hitTest(_root.head)) {
_root.score.text++;
}
}
Frame 3
gotoAndPlay (1);
Frame 4
stop();
stopAllSounds();
Frame 5
score.text = 0;
stop();
function Vector(x, y) {
this.x = x;
this.y = y;
this.length = Math.sqrt((x * x) + (y * y));
}
function constrain(p0, p1, l) {
var _local2 = 0.025;
var _local9 = p1._x - p0._x;
var _local8 = p1._y - p0._y;
var _local1 = new Vector(_local9, _local8);
var _local3 = (_local1.length - l) / _local1.length;
var _local7 = (_local1.x * 0.5) * _local3;
var _local6 = (_local1.y * 0.5) * _local3;
p1._x = p1._x - (_local7 - _local2);
p1._y = p1._y - _local6;
p0._x = p0._x + (_local7 + _local2);
p0._y = p0._y + _local6;
}
function update() {
var _local3;
var _local2 = 0;
while (_local2 < joints.length) {
this[joints[_local2]].update();
_local2++;
}
}
function collisions() {
var _local3;
var _local6;
var _local5;
var _local4 = false;
var _local2 = 0;
while (_local2 < joints.length) {
_local3 = this[joints[_local2]];
if (_local3.collisions()) {
_local4 = true;
_local6 = _local3._x;
_local5 = _local3._y;
}
_local2++;
}
if (_local4) {
if (!soundplaying) {
var _local7 = new Sound(this);
_local7.onSoundComplete = function () {
soundplaying = false;
};
var _local8 = random(3);
var _local9 = -100 + ((head._x * 200) / 445);
_local7.attachSound("break" + _local8);
_local7.start(0, 0);
_local7.setVolume(75);
_local7.setPan(_local9);
soundplaying = true;
}
drawblood(_local6, _local5);
}
}
function constraints() {
var _local1 = 0;
while (_local1 < 2) {
constrain(lhand, lelbow, 12);
constrain(lelbow, neck, 12);
constrain(rhand, relbow, 12);
constrain(relbow, neck, 12);
constrain(neck, waist, 20);
constrain(lknee, waist, 20);
constrain(lfoot, lknee, 20);
constrain(rknee, waist, 20);
constrain(rfoot, rknee, 20);
constrain(head, neck, 3.5);
_local1++;
}
}
function setup() {
constraints();
var _local2;
var _local3 = 0;
while (_local3 < joints.length) {
_local2 = this[joints[_local3]];
_local2.lx = _local2._x;
_local2.ly = _local2._y;
_local3++;
}
}
function drawblood(x, y) {
var _local2;
var _local1 = 0;
while (_local1 <= (random(30) + 3)) {
_local2 = attachMovie("Blood", "Blood" + blooddepth, blooddepth++);
_local2._x = x;
_local2._y = y;
_local1++;
}
}
function drawhead(col) {
var _local4 = 0;
var _local3 = 0;
var _local2 = 7;
head.beginFill(((col == undefined) ? 0 : (col)), 100);
head.moveTo(_local4 + _local2, _local3);
var _local1 = 0;
while (_local1 <= (Math.PI*2)) {
head.lineTo(_local4 + (Math.cos(_local1) * _local2), _local3 + (Math.sin(_local1) * _local2));
_local1 = _local1 + 0.0698131700797732;
}
head.endFill();
}
function draw(col) {
clear();
lineStyle(5, ((col == undefined) ? 0 : (col)), 100);
moveTo(lhand._x, lhand._y);
lineTo(lelbow._x, lelbow._y);
lineTo(neck._x, neck._y);
lineTo(relbow._x, relbow._y);
lineTo(rhand._x, rhand._y);
moveTo(neck._x, neck._y);
lineTo(waist._x, waist._y);
lineTo(lknee._x, lknee._y);
lineTo(lfoot._x, lfoot._y);
moveTo(waist._x, waist._y);
lineTo(rknee._x, rknee._y);
lineTo(rfoot._x, rfoot._y);
var _local2 = neck._x - head._x;
var _local1 = neck._y - head._y;
head._rotation = (Math.atan2(_local1, _local2) * 45) / Math.PI;
}
function onEnterFrame() {
update();
constraints();
collisions();
draw();
}
stop();
MovieClip.prototype.useHandCursor = false;
var dragging = null;
var blooddepth = 0;
var soundplaying = false;
var ragdollcolor = 0;
var joints = new Array("lhand", "lelbow", "rhand", "relbow", "neck", "waist", "lknee", "lfoot", "rknee", "rfoot", "head");
drawhead(ragdollcolor);
setup();
stop();
bounce = 50;
current = 0;
currentplus = 0.5;
currentdecrease = 0.5;
Instance of Symbol 96 MovieClip in Frame 5
onClipEvent (enterFrame) {
if (this.hitTest(_root.head)) {
_root.health.text++;
}
}
Instance of Symbol 99 MovieClip in Frame 5
onClipEvent (enterFrame) {
if (this.hitTest(_root.head)) {
_root.score.text++;
}
}
Frame 6
gotoAndPlay (1);
stop();
Symbol 1 MovieClip [Joint] Frame 1
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 40 Button
on (release) {
getURL ("http://www.newgrounds.com", "_blank");
}
Symbol 49 Button
on (release) {
_root.play();
}
Symbol 51 MovieClip Frame 1
_root.stop();
PercentLoaded = (_root.getBytesLoaded() / _root.getBytesTotal()) * 100;
if (PercentLoaded != 100) {
bar._xscale = PercentLoaded;
} else {
gotoAndStop ("loaded");
}
Symbol 51 MovieClip Frame 2
gotoAndPlay (1);
Symbol 61 Button
on (release) {
gotoAndStop (4);
}
Symbol 82 MovieClip Frame 1
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 2
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 3
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 4
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 5
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 6
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 7
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 8
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 9
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 82 MovieClip Frame 10
stop();
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 83 MovieClip Frame 1
function update() {
if (_root.dragging == this) {
xs = _root._xmouse - _x;
ys = _root._ymouse - _y;
} else {
xs = _x - lx;
ys = _y - ly;
}
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
if (_local3 > ms) {
xs = xs * (ms / _local3);
ys = ys * (ms / _local3);
}
if (Math.abs(xs) < 1) {
xs = 0;
}
if (Math.abs(ys) < 0.25) {
ys = 0;
}
lx = _x;
ly = _y;
_x = (_x + (xs * 0.94));
_y = (_y + (ys + 0.5));
}
function force() {
var _local3 = Math.sqrt((xs * xs) + (ys * ys));
return((_local3 >= 12) and (_root.dragging != this));
}
function collisions() {
var _local3 = false;
if (this._name != "headi") {
if (_root.boden.hitTest(this._x, this._y + 0.1, true)) {
_y = (_y - (ys + 0.5));
_local3 = true;
} else if (_y < 0) {
_y = 0;
_local3 = true;
}
if (_root.boden.hitTest(this._x + 0.1, this._y, true)) {
_x = (_x - (xs * 0.94));
_local3 = true;
} else if (_root.boden.hitTest(this._x - 0.1, this._y, true)) {
_x = (_x + (xs * 0.94));
_local3 = true;
}
} else {
var _local4 = _width / 2.5;
if (_root.boden.hitTest(this._x, this._y + 2.5, true)) {
_y = (_y - (ys + 2.5));
_local3 = true;
} else if (_y < _local4) {
_y = _local4;
_local3 = true;
}
if (_x > (640 - _local4)) {
_x = (640 - _local4);
_local3 = true;
} else if (_x < _local4) {
_x = _local4;
_local3 = true;
}
}
if (_local3) {
return(force());
}
return(false);
}
function onPress() {
_root.dragging = this;
}
function onRelease() {
_root.dragging = null;
}
var lx = _x;
var ly = _y;
var xs = 0;
var ys = 0;
var ms = 60;
var kl = {};
Key.addListener(kl);
kl.onKeyUp = function () {
var _local5 = Key.getCode();
if (_local5 == 32) {
var _local4 = _x - _root._xmouse;
var _local3 = _y - _root._ymouse;
var _local2 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
if (_local2 < 50) {
_x = (_x + ((_local4 / _local2) * ms));
_y = (_y + ((_local3 / _local2) * ms));
}
}
};
onReleaseOutside = onRelease;
Symbol 88 Button
on (press) {
_root.health.text = 0;
}
Symbol 89 Button
on (press) {
_root.score.text = 0;
}
Symbol 105 Button
on (release) {
gotoAndStop (3);
}
Symbol 112 Button
on (rollOver) {
_root.health.text = -100;
}
Symbol 113 Button
on (rollOver) {
_root.score.text = -100;
}
Symbol 115 Button
on (rollOver, rollOut, press, release, dragOut, dragOver, releaseOutside) {
_root.score.text = -100;
}