Combined Code
frame 1 {
var animtest = random(2) + 1;
_root.onEnterFrame = function () {
posX = _root._xmouse;
posY = _root._ymouse;
if (freeze == 0) {
dragon._x += (posX - dragon._x) * 0.15;
dragon._y += (posY - dragon._y) * 0.15;
moveX = dragon._x - otter._x;
if (moveX > 0 & moveX < 20) {
moveX = 20;
}
if (moveX < 0 & moveX > -20) {
moveX = -20;
}
newX = otter._x + moveX * -1 * 0.015;
if (newX <= 20) {
newX = 21;
}
if (newX >= 620) {
newX = 619;
}
otter._x = newX;
moveY = dragon._y - otter._y;
if (moveY > 0 & moveY < 20) {
moveY = 20;
}
if (moveY < 0 & moveY > -20) {
moveY = -20;
}
newY = otter._y + moveY * -1 * 0.015;
if (newY <= 20) {
newY = 21;
}
if (newY >= 460) {
newY = 459;
}
otter._y = newY;
xDiff = dragon._x - otter._x;
yDiff = dragon._y - otter._y;
dist = Math.sqrt(xDiff * xDiff + yDiff * yDiff);
dir = Math.atan2(yDiff, xDiff);
d = dir < 3.141593 ? dir * 180 / 3.141593 : (dir - 6.283185) * 180 / 3.141593;
if (d > otter._rotation) {
if (d - otter._rotation > 180) {
d -= 360;
}
} else {
if (otter._rotation - d > 180) {
d += 360;
}
}
eval(otter)._rotation = otter._rotation + (d - otter._rotation) / 1;
xDiff2 = posX - dragon._x;
yDiff2 = posY - dragon._y;
dist = Math.sqrt(xDiff2 * xDiff2 + yDiff2 * yDiff2);
dir = Math.atan2(yDiff2, xDiff2);
d = dir < 3.141593 ? dir * 180 / 3.141593 : (dir - 6.283185) * 180 / 3.141593;
if (d > dragon._rotation) {
if (d - dragon._rotation > 180) {
d -= 360;
}
} else {
if (dragon._rotation - d > 180) {
d += 360;
}
}
eval(dragon)._rotation = dragon._rotation + (d - dragon._rotation) / 1;
}
if (dragon.collisionbox.hitTest(otter) && freeze == 0) {
nomnom._x = dragon._x;
nomnom._y = dragon._y;
freeze = 1;
otter.gotoAndPlay('Stop');
if (animtest == 1) {
dragon.gotoAndPlay('Swallow');
nomnom.gotoAndPlay('Nom');
} else {
if (animtest == 2) {
dragon.gotoAndPlay('Hump');
nomnom.gotoAndPlay('Unf');
}
}
if (dragon._x > otter._x) {
dragon._yscale = -100;
otter._yscale = -52.2;
} else {
dragon._yscale = 100;
otter._yscale = 52.2;
}
}
};
playbutton.onRelease = function () {
gotoAndPlay(3);
};
mc_clickbox.onRelease = function () {
if (animtest == 1) {
animtest = 2;
} else {
if (animtest == 2) {
animtest = 1;
}
}
};
}
movieClip 2 {
}
movieClip 5 {
}
// unknown tag 88 length 80
button 8 {
on (release) {
_parent._parent.play();
}
}
movieClip 9 {
}
movieClip 10 {
frame 1 {
if (initial == undefined) {
_parent.stop();
initial = true;
}
loaded = _parent.getBytesLoaded() / _parent.getBytesTotal();
total = progress._totalframes;
progress.gotoAndStop(Math.round(total * loaded));
}
instance progress of movieClip 9 {
onClipEvent (load) {
stop();
}
}
}
instance of movieClip 10 {
onClipEvent (construct) {
loadMessage = 'Loading movie...';
}
}
movieClip 13 {
}
movieClip 14 {
frame 110 {
stop();
}
}
movieClip 19 {
frame 9 {
gotoAndPlay(1);
}
frame 10 {
stop();
}
}
movieClip 22 {
}
movieClip 71 {
frame 1 {
_root.freeze = 0;
}
frame 9 {
gotoAndPlay(1);
}
frame 48 {
_root.otter._x = random(640) + 21;
_root.otter._y = random(480) + 21;
_root.otter.play();
_root.freeze = 0;
_root.pop._x = _root.otter._x;
_root.pop._y = _root.otter._y;
_root.pop.gotoAndPlay(2);
gotoAndPlay(1);
}
frame 101 {
_root.otter._x = random(640) + 21;
_root.otter._y = random(480) + 21;
_root.otter.play();
_root.freeze = 0;
_root.pop._x = _root.otter._x;
_root.pop._y = _root.otter._y;
_root.pop.gotoAndPlay(2);
gotoAndPlay(1);
}
}
movieClip 76 {
frame 1 {
stop();
}
frame 36 {
gotoAndPlay(1);
}
frame 71 {
gotoAndPlay(1);
}
}
movieClip 82 {
frame 1 {
stop();
}
}
frame 3 {
stop();
}
movieClip 94 {
}
movieClip 145 {
frame 834 {
_root.gotoAndPlay(4);
}
}
frame 4 {
stop();
}
movieClip 335 {
frame 1833 {
_root.gotoAndPlay(5);
}
}
frame 5 {
stop();
}
movieClip 462 {
frame 1354 {
if (_root.animtest == 1) {
_root.gotoAndPlay(6);
} else {
if (_root.animtest == 2) {
_root.gotoAndPlay(7);
}
}
}
}
frame 6 {
stop();
}
movieClip 559 {
frame 1009 {
_root.gotoAndPlay(8);
}
}
frame 7 {
stop();
}
movieClip 726 {
}
movieClip 727 {
frame 1726 {
_root.gotoAndPlay(8);
}
}
frame 8 {
stop();
mc_tips.onRollOut = function () {
mc_tips.gotoAndStop(1);
};
mc_tips.onRollOver = function () {
mc_tips.gotoAndPlay(2);
};
mc_tips.onRelease = function () {
getURL('https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=6220244', _blank);
};
mc_hump.onRollOver = function () {
mc_hump.gotoAndStop(2);
};
mc_hump.onRollOut = function () {
mc_hump.gotoAndStop(1);
};
mc_eat.onRollOver = function () {
mc_eat.gotoAndStop(2);
};
mc_eat.onRollOut = function () {
mc_eat.gotoAndStop(1);
};
mc_fox.onRollOver = function () {
mc_fox.gotoAndStop(2);
};
mc_fox.onRollOut = function () {
mc_fox.gotoAndStop(1);
};
}
movieClip 731 {
frame 1 {
onRelease = function () {
_root.gotoAndPlay(6);
};
stop();
}
}
movieClip 733 {
frame 1 {
onRelease = function () {
_root.gotoAndPlay(7);
};
stop();
}
}
movieClip 738 {
frame 1 {
stop();
}
frame 4 {
stop();
}
}
movieClip 740 {
frame 1 {
onRelease = function () {
_root.gotoAndPlay(9);
};
stop();
}
}
button 744 {
on (release) {
gotoAndPlay(1);
}
}
button 747 {
on (release) {
getURL('http://www.furaffinity.net/user/slate/', '');
}
}
movieClip 749 {
}
frame 9 {
stop();
}
movieClip 764 {
frame 180 {
_root.gotoAndPlay(8);
}
}
frame 5326 {
stop();
}
button 765 {
on (release) {
gotoAndPlay(3);
}
}
button 767 {
on (release) {
getURL('http://www.furaffinity.net/user/info/slate/', '');
}
}