Frame 1
stop();
Frame 2
Engine.loadSounds();
Engine.playSound(Engine.SOUND_OFF_THE_WRIST_MUSIC, 1, 20);
Frame 58
gotoAndStop ("title");
Frame 59
stop();
Frame 60
stop();
Frame 61
stop();
Engine.main();
Frame 63
Symbol 80 MovieClip Frame 6
_visible = false;
Symbol 120 MovieClip Frame 58
stop();
Engine.dead();
Symbol 152 MovieClip Frame 61
Engine.win();
Symbol 155 MovieClip Frame 6
stop();
Symbol 156 MovieClip [allsequences] Frame 1
Symbol 162 MovieClip Frame 1
bytesLoaded = _root.getBytesLoaded();
bytesTotal = _root.getBytesTotal();
percentSetup = (bytesLoaded / bytesTotal) * 100;
percentage = int(percentSetup) + "%";
setProperty("_root.DropIn.LoaderBar", _xscale , percentSetup);
if (bytesLoaded == bytesTotal) {
_root.gotoAndPlay("splash");
}
Symbol 162 MovieClip Frame 2
if (bytesLoaded < bytesTotal) {
_root.DropIn.gotoAndPlay(1);
}
Symbol 228 MovieClip [__Packages.Engine] Frame 0
class Engine
{
static var text, levelText, scoreBox, dropShadow, lives, textAngle, textRadius, textAlpha, state, blurbclip1, blurbclip3, blurbclip2, ballX, ballY, endPos;
function Engine () {
}
static function main() {
if (!alreadyInitialised) {
alreadyInitialised = true;
text = ["DRINK UP!", "SPILT BEER", "BARRED", "OH FIDDLEDEEDEE"];
levelText = ["MINE'S A STOUT", "PASS THE PINT", "UP FOR THE CRAIC", "POT O' GOLD", "LUCKY CHARM"];
var _local3 = GRID_ACROSS;
while (_local3-- , _local3 >= 0) {
levelData[_local3] = new Array();
}
_local3 = 0;
while (_local3 < GRID_ACROSS) {
carrier[_local3] = new Array();
_local3++;
}
var _local2 = 0;
while (_local2 < GRID_DOWN) {
_local3 = 0;
while (_local3 < GRID_ACROSS) {
carrier[_local3][_local2] = new Carrier((("lepre" + _local3) + "_") + _local2, LEPRE_X_ORIGIN + (_local3 * LEPRE_X_SPACE), LEPRE_Y_ORIGIN + (_local2 * LEPRE_Y_SPACE), _local3, _local2);
_local3++;
}
_local2++;
}
var _local6 = new TextFormat("font", FONT_SIZE, 16777215);
_local6.align = "right";
scoreBox = _root.createTextField("scorefield", _root.getNextHighestDepth(), SCORES_X, SCORE_Y, SCORE_WIDTH, SCORE_HEIGHT);
scoreBox.setNewTextFormat(_local6);
scoreBox.selectable = false;
scoreBox.embedFonts = true;
var _local4 = new TextFormat("font", MESSAGE_SIZE, 16777215);
_local4.align = "center";
dropShadow = _root.createTextField("textfield", _root.getNextHighestDepth(), 320, 240, SCREEN_WIDTH, FONT_SIZE * 2);
dropShadow.setNewTextFormat(_local4);
dropShadow.selectable = false;
dropShadow.embedFonts = true;
dropShadow.textColor = 0;
dropShadow._alpha = 0;
_local3 = 2;
while (_local3-- , _local3 >= 0) {
textBox[_local3] = _root.createTextField("textfield", _root.getNextHighestDepth(), 320, 240, SCREEN_WIDTH, FONT_SIZE * 2);
textBox[_local3].setNewTextFormat(_local4);
textBox[_local3].selectable = false;
textBox[_local3].embedFonts = true;
textBox[_local3]._alpha = 0;
}
_local3 = MAX_LIVES;
while (_local3-- , _local3 >= 0) {
livesIcon[_local3] = _root.attachMovie("lifepint", "life" + _local3, _root.getNextHighestDepth());
livesIcon[_local3]._x = LIVES_X;
livesIcon[_local3]._y = (LIVES_Y + ((MAX_LIVES - 1) * LIVES_SPACING)) - (_local3 * LIVES_SPACING);
livesIcon[_local3].gotoAndStop(FRAME_ALIVE);
}
var _local5 = _root.createEmptyMovieClip("update", _root.getNextHighestDepth());
_local5.onEnterFrame = function () {
Engine.update();
};
_local5.onMouseDown = function () {
Engine.mouseDown();
};
_local5.onMouseUp = function () {
Engine.mouseUp();
};
_local5.onKeyDown = function () {
Engine.keyDown(Key.getCode());
};
Key.addListener(_local5);
} else {
scoreBox._visible = true;
var _local3 = MAX_LIVES;
while (_local3-- , _local3 >= 0) {
livesIcon[_local3]._visible = true;
}
}
_root.i_sound_off._visible = !soundOn;
if (soundOn) {
startSound();
}
newGame();
loadLevel(0);
}
static function newGame() {
score = 0;
lives = MAX_LIVES;
updateStatus();
}
static function update() {
var _local5 = GRID_ACROSS;
while (_local5-- , _local5 >= 0) {
var _local4 = GRID_DOWN;
while (_local4-- , _local4 >= 0) {
carrier[_local5][_local4].update();
}
}
if (textCounter > 0) {
if (textCounter > (MESSAGE_FADEOUT + MESSAGE_PAUSE)) {
textAngle = textAngle + MESSAGE_ANGULAR_VELOCITY;
textRadius = textRadius - MESSAGE_RADIAL_VELOCITY;
textAlpha = textAlpha + MESSAGE_ALPHA_FADE_SPEED;
} else if (textCounter > MESSAGE_FADEOUT) {
textAlpha = textAlpha + MESSAGE_ALPHA_FADE_SPEED;
dropShadow._alpha = 255;
} else {
textAngle = textAngle + MESSAGE_ANGULAR_VELOCITY;
textRadius = textRadius + MESSAGE_RADIAL_VELOCITY;
textAlpha = textAlpha - (4 * MESSAGE_ALPHA_FADE_SPEED);
dropShadow._alpha = 0;
}
var _local10 = (textRadius * MESSAGE_YSCALE) * Math.sin(textAngle * TO_RADIANS);
var _local11 = (textRadius * MESSAGE_XSCALE) * Math.cos(textAngle * TO_RADIANS);
textBox[0]._alpha = textAlpha;
textBox[1]._alpha = textAlpha;
textBox[0]._x = MESSAGE_X_ORIGIN + _local11;
textBox[1]._x = MESSAGE_X_ORIGIN - _local11;
textBox[0]._y = MESSAGE_Y_ORIGIN + _local10;
textBox[1]._y = MESSAGE_Y_ORIGIN - _local10;
textCounter--;
} else if (textCounter == 0) {
if (state == LOST) {
setCarriersVisible(false);
scoreBox._visible = false;
_local5 = MAX_LIVES;
while (_local5-- , _local5 >= 0) {
livesIcon[_local5]._visible = false;
}
var _local12 = new TextFormat("font", FONT_SIZE, 16777215);
_root.gotoAndStop("scoreframe");
if (HISCORES) {
} else {
var _local9 = new TextFormat("font", FONT_SIZE, 16777215);
_local9.align = "center";
blurbclip1 = _root.createEmptyMovieClip("bclip1", _root.getNextHighestDepth());
blurbclip3 = _root.createEmptyMovieClip("bclip3", _root.getNextHighestDepth());
blurbclip2 = _root.createEmptyMovieClip("bclip2", _root.getNextHighestDepth());
var _local7 = blurbclip1.createTextField("blurbfield1", _root.getNextHighestDepth(), 5, 50, 280, 240);
var _local6 = blurbclip2.createTextField("blurbfield2", _root.getNextHighestDepth(), 5, (50 + FONT_SIZE) + 2, 280, 240);
var _local8 = blurbclip3.createTextField("blurbfield3", _root.getNextHighestDepth(), 5, 50 + (2 * (FONT_SIZE + 2)), 280, 240);
_local7.setNewTextFormat(_local9);
_local6.setNewTextFormat(_local9);
_local8.setNewTextFormat(_local9);
_local7.selectable = false;
_local6.selectable = false;
_local8.selectable = false;
_local7.embedFonts = true;
_local6.embedFonts = true;
_local8.embedFonts = true;
_local7.wordWrap = true;
_local6.wordWrap = true;
_local8.wordWrap = true;
_local7.autoSize = "left";
_local6.autoSize = "left";
_local8.autoSize = "left";
_local6.textColor = 7829503 /* 0x7777FF */;
_local7.text = "Visit";
_local6.text = "www.offthewrist.com";
_local8.text = "to play the full version with a high score table.";
blurbclip2.onRelease = function () {
getURL ("http://www.offthewrist.com/index.jsp?content=/passpint/passpint.html");
};
}
} else if (state == START) {
var _local3 = 0;
while (_local3 < GRID_DOWN) {
var _local2 = 0;
while (_local2 < GRID_ACROSS) {
if (levelData[_local2][_local3] == DECAYED) {
carrier[_local2][_local3].active = false;
carrier[_local2][_local3].state = DECAYED;
} else {
carrier[_local2][_local3].init();
}
_local2++;
}
_local3++;
}
state = APPEAR;
textCounter = 7;
} else if (state == APPEAR) {
var _local3 = 0;
while (_local3 < GRID_DOWN) {
var _local2 = 0;
while (_local2 < GRID_ACROSS) {
switch (levelData[_local2][_local3]) {
case STRONG :
carrier[_local2][_local3].setStrong();
break;
case STRONGBALL :
carrier[_local2][_local3].setStrong();
ballX = _local2;
ballY = _local3;
carrier[ballX][ballY].hasBallDirection(UP);
break;
case WEAK :
carrier[_local2][_local3].setWeak();
break;
case WEAKBALL :
carrier[_local2][_local3].setWeak();
ballX = _local2;
ballY = _local3;
carrier[ballX][ballY].hasBallDirection(UP);
}
_local2++;
}
_local3++;
}
state = GAME;
}
textCounter--;
}
}
static function closeBlurb() {
blurbclip1.removeMovieClip();
blurbclip2.removeMovieClip();
blurbclip3.removeMovieClip();
notifyHighScoresClosed();
}
static function updateStatus() {
scoreBox.text = "" + score;
var _local1 = MAX_LIVES;
while (_local1-- , _local1 >= 0) {
if (_local1 <= (lives - 1)) {
livesIcon[_local1].gotoAndStop(FRAME_ALIVE);
} else {
livesIcon[_local1].gotoAndStop(FRAME_DEAD);
}
}
}
static function mouseDown() {
var _local5 = _root._xmouse;
var _local4 = _root._ymouse;
if (!(state === GAME)) {
} else {
var _local2 = Math.floor((_local5 - LEPRE_X_ORIGIN) / LEPRE_X_SPACE);
var _local3 = Math.floor((_local4 - LEPRE_Y_ORIGIN) / LEPRE_Y_SPACE) + 1;
if ((((_local2 >= 0) && (_local2 < GRID_ACROSS)) && (_local3 >= 0)) && (_local3 < GRID_DOWN)) {
if (_local2 == ballX) {
if (_local3 == (ballY - 1)) {
keyDown(38);
} else if (_local3 == (ballY + 1)) {
keyDown(40);
}
} else if (_local3 == ballY) {
if (_local2 == (ballX - 1)) {
keyDown(37);
} else if (_local2 == (ballX + 1)) {
keyDown(39);
}
}
}
}
}
static function loadSounds() {
var _local2 = 0;
while (_local2 < SOUNDCOUNT) {
var _local3 = _root.createEmptyMovieClip("sclip" + _local2, _root.getNextHighestDepth());
sounds[_local2] = new Sound(_local3);
sounds[_local2].attachSound("sound" + _local2);
_local2++;
}
}
static function playSound(i, loop, volume) {
if (soundOn) {
if (volume != undefined) {
sounds[i].setVolume(volume);
}
sounds[i].start(0, loop);
}
}
static function stopAllSound() {
var _local1 = 0;
while (_local1 < SOUNDCOUNT) {
sounds[_local1].stop();
_local1++;
}
musicPlaying = false;
}
static function startSound() {
if (!musicPlaying) {
musicPlaying = true;
playSound(SOUND_MUSIC, 1000, 20);
}
}
static function mouseUp() {
}
static function keyDown(code) {
if (state == GAME) {
switch (code) {
case 38 :
if (ballY > 0) {
if (carrier[ballX][ballY - 1].isActive()) {
carrier[ballX][ballY].passesBall(UP);
ballY--;
carrier[ballX][ballY].hasBallDirection(DOWN);
checkMoves();
}
}
break;
case 39 :
if (ballX < (GRID_ACROSS - 1)) {
if (carrier[ballX + 1][ballY].isActive()) {
carrier[ballX][ballY].passesBall(RIGHT);
ballX++;
carrier[ballX][ballY].hasBallDirection(LEFT);
checkMoves();
}
}
break;
case 40 :
if (ballY < (GRID_DOWN - 1)) {
if (carrier[ballX][ballY + 1].isActive()) {
carrier[ballX][ballY].passesBall(DOWN);
ballY++;
carrier[ballX][ballY].hasBallDirection(UP);
checkMoves();
}
}
break;
case 37 :
if (ballX <= 0) {
break;
}
if (!carrier[ballX - 1][ballY].isActive()) {
break;
}
carrier[ballX][ballY].passesBall(LEFT);
ballX--;
carrier[ballX][ballY].hasBallDirection(RIGHT);
checkMoves();
}
}
}
static function initFallingText(line) {
textBox[0].text = line;
textBox[1].text = line;
dropShadow.text = line;
dropShadow._alpha = 0;
dropShadow._x = MESSAGE_X_ORIGIN + 4;
dropShadow._y = MESSAGE_Y_ORIGIN + 4;
var _local2 = textBox[0].textWidth;
var _local3 = textBox[0].textHeight;
textAlpha = 0;
textRadius = SCREEN_WIDTH / 200;
MESSAGE_RADIAL_VELOCITY = textRadius / MESSAGE_FADEIN;
textAngle = 0;
textCounter = (MESSAGE_FADEOUT + MESSAGE_PAUSE) + MESSAGE_FADEIN;
}
static function dead() {
state = LOST;
lives--;
updateStatus();
if (lives <= 0) {
initFallingText(text[TEXT_DEAD]);
} else {
setCarriersVisible(false);
loadLevel(0);
}
}
static function win() {
nextLevel();
}
static function setCarriersVisible(flag) {
var _local2 = 0;
while (_local2 < GRID_ACROSS) {
var _local1 = 0;
while (_local1 < GRID_DOWN) {
carrier[_local2][_local1].sprite._visible = flag;
_local1++;
}
_local2++;
}
}
static function nextLevel() {
score = score + COMPLETE_SCORE;
updateStatus();
setCarriersVisible(false);
loadLevel(0);
}
static function loadLevel(code) {
if (code == 0) {
randomLevel();
}
initFallingText(levelText[rndInt(levelText.length)]);
state = START;
}
static function randomLevel() {
var _local2 = 0;
while (_local2 < GRID_ACROSS) {
var _local1 = 0;
while (_local1 < GRID_DOWN) {
levelData[_local2][_local1] = DECAYED;
_local1++;
}
_local2++;
}
_local2 = rndInt(GRID_ACROSS);
var _local1 = rndInt(GRID_DOWN);
var _local5;
var _local3 = 40;
var _local6 = false;
var _local4;
while (_local3 > 0) {
do {
_local5 = rndInt(4);
_local3--;
_local4 = canMoveRandom(_local2, _local1, _local5);
} while ((!_local4) && (_local3 > 0));
if (_local4) {
switch (_local5) {
case LEFT :
_local2--;
break;
case RIGHT :
_local2++;
break;
case UP :
_local1--;
break;
case DOWN :
_local1++;
}
if (levelData[_local2][_local1] == WEAK) {
levelData[_local2][_local1] = STRONG;
} else if (levelData[_local2][_local1] == DECAYED) {
levelData[_local2][_local1] = WEAK;
}
if (!_local6) {
endPos = _local2 + (_local1 * GRID_ACROSS);
_local6 = true;
}
}
}
if (levelData[_local2][_local1] == WEAK) {
levelData[_local2][_local1] = WEAKBALL;
} else if (levelData[_local2][_local1] == STRONG) {
levelData[_local2][_local1] = STRONGBALL;
}
}
static function canMoveRandom(x, y, direction) {
if ((x == 0) && (direction == LEFT)) {
return(false);
}
if ((y == 0) && (direction == UP)) {
return(false);
}
if ((x == (GRID_ACROSS - 1)) && (direction == RIGHT)) {
return(false);
}
if ((y == (GRID_DOWN - 1)) && (direction == DOWN)) {
return(false);
}
if ((direction == LEFT) && ((levelData[x - 1][y] == DECAYED) || (levelData[x - 1][y] == WEAK))) {
return(true);
}
if ((direction == RIGHT) && ((levelData[x + 1][y] == DECAYED) || (levelData[x + 1][y] == WEAK))) {
return(true);
}
if ((direction == UP) && ((levelData[x][y - 1] == DECAYED) || (levelData[x][y - 1] == WEAK))) {
return(true);
}
if ((direction == DOWN) && ((levelData[x][y + 1] == DECAYED) || (levelData[x][y + 1] == WEAK))) {
return(true);
}
return(false);
}
static function checkMoves() {
score = score + PASS_SCORE;
updateStatus();
if (!canMove()) {
var _local2 = 0;
while (_local2 < GRID_ACROSS) {
var _local1 = 0;
while (_local1 < GRID_DOWN) {
if ((_local2 != ballX) || (_local1 != ballY)) {
if (carrier[_local2][_local1].isActive()) {
carrier[ballX][ballY].eaten();
return(undefined);
}
}
_local1++;
}
_local2++;
}
carrier[ballX][ballY].won();
}
}
static function canMove() {
if (ballY > 0) {
if (carrier[ballX][ballY - 1].isActive()) {
return(true);
}
}
if (ballX > 0) {
if (carrier[ballX - 1][ballY].isActive()) {
return(true);
}
}
if (ballY < (GRID_DOWN - 1)) {
if (carrier[ballX][ballY + 1].isActive()) {
return(true);
}
}
if (ballX < (GRID_ACROSS - 1)) {
if (carrier[ballX + 1][ballY].isActive()) {
return(true);
}
}
return(false);
}
static function rndInt(range) {
return(Math.floor((Math.random() * range) - 0.001));
}
static function notifyTextFinished(text) {
}
static function notifyHighScoresClosed() {
_root.gotoAndPlay("gameFrame");
}
static var HISCORES = false;
static var SCREEN_WIDTH = 640;
static var SCREEN_HEIGHT = 480;
static var INIT = 0;
static var GAME = 1;
static var LOST = 2;
static var START = 3;
static var APPEAR = 4;
static var alreadyInitialised = false;
static var GRID_ACROSS = 6;
static var GRID_DOWN = 4;
static var LEPRE_X_ORIGIN = 0;
static var LEPRE_Y_ORIGIN = 180;
static var LEPRE_X_SPACE = 90;
static var LEPRE_Y_SPACE = 90;
static var carrier = new Array();
static var score = 0;
static var PASS_SCORE = 1;
static var COMPLETE_SCORE = 10;
static var FONT_SIZE = 18;
static var SCORES_X = 32;
static var SCORE_Y = 22;
static var SCORE_WIDTH = 108;
static var SCORE_HEIGHT = 24;
static var MAX_LIVES = 3;
static var livesIcon = new Array();
static var LIVES_X = 567;
static var LIVES_Y = 154;
static var LIVES_SPACING = 99;
static var FRAME_ALIVE = 1;
static var FRAME_DEAD = 2;
static var levelData = new Array();
static var STRONG = 0;
static var STRONGBALL = 1;
static var WEAK = 2;
static var WEAKBALL = 3;
static var DECAYED = 4;
static var TEXT_WON = 0;
static var TEXT_LOST = 1;
static var TEXT_DEAD = 2;
static var TEXT_GIVEUP = 3;
static var textBox = new Array();
static var textCounter = 0;
static var TEXT_WAIT = 12;
static var TEXT_SPEED = 20;
static var MESSAGE_SIZE = 40;
static var MESSAGE_ANGULAR_VELOCITY = 20;
static var MESSAGE_FADEIN = 12;
static var MESSAGE_PAUSE = 18;
static var MESSAGE_FADEOUT = 9;
static var MESSAGE_ALPHA_FADE_SPEED = 50 / MESSAGE_FADEIN;
static var MESSAGE_RADIAL_VELOCITY = SCREEN_WIDTH / MESSAGE_FADEIN;
static var MESSAGE_XSCALE = 10;
static var MESSAGE_YSCALE = 1;
static var MESSAGE_X_ORIGIN = 270 - (SCREEN_WIDTH / 2);
static var MESSAGE_Y_ORIGIN = 180;
static var MESSAGE_BG_COLOUR = 0;
static var TO_RADIANS = (Math.PI/180);
static var UP = 0;
static var DOWN = 1;
static var LEFT = 2;
static var RIGHT = 3;
static var GAME_ID = 3;
static var GAME_NAME = "passpint";
static var COLOUR_SCORE_0 = 2171937;
static var COLOUR_SCORE_1 = 2171937;
static var COLOUR_SCORE_BORDER = 8651776;
static var sounds = new Array();
static var soundOn = true;
static var musicPlaying = false;
static var SOUNDCOUNT = 8;
static var SOUND_OFF_THE_WRIST_MUSIC = 0;
static var SOUND_MUSIC = 1;
static var SOUND_WON = 2;
static var SOUND_DEAD = 3;
static var SOUND_PASS_STRONG = 4;
static var SOUND_PASS_WEAK = 5;
static var SOUND_PASS_STRONG2 = 6;
static var SOUND_PASS_WEAK2 = 7;
}
Symbol 229 MovieClip [__Packages.Carrier] Frame 0
class Carrier
{
var name, xIndex, yIndex, sprite, alt, hasBall, active, winCount, eatenDelay, count, state, wonDelay;
function Carrier (myname, posX, posY, ix, iy) {
name = myname;
xIndex = ix;
yIndex = iy;
sprite = _root.attachMovie("allsequences", name, _root.getNextHighestDepth());
sprite.gotoAndStop(1);
sprite._x = posX;
sprite._y = posY;
alt = ((xIndex + (yIndex * (Engine.GRID_ACROSS + 1))) % 2) == 0;
hasBall = false;
active = false;
winCount = 0;
sprite._visible = false;
}
function init() {
eatenDelay = 0;
active = true;
count = 0;
sprite._visible = true;
sprite.gotoAndStop(ANIM_APPEARING);
}
function update() {
switch (state) {
case WEAKPASSING :
case STRONGPASSING :
snap();
}
if (eatenDelay > 0) {
eatenDelay--;
if (eatenDelay == 0) {
Engine.playSound(Engine.SOUND_DEAD, 1, 100);
Engine.initFallingText(Engine.text[Engine.TEXT_LOST]);
sprite.gotoAndStop(ANIM_LOST);
state = LOST;
}
}
if (wonDelay > 0) {
wonDelay--;
if (wonDelay == 0) {
Engine.playSound(Engine.SOUND_WON, 1, 100);
Engine.initFallingText(Engine.text[Engine.TEXT_WON]);
sprite.gotoAndStop(ANIM_WON);
state = WON;
}
}
}
function setStrong() {
state = STRONG;
if (alt) {
sprite.gotoAndStop(ANIM_STRONG1);
} else {
sprite.gotoAndStop(ANIM_STRONG2);
}
}
function setWeak() {
state = WEAK;
if (alt) {
sprite.gotoAndStop(ANIM_WEAK1);
} else {
sprite.gotoAndStop(ANIM_WEAK2);
}
}
function hasBallDirection(dir) {
if (state == WEAK) {
state = WEAKPASSING;
} else if (state == STRONG) {
state = STRONGPASSING;
}
switch (dir) {
case Engine.UP :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGBOT));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGBOT));// not popped
}
break;
case Engine.DOWN :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGTOP));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGTOP));// not popped
}
break;
case Engine.LEFT :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGRIGHT));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGRIGHT));// not popped
}
break;
case Engine.RIGHT :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGLEFT));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGLEFT));// not popped
}
}
hasBall = true;
}
function isActive() {
return(active);
}
function passesBall(dir) {
if ((state == WEAKHASBALL) || (state == WEAKPASSING)) {
if (alt) {
Engine.playSound(Engine.SOUND_PASS_WEAK, 1, 100);
} else {
Engine.playSound(Engine.SOUND_PASS_WEAK2, 1, 100);
}
state = WEAKPASSING;
active = false;
} else if ((state == STRONGHASBALL) || (state == STRONGPASSING)) {
if (alt) {
Engine.playSound(Engine.SOUND_PASS_STRONG, 1, 100);
} else {
Engine.playSound(Engine.SOUND_PASS_STRONG2, 1, 100);
}
state = STRONGPASSING;
}
switch (dir) {
case Engine.UP :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGBOT));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGBOT));// not popped
}
break;
case Engine.DOWN :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGTOP));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGTOP));// not popped
}
break;
case Engine.LEFT :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGRIGHT));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGRIGHT));// not popped
}
break;
case Engine.RIGHT :
if (state != STRONGPASSING) {
(sprite.gotoAndStop(ANIM_WEAKPASSINGLEFT));// not popped
} else {
(sprite.gotoAndStop(ANIM_STRONGPASSINGLEFT));// not popped
}
}
hasBall = false;
}
function fallOver() {
sprite.gotoAndStop(ANIM_DECAYING);
state = DECAYING;
active = false;
}
function eaten() {
eatenDelay = 22;
}
function won() {
wonDelay = 15;
}
function snap() {
if (hasBall) {
if (state == WEAKPASSING) {
state = WEAKHASBALL;
sprite.gotoAndStop(ANIM_WEAKHASBALL);
} else {
state = STRONGHASBALL;
sprite.gotoAndStop(ANIM_STRONGHASBALL);
}
} else if (state == WEAKPASSING) {
fallOver();
} else {
setWeak();
}
}
static var STRONG = 0;
static var WEAK = 1;
static var STRONGHASBALL = 2;
static var WEAKHASBALL = 3;
static var STRONGPASSING = 4;
static var WEAKPASSING = 5;
static var DECAYING = 6;
static var LOST = 7;
static var WON = 8;
static var ANIM_STRONG1 = 1;
static var ANIM_STRONGHASBALL = 2;
static var ANIM_STRONGPASSINGBOT = 3;
static var ANIM_STRONGPASSINGTOP = 4;
static var ANIM_STRONGPASSINGRIGHT = 5;
static var ANIM_STRONGPASSINGLEFT = 6;
static var ANIM_WEAK1 = 7;
static var ANIM_WEAKHASBALL = 8;
static var ANIM_WEAKPASSINGBOT = 9;
static var ANIM_WEAKPASSINGTOP = 10;
static var ANIM_WEAKPASSINGRIGHT = 11;
static var ANIM_WEAKPASSINGLEFT = 12;
static var ANIM_DECAYING = 13;
static var ANIM_LOST = 14;
static var ANIM_WON = 15;
static var ANIM_STRONG2 = 16;
static var ANIM_WEAK2 = 17;
static var ANIM_APPEARING = 18;
}
Symbol 183 Button
on (release) {
gotoAndStop (60);
}
Symbol 203 Button
on (release) {
gotoAndStop (61);
}
Symbol 205 Button
on (press) {
if (Engine.soundOn) {
Engine.stopAllSound();
Engine.soundOn = false;
_root.i_sound_off._visible = true;
} else {
Engine.soundOn = true;
Engine.startSound();
_root.i_sound_off._visible = false;
}
}
Symbol 209 Button
on (release) {
getURL ("http://www.offthewrist.com");
}
Symbol 215 Button
on (release) {
Engine.closeBlurb();
}
Symbol 218 Button
on (release) {
getURL ("http://frenzy.morpheme.co.uk/frenzy/index.jsp?gameId=0");
}
Symbol 221 Button
on (release) {
getURL ("http://frenzy.morpheme.co.uk/frenzy/index.jsp?gameId=2");
}
Symbol 224 Button
on (release) {
getURL ("http://www.offthewrist.com/index.jsp?content=bhb.htm");
}
Symbol 227 Button
on (release) {
getURL ("http://www.offthewrist.com/index.jsp?content=pooch.htm");
}