Frame 1
amtLoaded = _root._framesLoaded / _root._totalFrames;
_root.bar._width = amtLoaded * _root.meter._width;
lastAte = 0;
lastPlayed = 0;
_root.money = 100;
twitch = 0;
prevy = _root.person._y;
prevx = _root.person._x;
prevrot = 0;
numTanks = 1;
numKills = 3;
phone = 0;
nextPhone = (5 + random(50)) * 12;
CID = false;
TV = false;
finalEat = 2412;
finalPlayed = 2400;
numTanks = 1;
numKills = 1;
bet = 5;
if (!defaultsSet) {
defaultsSet = true;
SpeedKey = Key.DELETEKEY;
RotUpKey = Key.HOME;
RotDownKey = Key.END;
FireKey = Key.INSERT;
UpKey = Key.UP;
DownKey = Key.DOWN;
LeftKey = Key.LEFT;
RightKey = Key.RIGHT;
}
Frame 2
if (amtLoaded < 1) {
gotoAndPlay (1);
}
Frame 3
stop();
Frame 4
open = false;
_root.sofa.lounger._visible = false;
i = 2;
while (numTanks >= i) {
_root["enemy" + i].removeMovieClip();
_root["bullet" + i].removeMovieClip();
i++;
}
if (TV) {
_root.television._visible = true;
} else {
_root.television._visible = false;
}
enemiesDestroyed = 0;
_root.person._x = prevx;
_root.person._y = prevy;
_root.person._rotation = prevrot;
computer = false;
Frame 5
if (!lounging) {
if (Key.isDown(Key.SHIFT)) {
moveSpeed = 9;
if (((Key.isDown(Key.UP) || (Key.isDown(Key.DOWN))) || (Key.isDown(Key.LEFT))) || (Key.isDown(Key.RIGHT))) {
_root.person.nextFrame();
}
} else {
moveSpeed = 6;
}
if (Key.isDown(Key.UP) && (_root.floor.getBounds(_root).yMin < _root.person.getBounds(_root).yMin)) {
_root.person._rotation = 90;
_root.person.nextFrame();
_root.person._y = _root.person._y - moveSpeed;
} else if (Key.isDown(Key.DOWN) && (_root.person.getBounds(_root).yMax < _root.floor.getBounds(_root).yMax)) {
_root.person._rotation = 270;
_root.person.nextFrame();
_root.person._y = _root.person._y + moveSpeed;
} else if (Key.isDown(Key.RIGHT) && (_root.person.getBounds(_root).xMax < _root.floor.getBounds(_root).xMax)) {
_root.person._rotation = 180;
_root.person.nextFrame();
_root.person._x = _root.person._x + moveSpeed;
} else if (Key.isDown(Key.LEFT) && (_root.floor.getBounds(_root).xMin < _root.person.getBounds(_root).xMin)) {
_root.person._rotation = 0;
_root.person.nextFrame();
_root.person._x = _root.person._x - moveSpeed;
}
} else if (Key.isDown(Key.LEFT)) {
_root.person._rotation = 0;
_root.person.nextFrame();
_root.person._y = 320;
playedLoungin = false;
}
if (_root.person.hitTest(_root.fridge)) {
_root.gotoAndPlay("fridge");
} else if (_root.person.hitTest(_root.desk)) {
gotoAndPlay (110);
} else if (((_root.money >= 2000) && (_root.TV)) && (_root.cID)) {
gotoAndPlay (231);
} else if (-100 >= money) {
gotoAndPlay (169);
} else if (phone >= nextPhone) {
gotoAndPlay (98);
} else {
prevx = _root.person._x;
prevy = _root.person._y;
prevrot = _root.person._rotation;
}
if ((lastPlayed % 720) == 0) {
twitch++;
}
_root.person._x = _root.person._x + random(twitch);
_root.person._y = _root.person._y + random(twitch);
_root.person._x = _root.person._x - random(twitch);
_root.person._y = _root.person._y - random(twitch);
if (_root.person.hitTest(_root.sofa)) {
_root.person._visible = false;
_root.sofa.lounger._visible = true;
lounging = true;
if (!playedLoungin) {
playedLoungin = true;
loungeSound = new Sound();
loungeSound.attachSound("loungin");
loungeSound.start();
}
if (TV) {
TVOn = true;
}
} else {
_root.person._visible = true;
_root.sofa.lounger._visible = false;
lounging = false;
TVOn = false;
}
if (Key.isDown(81)) {
quality = (quality + 1) % 4;
if (quality == 0) {
_root._quality = "HIGH";
} else if (quality == 1) {
_root._quality = "BEST";
} else if (quality == 2) {
_root._quality = "LOW";
} else if (quality == 3) {
_root._quality = "MEDIUM";
}
}
if (TV && (_root.person.hitTest(_root.television))) {
if (Key.isDown(Key.DOWN)) {
_root.person._y = _root.person._y - moveSpeed;
} else if (Key.isDown(Key.RIGHT)) {
_root.person._x = _root.person._x - moveSpeed;
} else if (Key.isDown(Key.LEFT)) {
_root.person._x = _root.person._x + moveSpeed;
}
}
Frame 6
gotoAndPlay (5);
Frame 7
firing = false;
rad = 40;
hstrength = 10;
a = new Array();
i = 0;
while (i < numTanks) {
a[i] = 0;
i++;
}
enemiesDestroyed = 0;
enemiesThru = 0;
i = 2;
while (numTanks >= i) {
_root.bullet1.duplicateMovieClip("bullet" + i, i + 20);
i++;
}
i = 2;
while (numTanks >= i) {
_root.enemy1.duplicateMovieClip("enemy" + i, i);
_root["enemy" + i].reset();
i++;
}
Instance of Symbol 110 MovieClip "enemy1" in Frame 7
onClipEvent (load) {
function reset() {
this.strength = 2;
this._x = 570 + random(50);
this._y = random(_root.tankGround._height - (2 * this._height)) + this._height;
this.moveSpeed = random(7) + 5;
fired = false;
_root["bullet" + num]._y = this._y;
_root["bullet" + num]._x = this._x;
}
strength = 2;
i = 1;
while (_root.numTanks >= i) {
if (this._name.charAt(5) == i) {
num = i;
}
i++;
}
}
onClipEvent (enterFrame) {
rad = Math.sqrt(Math.pow(Math.abs(_x - _root.tank._x), 2) + Math.pow(Math.abs(_y - _root.tank._y), 2));
opp = Math.abs(_y - _root.tank._y);
rot = Math.asin(opp / rad);
rot = rot * 57.2957795130823;
if (_root.tank._y < this._y) {
this.nozzle._rotation = rot;
} else {
rot = rot * -1;
this.nozzle._rotation = rot;
}
if (fired == false) {
rot = (Math.PI * rot) / 180;
fired = true;
this.yslope = 42 * Math.sin(rot);
this.xslope = 42 * Math.cos(rot);
temp = random(3) + 1;
xslope = xslope / temp;
yslope = yslope / temp;
}
this._x = this._x - moveSpeed;
if (this.hitTest(_root.bullet) && (_root.firing)) {
strength--;
_root.firing = false;
}
if (0 >= this.strength) {
_root.enemiesDestroyed++;
_root.explosion.duplicateMovieClip("explosion" + _root.enemiesDestroyed, _root.enemiesDestroyed + 10);
_root["explosion" + _root.enemiesDestroyed]._x = this._x;
_root["explosion" + _root.enemiesDestroyed]._y = this._y;
_root.a[this.temp2] = 0;
this.reset();
}
if (_x < 0) {
_root.enemiesThru++;
_root.a[this.temp2] = 0;
this.reset();
}
if (_root["bullet" + num].hitTest(_root.tank)) {
if (this.hit == false) {
this.hit = true;
_root.hstrength = _root.hstrength - 2;
}
}
_root["bullet" + num]._x = _root["bullet" + num]._x - this.xslope;
_root["bullet" + num]._y = _root["bullet" + num]._y - this.yslope;
if (_root["bullet" + num]._x < 0) {
_root["bullet" + num]._y = this._y;
_root["bullet" + num]._x = this._x;
fired = false;
hit = false;
}
_root["bullet" + num];
if ((_y < 0) || (480 < _root["bullet" + num]._y)) {
_root["bullet" + num]._y = this._y;
_root["bullet" + num]._x = this._x;
fired = false;
hit = false;
}
}
Instance of Symbol 123 MovieClip "explosion" in Frame 7
onClipEvent (enterFrame) {
if (done) {
this.removeMovieClip();
}
}
Frame 8
if (Key.isDown(SpeedKey)) {
moveSpeed = 15;
} else {
moveSpeed = 10;
}
if (Key.isDown(RotUpKey)) {
_root.nozzle._rotation = _root.nozzle._rotation - 10;
} else if (Key.isDown(RotDownKey)) {
_root.nozzle._rotation = _root.nozzle._rotation + 10;
}
if (Key.isDown(RightKey)) {
if (_root.tank._x < (_root.tankGround._width / 2)) {
_root.tank._rotation = 0;
_root.tank._x = _root.tank._x + moveSpeed;
}
} else if (Key.isDown(LeftKey)) {
if ((0 + _root.tank._width) < _root.tank._x) {
_root.tank._rotation = 0;
_root.tank._x = _root.tank._x - moveSpeed;
}
} else if (Key.isDown(DownKey)) {
if (_root.tank._y < (_root.tankGround._height - _root.tank._height)) {
_root.tank._rotation = 90;
_root.tank._y = _root.tank._y + moveSpeed;
}
} else if (Key.isDown(UpKey)) {
if ((0 + _root.tank._height) < _root.tank._y) {
_root.tank._rotation = 90;
_root.tank._y = _root.tank._y - moveSpeed;
}
}
_root.nozzle._x = _root.tank._x;
_root.nozzle._y = _root.tank._y;
if (firing == false) {
if (Key.isDown(FireKey)) {
firing = true;
rot = _root.nozzle._rotation % 360;
rot = (Math.PI * rot) / 180;
yslope = rad * Math.sin(rot);
xslope = rad * Math.cos(rot);
}
_root.bullet._x = _root.nozzle._x;
_root.bullet._y = _root.nozzle._y;
} else {
_root.bullet._y = _root.bullet._y + yslope;
_root.bullet._x = _root.bullet._x + xslope;
if ((((550 < _root.bullet._x) || (_root.bullet._x < 0)) || (_root.bullet._y < 0)) || (450 < _root.bullet._y)) {
firing = false;
}
}
if (enemiesDestroyed == numKills) {
gotoAndPlay (10);
}
if (hstrength == 0) {
_root.explosion.duplicateMovieClip("e", 1000);
_root.e._x = _root.tank._x;
_root.e._y = _root.tank._y;
gotoAndPlay (20);
}
Frame 9
gotoAndPlay (8);
Frame 19
betAmt = Number(betAmt);
money = money + betAmt;
gotoAndPlay (4);
Frame 33
betAmt = Number(betAmt);
money = money - betAmt;
gotoAndPlay (4);
Frame 35
gotoAndPlay (34);
Frame 36
i = 0;
while (i < pCards) {
_root["pcard" + i].removeMovieClip();
i++;
}
i = 0;
while (i < dCards) {
_root["dcard" + i].removeMovieClip();
i++;
}
mood = "bad";
stop();
Frame 37
mood = "bad";
Frame 39
gotoAndPlay (37);
Frame 97
money = money - 5;
gotoAndPlay (4);
Frame 98
s = new Sound();
s.attachSound("phone");
s.start();
numVoices = 7;
winAmount = random(499) + 1;
loseAmount = random(99) + 1;
r = random(numVoices) + 1;
nextPhone = (5 + random(50)) * 12;
phone = 0;
mood = "plain";
c1 = "Invitation to the bars";
c4 = "Nuggets";
c3 = "Needs a ride";
c6 = "Needs your computer";
c2 = "Sweepstakes";
c5 = "Your Mom";
c7 = "Investor";
c100 = "private";
c101 = "unavailable";
e1 = "Hey, wanna go to the bars?";
e2 = "You just won $" + winAmount;
e3 = "My car just broke down and I need you to pick me up";
e4 = "I just got a Q.P. of nuggets, come by and grab some";
e5 = "It's your mother, I need you to come by and help me do some chores around the house";
e6 = "I gotta come by and use your computer.";
e7 = ("Hello Sir, how would you like to invest a little, but recieve huge paybacks. Well all you need to do is give me $" + loseAmount) + " to be on your way to becoming a millionare.";
e11 = "No, I gotta clean my room.";
e12 = "No, I'm getting sick";
e13 = "OK, count me in, I'm dying to get out of the house. Come get me as soon as possible.";
e21 = "Woo Hoo....Whats the catch";
e22 = "Wow, I'm never this lucky";
e23 = "I don't want it, give it to charity";
e31 = "My, car broke down too, sorry";
e32 = "Who is this, I don't know you";
e33 = "Ok, I'll be right there";
e41 = "Oh, I'm quitting, I'm going to turn around my life, no more lounging for me";
e42 = "Ok, I'll be right by";
e43 = "I'm good right now, I don't wanna leave the house";
e51 = "I'd love to, but I'm really busy right now.";
e52 = "I really hurt my back the other day, and the doctor said that I shouldn't move around much.";
e53 = "Ok, I'll be right by.";
e61 = "Oh man, it just crashed...Sorry, call me in an hour and maybe I'll have it working again";
e62 = "Sorry, I'm writing a very important paper right now.";
e63 = "Sure, I'm not using it right now.";
e71 = "No way man, call some other sucker to fall for you shananagins.";
e72 = "Hmmm.....Sounds legit. Count me in.";
e73 = "Well, sounds like too much money, can I go in with half";
e121 = (e111 = (e113 = (("No excuse, your going out, I'll be there in five minutes\n\nGoing to the bar costs Money, $" + loseAmount) + " has been deducted from your bank account") + "\t"));
e122 = (e112 = (e123 = "Ok, talk to you later\n\nWhew...that was a close one. You got lucky this time."));
e131 = (e132 = (e133 = (("Ok, I'll be there shortly\n\nGoing to the bar costs Money, $" + loseAmount) + " has been deducted from your bank account") + "\t"));
e211 = (("Ha, fooled you, your not sick your going to the bar\n\nGoing to the bar costs Money, $" + loseAmount) + " has been deducted from your bank account") + "\t";
e212 = (("No, catch I'll forward it to your bank account\n\nGreat, you just added $" + winAmount) + " to your bank account.") + newline;
e221 = (((((("Well...techniquely after we tax your winnings you owe us $" + loseAmount) + newline) + newline) + "Oh well, $") + loseAmount) + " has been deducted from your bank account") + "\t";
e222 = (("Well, then today's your lucky day\n\nGreat, you just added $" + winAmount) + " to your bank account.") + newline;
e231 = (e232 = "Wow, what a kind person you are\n\nWell, nothing won, nothing lost, cant complain about that");
e311 = "Oh, ok, I'll call someone else\n\nWhew...that was a close one. You got lucky this time.";
e312 = (("I saw driving this morning...you suck\n\nNow your going to have to pay for his tow truck to make up for this, $" + loseAmount) + " has been deducted from your bank account") + "\t";
e321 = (("Well, screw you! We're not friends anymore.\n\nNow your going to have to pay for his tow truck to make up for this, $" + loseAmount) + " has been deducted from your bank account") + "\t";
e322 = "Sorry, I must have the wrong number\n\nWhew...that was a close one. You got lucky this time.";
e331 = (("Thank's a lot\n\nAfter gas the trip cost you $" + loseAmount) + " oh well.") + "\t";
e332 = (("Thank's a lot\n\nGreat he gave you $" + winAmount) + " for your troubles.") + newline;
e411 = "ok, fine, but this chance only comes around every one and a while";
e412 = (("Fine, but you'll have to buy it later\n\nWhat were you thinking, of course you aren't quitting, now you have to buy some $" + loseAmount) + " has been deducted from your bank account") + "\t";
e421 = (("Ahh...Drugs are bad\n\nOn your way home you got pulled over, so now you have to devote $" + loseAmount) + " towards bail") + "\t";
e422 = (("Nice\n\nYou even have a bit left over to sell. $" + winAmount) + " has been added to your bank account") + newline;
e431 = "fine, fine, just trying to be nice";
e432 = "Oh, well, your loss";
e511 = (e522 = (("Well then you are going to have to hire someone\n\nYou should always help your mother...now its gonna cost you $" + loseAmount) + "to help her.") + "\t");
e512 = "Ok, well I hope things settle down for you soon.";
e521 = "Oh, well you should rest up, I'll call you later.";
e531 = (("Great\n\nGood job, she gave you $" + winAmount) + " for helping her") + newline;
e532 = (("Great\n\nGood job, but it really put a strain on your back $" + loseAmount) + " needs to go to a doctor") + "\t";
e611 = "Are you kidding, that sucks, I guess I'll call someone else.\n\nNice, The computer is all your for the rest of the night.";
e612 = (("I can fix it, I'll be right by.\n\nGreat, now he really broke it its gonna cost you $" + loseAmount) + " to have it fixed and your computer angst has shot way up") + "\t";
e621 = "Ok, maybe i'll call you later.\n\nGood excuse, that took care of him.";
e622 = "Oh, it will just take a minute.\n\nWell, he was there for a few hours. Your computer angst has shot way up.";
e631 = (e632 = "OK, i'll be right by\n\nHe was there for hours, your computer Angst has shot way up.");
if (loseAmount >= winAmount) {
winAmount2 = loseAmount + 1;
} else {
winAmount2 = WinAmount;
}
e711 = "Oh well, your loss. You could have had a ton of money in your pocket.";
e712 = "Too bad I had a real winning investment in my hands";
e721 = (("Wise idea sir. I'll be back to you shortly with your profit margin\n\nWell, this one turned out in your favor. You have another $" + winAmount2) + " in your a bank account.") + newline;
e722 = (("Sometimes these things just don't work out. Oh well, at least you only lost $" + loseAmount) + ". Maybe nextime the luck will be in your favor.") + "\t";
e731 = "No way, I got a bunch of other people waiting in line for this deal, so your loss.";
e732 = (("Well, ok.\n\nDammit, you lost $" + Math.ceil(loseAmount / 2)) + " Oh well, maybe next time") + "\t";
e733 = (("Well, ok.\n\nYes, you win $" + Math.ceil(winAmount / 2)) + " Lady luck must be smiling upon you") + newline;
Frame 107
if (cID) {
_root.callerID._visible = true;
temp = random(2);
if (temp == 0) {
_root.callerID.callerID = _root["c" + r];
} else if (random(2) == 0) {
_root.callerID.callerID = _root.c100;
} else {
_root.callerID.callerID = _root.c101;
}
} else {
_root.callerID._visible = false;
}
mood = "shocked";
stop();
Frame 108
mood = "plain";
_root.t = _root["e" + r];
i = 1;
while (3 >= i) {
_root["excuse" + i] = _root[("e" + r) + i];
i++;
}
phoneVoice = new Sound();
phoneVoice.attachSound("voice" + r);
phoneVoice.start();
stop();
Frame 109
r3 = random(2) + 1;
if (r == 7) {
if (r2 == 2) {
winAmount = winAmount2;
}
if (r2 == 3) {
r3 = random(3) + 1;
loseAmount = Math.ceil(loseAmount / 2);
winAmount = Math.ceil(winAmount / 2);
}
}
_root.t = _root[(("e" + r) + r2) + r3];
if (((r == 4) && (r2 == 2)) && (r3 == 1)) {
sound1 = new Sound();
sound1.attachSound("drugsBad");
sound1.start();
}
if (r == 7) {
if (r2 == 2) {
winAmount = winAmount2;
}
if (r2 == 3) {
loseAmount = Math.ceil(loseAmount / 2);
winAmount = Math.ceil(winAmount / 2);
}
}
if (_root.t.charAt(_root.t.length - 1) == "\t") {
money = money - loseAmount;
mood = "bad";
} else if (_root.t.charAt(_root.t.length - 1) == newline) {
money = money + winAmount;
mood = "good";
} else {
mood = "plain";
}
if (r == 6) {
if ((r2 == 3) || (r3 == 2)) {
lastPlayed = lastPlayed + (360 + random(360));
}
}
phone = 0;
stop();
Frame 110
twitch = 0;
lastPlayed = 0;
computer = true;
stop();
Frame 111
stop();
Frame 112
stop();
Frame 113
stop();
Frame 114
stop();
Frame 115
stop();
Frame 116
_root.score = 600;
_root.hitGrey._alpha = 50;
_root.standGrey._alpha = 50;
_root.betUpGrey._alpha = 0;
_root.betDownGrey._alpha = 0;
_root.maxBetGrey._alpha = 0;
_root.dealGrey._alpha = 0;
_root.doubleGrey._alpha = 50;
bet = 5;
dist = 30;
firstDeal = false;
total = 0;
dtotal = 0;
winText = "";
_root.pcard._visible = false;
_root.dcard._visible = false;
_root.cover._visible = false;
Suits = new Array();
Values = new Array();
score = money;
i = 0;
while (i < 4) {
j = 0;
while (j < 13) {
if (i == 1) {
let = "S";
} else if (i == 0) {
let = "D";
} else if (i == 2) {
let = "H";
} else if (i == 3) {
let = "C";
}
Suits[(13 * i) + j] = let;
Values[(13 * i) + j] = j + 1;
j++;
}
i++;
}
betText = "";
gameOver = true;
stop();
Frame 117
_root.hitGrey._alpha = 0;
_root.standGrey._alpha = 0;
_root.betUpGrey._alpha = 50;
_root.betDownGrey._alpha = 50;
_root.maxBetGrey._alpha = 50;
_root.dealGrey._alpha = 50;
_root.doubleGrey._alpha = 0;
win = false;
double = false;
firstDeal = true;
bust = false;
gameOver = false;
pCards = 2;
dCards = 2;
turn = true;
hit = false;
dhit = false;
aceCount = 0;
daceCount = 0;
dtotal = 0;
deckOut = 0;
pCardsOut = 0;
dCardsOut = 0;
_root.total = 0;
winText = "";
_root.cover._visible = true;
pHandV = new Array();
dHandV = new Array();
pHandS = new Array();
dHandS = new Array();
i = 0;
while (i < 300) {
rand1 = random(52);
temp = Suits[rand1];
temp2 = Values[rand1];
rand = random(52);
Suits[rand1] = Suits[rand];
Values[rand1] = Values[rand];
Suits[rand] = temp;
Values[rand] = temp2;
i++;
}
i = 0;
while (i < 2) {
pHandV[i] = Values[deckOut];
pHandS[i] = Suits[deckOut];
deckOut++;
dHandV[i] = Values[deckOut];
dHandS[i] = Suits[deckOut];
deckOut++;
i++;
}
_root.dcard.duplicateMovieClip("dcard0", 100);
_root.dcard0.mySuit = dHandS[0];
_root["dcard" + i]._x = _root["dcard" + i]._x + (_root.dcard._width / 3);
if (10 < dHandV[0]) {
if (dHandV[0] == 11) {
_root.dcard0.value = "J";
} else if (dHandV[0] == 12) {
_root.dcard0.value = "Q";
} else if (dHandV[0] == 13) {
_root.dcard0.value = "K";
}
dtotal = dtotal + 10;
} else if (dHandV[0] == 1) {
daceCount++;
_root.dcard0.value = "A";
if (21 >= (dtotal + 11)) {
dtotal = dtotal + 11;
} else {
dtotal = dtotal + 1;
}
} else {
dtotal = dtotal + dHandV[0];
_root.dcard0.value = dHandV[0];
}
dCardsOut = 1;
Frame 118
if (hit == true) {
_root.pHandV[_root.pCardsOut] = _root.Values[_root.decKOut];
_root.pHandS[_root.pCardsOut] = _root.Suits[_root.deckOut];
_root.deckOut++;
_root.pCards++;
hit = false;
firstDeal = false;
}
i = pCardsOut;
while (i < pCards) {
_root.pcard.duplicateMovieClip("pcard" + i, i);
_root["pcard" + i].mySuit = pHandS[i];
if (0 < i) {
_root["pcard" + i]._x = _root["pcard" + (i - 1)]._x;
}
_root["pcard" + i]._x = _root["pcard" + i]._x + (_root.pcard._width / 3);
if (10 < pHandV[i]) {
if (pHandV[i] == 11) {
_root["pcard" + i].value = "J";
} else if (pHandV[i] == 12) {
_root["pcard" + i].value = "Q";
} else if (pHandV[i] == 13) {
_root["pcard" + i].value = "K";
}
total = total + 10;
} else if (pHandV[i] == 1) {
_root["pcard" + i].value = "A";
if (21 >= (total + 11)) {
total = total + 11;
aceCount++;
} else {
total = total + 1;
}
} else {
total = total + pHandV[i];
_root["pcard" + i].value = pHandV[i];
}
i++;
}
if (0 < aceCount) {
if (21 < total) {
total = total - 10;
aceCount--;
}
}
pCardsOut = pCards;
if ((total >= 21) || (double)) {
turn = false;
if (21 < total) {
bust = true;
}
_root.gotoAndPlay("dealer");
}
if (((pHandV[0] == 1) || (pHandV[1] == 1)) && ((9 < pHandV[0]) || (9 < pHandV[1]))) {
if (((dHandV[0] == 1) || (dHandV[1] == 1)) && ((9 < dHandV[0]) || (9 < dHandV[1]))) {
draw = true;
} else {
win = true;
blackJack = true;
}
gotoAndPlay (131);
} else if (((dHandV[0] == 1) || (dHandV[1] == 1)) && ((9 < dHandV[0]) || (9 < dHandV[1]))) {
if (((pHandV[0] == 1) || (pHandV[1] == 1)) && ((9 < pHandV[0]) || (9 < pHandV[1]))) {
draw = true;
} else {
win = false;
}
gotoAndPlay (120);
}
stop();
Frame 119
_root.doubleGrey._alpha = 50;
_root.gotoAndPlay("player");
Frame 120
_root.hitGrey._alpha = 50;
_root.standGrey._alpha = 50;
_root.betUpGrey._alpha = 50;
_root.betDownGrey._alpha = 50;
_root.maxBetGrey._alpha = 50;
_root.dealGrey._alpha = 50;
_root.doubleGrey._alpha = 50;
turn = false;
if (dhit == true) {
_root.dHandV[_root.dCardsOut] = _root.Values[_root.decKOut];
_root.dHandS[_root.dCardsOut] = _root.Suits[_root.deckOut];
_root.deckOut++;
_root.dCards++;
dhit = false;
}
i = dCardsOut;
while (i < dCards) {
_root.dcard.duplicateMovieClip("dcard" + i, i + 100);
_root["dcard" + i].mySuit = dHandS[i];
if (0 < i) {
_root["dcard" + i]._x = _root["dcard" + (i - 1)]._x;
}
_root["dcard" + i]._x = _root["dcard" + i]._x + (_root.dcard._width / 3);
if (10 < dHandV[i]) {
if (dHandV[i] == 11) {
_root["dcard" + i].value = "J";
} else if (dHandV[i] == 12) {
_root["dcard" + i].value = "Q";
} else if (dHandV[i] == 13) {
_root["dcard" + i].value = "K";
}
dtotal = dtotal + 10;
} else if (dHandV[i] == 1) {
daceCount++;
_root["dcard" + i].value = "A";
if (21 >= (dtotal + 11)) {
dtotal = dtotal + 11;
} else {
dtotal = dtotal + 1;
}
} else {
dtotal = dtotal + dHandV[i];
_root["dcard" + i].value = dHandV[i];
}
i++;
}
dCardsOut = dCards;
play();
Frame 130
if (bust == true) {
win = false;
_root.gotoAndPlay("winBJ");
} else if ((dtotal < 17) && (!win)) {
dhit = true;
_root.gotoAndPlay("dealer");
} else {
dhit = false;
if ((dtotal < total) || (21 < dtotal)) {
win = true;
} else if (total < dtotal) {
win = false;
}
_root.gotoAndPlay("winBJ");
}
Frame 131
gameOver = true;
if (((total == dtotal) && (21 >= total)) || (draw)) {
winText = "Draw";
draw = false;
} else if (win == true) {
if (blackJack == true) {
money = money + Math.ceil(bet * 1.5);
blackJack = false;
winText = "Blackjack!!!";
} else {
money = money + bet;
winText = "You Win!";
}
} else {
money = money - bet;
winText = "You Lose";
}
if (double) {
bet = bet / 2;
}
_root.hitGrey._alpha = 50;
_root.standGrey._alpha = 50;
_root.betUpGrey._alpha = 0;
_root.betDownGrey._alpha = 0;
_root.maxBetGrey._alpha = 0;
_root.dealGrey._alpha = 0;
_root.doubleGrey._alpha = 50;
stop();
Frame 132
if (pickleTime == 16) {
luck = random(2);
if (luck == 1) {
mood = "shocked";
gotoAndPlay (134);
} else {
mood = "good";
gotoAndPlay (168);
}
}
mood = "plain";
_root.face3._x = _root.face3._x + random(5);
_root.face3._x = _root.face3._x - random(5);
_root.face3._y = _root.face3._y + random(5);
_root.face3._y = _root.face3._y - random(5);
pickleTime++;
_root.pickleText = "That pickle really upset your stomache";
Frame 133
gotoAndPlay (132);
Frame 134
mood = "shocked";
pukeSound = new Sound();
pukeSound.attachSound("puke");
pukeSound.start();
Frame 167
loseAmount = random(100) + 1;
_root.pickleText = ("Now you've done it, those pickles have been there for years. You lose $" + loseAmount) + " for hospital bills";
money = money - loseAmount;
mood = "plain";
stop();
Frame 168
mood = "good";
_root.pickleText = "Whew, those pickles have been there for years. Lucky you didn't get sick";
lastAte = 0;
stop();
Frame 228
gotoAndPlay (169);
Frame 229
if ((0 < betTanks) && (0 < betKills)) {
maxBet = (betTanks * betKills) * 10;
} else {
maxBet = 0;
}
if (betKills < Math.ceil(betTanks / 2)) {
betKills = Math.ceil(betTanks / 2);
}
numTanks = betTanks;
numKills = betKills;
if (betTanks == null) {
betTanks = 1;
}
if (betKills == null) {
betKills == 10;
}
if (betAmt == null) {
betAmt = 10;
}
Frame 230
gotoAndPlay (229);
Frame 316
gotoAndPlay (231);
Symbol 33 MovieClip Frame 2
blink++;
if (0 < (blink % 36)) {
gotoAndPlay (1);
}
Symbol 50 Button
on (press, release) {
if (_root.amtLoaded == 1) {
gotoAndPlay (114);
}
}
Symbol 53 Button
on (press, release) {
if (_root.amtLoaded == 1) {
gotoAndPlay (4);
}
}
Symbol 57 MovieClip Frame 1
if (_root.TVOn) {
screen._visible = true;
screen._alpha = random(70);
} else {
screen._visible = false;
}
Symbol 57 MovieClip Frame 2
Symbol 60 Button
on (release) {
gotoAndPlay (114);
}
Symbol 67 MovieClip Frame 1
stop();
Symbol 67 MovieClip Frame 2
Symbol 67 MovieClip Frame 10
_root.gotoAndPlay("fridge");
Symbol 72 MovieClip Frame 1
stop();
Symbol 72 MovieClip Frame 7
click = new Sound();
click.attachSound("click");
click.start();
Symbol 72 MovieClip Frame 19
click = new Sound();
click.attachSound("click");
click.start();
Symbol 72 MovieClip Frame 25
gotoAndPlay (1);
Symbol 85 MovieClip Frame 4
if (moneyStop == true) {
stop();
}
Symbol 86 MovieClip Frame 4
if (moneyStop == true) {
stop();
}
Symbol 87 MovieClip Frame 4
if (moneyStop == true) {
stop();
}
Symbol 91 MovieClip Frame 4
if (moneyStop == true) {
stop();
}
Instance of Symbol 85 MovieClip "hundred" in Symbol 92 MovieClip Frame 1
onClipEvent (load) {
if (_root.money >= 0) {
this.number.number = Math.floor((_root.money % 1000) / 100);
} else {
this.number.number = Math.floor(((_root.money * -1) % 1000) / 100);
}
this.moneystop = false;
nextF = true;
}
onClipEvent (enterFrame) {
if (_root.money >= 0) {
value = Math.floor((_root.money % 1000) / 100);
} else {
value = Math.floor(((_root.money * -1) % 1000) / 100);
}
if (this.number.number != value) {
this.moneystop = false;
if (this.number.number < value) {
nextF = true;
if (this._currentframe == 1) {
this.number.number = (this.number.number + 1) % 10;
}
} else {
nextF = false;
if (this._currentframe == 1) {
this.number.number = (this.number.number - 1) % 10;
}
}
} else {
moneystop = true;
}
if ((_currentframe != 4) || (!moneystop)) {
if (nextF) {
if (_currentframe == 7) {
this.gotoAndStop(1);
} else {
this.nextFrame();
}
} else if (_currentframe == 1) {
this.gotoAndStop(7);
} else {
this.prevFrame();
}
}
}
Instance of Symbol 86 MovieClip "ten" in Symbol 92 MovieClip Frame 1
onClipEvent (load) {
if (_root.money >= 0) {
this.number.number = Math.floor((_root.money % 100) / 10);
} else {
this.number.number = Math.floor(((_root.money * -1) % 100) / 10);
}
this.moneystop = false;
nextF = true;
}
onClipEvent (enterFrame) {
if (_root.money >= 0) {
value = Math.floor((_root.money % 100) / 10);
} else {
value = Math.floor(((_root.money * -1) % 100) / 10);
}
if (this.number.number != value) {
this.moneystop = false;
if (this.number.number < value) {
nextF = true;
if (this._currentframe == 1) {
this.number.number = (this.number.number + 1) % 10;
}
} else {
nextF = false;
if (this._currentframe == 1) {
this.number.number = (this.number.number - 1) % 10;
}
}
} else {
moneystop = true;
}
if ((_currentframe != 4) || (!moneystop)) {
if (nextF) {
if (_currentframe == 7) {
this.gotoAndStop(1);
} else {
this.nextFrame();
}
} else if (_currentframe == 1) {
this.gotoAndStop(7);
} else {
this.prevFrame();
}
}
}
Instance of Symbol 87 MovieClip "one" in Symbol 92 MovieClip Frame 1
onClipEvent (load) {
if (_root.money >= 0) {
this.number.number = _root.money % 10;
} else {
this.number.number = (_root.money * -1) % 10;
}
this.moneystop = false;
nextF = true;
}
onClipEvent (enterFrame) {
if (_root.money >= 0) {
value = _root.money % 10;
} else {
value = (_root.money * -1) % 10;
}
if (this.number.number != value) {
this.moneystop = false;
if (this.number.number < value) {
nextF = true;
if (this._currentframe == 1) {
this.number.number = (this.number.number + 1) % 10;
}
} else {
nextF = false;
if (this._currentframe == 1) {
this.number.number = (this.number.number - 1) % 10;
}
}
} else {
moneystop = true;
}
if ((_currentframe != 4) || (!moneystop)) {
if (nextF) {
if (_currentframe == 7) {
this.gotoAndStop(1);
} else {
this.nextFrame();
}
} else if (_currentframe == 1) {
this.gotoAndStop(7);
} else {
this.prevFrame();
}
}
}
Instance of Symbol 91 MovieClip "thousand" in Symbol 92 MovieClip Frame 1
onClipEvent (load) {
if (_root.money >= 0) {
this.number.number = Math.floor(_root.money / 1000);
} else {
this.number.number = "-";
}
this.moneystop = false;
nextF = true;
}
onClipEvent (enterFrame) {
if (_root.money >= 0) {
if (this.number.number == "-") {
this.number.number = 0;
}
value = Math.floor(_root.money / 1000);
if (this.number.number != value) {
this.moneystop = false;
if (this.number.number < value) {
nextF = true;
if (this._currentframe == 1) {
this.number.number = (this.number.number + 1) % 10;
}
} else {
nextF = false;
if (this._currentframe == 1) {
this.number.number = (this.number.number - 1) % 10;
}
}
} else {
moneystop = true;
}
} else {
this.number.number = "-";
if (_currentframe == 4) {
moneystop = true;
}
}
if ((_currentframe != 4) || (!moneystop)) {
if (nextF) {
if (_currentframe == 7) {
this.gotoAndStop(1);
} else {
this.nextFrame();
}
} else if (_currentframe == 1) {
this.gotoAndStop(7);
} else {
this.prevFrame();
}
}
}
Symbol 93 MovieClip Frame 1
_root.lastAte++;
if (!_root.computer) {
_root.lastPlayed++;
}
_root.phone++;
this.hungerBar._width = (_root.lastAte / _root.finalEat) * meter._width;
this.compBar._width = (_root.lastPlayed / _root.finalPlayed) * meter._width;
if (_root.lastAte >= _root.finalEat) {
_root.gotoAndPlay("dead_by_eat");
} else if (_root.lastPlayed >= _root.finalPlayed) {
if ((_root._currentFrame != 34) && (_root._currentframe != 35)) {
_root.gotoAndPlay("dead_by_played");
}
}
Symbol 93 MovieClip Frame 2
gotoAndPlay (1);
Symbol 110 MovieClip Frame 1
hit = false;
Symbol 123 MovieClip Frame 10
done = true;
Symbol 126 MovieClip Frame 1
if (_root.hstrength < 10) {
this.meter._width = _root.bar._width * (_root.hstrength * 0.1);
}
Symbol 126 MovieClip Frame 2
gotoAndPlay (1);
Symbol 143 Button
on (press, release) {
if (_root.money >= 5) {
_root.textBox = "";
gotoAndPlay (40);
lastAte = 0;
} else {
_root.textBox = "No more money, you're going to have to eat the pickle.";
}
}
Symbol 145 Button
on (press, release) {
pickleTime = 0;
_root.textBox = "";
gotoAndPlay (132);
}
Symbol 149 Button
on (press) {
gotoAndPlay (4);
}
Symbol 166 MovieClip Frame 2
blink++;
if (0 < (blink % 36)) {
gotoAndPlay (1);
}
Symbol 167 MovieClip Frame 2
blink++;
if (0 < (blink % 36)) {
gotoAndPlay (1);
}
Symbol 171 MovieClip Frame 1
playedYes = false;
if (_root.mood == "good") {
this.mouth.attachMovie("smile", "smile", 1);
if (!playedYes) {
playedYes = true;
yes = new Sound();
yes.attachSound("yes");
yes.start();
}
}
if (_root.mood == "plain") {
this.mouth.attachMovie("plain", "plain", 1);
}
if (_root.mood == "bad") {
this.mouth.attachMovie("frown", "frown", 1);
}
if (_root.mood == "shocked") {
this.mouth.attachMovie("shocked", "shocked", 1);
}
Symbol 171 MovieClip Frame 2
if (_root.mood == "good") {
this.mouth.attachMovie("smile", "smile", 1);
if (!playedYes) {
playedYes = true;
yes = new Sound();
yes.attachSound("yes");
yes.start();
}
}
if (_root.mood == "plain") {
this.mouth.attachMovie("plain", "plain", 1);
}
if (_root.mood == "bad") {
this.mouth.attachMovie("frown", "frown", 1);
}
if (_root.mood == "shocked") {
this.mouth.attachMovie("shocked", "shocked", 1);
}
Symbol 171 MovieClip Frame 3
gotoAndPlay (2);
Symbol 177 Button
on (release) {
gotoAndPlay (1);
}
Symbol 216 Button
on (release) {
gotoAndPlay (108);
}
Symbol 219 Button
on (release) {
gotoAndPlay (4);
}
Symbol 227 Button
on (release) {
gotoAndPlay (109);
_root.r2 = 1;
}
Symbol 228 Button
on (release) {
gotoAndPlay (109);
_root.r2 = 2;
}
Symbol 229 Button
on (release) {
gotoAndPlay (109);
_root.r2 = 3;
}
Symbol 236 Button
on (release) {
gotoAndPlay (4);
}
Symbol 238 Button
on (release) {
gotoAndPlay (229);
}
Symbol 241 Button
on (release) {
gotoAndPlay (111);
}
Symbol 242 Button
on (release) {
gotoAndPlay (115);
}
Symbol 243 Button
on (release) {
gotoAndPlay (4);
}
Symbol 248 Button
on (release) {
gotoAndPlay (116);
}
Symbol 253 Button
on (release) {
if (_root.money >= 300) {
cID = true;
_root.money = _root.money - 300;
gotoAndPlay (112);
} else {
gotoAndPlay (113);
}
}
Symbol 255 Button
on (release) {
if (_root.money >= 2000) {
VGC = true;
_root.money = _root.money - 2000;
gotoAndPlay (112);
} else {
gotoAndPlay (113);
}
}
Symbol 256 Button
on (release) {
if (_root.money >= 1000) {
TV = true;
_root.money = _root.money - 1000;
gotoAndPlay (112);
} else {
gotoAndPlay (113);
}
}
Symbol 259 Button
on (release) {
gotoAndPlay (4);
}
Symbol 261 Button
on (release) {
gotoAndPlay (4);
}
Symbol 270 Button
on (release) {
gotoAndPlay (110);
}
Symbol 278 Button
on (press, release) {
lastKey = _root.ruKey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.ruKey = "BackSpace";
} else if (keyPressed == 20) {
_root.ruKey = "Caplock";
} else if (keyPressed == 17) {
_root.ruKey = "Control";
} else if (keyPressed == 46) {
_root.ruKey = "Delete";
} else if (keyPressed == 40) {
_root.ruKey = "Down Arrow";
} else if (keyPressed == 35) {
_root.ruKey = "End";
} else if (keyPressed == 13) {
_root.ruKey = "Enter";
} else if (keyPressed == 27) {
_root.ruKey = "Escape";
} else if (keyPressed == 36) {
_root.ruKey = "Home";
} else if (keyPressed == 45) {
_root.ruKey = "Insert";
} else if (keyPressed == 37) {
_root.ruKey = "Left Arrow";
} else if (keyPressed == 34) {
_root.ruKey = "Page Down";
} else if (keyPressed == 33) {
_root.ruKey = "Page Up";
} else if (keyPressed == 39) {
_root.ruKey = "Right Arrow";
} else if (keyPressed == 16) {
_root.ruKey = "Shift";
} else if (keyPressed == 32) {
_root.ruKey = "Space";
} else if (keyPressed == 9) {
_root.ruKey = "Tab";
} else if (keyPressed == 38) {
_root.ruKey = "Up Arrow";
} else {
_root.ruKey = chr(Key.getAscii());
}
if (rukey == ukey) {
ukey = lastKey;
_root.UpKey = _root.RotUpKey;
} else if (rukey == dkey) {
dkey = lastKey;
_root.DownKey = _root.RotUpKey;
} else if (rukey == rkey) {
rkey = lastKey;
_root.RightKey = _root.RotUpKey;
} else if (rukey == lkey) {
lkey = lastKey;
_root.LeftKey = _root.RotUpKey;
} else if (rukey == rdkey) {
rdkey = lastKey;
_root.RotDownKey = _root.RotUpKey;
} else if (rukey == sukey) {
sukey = lastKey;
_root.SpeedKey = _root.RotUpKey;
} else if (rukey == fkey) {
fkey = lastKey;
_root.FireKey = _root.RotUpKey;
}
_root.RotUpKey = keyPressed;
}
Symbol 283 Button
on (press, release) {
lastKey = _root.ukey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.ukey = "BackSpace";
} else if (keyPressed == 20) {
_root.ukey = "Caplock";
} else if (keyPressed == 17) {
_root.ukey = "Control";
} else if (keyPressed == 46) {
_root.ukey = "Delete";
} else if (keyPressed == 40) {
_root.ukey = "Down Arrow";
} else if (keyPressed == 35) {
_root.ukey = "End";
} else if (keyPressed == 13) {
_root.ukey = "Enter";
} else if (keyPressed == 27) {
_root.ukey = "Escape";
} else if (keyPressed == 36) {
_root.ukey = "Home";
} else if (keyPressed == 45) {
_root.ukey = "Insert";
} else if (keyPressed == 37) {
_root.ukey = "Left Arrow";
} else if (keyPressed == 34) {
_root.ukey = "Page Down";
} else if (keyPressed == 33) {
_root.ukey = "Page Up";
} else if (keyPressed == 39) {
_root.ukey = "Right Arrow";
} else if (keyPressed == 16) {
_root.ukey = "Shift";
} else if (keyPressed == 32) {
_root.ukey = "Space";
} else if (keyPressed == 9) {
_root.ukey = "Tab";
} else if (keyPressed == 38) {
_root.ukey = "Up Arrow";
} else {
_root.ukey = chr(Key.getAscii());
}
if (ukey == rukey) {
rukey = lastKey;
_root.RotUpKey = _root.UpKey;
} else if (ukey == dkey) {
dkey = lastKey;
_root.DownKey = _root.UpKey;
} else if (ukey == rkey) {
rkey = lastKey;
_root.RightKey = _root.UpKey;
} else if (ukey == lkey) {
lkey = lastKey;
_root.LeftKey = _root.UpKey;
} else if (ukey == rdkey) {
rdkey = lastKey;
_root.RotDownKey = _root.UpKey;
} else if (ukey == sukey) {
sukey = lastKey;
_root.SpeedKey = _root.UpKey;
} else if (ukey == fkey) {
fkey = lastKey;
_root.FireKey = _root.UpKey;
}
_root.UpKey = keyPressed;
}
Symbol 284 Button
on (press, release) {
lastKey = _root.dkey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.dkey = "BackSpace";
} else if (keyPressed == 20) {
_root.dkey = "Caplock";
} else if (keyPressed == 17) {
_root.dkey = "Control";
} else if (keyPressed == 46) {
_root.dkey = "Delete";
} else if (keyPressed == 40) {
_root.dkey = "Down Arrow";
} else if (keyPressed == 35) {
_root.dkey = "End";
} else if (keyPressed == 13) {
_root.dkey = "Enter";
} else if (keyPressed == 27) {
_root.dkey = "Escape";
} else if (keyPressed == 36) {
_root.dkey = "Home";
} else if (keyPressed == 45) {
_root.dkey = "Insert";
} else if (keyPressed == 37) {
_root.dkey = "Left Arrow";
} else if (keyPressed == 34) {
_root.dkey = "Page Down";
} else if (keyPressed == 33) {
_root.dkey = "Page Up";
} else if (keyPressed == 39) {
_root.dkey = "Right Arrow";
} else if (keyPressed == 16) {
_root.dkey = "Shift";
} else if (keyPressed == 32) {
_root.dkey = "Space";
} else if (keyPressed == 9) {
_root.dkey = "Tab";
} else if (keyPressed == 38) {
_root.dkey = "Up Arrow";
} else {
_root.dkey = chr(Key.getAscii());
}
if (dkey == ukey) {
ukey = lastKey;
_root.UpKey = _root.DownKey;
} else if (dkey == rukey) {
rukey = lastKey;
_root.RotUpKey = _root.DownKey;
} else if (dkey == rkey) {
rkey = lastKey;
_root.RightKey = _root.DownKey;
} else if (dkey == lkey) {
lkey = lastKey;
_root.LeftKey = _root.DownKey;
} else if (dkey == rdkey) {
rdkey = lastKey;
_root.RotDownKey = _root.DownKey;
} else if (dkey == sukey) {
sukey = lastKey;
_root.SpeedKey = _root.DownKey;
} else if (dkey == fkey) {
fkey = lastKey;
_root.FireKey = _root.DownKey;
}
_root.DownKey = keyPressed;
}
Symbol 285 Button
on (press, release) {
lastKey = _root.lkey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.lkey = "BackSpace";
} else if (keyPressed == 20) {
_root.lkey = "Caplock";
} else if (keyPressed == 17) {
_root.lkey = "Control";
} else if (keyPressed == 46) {
_root.lkey = "Delete";
} else if (keyPressed == 40) {
_root.lkey = "Down Arrow";
} else if (keyPressed == 35) {
_root.lkey = "End";
} else if (keyPressed == 13) {
_root.lkey = "Enter";
} else if (keyPressed == 27) {
_root.lkey = "Escape";
} else if (keyPressed == 36) {
_root.lkey = "Home";
} else if (keyPressed == 45) {
_root.lkey = "Insert";
} else if (keyPressed == 37) {
_root.lkey = "Left Arrow";
} else if (keyPressed == 34) {
_root.lkey = "Page Down";
} else if (keyPressed == 33) {
_root.lkey = "Page Up";
} else if (keyPressed == 39) {
_root.lkey = "Right Arrow";
} else if (keyPressed == 16) {
_root.lkey = "Shift";
} else if (keyPressed == 32) {
_root.lkey = "Space";
} else if (keyPressed == 9) {
_root.lkey = "Tab";
} else if (keyPressed == 38) {
_root.lkey = "Up Arrow";
} else {
_root.lkey = chr(Key.getAscii());
}
if (lkey == ukey) {
ukey = lastKey;
_root.UpKey = _root.LeftKey;
} else if (lkey == dkey) {
dkey = lastKey;
_root.DownKey = _root.LeftKey;
} else if (lkey == rkey) {
rkey = lastKey;
_root.RightKey = _root.LeftKey;
} else if (lkey == rukey) {
rukey = lastKey;
_root.RotUpKey = _root.LeftKey;
} else if (lkey == rdkey) {
rdkey = lastKey;
_root.RotDownKey = _root.LeftKey;
} else if (lkey == sukey) {
sukey = lastKey;
_root.SpeedKey = _root.LeftKey;
} else if (lkey == fkey) {
fkey = lastKey;
_root.FireKey = _root.LeftKey;
}
_root.LeftKey = keyPressed;
}
Symbol 286 Button
on (press, release) {
lastKey = _root.rkey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.rkey = "BackSpace";
} else if (keyPressed == 20) {
_root.rkey = "Caplock";
} else if (keyPressed == 17) {
_root.rkey = "Control";
} else if (keyPressed == 46) {
_root.rkey = "Delete";
} else if (keyPressed == 40) {
_root.rkey = "Down Arrow";
} else if (keyPressed == 35) {
_root.rkey = "End";
} else if (keyPressed == 13) {
_root.rkey = "Enter";
} else if (keyPressed == 27) {
_root.rkey = "Escape";
} else if (keyPressed == 36) {
_root.rkey = "Home";
} else if (keyPressed == 45) {
_root.rkey = "Insert";
} else if (keyPressed == 37) {
_root.rkey = "Left Arrow";
} else if (keyPressed == 34) {
_root.rkey = "Page Down";
} else if (keyPressed == 33) {
_root.rkey = "Page Up";
} else if (keyPressed == 39) {
_root.rkey = "Right Arrow";
} else if (keyPressed == 16) {
_root.rkey = "Shift";
} else if (keyPressed == 32) {
_root.rkey = "Space";
} else if (keyPressed == 9) {
_root.rkey = "Tab";
} else if (keyPressed == 38) {
_root.rkey = "Up Arrow";
} else {
_root.rkey = chr(Key.getAscii());
}
if (rkey == ukey) {
ukey = lastKey;
_root.UpKey = _root.RightKey;
} else if (rkey == dkey) {
dkey = lastKey;
_root.DownKey = _root.RightKey;
} else if (rkey == rukey) {
rukey = lastKey;
_root.RotUpKey = _root.RightKey;
} else if (rkey == lkey) {
lkey = lastKey;
_root.LeftKey = _root.RightKey;
} else if (rkey == rdkey) {
rdkey = lastKey;
_root.RotDownKey = _root.RightKey;
} else if (rkey == sukey) {
sukey = lastKey;
_root.SpeedKey = _root.RightKey;
} else if (rkey == fkey) {
fkey = lastKey;
_root.FireKey = _root.RightKey;
}
_root.RightKey = keyPressed;
}
Symbol 287 Button
on (press, release) {
lastKey = _root.rdkey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.rdkey = "BackSpace";
} else if (keyPressed == 20) {
_root.rdkey = "Caplock";
} else if (keyPressed == 17) {
_root.rdkey = "Control";
} else if (keyPressed == 46) {
_root.rdkey = "Delete";
} else if (keyPressed == 40) {
_root.rdkey = "Down Arrow";
} else if (keyPressed == 35) {
_root.rdkey = "End";
} else if (keyPressed == 13) {
_root.rdkey = "Enter";
} else if (keyPressed == 27) {
_root.rdkey = "Escape";
} else if (keyPressed == 36) {
_root.rdkey = "Home";
} else if (keyPressed == 45) {
_root.rdkey = "Insert";
} else if (keyPressed == 37) {
_root.rdkey = "Left Arrow";
} else if (keyPressed == 34) {
_root.rdkey = "Page Down";
} else if (keyPressed == 33) {
_root.rdkey = "Page Up";
} else if (keyPressed == 39) {
_root.rdkey = "Right Arrow";
} else if (keyPressed == 16) {
_root.rdkey = "Shift";
} else if (keyPressed == 32) {
_root.rdkey = "Space";
} else if (keyPressed == 9) {
_root.rdkey = "Tab";
} else if (keyPressed == 38) {
_root.rdkey = "Up Arrow";
} else {
_root.rdkey = chr(Key.getAscii());
}
if (rdkey == ukey) {
ukey = lastKey;
_root.UpKey = _root.RotDownKey;
} else if (rdkey == dkey) {
dkey = lastKey;
_root.DownKey = _root.RotDownKey;
} else if (rdkey == rkey) {
rkey = lastKey;
_root.RightKey = _root.RotDownKey;
} else if (rdkey == lkey) {
lkey = lastKey;
_root.LeftKey = _root.RotDownKey;
} else if (rdkey == rukey) {
rukey = lastKey;
_root.RotUpKey = _root.RotDownKey;
} else if (rdkey == sukey) {
sukey = lastKey;
_root.SpeedKey = _root.RotDownKey;
} else if (rdkey == fkey) {
fkey = lastKey;
_root.FireKey = _root.RotDownKey;
}
_root.RotDownKey = keyPressed;
}
Symbol 288 Button
on (press, release) {
lastKey = _root.fkey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.fkey = "BackSpace";
} else if (keyPressed == 20) {
_root.fkey = "Caplock";
} else if (keyPressed == 17) {
_root.fkey = "Control";
} else if (keyPressed == 46) {
_root.fkey = "Delete";
} else if (keyPressed == 40) {
_root.fkey = "Down Arrow";
} else if (keyPressed == 35) {
_root.fkey = "End";
} else if (keyPressed == 13) {
_root.fkey = "Enter";
} else if (keyPressed == 27) {
_root.fkey = "Escape";
} else if (keyPressed == 36) {
_root.fkey = "Home";
} else if (keyPressed == 45) {
_root.fkey = "Insert";
} else if (keyPressed == 37) {
_root.fkey = "Left Arrow";
} else if (keyPressed == 34) {
_root.fkey = "Page Down";
} else if (keyPressed == 33) {
_root.fkey = "Page Up";
} else if (keyPressed == 39) {
_root.fkey = "Right Arrow";
} else if (keyPressed == 16) {
_root.fkey = "Shift";
} else if (keyPressed == 32) {
_root.fkey = "Space";
} else if (keyPressed == 9) {
_root.fkey = "Tab";
} else if (keyPressed == 38) {
_root.fkey = "Up Arrow";
} else {
_root.fkey = chr(Key.getAscii());
}
if (fkey == ukey) {
ukey = lastKey;
_root.UpKey = _root.FireKey;
} else if (fkey == dkey) {
dkey = lastKey;
_root.DownKey = _root.FireKey;
} else if (fkey == rkey) {
rkey = lastKey;
_root.RightKey = _root.FireKey;
} else if (fkey == lkey) {
lkey = lastKey;
_root.LeftKey = _root.FireKey;
} else if (fkey == rdkey) {
rdkey = lastKey;
_root.RotDownKey = _root.FireKey;
} else if (fkey == sukey) {
sukey = lastKey;
_root.SpeedKey = _root.FireKey;
} else if (fkey == rukey) {
rukey = lastKey;
_root.RotUpKey = _root.FireKey;
}
_root.FireKey = keyPressed;
}
Symbol 289 Button
on (press, release) {
lastKey = _root.sukey;
keyPressed = Key.getCode();
if (keyPressed == 8) {
_root.sukey = "BackSpace";
} else if (keyPressed == 20) {
_root.sukey = "Caplock";
} else if (keyPressed == 17) {
_root.sukey = "Control";
} else if (keyPressed == 46) {
_root.sukey = "Delete";
} else if (keyPressed == 40) {
_root.sukey = "Down Arrow";
} else if (keyPressed == 35) {
_root.sukey = "End";
} else if (keyPressed == 13) {
_root.sukey = "Enter";
} else if (keyPressed == 27) {
_root.sukey = "Escape";
} else if (keyPressed == 36) {
_root.sukey = "Home";
} else if (keyPressed == 45) {
_root.sukey = "Insert";
} else if (keyPressed == 37) {
_root.sukey = "Left Arrow";
} else if (keyPressed == 34) {
_root.sukey = "Page Down";
} else if (keyPressed == 33) {
_root.sukey = "Page Up";
} else if (keyPressed == 39) {
_root.sukey = "Right Arrow";
} else if (keyPressed == 16) {
_root.sukey = "Shift";
} else if (keyPressed == 32) {
_root.sukey = "Space";
} else if (keyPressed == 9) {
_root.sukey = "Tab";
} else if (keyPressed == 38) {
_root.sukey = "Up Arrow";
} else {
_root.sukey = chr(Key.getAscii());
}
if (sukey == ukey) {
ukey = lastKey;
_root.UpKey = _root.SpeedKey;
} else if (sukey == dkey) {
dkey = lastKey;
_root.DownKey = _root.SpeedKey;
} else if (sukey == rkey) {
rkey = lastKey;
_root.RightKey = _root.SpeedKey;
} else if (sukey == lkey) {
lkey = lastKey;
_root.LeftKey = _root.SpeedKey;
} else if (sukey == rdkey) {
rdkey = lastKey;
_root.RotDownKey = _root.SpeedKey;
} else if (sukey == rukey) {
rukey = lastKey;
_root.RotUpKey = _root.SpeedKey;
} else if (sukey == fkey) {
fkey = lastKey;
_root.FireKey = _root.SpeedKey;
}
_root.SpeedKey = keyPressed;
}
Symbol 292 Button
on (press, release) {
SpeedKey = Key.DELETEKEY;
RotUpKey = Key.HOME;
RotDownKey = Key.END;
FireKey = Key.INSERT;
UpKey = Key.UP;
DownKey = Key.DOWN;
LeftKey = Key.LEFT;
RightKey = Key.RIGHT;
rkey = "Right Arrow";
dkey = "Down Arrow";
ukey = "Up Arrow";
lkey = "Left Arrow";
sukey = "Delete";
fkey = "Insert";
rukey = "Home";
rdkey = "End";
}
Symbol 328 MovieClip Frame 1
jc = new Color(jack.jackface);
qc = new Color(queen.queenface);
kc = new Color(king.kingface);
jc1 = new Color(jack.jackface1);
qc1 = new Color(queen.queenface1);
kc1 = new Color(king.kingface1);
spade._visible = false;
heart._visible = false;
club._visible = false;
diamond._visible = false;
i = 1;
while (i < 16) {
this["tem" + i]._visible = false;
this["ctem" + i]._visible = false;
this["dtem" + i]._visible = false;
this["htem" + i]._visible = false;
i++;
}
this.jack._visible = false;
this.queen._visible = false;
this.king._visible = false;
Symbol 328 MovieClip Frame 2
if (mySuit == "S") {
this.spade._visible = true;
if (value == "A") {
tem8._visible = true;
} else if (value == 2) {
tem6._visible = true;
tem10._visible = true;
} else if (value == 3) {
tem6._visible = true;
tem8._visible = true;
tem10._visible = true;
} else if (value == 4) {
tem1._visible = true;
tem5._visible = true;
tem11._visible = true;
tem15._visible = true;
} else if (value == 5) {
tem1._visible = true;
tem5._visible = true;
tem11._visible = true;
tem15._visible = true;
tem8._visible = true;
} else if (value == 6) {
tem1._visible = true;
tem3._visible = true;
tem5._visible = true;
tem11._visible = true;
tem13._visible = true;
tem15._visible = true;
} else if (value == 7) {
tem1._visible = true;
tem3._visible = true;
tem5._visible = true;
tem11._visible = true;
tem13._visible = true;
tem15._visible = true;
tem7._visible = true;
} else if (value == 8) {
tem1._visible = true;
tem2._visible = true;
tem4._visible = true;
tem5._visible = true;
tem11._visible = true;
tem12._visible = true;
tem14._visible = true;
tem15._visible = true;
} else if (value == 9) {
tem1._visible = true;
tem2._visible = true;
tem4._visible = true;
tem5._visible = true;
tem11._visible = true;
tem12._visible = true;
tem14._visible = true;
tem15._visible = true;
tem8._visible = true;
} else if (value == 10) {
tem1._visible = true;
tem2._visible = true;
tem4._visible = true;
tem5._visible = true;
tem11._visible = true;
tem12._visible = true;
tem14._visible = true;
tem15._visible = true;
tem7._visible = true;
tem9._visible = true;
}
} else if (mySuit == "H") {
this.heart._visible = true;
if (value == "A") {
htem8._visible = true;
} else if (value == 2) {
htem6._visible = true;
htem10._visible = true;
} else if (value == 3) {
htem6._visible = true;
htem8._visible = true;
htem10._visible = true;
} else if (value == 4) {
htem1._visible = true;
htem5._visible = true;
htem11._visible = true;
htem15._visible = true;
} else if (value == 5) {
htem1._visible = true;
htem5._visible = true;
htem11._visible = true;
htem15._visible = true;
htem8._visible = true;
} else if (value == 6) {
htem1._visible = true;
htem3._visible = true;
htem5._visible = true;
htem11._visible = true;
htem13._visible = true;
htem15._visible = true;
} else if (value == 7) {
htem1._visible = true;
htem3._visible = true;
htem5._visible = true;
htem11._visible = true;
htem13._visible = true;
htem15._visible = true;
htem7._visible = true;
} else if (value == 8) {
htem1._visible = true;
htem2._visible = true;
htem4._visible = true;
htem5._visible = true;
htem11._visible = true;
htem12._visible = true;
htem14._visible = true;
htem15._visible = true;
} else if (value == 9) {
htem1._visible = true;
htem2._visible = true;
htem4._visible = true;
htem5._visible = true;
htem11._visible = true;
htem12._visible = true;
htem14._visible = true;
htem15._visible = true;
htem8._visible = true;
} else if (value == 10) {
htem1._visible = true;
htem2._visible = true;
htem4._visible = true;
htem5._visible = true;
htem11._visible = true;
htem12._visible = true;
htem14._visible = true;
htem15._visible = true;
htem7._visible = true;
htem9._visible = true;
}
} else if (mySuit == "C") {
this.club._visible = true;
if (value == "A") {
ctem8._visible = true;
} else if (value == 2) {
ctem6._visible = true;
ctem10._visible = true;
} else if (value == 3) {
ctem6._visible = true;
ctem8._visible = true;
ctem10._visible = true;
} else if (value == 4) {
ctem1._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem15._visible = true;
} else if (value == 5) {
ctem1._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem15._visible = true;
ctem8._visible = true;
} else if (value == 6) {
ctem1._visible = true;
ctem3._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem13._visible = true;
ctem15._visible = true;
} else if (value == 7) {
ctem1._visible = true;
ctem3._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem13._visible = true;
ctem15._visible = true;
ctem7._visible = true;
} else if (value == 8) {
ctem1._visible = true;
ctem2._visible = true;
ctem4._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem12._visible = true;
ctem14._visible = true;
ctem15._visible = true;
} else if (value == 9) {
ctem1._visible = true;
ctem2._visible = true;
ctem4._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem12._visible = true;
ctem14._visible = true;
ctem15._visible = true;
ctem8._visible = true;
} else if (value == 10) {
ctem1._visible = true;
ctem2._visible = true;
ctem4._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem12._visible = true;
ctem14._visible = true;
ctem15._visible = true;
ctem7._visible = true;
ctem9._visible = true;
}
} else if (mySuit == "D") {
this.diamond._visible = true;
if (value == "A") {
dtem8._visible = true;
} else if (value == 2) {
dtem6._visible = true;
dtem10._visible = true;
} else if (value == 3) {
dtem6._visible = true;
dtem8._visible = true;
dtem10._visible = true;
} else if (value == 4) {
dtem1._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem15._visible = true;
} else if (value == 5) {
dtem1._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem15._visible = true;
dtem8._visible = true;
} else if (value == 6) {
dtem1._visible = true;
dtem3._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem13._visible = true;
dtem15._visible = true;
} else if (value == 7) {
dtem1._visible = true;
dtem3._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem13._visible = true;
dtem15._visible = true;
dtem7._visible = true;
} else if (value == 8) {
dtem1._visible = true;
dtem2._visible = true;
dtem4._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem12._visible = true;
dtem14._visible = true;
dtem15._visible = true;
} else if (value == 9) {
dtem1._visible = true;
dtem2._visible = true;
dtem4._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem12._visible = true;
dtem14._visible = true;
dtem15._visible = true;
dtem8._visible = true;
} else if (value == 10) {
dtem1._visible = true;
dtem2._visible = true;
dtem4._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem12._visible = true;
dtem14._visible = true;
dtem15._visible = true;
dtem7._visible = true;
dtem9._visible = true;
}
}
if (value == "J") {
jack._visible = true;
if ((mySuit == "S") || (mySuit == "C")) {
jc.setRGB(0);
jc1.setRGB(0);
} else {
jc.setRGB(16711680);
jc1.setRGB(16711680);
}
}
if (value == "Q") {
queen._visible = true;
if ((mySuit == "S") || (mySuit == "C")) {
qc.setRGB(0);
qc1.setRGB(0);
} else {
qc.setRGB(16711680);
qc1.setRGB(16711680);
}
}
if (value == "K") {
if ((mySuit == "S") || (mySuit == "C")) {
kc.setRGB(0);
kc1.setRGB(0);
} else {
kc.setRGB(16711680);
kc1.setRGB(16711680);
}
king._visible = true;
}
Symbol 328 MovieClip Frame 3
gotoAndPlay (2);
Symbol 331 Button
on (press) {
if (firstDeal) {
if (money >= (bet * 2)) {
betText = "";
_root.bet = _root.bet * 2;
_root.hit = true;
_root.double = true;
_root.gotoAndPlay("player");
} else {
betText = "not enough money";
}
}
}
Symbol 334 Button
on (press) {
if (turn == true) {
betText = "";
_root.hit = true;
_root.gotoAndPlay("playerinit");
}
}
Symbol 336 Button
on (press) {
if (turn == true) {
betText = "";
_root.gotoAndPlay("dealer");
}
}
Symbol 338 Button
on (press) {
if (gameOver) {
if (money < bet) {
bet = money;
}
if ((money >= bet) && (0 < bet)) {
betText = "";
i = 0;
while (i < pCards) {
_root["pcard" + i].removeMovieClip();
i++;
}
i = 0;
while (i < dCards) {
_root["dcard" + i].removeMovieClip();
i++;
}
_root.gotoAndPlay("newHand");
} else if (0 >= bet) {
betText = "need to raise bet";
} else {
betText = "not enough money";
}
}
}
Symbol 340 Button
on (press) {
if (gameOver == true) {
_root.bet = _root.bet + 5;
}
}
Symbol 342 Button
on (press) {
if (gameOver == true) {
_root.bet = _root.bet - 5;
}
}
Symbol 348 Button
on (press) {
if (gameOver == true) {
_root.bet = money;
}
}
Symbol 350 MovieClip Frame 1
_root.lastAte++;
if (!_root.computer) {
_root.lastPlayed++;
}
_root.phone++;
this.hungerBar._width = (_root.lastAte / _root.finalEat) * meter._width;
this.compBar._width = (_root.lastPlayed / _root.finalPlayed) * meter._width;
if (_root.lastAte >= _root.finalEat) {
_root.gotoAndPlay("dead_by_eat");
} else if (_root.lastPlayed >= _root.finalPlayed) {
if ((_root._currentFrame != 34) && (_root._currentframe != 35)) {
_root.gotoAndPlay("dead_by_played");
}
}
Symbol 350 MovieClip Frame 2
gotoAndPlay (1);
Symbol 356 MovieClip Frame 1
jc = new Color(jack.jackface);
qc = new Color(queen.queenface);
kc = new Color(king.kingface);
jc1 = new Color(jack.jackface1);
qc1 = new Color(queen.queenface1);
kc1 = new Color(king.kingface1);
spade._visible = false;
heart._visible = false;
club._visible = false;
diamond._visible = false;
i = 1;
while (i < 16) {
this["tem" + i]._visible = false;
this["ctem" + i]._visible = false;
this["dtem" + i]._visible = false;
this["htem" + i]._visible = false;
i++;
}
this.jack._visible = false;
this.queen._visible = false;
this.king._visible = false;
Symbol 356 MovieClip Frame 2
if (mySuit == "S") {
this.spade._visible = true;
if (value == "A") {
tem8._visible = true;
} else if (value == 2) {
tem6._visible = true;
tem10._visible = true;
} else if (value == 3) {
tem6._visible = true;
tem8._visible = true;
tem10._visible = true;
} else if (value == 4) {
tem1._visible = true;
tem5._visible = true;
tem11._visible = true;
tem15._visible = true;
} else if (value == 5) {
tem1._visible = true;
tem5._visible = true;
tem11._visible = true;
tem15._visible = true;
tem8._visible = true;
} else if (value == 6) {
tem1._visible = true;
tem3._visible = true;
tem5._visible = true;
tem11._visible = true;
tem13._visible = true;
tem15._visible = true;
} else if (value == 7) {
tem1._visible = true;
tem3._visible = true;
tem5._visible = true;
tem11._visible = true;
tem13._visible = true;
tem15._visible = true;
tem7._visible = true;
} else if (value == 8) {
tem1._visible = true;
tem2._visible = true;
tem4._visible = true;
tem5._visible = true;
tem11._visible = true;
tem12._visible = true;
tem14._visible = true;
tem15._visible = true;
} else if (value == 9) {
tem1._visible = true;
tem2._visible = true;
tem4._visible = true;
tem5._visible = true;
tem11._visible = true;
tem12._visible = true;
tem14._visible = true;
tem15._visible = true;
tem8._visible = true;
} else if (value == 10) {
tem1._visible = true;
tem2._visible = true;
tem4._visible = true;
tem5._visible = true;
tem11._visible = true;
tem12._visible = true;
tem14._visible = true;
tem15._visible = true;
tem7._visible = true;
tem9._visible = true;
}
} else if (mySuit == "H") {
this.heart._visible = true;
if (value == "A") {
htem8._visible = true;
} else if (value == 2) {
htem6._visible = true;
htem10._visible = true;
} else if (value == 3) {
htem6._visible = true;
htem8._visible = true;
htem10._visible = true;
} else if (value == 4) {
htem1._visible = true;
htem5._visible = true;
htem11._visible = true;
htem15._visible = true;
} else if (value == 5) {
htem1._visible = true;
htem5._visible = true;
htem11._visible = true;
htem15._visible = true;
htem8._visible = true;
} else if (value == 6) {
htem1._visible = true;
htem3._visible = true;
htem5._visible = true;
htem11._visible = true;
htem13._visible = true;
htem15._visible = true;
} else if (value == 7) {
htem1._visible = true;
htem3._visible = true;
htem5._visible = true;
htem11._visible = true;
htem13._visible = true;
htem15._visible = true;
htem7._visible = true;
} else if (value == 8) {
htem1._visible = true;
htem2._visible = true;
htem4._visible = true;
htem5._visible = true;
htem11._visible = true;
htem12._visible = true;
htem14._visible = true;
htem15._visible = true;
} else if (value == 9) {
htem1._visible = true;
htem2._visible = true;
htem4._visible = true;
htem5._visible = true;
htem11._visible = true;
htem12._visible = true;
htem14._visible = true;
htem15._visible = true;
htem8._visible = true;
} else if (value == 10) {
htem1._visible = true;
htem2._visible = true;
htem4._visible = true;
htem5._visible = true;
htem11._visible = true;
htem12._visible = true;
htem14._visible = true;
htem15._visible = true;
htem7._visible = true;
htem9._visible = true;
}
} else if (mySuit == "C") {
this.club._visible = true;
if (value == "A") {
ctem8._visible = true;
} else if (value == 2) {
ctem6._visible = true;
ctem10._visible = true;
} else if (value == 3) {
ctem6._visible = true;
ctem8._visible = true;
ctem10._visible = true;
} else if (value == 4) {
ctem1._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem15._visible = true;
} else if (value == 5) {
ctem1._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem15._visible = true;
ctem8._visible = true;
} else if (value == 6) {
ctem1._visible = true;
ctem3._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem13._visible = true;
ctem15._visible = true;
} else if (value == 7) {
ctem1._visible = true;
ctem3._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem13._visible = true;
ctem15._visible = true;
ctem7._visible = true;
} else if (value == 8) {
ctem1._visible = true;
ctem2._visible = true;
ctem4._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem12._visible = true;
ctem14._visible = true;
ctem15._visible = true;
} else if (value == 9) {
ctem1._visible = true;
ctem2._visible = true;
ctem4._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem12._visible = true;
ctem14._visible = true;
ctem15._visible = true;
ctem8._visible = true;
} else if (value == 10) {
ctem1._visible = true;
ctem2._visible = true;
ctem4._visible = true;
ctem5._visible = true;
ctem11._visible = true;
ctem12._visible = true;
ctem14._visible = true;
ctem15._visible = true;
ctem7._visible = true;
ctem9._visible = true;
}
} else if (mySuit == "D") {
this.diamond._visible = true;
if (value == "A") {
dtem8._visible = true;
} else if (value == 2) {
dtem6._visible = true;
dtem10._visible = true;
} else if (value == 3) {
dtem6._visible = true;
dtem8._visible = true;
dtem10._visible = true;
} else if (value == 4) {
dtem1._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem15._visible = true;
} else if (value == 5) {
dtem1._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem15._visible = true;
dtem8._visible = true;
} else if (value == 6) {
dtem1._visible = true;
dtem3._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem13._visible = true;
dtem15._visible = true;
} else if (value == 7) {
dtem1._visible = true;
dtem3._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem13._visible = true;
dtem15._visible = true;
dtem7._visible = true;
} else if (value == 8) {
dtem1._visible = true;
dtem2._visible = true;
dtem4._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem12._visible = true;
dtem14._visible = true;
dtem15._visible = true;
} else if (value == 9) {
dtem1._visible = true;
dtem2._visible = true;
dtem4._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem12._visible = true;
dtem14._visible = true;
dtem15._visible = true;
dtem8._visible = true;
} else if (value == 10) {
dtem1._visible = true;
dtem2._visible = true;
dtem4._visible = true;
dtem5._visible = true;
dtem11._visible = true;
dtem12._visible = true;
dtem14._visible = true;
dtem15._visible = true;
dtem7._visible = true;
dtem9._visible = true;
}
}
if (value == "J") {
jack._visible = true;
if ((mySuit == "S") || (mySuit == "C")) {
jc.setRGB(0);
jc1.setRGB(0);
} else {
jc.setRGB(16711680);
jc1.setRGB(16711680);
}
}
if (value == "Q") {
queen._visible = true;
if ((mySuit == "S") || (mySuit == "C")) {
qc.setRGB(0);
qc1.setRGB(0);
} else {
qc.setRGB(16711680);
qc1.setRGB(16711680);
}
}
if (value == "K") {
if ((mySuit == "S") || (mySuit == "C")) {
kc.setRGB(0);
kc1.setRGB(0);
} else {
kc.setRGB(16711680);
kc1.setRGB(16711680);
}
king._visible = true;
}
Symbol 356 MovieClip Frame 3
gotoAndPlay (2);
Symbol 357 Button
on (press) {
if (gameOver) {
gotoAndPlay (4);
_root.dcard.duplicateMovieClip("dcard0", 100);
i = 0;
while (i < 100) {
_root["pcard" + i].removeMovieClip();
i++;
}
i = 0;
while (i < 100) {
_root["dcard" + i].removeMovieClip();
i++;
}
}
}
Symbol 361 Button
on (press, release) {
gotoAndPlay (4);
}
Symbol 366 Button
on (press, release) {
gotoAndPlay (1);
}
Symbol 369 MovieClip Frame 1
playedYes = false;
if (_root.mood == "good") {
this.mouth.attachMovie("smile", "smile", 1);
if (!playedYes) {
playedYes = true;
yes = new Sound();
yes.attachSound("yes");
yes.start();
}
}
if (_root.mood == "plain") {
this.mouth.attachMovie("plain", "plain", 1);
}
if (_root.mood == "bad") {
this.mouth.attachMovie("frown", "frown", 1);
}
if (_root.mood == "shocked") {
this.mouth.attachMovie("shocked", "shocked", 1);
}
Symbol 369 MovieClip Frame 2
if (_root.mood == "good") {
this.mouth.attachMovie("smile", "smile", 1);
if (!playedYes) {
playedYes = true;
yes = new Sound();
yes.attachSound("yes");
yes.start();
}
}
if (_root.mood == "plain") {
this.mouth.attachMovie("plain", "plain", 1);
}
if (_root.mood == "bad") {
this.mouth.attachMovie("frown", "frown", 1);
}
if (_root.mood == "shocked") {
this.mouth.attachMovie("shocked", "shocked", 1);
}
Symbol 369 MovieClip Frame 3
gotoAndPlay (2);
Symbol 381 Button
on (press, release) {
betAmount = Number(betAmount);
if ((((0 < maxBet) && (0 < betAmt)) && (maxBet >= betAmt)) && (money >= betAmt)) {
wagerText = "";
gotoAndPlay (7);
} else if (maxBet < betAmt) {
wagerText = "Your bet is too high, you can only bet " + maxBet;
} else if (_root.money < betAmt) {
wagerText = "You don't have enough money";
} else if (0 >= betAmt) {
wagerText = "You need to bet more money";
}
}
Symbol 386 Button
on (release) {
gotoAndPlay (4);
}
Symbol 396 MovieClip Frame 1
if (_root.TVOn) {
screen._visible = true;
screen._alpha = random(70);
} else {
screen._visible = false;
}
Symbol 396 MovieClip Frame 2