Frame 1
stop();
Frame 2
stop();
Frame 3
stop();
Frame 4
function addToInventory(k) {
if (!isInInventory(k)) {
inventory.push(k);
}
invNum = inventory.length - 1;
}
function remFromInventory(k) {
for (var _local2 in inventory) {
if (inventory[_local2] == k) {
inventory.splice(_local2, 1);
}
}
}
function isInInventory(k) {
for (var _local2 in inventory) {
if (inventory[_local2] == k) {
return(true);
}
}
return(false);
}
function getScreenNum(xval) {
return(1 + Math.floor(xval / Stage.width));
}
function displayMsg(s) {
if (s == display.newText) {
return(undefined);
}
msgDisplay = true;
display.moving = true;
display.showing = true;
display.endPoint = -280;
display.newText = s;
}
function hideMsg() {
if (!msgDisplay) {
return(undefined);
}
msgDisplay = false;
display.moving = true;
display.showing = false;
display.endPoint = -280;
display.newText = "";
}
function actionHandler(s) {
_root.kSd = true;
switch (s) {
case "sc1treec" :
var _local2 = new Array();
if (!_root.isInInventory(1)) {
_root.invEnabled = false;
_local2.push(["StrawberryClock", "Hey, heres WoodClock's handsaw. I had better get this back to him right away!"]);
_root.addToInventory(1);
} else {
_local2.push(["StrawberryClock", "I really don't know what you expect to be back here. At this rate, you are shaping up to be one sorry \"would-be\" king."]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc1door1" :
sceneNum = 2;
player.x = 209;
player.y = 375;
break;
case "sc1banan" :
_local2 = new Array();
if (_root.gameTriggers[7] == 0) {
_local2.push(["StrawberryClock", "Hey, what's new, BananaClock?"]);
_local2.push(["BananaClock", "GTFO, n00b!"]);
} else if ((_root.gameTriggers[7] == 1) && (isInInventory(4))) {
_root.invEnabled = false;
_local2.push(["StrawberryClock", "Hey, BananaClock. Here is that yo-yo you wanted."]);
_local2.push(["BananaClock", "Thanks."]);
_local2.push(["StrawberryClock", "...so, can I take that slingshot?"]);
_local2.push(["BananaClock", "WTF do I care? It's not even mine."]);
_root.remFromInventory(4);
_root.addToInventory(5);
} else if (_root.gameTriggers[7] == 1) {
_local2.push(["StrawberryClock", "Hey, BananaClock. Could I possibly have your slingshot?"]);
_local2.push(["BananaClock", "GTFO, n00b! -- Well, I guess I could trade you for it. I've had my eye on that yo-yo for sale in AubergineClock's shop."]);
_local2.push(["StrawberryClock", "Alright, I could do that for you."]);
_local2.push(["BananaClock", "...whatev..."]);
_root.gameTriggers[4] = 1;
}
_root.currentConv = new Conversation(_local2);
break;
case "sc1door2" :
sceneNum = 4;
player.x = 155;
player.y = 375;
break;
case "sc1door3" :
sceneNum = 3;
player.x = 60;
player.y = 375;
break;
case "sc1rocks" :
_local2 = new Array();
if (!isInInventory(6)) {
_root.invEnabled = false;
_local2.push(["StrawberryClock", "I guess I'll just fish through these rocks and pick out some small ones."]);
_local2.push(["StrawberryClock", "There. That should be enough."]);
_root.addToInventory(6);
} else {
_local2.push(["StrawberryClock", "And what exactly do you expect me to do with MORE rocks? Make a rock garden? This is hardly the time for the art of Zen."]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc1treef" :
_local2 = new Array();
if ((_root.gameTriggers[5] > 0) && (isInInventory(2))) {
_local2.push(["StrawberryClock", "I guess this is as good a place as any to use my ladder. No sense in letting this marvelous gift go to waste."]);
_root.remFromInventory(2);
_root.gameTriggers[6] = 1;
} else if (_root.gameTriggers[6] >= 1) {
_root.mapEnabled = false;
_local2.push(["StrawberryClock", "Yeah, yeah, I'm climbing..."]);
_root.player.x = 100;
_root.player.y = Y_BOTTOM - 50;
_root.sceneNum = 6;
} else {
_local2.push(["StrawberryClock", "That is a magnificent tree. I mean, really. As far as trees go, this is one of the nicest."]);
_local2.push(["StrawberryClock", "I guess what I'm trying to say is, if there were to be a tree beauty contest, this would be the winner."]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc1orang" :
_local2 = new Array();
if (_root.inventory[_root.invNum] == 7) {
_root.mapEnabled = false;
_local2.push(["OrangeClock", "Nice outfit! Go ahead through, \"sir\"."]);
_root.sceneNum = 6;
_root.player.x = 840;
_root.player.y = Y_BOTTOM - 10;
} else if (_root.gameTriggers[5] == 0) {
_local2.push(["StrawberryClock", "Can you please let me through? I have to get into the castle."]);
_local2.push(["OrangeClock", "And why would I do a thing like that?"]);
_local2.push(["StrawberryClock", "Because this creepy ghost is floating in my house right now, and he told me I was going to be king."]);
_local2.push(["OrangeClock", "I see. That's fair enough. But if I let you through here, I could lose my job. How about you just climb the wall?"]);
_local2.push(["StrawberryClock", "Those goddamn walls? That's impossible!"]);
_local2.push(["OrangeClock", "Don't be so sure of that. If go by that tree over there, you might be able to climb over without getting caught."]);
_root.gameTriggers[5] = 1;
} else if (_root.gameTriggers[5] >= 1) {
_local2.push(["OrangeClock", "If I let you through here, I could lose my job. How about you just climb the wall?"]);
_local2.push(["StrawberryClock", "Those goddamn walls? That's impossible!"]);
_local2.push(["OrangeClock", "Don't be so sure of that. If go by that tree over there, you might be able to climb over without getting caught."]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc1door4" :
sceneNum = 5;
player.x = 95;
player.y = 375;
break;
case "sc2ghost" :
_local2 = new Array();
if (_root.gameTriggers[0] == 0) {
_local2.push(["The Ghost of PineappleClock", "Straw... Straw...\rStrawberryClock..."]);
_local2.push(["StrawberryClock", "Ummm... Yes? That's me..."]);
_local2.push(["The Ghost of PineappleClock", "Heed my words child:\r You have a duty. You are to be the next King of the Portal."]);
_local2.push(["StrawberryClock", "Me!? King!? But how!?"]);
_local2.push(["The Ghost of PineappleClock", "You must remove our current king, King Waid Flump! You must find your way into the Portal Castle, and defeat him."]);
} else if (_root.gameTriggers[0] == 1) {
_local2.push(["The Ghost of PineappleClock", "I hope you don't mind if I just, ya' know... hover here a while..."]);
_local2.push(["StrawberryClock", "Nah. That's cool, I guess."]);
} else if ((_root.gameTriggers[0] % 2) == 0) {
_local2.push(["StrawberryClock", "The way he just hovers there... It kinda creeps me out, ya' know?"]);
} else {
_local2.push(["The Ghost of PineappleClock", "What are you still doing here? You must remove our current king, King Waid Flump! You must find your way into the Portal Castle, and defeat him."]);
}
_root.currentConv = new Conversation(_local2);
_root.gameTriggers[0]++;
break;
case "sc2coins" :
_local2 = new Array();
if (_root.gameTriggers[3] == 0) {
_root.invEnabled = false;
_local2.push(["StrawberryClock", "Yay, 6 Coins Get!"]);
_root.addToInventory(3);
_root.gameTriggers[3] = 1;
} else {
_local2.push(["StrawberryClock", "Nothing left here but your poor taste in furniture."]);
_local2.push(["StrawberryClock", "You know, if you ever plan on landing a Mrs. StrawberryClock, you should think about redecorating."]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc2door1" :
sceneNum = 1;
player.x = 375;
player.y = 305;
break;
case "sc3door1" :
sceneNum = 1;
player.x = 1780;
player.y = Y_TOPS[1];
break;
case "sc3auber" :
_local2 = new Array();
if (_root.gameTriggers[4] == 0) {
_local2.push(["StrawberryClock", "He's not selling anything I'm interested in."]);
} else if ((_root.gameTriggers[4] == 1) && (!isInInventory(3))) {
_local2.push(["AubergineClock", "What can I do for you this fine day, sir?"]);
_local2.push(["StrawberryClock", "I am interested in purchasing your finest yo-yo, my good man."]);
_local2.push(["AubergineClock", "Good choice, sir. Your total comes to 5 Coins."]);
_local2.push(["StrawberryClock", "Funny story actually; I don't actually have any money."]);
_local2.push(["AubergineClock", "Then come back when you do."]);
} else if ((_root.gameTriggers[4] == 1) && (isInInventory(3))) {
_root.invEnabled = false;
_local2.push(["AubergineClock", "What can I do for you this fine day, sir?"]);
_local2.push(["StrawberryClock", "I am interested in purchasing your finest yo-yo, my good man."]);
_local2.push(["AubergineClock", "Good choice, sir. Your total comes to 5 Coins."]);
_local2.push(["StrawberryClock", "How about 6 Coins? It's all I've got."]);
_local2.push(["AubergineClock", "Alright! I'll take it."]);
_local2.push(["StrawberryClock", "Heh, sucker! StrawberryClock, you are one thrifty consumer."]);
_root.remFromInventory(3);
_root.addToInventory(4);
_root.gameTriggers[1] = 1;
} else {
_local2.push(["StrawberryClock", "Nothing left in this shop but AubergineClock himself. And I'm sure you don't have enough money for him."]);
_local2.push(["StrawberryClock", "Wait... What exactly does that imply?"]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc3eyoyo" :
_root.currentConv = new Conversation([["StrawberryClock", "It's a goddamn yo-yo. Are you expecting magical properties or something? GTFO!"]]);
break;
case "sc4door1" :
sceneNum = 1;
player.x = 1215;
player.y = Y_TOPS[1];
break;
case "sc4cloud" :
_local2 = new Array();
if (_root.gameTriggers[10] == 0) {
_local2.push(["Cloud Strife", "Noble adventurer, what can I do to help you?"]);
_local2.push(["StrawberryClock", "Nothing, at the moment. I'd mention something about coming back to see you later in the game, but foreshadowing makes for poor script writing."]);
} else if (_root.gameTriggers[10] == 1) {
_root.invEnabled = false;
_local2.push(["StrawberryClock", "I'm looking for something to help me with a quest. A feather that restores life?"]);
_local2.push(["Cloud Strife", "Yeah, sure... It's called a \"phoenix down\". I guess I can let you have it."]);
_local2.push(["Aeris Gainsborough", "But what will we do now if one of us dies?"]);
_local2.push(["Cloud Strife", "Load from a previous saved game file?"]);
_root.addToInventory(8);
} else if (_root.gameTriggers[10] == 2) {
_local2.push(["Cloud Strife", "Good luck, noble adventurer!"]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc5door1" :
sceneNum = 1;
player.x = 4720;
player.y = Y_TOPS[1];
break;
case "sc5woodc" :
_local2 = new Array();
if (_root.gameTriggers[2] == 0) {
_local2.push(["WoodClock", "StrawberryClock, am I glad to see you!"]);
_local2.push(["StrawberryClock", "What can I do for you, WoodClock?"]);
_local2.push(["WoodClock", "I lost my handsaw, and I need it badly? If you help me find it, I'll give you... uhh... this ladder?"]);
_local2.push(["StrawberryClock", "That sounds like a decent trade (I guess). Where did you lose it?"]);
_local2.push(["WoodClock", "All I can remember is that I went to go cut down that rotten tree by your house, when it suddenly began storming."]);
_local2.push(["WoodClock", "I ran all the way home. Thats the last time I remember seeing it."]);
_local2.push(["StrawberryClock", "Then that is where I will begin looking."]);
_root.gameTriggers[2] = 1;
} else if (_root.isInInventory(1)) {
_root.invEnabled = false;
_local2.push(["WoodClock", "Oh, frabjous day! You've found my handsaw. Here, take this ladder as your payment, I insist!"]);
_local2.push(["StrawberryClock", "Gee...\r...Thanks."]);
_root.gameTriggers[2] = 2;
_root.remFromInventory(1);
_root.addToInventory(2);
} else if (_root.gameTriggers[2] == 1) {
_local2.push(["WoodClock", "All I can remember is that I went to go cut down that rotten tree by your house, when it suddenly began storming."]);
_local2.push(["WoodClock", "I ran all the way home. Thats the last time I remember seeing it."]);
_local2.push(["StrawberryClock", "Then that is where I will begin looking."]);
} else if (_root.gameTriggers[2] == 2) {
_local2.push(["StrawberryClock", "No thanks. If I talk to him again, he might have some other lame errand for me to run."]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc6leave" :
sceneNum = 1;
player.x = 3585;
player.y = Y_TOPS[1];
break;
case "sc6cgate" :
_local2 = new Array();
if ((_root.gameTriggers[7] == 2) && (_root.inventory[_root.invNum] == 7)) {
sceneNum = 7;
player.x = 1590;
player.y = 375;
} else if (_root.gameTriggers[7] == 2) {
_local2.push(["StrawberryClock", "Yeah, definately, you should just run in there. You should probably dress a bit more like a guard, if youre going to run in, head-first."]);
_local2.push(["StrawberryClock", "You're an idiot, you know..."]);
} else {
_local2.push(["StrawberryClock", "The gate is locked, and I wouldn't start waiting for it to open just because you \"will\" it so."]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc6grdun" :
_local2 = new Array();
_local2.push(["StrawberryClock", "Whee! Guard Outfit Get!"]);
_root.invEnabled = false;
_root.addToInventory(7);
_root.gameTriggers[8] = 1;
_root.currentConv = new Conversation(_local2);
break;
case "sc6bellw" :
_local2 = new Array();
if (_root.gameTriggers[7] == 2) {
_local2.push(["StrawberryClock", "Hitting the bell at this point would probably just be considered obnoxious."]);
} else if (((_root.gameTriggers[7] == 1) && (isInInventory(5))) && (isInInventory(6))) {
_local2.push(["StrawberryClock", "You know, with this slingshot, I can just about hit the bell. Let's see..."]);
_local2.push(["StrawberryClock", "PERFECT! Now to get inside the castle!", "castlebell"]);
_root.gameTriggers[7] = 2;
} else if ((_root.gameTriggers[7] == 1) && (isInInventory(6))) {
_local2.push(["StrawberryClock", "Well, I think these rocks are the right idea, but I could never hit it from here. If only I had something to make these fly farther."]);
_local2.push(["StrawberryClock", "I think I remember BananaClock having a slingshot. I wonder if he would be willing to part with it."]);
} else if ((_root.gameTriggers[7] == 1) && (isInInventory(5))) {
_local2.push(["StrawberryClock", "Has it occured to you that I have no ammunition for this slingshot. Though, I can imagine it would fly pretty far if I threw it."]);
_local2.push(["StrawberryClock", "On second thought, I would probably have more luck shooting imaginary rocks than I would trying to throw this slingshot at that window."]);
} else if (_root.gameTriggers[7] <= 1) {
_local2.push(["StrawberryClock", "Hey, look! I bet that is the bell that alerts the guards to open the gate. What poor planning, putting it so close to a window."]);
_local2.push(["StrawberryClock", "If only I had something to hit the bell with. Maybe a rock or something. But I could never throw that high."]);
_local2.push(["StrawberryClock", "You know, the thought just occured to me -- the window is broken. I'm clearly not the first to think of this."]);
_root.gameTriggers[7] = 1;
}
_root.currentConv = new Conversation(_local2);
break;
case "sc7kwaid" :
_local2 = new Array();
if (_root.gameTriggers[11] == 0) {
_local2.push(["StrawberryClock", "Oh, Yeah... It is definately going to be that easy. All you have to do is \"ask\" him nicely to leave? Umm, think again. GTFO!"]);
} else {
_local2.push(["King Waid Flump", "The GHOSTS!"]);
_root.endGame = true;
}
_root.currentConv = new Conversation(_local2);
break;
case "sc7light" :
if ((_root.gameTriggers[9] == 1) && (_root.gameTriggers[11] == 0)) {
_local2 = new Array();
_local2.push(["StrawberryClock", "If this castle were a bit more advanced, they would have installed a Clapper (C). But I suppose I could be bothered to flip a switch. What a hassle!"]);
_root.currentConv = new Conversation(_local2);
_root.mapEnabled = false;
_root.gameTriggers[11] = 1;
}
break;
case "sc7tfulp" :
_local2 = new Array();
if (_root.gameTriggers[10] == 2) {
_local2.push(["StrawberryClock", "I have got to say, that was a fuckin' ripoff. Goddamn statue!"]);
} else if (isInInventory(8)) {
_root.invEnabled = false;
_local2.push(["StrawberryClock", "I'll just place this phoenix down in the statue's hand."]);
_local2.push(["Golden Statue", "Thank you, adventurer. You gain a level."]);
_local2.push(["StrawberryClock", "Whoo! I gained a level!"]);
_local2.push(["StrawberryClock", "Wait! This game doesn't have a stat system! There are no fuckin' levels! I have got to say, that was a fuckin' ripoff. Goddamn statue!"]);
_root.remFromInventory(8);
_root.gameTriggers[10] = 2;
} else if (_root.gameTriggers[10] == 1) {
_local2.push(["Golden Statue", "Bring me a feather which restores life, and place it in my hand,\rand I will shine my blessings upon you."]);
_local2.push(["StrawberryClock", "Ooooh! Sounds sexy!"]);
} else {
_local2.push(["StrawberryClock", "What a beautiful golden statue! It is so beautiful. And golden. And statue-y."]);
_local2.push(["StrawberryClock", "Hmmm, what is this? There is an inscription at the foot of the statue. It seems this is a statue of the first king, Tom Flump. It reads:"]);
_local2.push(["Golden Statue", "Bring me a feather which restores life, and place it in my hand,\rand I will shine my blessings upon you."]);
_local2.push(["StrawberryClock", "Ooooh! Sounds sexy!"]);
_root.gameTriggers[10] = 1;
}
_root.currentConv = new Conversation(_local2);
break;
case "sc7door1" :
_local2 = new Array();
if (_root.gameTriggers[9] == 0) {
_local2.push(["LemonClock", "Just be careful. You remember what happened last time power went out in the castle."]);
_local2.push(["LimeClock", "Oh, dear lord, yes. King Waid nearly had a fit. Kept yelling something about ghosts and Dracula."]);
_local2.push(["LemonClock", "What a royal nutcase!"]);
_local2.push(["LimeClock", "You can say that again..."]);
_root.gameTriggers[9] = 1;
} else {
_local2.push(["LemonClock", "It's hard to imagine that such a powerful man is afraid of the dark."]);
_local2.push(["LimeClock", "Royally lame!"]);
}
_root.currentConv = new Conversation(_local2);
break;
case "sc7leave" :
sceneNum = 6;
player.x = 840;
player.y = Y_TOPS[6];
break;
}
}
function timeout(f, t) {
setTimeout(f, t);
}
function playSoundEffect(id) {
var _local2 = _root.createEmptyMovieClip(id + getTimer(), _root.getNextHighestDepth());
var _local3 = new SoundEffect(_local2);
_local3.play(id, _local2);
}
var TOP_MAIN = 295;
var TOP_ROOMS = 350;
var Y_TOPS = new Array(null, TOP_MAIN, TOP_ROOMS, TOP_ROOMS, TOP_ROOMS, TOP_ROOMS, TOP_MAIN, TOP_MAIN);
var Y_BOTTOM = (Stage.height - 10);
var FLAG_N = 1;
var FLAG_W = 2;
var FLAG_E = 4;
var FLAG_S = 8;
var sc1flags = new Array(null, 4, 6, 6, 6, 6, 6, 7, 6, 2);
var sc2flags = new Array(null, 8);
var sc3flags = new Array(null, 2);
var sc4flags = new Array(null, 8);
var sc5flags = new Array(null, 8);
var sc6flags = new Array(null, 4, 15, 2);
var sc7flags = new Array(null, 4, 6, 6);
var compFlags = new Array(null, sc1flags, sc2flags, sc3flags, sc4flags, sc5flags, sc6flags, sc7flags);
var mapEnabled = true;
var gameEnabled = true;
var invEnabled = true;
var endGame = false;
var kSd = false;
var spaceHandler = false;
var currentConv;
var sceneNum = 2;
var player = new Object();
var gameTriggers = new Array();
var i = 0;
while (i < 100) {
gameTriggers.push(0);
i++;
}
var dist = 50;
var dist2 = (dist * dist);
player.x = 460;
player.y = Y_TOPS[sceneNum];
player.spd = 7;
var inventory = new Array();
var invNum = 0;
sbc.onEnterFrame = function () {
if (!_root.mapEnabled) {
return(undefined);
}
this._x = _root.player.x % Stage.width;
this._y = _root.player.y;
};
sbc.onEnterFrame();
inven.stop();
inven.onEnterFrame = function () {
_root.invNum = Math.max(0, Math.min(_root.invNum, _root.inventory.length - 1));
if (!_root.invEnabled) {
return(undefined);
}
_root.inven.gotoAndStop((_root.inventory.length ? (_root.inventory[_root.invNum] + 1) : 1));
_root.invDBtn._visible = (_root.invDBtn.enabled = _root.invNum < (_root.inventory.length - 1));
_root.invUBtn._visible = (_root.invUBtn.enabled = _root.invNum > 0);
};
inven.onEnterFrame();
scene.stop();
scene.onEnterFrame = function () {
if (!_root.mapEnabled) {
return(undefined);
}
this.gotoAndStop(_root.sceneNum);
this.screen.stop();
this.screen.gotoAndStop(getScreenNum(_root.player.x));
};
scene.onEnterFrame();
display.moving = false;
display.showing = false;
display._x = (display.endPoint = -280);
display.spd = 0;
display.newText = "";
var msgDisplay = false;
display.onEnterFrame = function () {
var _local3 = 0.92;
if (this.moving) {
var _local2 = ((this._x >= this.endPoint) ? -1 : 1);
this._x = this._x + ((this.spd = this.spd + _local2));
this.spd = this.spd * _local3;
if (((_local2 < 0) && (this.endPoint == -280)) && (this._x < -270)) {
this._x = -280;
this.spd = 0;
if (this.showing) {
this.endPoint = -5;
this.txt.text = this.newText;
} else {
this.moving = false;
}
}
if ((Math.abs(this.spd) < 0.01) && (Math.abs(this.endPoint - this._x) < 10)) {
this._x = this.endPoint;
this.moving = false;
}
}
};
display.onEnterFrame();
_root.onEnterFrame = function () {
if (!gameEnabled) {
hideMsg();
return(undefined);
}
comp._visible = compFlags[sceneNum][getScreenNum(player.x)];
compN._visible = compFlags[sceneNum][getScreenNum(player.x)] & FLAG_N;
compW._visible = compFlags[sceneNum][getScreenNum(player.x)] & FLAG_W;
compE._visible = compFlags[sceneNum][getScreenNum(player.x)] & FLAG_E;
compS._visible = compFlags[sceneNum][getScreenNum(player.x)] & FLAG_S;
var _local11 = player.x;
var _local10 = player.y;
var _local9 = 1;
player.x = player.x + ((player.spd * _local9) * (Key.isDown(39) - Key.isDown(37)));
player.y = player.y + ((player.spd / 3) * (Key.isDown(40) - Key.isDown(38)));
player.x = Math.max(0, Math.min(player.x, (Stage.width * scene.screen._totalframes) - 1));
player.y = Math.max(Y_TOPS[sceneNum], Math.min(player.y, Y_BOTTOM));
if ((_local11 != player.x) || (_local10 != player.y)) {
sbc.walkanim.play();
}
var _local7 = false;
for (var _local8 in msgLocations[sceneNum]) {
var _local2 = msgLocations[sceneNum][_local8];
var _local5 = Math.abs(player.x - _local2[0]);
var _local6 = Math.abs(player.y - _local2[1]);
var _local4 = ((_local2[7] === false) ? -1 : 1);
var _local3 = false;
_local3 = _local3 | (_local2[5] == undefined);
_local3 = _local3 | ((_root.gameTriggers[_local2[5]] * _local4) >= (_local2[6] * _local4));
if ((((_local5 < _local2[2]) && (_local6 < (_local2[2] * 0.5))) && (_local3)) && (getScreenNum(_local2[0]) == getScreenNum(player.x))) {
if (((!kSd) && (Key.isDown(32))) && (!spaceHandler)) {
actionHandler(_local2[3]);
}
if (_local2[4] == "") {
continue;
}
_local7 = true;
displayMsg("Press [SPACE] to " + _local2[4]);
}
}
kSd = Key.isDown(32);
if (!_local7) {
hideMsg();
}
};
var scene1 = new Array();
scene1.push([65, Y_TOPS[1], 60, "sc1treec", "", 2, 1]);
scene1.push([375, Y_TOPS[1], 60, "sc1door1", "Enter"]);
scene1.push([891, Y_TOPS[1], 60, "sc1banan", "Talk to BananaClock"]);
scene1.push([1215, Y_TOPS[1], 60, "sc1door2", "Enter"]);
scene1.push([1780, Y_TOPS[1], 60, "sc1door3", "Enter"]);
scene1.push([1985, Y_TOPS[1], 60, "sc1rocks", ""]);
scene1.push([2275, Y_TOPS[1], 80, "sc1treef", ""]);
scene1.push([3585, Y_TOPS[1], 100, "sc1orang", "Talk to OrangeClock"]);
scene1.push([4720, Y_TOPS[1], 80, "sc1door4", "Enter"]);
var scene2 = new Array();
scene2.push([304, Y_TOPS[2], 80, "sc2ghost", "Talk to the Ghost of PineappleClock"]);
scene2.push([209, Y_BOTTOM, 80, "sc2door1", "Leave", 0, 1]);
scene2.push([55, Y_TOPS[2], 80, "sc2coins", "Pick up Coins"]);
var SC3_MIDDLE = ((Y_TOPS[3] + Y_BOTTOM) / 2);
var scene3 = new Array();
scene3.push([0, SC3_MIDDLE, 100, "sc3door1", "Leave"]);
scene3.push([220, Y_TOPS[3], 80, "sc3auber", "Talk to AubergineClock"]);
scene3.push([460, Y_TOPS[3], 80, "sc3eyoyo", "Examine\rthe Yo-Yo", 1, 0, false]);
var scene4 = new Array();
scene4.push([95, Y_BOTTOM, 80, "sc4door1", "Leave"]);
scene4.push([395, Y_TOPS[4], 150, "sc4cloud", "Talk to the Warriors"]);
var scene5 = new Array();
scene5.push([95, Y_BOTTOM, 80, "sc5door1", "Leave"]);
scene5.push([460, Y_TOPS[5], 80, "sc5woodc", "Talk to WoodClock"]);
var scene6 = new Array();
scene6.push([180, Y_TOPS[6], 120, "sc6bellw", "Look in the Window"]);
scene6.push([840, Y_TOPS[6], 100, "sc6cgate", "Enter the Castle"]);
scene6.push([840, Y_BOTTOM, 100, "sc6leave", "Leave the Castle Grounds"]);
scene6.push([1430, Y_TOPS[6], 60, "sc6grdun", "Pick up Uniform", 8, 0, false]);
var SC7_MIDDLE = ((Y_TOPS[7] + Y_BOTTOM) / 2);
var scene7 = new Array();
scene7.push([185, Y_TOPS[7], 85, "sc7kwaid", "De-throne\rKing Waid Flump"]);
scene7.push([485, Y_TOPS[7], 60, "sc7light", ""]);
scene7.push([824, Y_TOPS[7], 100, "sc7tfulp", "Examine the Golden Statue"]);
scene7.push([1202, Y_TOPS[7], 80, "sc7door1", "Examine the Servants' Door"]);
scene7.push([1649, SC7_MIDDLE, 120, "sc7leave", "Leave the Castle"]);
var msgLocations = new Array(null, scene1, scene2, scene3, scene4, scene5, scene6, scene7);
var m = new Sound(_root.musicHolder);
m.onSoundComplete = function () {
this.start(0, 1);
};
m.attachSound("NG54914");
m.start(0, 1);
musicHolder.onEnterFrame = function () {
_root.m.setVolume((_root.soundEffectsInPlay ? 30 : 100));
};
var soundEffectsInPlay = 0;
Frame 5
stop();
Frame 6
stop();
Instance of Symbol 13 MovieClip in Symbol 14 MovieClip Frame 1
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.inventory[_root.invNum] == 7;
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.inventory[_root.invNum] == 7;
}
Instance of Symbol 21 MovieClip in Symbol 22 MovieClip Frame 1
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.inventory[_root.invNum] == 7;
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.inventory[_root.invNum] == 7;
}
Symbol 30 MovieClip Frame 1
function playThis(w) {
w.play();
}
stop();
setTimeout(this.playThis, 1500 + Math.round(Math.random() * 3500), this);
Symbol 30 MovieClip Frame 21
this.gotoAndStop(1);
Symbol 86 MovieClip Frame 1
stop();
Symbol 86 MovieClip Frame 2
stop();
Symbol 86 MovieClip Frame 3
stop();
Symbol 100 MovieClip Frame 1
flashfile._rotation = flashfile._rotation + (random(358) + 2);
Symbol 101 MovieClip Frame 1
gotoAndPlay(random(39) + 1);
Symbol 101 MovieClip Frame 41
gotoAndPlay(random(18) + 41);
Symbol 101 MovieClip Frame 60
gotoAndPlay (2);
Symbol 125 MovieClip Frame 20
gotoAndPlay (1);
Symbol 130 MovieClip Frame 20
gotoAndPlay (1);
Symbol 132 MovieClip Frame 1
half1._rotation = (_root.getBytesLoaded() / _root.getBytesTotal()) * 360;
if (((_root.getBytesLoaded() / _root.getBytesTotal()) * 360) >= 180) {
gotoAndPlay (3);
}
Symbol 132 MovieClip Frame 2
half1._rotation = (_root.getBytesLoaded() / _root.getBytesTotal()) * 360;
if (((_root.getBytesLoaded() / _root.getBytesTotal()) * 360) >= 180) {
gotoAndPlay (3);
}
gotoAndPlay (1);
Symbol 132 MovieClip Frame 3
half1._rotation = 180;
half2._rotation = ((_root.getBytesLoaded() / _root.getBytesTotal()) * 360) - 180;
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
half2._rotation = 180;
}
Symbol 132 MovieClip Frame 4
half1._rotation = 180;
half2._rotation = ((_root.getBytesLoaded() / _root.getBytesTotal()) * 360) - 180;
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
half2._rotation = 180;
}
gotoAndPlay (3);
Symbol 141 MovieClip Frame 1
textloaded = ((Math.round(_root.getBytesLoaded() * 0.000872) + "/") + Math.round(_root.getBytesTotal() * 0.000872)) + "Kb";
if (Math.round(_root.getBytesTotal() * 0.000872) > 999) {
textloaded = (((Math.round((_root.getBytesLoaded() * 0.9213) / 10000) / 100) + "/") + (Math.round((_root.getBytesTotal() * 0.9213) / 10000) / 100)) + "Mb";
}
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
_parent._parent.play();
}
Symbol 141 MovieClip Frame 2
textloaded = ((Math.round(_root.getBytesLoaded() * 0.000872) + "/") + Math.round(_root.getBytesTotal() * 0.000872)) + "Kb";
if (Math.round(_root.getBytesTotal() * 0.000872) > 999) {
textloaded = (((Math.round((_root.getBytesLoaded() * 0.9213) / 10000) / 100) + "/") + (Math.round((_root.getBytesTotal() * 0.9213) / 10000) / 100)) + "Mb";
}
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
_parent._parent.play();
}
Symbol 152 MovieClip Frame 1
areacolor = new Color(area);
areacolor.setRGB(_parent._parent.randomcolor);
Symbol 155 MovieClip Frame 1
stop();
Symbol 158 MovieClip Frame 1
stop();
Symbol 159 MovieClip Frame 1
stripe1.play();
Symbol 159 MovieClip Frame 2
stripe2.play();
Symbol 159 MovieClip Frame 3
stripe3.play();
Symbol 159 MovieClip Frame 4
stripe4.play();
Symbol 159 MovieClip Frame 5
stripe5.play();
Symbol 159 MovieClip Frame 6
stripe6.play();
Symbol 159 MovieClip Frame 7
stripe7.play();
Symbol 159 MovieClip Frame 8
stripe8.play();
Symbol 159 MovieClip Frame 9
stripe9.play();
Symbol 159 MovieClip Frame 10
stripe10.play();
Symbol 159 MovieClip Frame 11
stripe11.play();
Symbol 159 MovieClip Frame 12
stripe12.play();
Symbol 159 MovieClip Frame 13
stripe13.play();
Symbol 159 MovieClip Frame 14
stripe14.play();
Symbol 159 MovieClip Frame 15
stripe15.play();
Symbol 159 MovieClip Frame 16
stripe16.play();
Symbol 159 MovieClip Frame 17
stripe17.play();
Symbol 159 MovieClip Frame 18
stripe18.play();
stop();
Symbol 161 Button
on (release) {
_parent.play();
nextFrame();
}
Symbol 162 MovieClip Frame 1
randomcolor = random(16777215);
skycolor = new Color(sky);
skycolor.setRGB(randomcolor);
stop();
Symbol 162 MovieClip Frame 13
stop();
Symbol 162 MovieClip Frame 14
stop();
Symbol 166 Button
on (release) {
getURL ("http://www.clockcrew.cc", _blank);
}
Symbol 167 MovieClip Frame 1
_root.stop();
Symbol 167 MovieClip Frame 3
if (this._framesloaded > 30) {
play();
} else {
gotoAndPlay (2);
}
Symbol 167 MovieClip Frame 16
_quality = "MEDIUM";
Symbol 167 MovieClip Frame 28
_quality = "HIGH";
Symbol 167 MovieClip Frame 29
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
logo.gotoAndPlay(6);
gotoAndStop ("done");
}
Symbol 167 MovieClip Frame 30
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
logo.gotoAndPlay(6);
gotoAndStop ("done");
}
gotoAndPlay ("reload");
Symbol 167 MovieClip Frame 32
_quality = "MEDIUM";
Symbol 167 MovieClip Frame 44
_quality = "HIGH";
Symbol 167 MovieClip Frame 61
_root.play();
stop();
Symbol 170 Button
on (release) {
getURL ("http://www.newgrounds.com/", "_blank");
}
Symbol 389 MovieClip [__Packages.Conversation] Frame 0
class Conversation
{
var holder, txtInt, keyInt;
function Conversation (c) {
conv = new Array();
var _local3 = 0;
while (_local3 < c.length) {
conv.push(c[_local3]);
_local3++;
}
cNum = -1;
_root.gameEnabled = false;
holder = _root.attachMovie("conversationHolder", "conv", 10000);
holder._x = (Stage.width - holder.bgBox._width) / 2;
holder._y = ((Stage.height - holder.bgBox._height) - (holder.bgBox._y - holder.box._y)) - holder._x;
txtInt = setInterval(showMoreText, 60, this);
keyInt = setInterval(keyCheck, 0, this);
showNext();
holder.con = this;
holder.onRelease = function () {
if (this.spkrText.text == this.con.totalText) {
this.con.showNext();
} else {
this.spkrText.text = this.con.totalText;
}
};
}
function showNext() {
cNum++;
if (cNum >= conv.length) {
clearInterval(txtInt);
clearInterval(keyInt);
_root.invEnabled = true;
_root.gameEnabled = true;
_root.mapEnabled = true;
holder.removeMovieClip();
if (_root.endGame) {
_root.gotoAndStop("finalmovie");
}
}
if (!(conv[cNum][2] === undefined)) {
_root.playSoundEffect(conv[cNum][2]);
}
holder.spkrName.text = conv[cNum][0];
holder.spkrText.text = "";
var _local3 = conv[cNum][0].split(" ");
holder.box.gotoAndStop(_local3[_local3.length - 1]);
totalText = conv[cNum][1];
}
function showMoreText(m) {
m.holder.nextDisplay.gotoAndStop(((m.holder.spkrText.text.length < m.totalText.length) ? 1 : (((m.cNum == (m.conv.length - 1)) ? 2 : 3))));
if (m.holder.spkrText.text.length == m.totalText.length) {
return(undefined);
}
m.holder.spkrText.text = m.holder.spkrText.text + m.totalText.charAt(m.holder.spkrText.text.length);
}
function keyCheck(m) {
if ((m.kSd === false) && (Key.isDown(32))) {
if (m.holder.spkrText.text == m.totalText) {
m.showNext();
} else {
m.holder.spkrText.text = m.totalText;
}
}
_root.kSd = (m.kSd = Key.isDown(32));
}
var conv = new Array();
var cNum = 0;
var totalText = new String();
}
Symbol 390 MovieClip [__Packages.SoundEffect] Frame 0
class SoundEffect extends Sound
{
var attachSound, par, onSoundComplete, start;
function SoundEffect () {
super();
}
function play(id, h) {
attachSound(id);
par = h;
_root.soundEffectsInPlay++;
onSoundComplete = function () {
_root.soundEffectsInPlay--;
this.par.removeMovieClip();
};
start(0, 1);
}
}
Instance of Symbol 194 MovieClip in Symbol 211 MovieClip Frame 1
on (release) {
_root.gotoAndStop("game");
}
Instance of Symbol 197 MovieClip in Symbol 211 MovieClip Frame 1
on (release) {
_root.gotoAndStop("instructions");
}
Instance of Symbol 207 MovieClip in Symbol 211 MovieClip Frame 1
on (release) {
_root.gotoAndStop("credits");
}
Symbol 213 Button
on (release) {
getURL ("http://www.dfblaze.net/", "_blank");
}
Symbol 215 Button
on (release) {
getURL ("http://www.authorblues.com/", "_blank");
}
Symbol 233 Button
on (release) {
_root.gotoAndStop("mainmenu");
}
Instance of Symbol 242 MovieClip in Symbol 265 MovieClip Frame 2
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = !_root.isInInventory(5);
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = !_root.isInInventory(5);
}
Instance of Symbol 252 MovieClip in Symbol 265 MovieClip Frame 5
onClipEvent (load) {
this._visible = _root.gameTriggers[6] >= 1;
}
onClipEvent (enterFrame) {
this._visible = _root.gameTriggers[6] >= 1;
}
Instance of Symbol 291 MovieClip in Symbol 292 MovieClip Frame 1
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[1] == 0;
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[1] == 0;
}
Instance of Symbol 252 MovieClip in Symbol 306 MovieClip Frame 1
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[2] != 2;
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[2] != 2;
}
Instance of Symbol 303 MovieClip in Symbol 306 MovieClip Frame 1
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[2] == 2;
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[2] == 2;
}
Instance of Symbol 318 MovieClip in Symbol 321 MovieClip Frame 1
onClipEvent (load) {
this.stop();
this.gotoAndStop(((_root.gameTriggers[7] >= 2) ? 2 : 1));
}
onClipEvent (enterFrame) {
this.gotoAndStop(((_root.gameTriggers[7] >= 2) ? 2 : 1));
}
Instance of Symbol 324 MovieClip in Symbol 325 MovieClip Frame 3
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = !_root.isInInventory(7);
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = !_root.isInInventory(7);
}
Instance of Symbol 338 MovieClip in Symbol 347 MovieClip Frame 1
onClipEvent (load) {
this.stop();
if (!_root.mapEnabled) {
return(undefined);
}
this.gotoAndStop(((!_root.gameTriggers[11]) ? 1 : 2));
}
onClipEvent (enterFrame) {
if (!_root.mapEnabled) {
return(undefined);
}
this.gotoAndStop(((!_root.gameTriggers[11]) ? 1 : 2));
}
Instance of Symbol 285 MovieClip in Symbol 348 MovieClip Frame 2
onClipEvent (load) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[3] == 0;
}
onClipEvent (enterFrame) {
if (!_root.invEnabled) {
return(undefined);
}
this._visible = _root.gameTriggers[3] == 0;
}
Symbol 356 MovieClip Frame 1
stop();
Symbol 369 MovieClip Frame 1
stop();
Symbol 372 Button
on (release) {
_root.invNum++;
}
Symbol 373 Button
on (release) {
_root.invNum--;
}
Symbol 383 Button
on (release) {
_root.gotoAndStop("credits");
}
Symbol 384 MovieClip Frame 200
stop();
Symbol 388 MovieClip Frame 1255
_root.gotoAndStop("mainmenu");