Frame 1
function __com_mochibot__(swfid, mc, lv) {
var x;
var g;
var s;
var fv;
var sb;
var u;
var res;
var mb;
var mbc;
mb = "__mochibot__";
mbc = "mochibot.com";
g = (_global ? (_global) : (_level0._root));
if (g[mb + swfid]) {
return(g[mb + swfid]);
}
s = System.security;
x = mc._root.getSWFVersion;
fv = (x ? (mc.getSWFVersion()) : ((_global ? 6 : 5)));
if (!s) {
s = {};
}
sb = s.sandboxType;
if (sb == "localWithFile") {
return(null);
}
x = s.allowDomain;
if (x) {
s.allowDomain(mbc);
}
x = s.allowInsecureDomain;
if (x) {
s.allowInsecureDomain(mbc);
}
u = ((((((((((("http://" + mbc) + "/my/core.swf?mv=5&fv=") + fv) + "&v=") + escape(getVersion())) + "&swfid=") + escape(swfid)) + "&l=") + lv) + "&f=") + mc) + (sb ? ("&sb=" + sb) : "");
lv = ((fv > 6) ? (mc.getNextHighestDepth()) : ((g[mb + "level"] ? (g[mb + "level"] + 1) : (lv))));
g[mb + "level"] = lv;
if (fv == 5) {
res = "_level" + lv;
if (!eval (res)) {
loadMovieNum (u, lv);
}
} else {
res = mc.createEmptyMovieClip(mb + swfid, lv);
res.loadMovie(u);
}
return(res);
}
__com_mochibot__("cded6e87", this, 10301);
System.security.allowDomain("bot.armorstudios.com", "www.armorstudios.com");
Frame 2
stop();
Stage.showMenu = false;
Stage.scaleMode = "noScale";
this.createTextField("sPreload", 1, 50, 230, 500, 100);
this.sPreload.embedFonts = true;
this.sPreload.selectable = false;
this.myformat = new TextFormat();
this.myformat.font = "Fiolex Girls";
this.myformat.color = 16777215 /* 0xFFFFFF */;
this.myformat.align = "center";
this.onEnterFrame = function () {
if (preloader.getBytesLoaded() != preloader.getBytesTotal()) {
this.sPreload.text = "Loading Sounds: " + ((this.preloader.getBytesLoaded() / this.preloader.getBytesTotal()) * 100);
this.sPreload.setTextFormat(this.myformat);
} else {
this.sPreload.text = "";
this.sPreload.setTextFormat(this.myformat);
delete this.onEnterFrame;
}
};
pldm128947 = new LoadVars();
pldm128947.mv = _level0._url;
pldm128947.md = "c0e3f3bd815a862433bc3399c487926b";
pldm128947.mid = 90;
pldm128947.sendAndLoad("http://bot.armorstudios.com/track.php", pldm128947, "POST");
Symbol 3 MovieClip [glob] Frame 94
this.removeMovieClip();
Symbol 4 MovieClip [FUIComponentSymbol] Frame 1
#initclip 3
function FUIComponentClass() {
this.init();
}
FUIComponentClass.prototype = new MovieClip();
FUIComponentClass.prototype.init = function () {
this.enable = true;
this.focused = false;
this.useHandCursor = false;
this._accImpl = new Object();
this._accImpl.stub = true;
this.styleTable = new Array();
if (_global.globalStyleFormat == undefined) {
_global.globalStyleFormat = new FStyleFormat();
globalStyleFormat.isGlobal = true;
_global._focusControl = new Object();
_global._focusControl.onSetFocus = function (oldFocus, newFocus) {
oldFocus.myOnKillFocus();
newFocus.myOnSetFocus();
};
Selection.addListener(_global._focusControl);
}
if (this._name != undefined) {
this._focusrect = false;
this.tabEnabled = true;
this.focusEnabled = true;
this.tabChildren = false;
this.tabFocused = true;
if (this.hostStyle == undefined) {
globalStyleFormat.addListener(this);
} else {
this.styleTable = this.hostStyle;
}
this.deadPreview._visible = false;
this.deadPreview._width = (this.deadPreview._height = 1);
this.methodTable = new Object();
this.keyListener = new Object();
this.keyListener.controller = this;
this.keyListener.onKeyDown = function () {
this.controller.myOnKeyDown();
};
this.keyListener.onKeyUp = function () {
this.controller.myOnKeyUp();
};
for (var i in this.styleFormat_prm) {
this.setStyleProperty(i, this.styleFormat_prm[i]);
}
}
};
FUIComponentClass.prototype.setEnabled = function (enabledFlag) {
this.enable = ((arguments.length > 0) ? (enabledFlag) : true);
this.tabEnabled = (this.focusEnabled = enabledFlag);
if ((!this.enable) && (this.focused)) {
Selection.setFocus(undefined);
}
};
FUIComponentClass.prototype.getEnabled = function () {
return(this.enable);
};
FUIComponentClass.prototype.setSize = function (w, h) {
this.width = w;
this.height = h;
this.focusRect.removeMovieClip();
};
FUIComponentClass.prototype.setChangeHandler = function (chng, obj) {
this.handlerObj = ((obj == undefined) ? (this._parent) : (obj));
this.changeHandler = chng;
};
FUIComponentClass.prototype.invalidate = function (methodName) {
this.methodTable[methodName] = true;
this.onEnterFrame = this.cleanUI;
};
FUIComponentClass.prototype.cleanUI = function () {
if (this.methodTable.setSize) {
this.setSize(this.width, this.height);
} else {
this.cleanUINotSize();
}
this.methodTable = new Object();
delete this.onEnterFrame;
};
FUIComponentClass.prototype.cleanUINotSize = function () {
for (var funct in this.methodTable) {
this[funct]();
}
};
FUIComponentClass.prototype.drawRect = function (x, y, w, h) {
var inner = this.styleTable.focusRectInner.value;
var outer = this.styleTable.focusRectOuter.value;
if (inner == undefined) {
inner = 16777215 /* 0xFFFFFF */;
}
if (outer == undefined) {
outer = 0;
}
this.createEmptyMovieClip("focusRect", 1000);
this.focusRect.controller = this;
this.focusRect.lineStyle(1, outer);
this.focusRect.moveTo(x, y);
this.focusRect.lineTo(x + w, y);
this.focusRect.lineTo(x + w, y + h);
this.focusRect.lineTo(x, y + h);
this.focusRect.lineTo(x, y);
this.focusRect.lineStyle(1, inner);
this.focusRect.moveTo(x + 1, y + 1);
this.focusRect.lineTo((x + w) - 1, y + 1);
this.focusRect.lineTo((x + w) - 1, (y + h) - 1);
this.focusRect.lineTo(x + 1, (y + h) - 1);
this.focusRect.lineTo(x + 1, y + 1);
};
FUIComponentClass.prototype.pressFocus = function () {
this.tabFocused = false;
this.focusRect.removeMovieClip();
Selection.setFocus(this);
};
FUIComponentClass.prototype.drawFocusRect = function () {
this.drawRect(-2, -2, this.width + 4, this.height + 4);
};
FUIComponentClass.prototype.myOnSetFocus = function () {
this.focused = true;
Key.addListener(this.keyListener);
if (this.tabFocused) {
this.drawFocusRect();
}
};
FUIComponentClass.prototype.myOnKillFocus = function () {
this.tabFocused = true;
this.focused = false;
this.focusRect.removeMovieClip();
Key.removeListener(this.keyListener);
};
FUIComponentClass.prototype.executeCallBack = function () {
this.handlerObj[this.changeHandler](this);
};
FUIComponentClass.prototype.updateStyleProperty = function (styleFormat, propName) {
this.setStyleProperty(propName, styleFormat[propName], styleFormat.isGlobal);
};
FUIComponentClass.prototype.setStyleProperty = function (propName, value, isGlobal) {
if (value == "") {
return(undefined);
}
var tmpValue = parseInt(value);
if (!isNaN(tmpValue)) {
value = tmpValue;
}
var global = ((arguments.length > 2) ? (isGlobal) : false);
if (this.styleTable[propName] == undefined) {
this.styleTable[propName] = new Object();
this.styleTable[propName].useGlobal = true;
}
if (this.styleTable[propName].useGlobal || (!global)) {
this.styleTable[propName].value = value;
if (this.setCustomStyleProperty(propName, value)) {
} else if (propName == "embedFonts") {
this.invalidate("setSize");
} else if (propName.subString(0, 4) == "text") {
if (this.textStyle == undefined) {
this.textStyle = new TextFormat();
}
var textProp = propName.subString(4, propName.length);
this.textStyle[textProp] = value;
this.invalidate("setSize");
} else {
for (var j in this.styleTable[propName].coloredMCs) {
var myColor = new Color(this.styleTable[propName].coloredMCs[j]);
if (this.styleTable[propName].value == undefined) {
var myTObj = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
myColor.setTransform(myTObj);
} else {
myColor.setRGB(value);
}
}
}
this.styleTable[propName].useGlobal = global;
}
};
FUIComponentClass.prototype.registerSkinElement = function (skinMCRef, propName) {
if (this.styleTable[propName] == undefined) {
this.styleTable[propName] = new Object();
this.styleTable[propName].useGlobal = true;
}
if (this.styleTable[propName].coloredMCs == undefined) {
this.styleTable[propName].coloredMCs = new Object();
}
this.styleTable[propName].coloredMCs[skinMCRef] = skinMCRef;
if (this.styleTable[propName].value != undefined) {
var myColor = new Color(skinMCRef);
myColor.setRGB(this.styleTable[propName].value);
}
};
_global.FStyleFormat = function () {
this.nonStyles = {listeners:true, isGlobal:true, isAStyle:true, addListener:true, removeListener:true, nonStyles:true, applyChanges:true};
this.listeners = new Object();
this.isGlobal = false;
if (arguments.length > 0) {
for (var i in arguments[0]) {
this[i] = arguments[0][i];
}
}
};
_global.FStyleFormat.prototype = new Object();
FStyleFormat.prototype.addListener = function () {
var arg = 0;
while (arg < arguments.length) {
var mcRef = arguments[arg];
this.listeners[arguments[arg]] = mcRef;
for (var i in this) {
if (this.isAStyle(i)) {
mcRef.updateStyleProperty(this, i.toString());
}
}
arg++;
}
};
FStyleFormat.prototype.removeListener = function (component) {
this.listeners[component] = undefined;
for (var prop in this) {
if (this.isAStyle(prop)) {
if (component.styleTable[prop].useGlobal == this.isGlobal) {
component.styleTable[prop].useGlobal = true;
var value = (this.isGlobal ? undefined : (globalStyleFormat[prop]));
component.setStyleProperty(prop, value, true);
}
}
}
};
FStyleFormat.prototype.applyChanges = function () {
var count = 0;
for (var i in this.listeners) {
var component = this.listeners[i];
if (arguments.length > 0) {
var j = 0;
while (j < arguments.length) {
if (this.isAStyle(arguments[j])) {
component.updateStyleProperty(this, arguments[j]);
}
j++;
}
} else {
for (var j in this) {
if (this.isAStyle(j)) {
component.updateStyleProperty(this, j.toString());
}
}
}
}
};
FStyleFormat.prototype.isAStyle = function (name) {
return((this.nonStyles[name] ? false : true));
};
#endinitclip
Symbol 17 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 28 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 41 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "foregroundDisabled");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 42 MovieClip [UpArrow] Frame 1
stop();
Symbol 42 MovieClip [UpArrow] Frame 2
stop();
Symbol 42 MovieClip [UpArrow] Frame 3
stop();
Symbol 49 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 56 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 61 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(highlight3D_mc, "highlight3D");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
Symbol 62 MovieClip [ScrollThumb] Frame 1
stop();
Symbol 63 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 64 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 72 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "foregroundDisabled");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 73 MovieClip [DownArrow] Frame 1
stop();
Symbol 73 MovieClip [DownArrow] Frame 2
stop();
Symbol 73 MovieClip [DownArrow] Frame 3
stop();
Symbol 76 MovieClip [FHighlightSymbol] Frame 1
var component = _parent.controller;
component.registerSkinElement(highlight_mc, "selection");
stop();
Symbol 76 MovieClip [FHighlightSymbol] Frame 2
component.registerSkinElement(highlight_mc2, "selectionDisabled");
stop();
Symbol 76 MovieClip [FHighlightSymbol] Frame 3
component.registerSkinElement(highlight_mc3, "selectionUnfocused");
stop();
Symbol 79 MovieClip [FLabelSymbol] Frame 1
#initclip 1
_global.FLabelClass = function () {
if (this.hostComponent == undefined) {
this.hostComponent = ((this._parent.controller == undefined) ? (this._parent) : (this._parent.controller));
}
if (this.customTextStyle == undefined) {
if (this.hostComponent.textStyle == undefined) {
this.hostComponent.textStyle = new TextFormat();
}
this.textStyle = this.hostComponent.textStyle;
this.enable = true;
}
};
FLabelClass.prototype = new MovieClip();
Object.registerClass("FLabelSymbol", FLabelClass);
FLabelClass.prototype.setLabel = function (label) {
var val = this.hostComponent.styleTable.embedFonts.value;
if (val != undefined) {
this.labelField.embedFonts = val;
}
this.labelField.setNewTextFormat(this.textStyle);
this.labelField.text = label;
this.labelField._height = this.labelField.textHeight + 2;
};
FLabelClass.prototype.setSize = function (width) {
this.labelField._width = width;
};
FLabelClass.prototype.setEnabled = function (enable) {
this.enable = enable;
var tmpColor = this.hostComponent.styleTable[(enable ? "textColor" : "textDisabled")].value;
if (tmpColor == undefined) {
tmpColor = (enable ? 0 : 8947848);
}
this.setColor(tmpColor);
};
FLabelClass.prototype.getLabel = function () {
return(this.labelField.text);
};
FLabelClass.prototype.setColor = function (col) {
this.labelField.textColor = col;
};
#endinitclip
Symbol 81 MovieClip [FPSMeter] Frame 1
#initclip 2
FPSMeterClass = function () {
this.listenersList = [];
this.init();
};
Object.registerClass("FPSMeter", FPSMeterClass);
FPSMeterClass.prototype.init = function () {
if (this._targetInstanceName.length > 0) {
this.FPSMeterTarget = (this.targetInstance = this._parent[this._targetInstanceName]);
if (this.FPSMeterTarget instanceof TextField) {
this._visible = false;
this.past = 0;
this.now = 0;
this.fps = 0;
this.pass = 0;
this.delta = 0;
this.population = new Array(this.populationSize);
} else {
trace("FPSMeter Component: no target TextField found!");
}
}
};
FPSMeterClass.prototype.onEnterFrame = function () {
this.now = getTimer();
this.delta = this.now - this.past;
if (this.modus) {
this.population[this.pass] = this.delta;
this.pass++;
if (this.pass >= this.populationSize) {
var sum = 0;
for (var measurement in this.population) {
sum = sum + this.population[measurement];
}
this.fps = int((1000 * this.populationSize) / sum);
this.sendFPSMeterEvent(this.fps);
this.pass = 0;
}
} else {
this.fps = int(1000 / this.delta);
this.sendFPSMeterEvent(this.fps);
}
this.past = this.now;
};
FPSMeterClass.prototype.getFPS = function () {
return(this.fps);
};
FPSMeterClass.prototype.addListener = function (ref) {
this.listenersList[ref] = ref;
};
FPSMeterClass.prototype.removeListener = function (ref) {
delete this.listenersList[ref];
};
FPSMeterClass.prototype.sendFPSMeterEvent = function (value) {
this.FPSMeterTarget.text = (this.prefix + value) + this.suffix;
for (var i in this.listenersList) {
this.listenersList[i].getFPS(value);
}
};
#endinitclip
Symbol 84 MovieClip Frame 21
this._parent.removeMovieClip();
Symbol 102 MovieClip Frame 1
this.createEmptyMovieClip("handle", 30);
this.sW = 640;
this.sH = 540;
this.mpx = this._xmouse;
this.mpy = this._ymouse;
this.gds = (this.gd = 100);
this.gdm = 1000;
this.pi = Math.PI;
this.rc = (Math.PI/180);
this.genGlob = function (x, y, ang, dist) {
var t = this;
t.mask.attachMovie("glob", "g" + t.gd, t.gd);
var n = t.mask["g" + t.gd];
n._x = x;
n._y = y;
n._xscale = (n._yscale = dist * 2);
n._rotation = ang / t.rc;
if (t.gd < t.gdm) {
t.gd++;
} else {
t.gd = t.gds;
}
};
this.handle.onEnterFrame = function () {
var p = this._parent;
loading = p._parent.getBytesLoaded();
total = p._parent.getBytesTotal();
percent = percent - ((percent - ((loading / total) * 100)) * 0.25);
per = int(percent);
p.masked.percent = per;
p.smallPre = per + "%";
if (percent > 99) {
percent = 100;
p._alpha = p._alpha - 4;
if (p._alpha < 0) {
_global.pie = 12023493553;
p._parent.gotoAndStop("intro");
}
}
};
this.handle.onMouseMove = function () {
var p = this._parent;
var xm = p._xmouse;
var ym = p._ymouse;
var dx = (xm - p.mpx);
var dy = (ym - p.mpy);
var ang = Math.atan2(dy, dx);
var genAng = ((ang - ((3 * p.pi) / 4)) + (Math.random() * (p.pi / 2)));
var dist = Math.sqrt((dx * dx) + (dy * dy));
if (dist > 80) {
dist = 80;
}
p.genGlob(xm, ym, genAng, dist);
p.mpx = xm;
p.mpy = ym;
};
Symbol 139 MovieClip Frame 430
stop();
this._parent.play();
Symbol 144 MovieClip Frame 1
stop();
Symbol 194 MovieClip Frame 113
stop();
this._parent.play();
Instance of Symbol 144 MovieClip in Symbol 203 MovieClip Frame 1
on (release) {
this._parent._parent.gotoAndStop("game");
}
on (rollOver) {
this.gotoAndStop(2);
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 203 MovieClip Frame 12
stop();
Symbol 203 MovieClip Frame 37
stop();
Instance of Symbol 103 MovieClip in Symbol 203 MovieClip Frame 60
on (release) {
getURL ("http://goldsickle.deviantart.com/", "_blank");
}
Symbol 203 MovieClip Frame 177
stop();
this._parent.gotoAndStop("game");
Symbol 228 MovieClip [gallery] Frame 1
stop();
Symbol 245 MovieClip Frame 15
stop();
Symbol 246 MovieClip [fadeA] Frame 50
this.removeMovieClip();
Symbol 253 MovieClip Frame 1
var component = _parent;
component.registerSkinElement(track_mc, "scrollTrack");
Symbol 254 MovieClip [FScrollBarSymbol] Frame 1
#initclip 6
FScrollBarClass = function () {
if (this._height == 4) {
return(undefined);
}
this.init();
this.minPos = (this.maxPos = (this.pageSize = (this.largeScroll = 0)));
this.smallScroll = 1;
this.width = (this.horizontal ? (this._width) : (this._height));
this._xscale = (this._yscale = 100);
this.setScrollPosition(0);
this.tabEnabled = false;
if (this._targetInstanceName.length > 0) {
this.setScrollTarget(this._parent[this._targetInstanceName]);
}
this.tabChildren = false;
this.setSize(this.width);
};
FScrollBarClass.prototype = new FUIComponentClass();
FScrollBarClass.prototype.setHorizontal = function (flag) {
if (this.horizontal && (!flag)) {
this._xscale = 100;
this._rotation = 0;
} else if (flag && (!this.horizontal)) {
this._xscale = -100;
this._rotation = -90;
}
this.horizontal = flag;
};
FScrollBarClass.prototype.setScrollProperties = function (pSize, mnPos, mxPos) {
if (!this.enable) {
return(undefined);
}
this.pageSize = pSize;
this.minPos = Math.max(mnPos, 0);
this.maxPos = Math.max(mxPos, 0);
this.scrollPosition = Math.max(this.minPos, this.scrollPosition);
this.scrollPosition = Math.min(this.maxPos, this.scrollPosition);
if ((this.maxPos - this.minPos) <= 0) {
this.scrollThumb_mc.removeMovieClip();
this.upArrow_mc.gotoAndStop(3);
this.downArrow_mc.gotoAndStop(3);
this.downArrow_mc.onPress = (this.downArrow_mc.onRelease = (this.downArrow_mc.onDragOut = null));
this.upArrow_mc.onPress = (this.upArrow_mc.onRelease = (this.upArrow_mc.onDragOut = null));
this.scrollTrack_mc.onPress = (this.scrollTrack_mc.onRelease = null);
this.scrollTrack_mc.onDragOut = (this.scrollTrack_mc.onRollOut = null);
this.scrollTrack_mc.useHandCursor = false;
} else {
var tmp = this.getScrollPosition();
this.upArrow_mc.gotoAndStop(1);
this.downArrow_mc.gotoAndStop(1);
this.upArrow_mc.onPress = (this.upArrow_mc.onDragOver = this.startUpScroller);
this.upArrow_mc.onRelease = (this.upArrow_mc.onDragOut = this.stopScrolling);
this.downArrow_mc.onPress = (this.downArrow_mc.onDragOver = this.startDownScroller);
this.downArrow_mc.onRelease = (this.downArrow_mc.onDragOut = this.stopScrolling);
this.scrollTrack_mc.onPress = (this.scrollTrack_mc.onDragOver = this.startTrackScroller);
this.scrollTrack_mc.onRelease = this.stopScrolling;
this.scrollTrack_mc.onDragOut = this.stopScrolling;
this.scrollTrack_mc.onRollOut = this.stopScrolling;
this.scrollTrack_mc.useHandCursor = false;
this.attachMovie("ScrollThumb", "scrollThumb_mc", 3);
this.scrollThumb_mc._x = 0;
this.scrollThumb_mc._y = this.upArrow_mc._height;
this.scrollThumb_mc.onPress = this.startDragThumb;
this.scrollThumb_mc.controller = this;
this.scrollThumb_mc.onRelease = (this.scrollThumb_mc.onReleaseOutside = this.stopDragThumb);
this.scrollThumb_mc.useHandCursor = false;
this.thumbHeight = (this.pageSize / ((this.maxPos - this.minPos) + this.pageSize)) * this.trackSize;
this.thumbMid_mc = this.scrollThumb_mc.mc_sliderMid;
this.thumbTop_mc = this.scrollThumb_mc.mc_sliderTop;
this.thumbBot_mc = this.scrollThumb_mc.mc_sliderBot;
this.thumbHeight = Math.max(this.thumbHeight, 6);
this.midHeight = (this.thumbHeight - this.thumbTop_mc._height) - this.thumbBot_mc._height;
this.thumbMid_mc._yScale = (this.midHeight * 100) / this.thumbMid_mc._height;
this.thumbMid_mc._y = this.thumbTop_mc._height;
this.thumbBot_mc._y = this.thumbTop_mc._height + this.midHeight;
this.scrollTop = this.scrollThumb_mc._y;
this.trackHeight = this.trackSize - this.thumbHeight;
this.scrollBot = this.trackHeight + this.scrollTop;
tmp = Math.min(tmp, this.maxPos);
this.setScrollPosition(Math.max(tmp, this.minPos));
}
};
FScrollBarClass.prototype.getScrollPosition = function () {
return(this.scrollPosition);
};
FScrollBarClass.prototype.setScrollPosition = function (pos) {
this.scrollPosition = pos;
if (this.scrollThumb_mc != undefined) {
pos = Math.min(pos, this.maxPos);
pos = Math.max(pos, this.minPos);
}
this.scrollThumb_mc._y = (((pos - this.minPos) * this.trackHeight) / (this.maxPos - this.minPos)) + this.scrollTop;
this.executeCallBack();
};
FScrollBarClass.prototype.setLargeScroll = function (lScroll) {
this.largeScroll = lScroll;
};
FScrollBarClass.prototype.setSmallScroll = function (sScroll) {
this.smallScroll = sScroll;
};
FScrollBarClass.prototype.setEnabled = function (enabledFlag) {
var wasEnabled = this.enable;
if (enabledFlag && (!wasEnabled)) {
this.enable = enabledFlag;
if (this.textField != undefined) {
this.setScrollTarget(this.textField);
} else {
this.setScrollProperties(this.pageSize, this.cachedMinPos, this.cachedMaxPos);
this.setScrollPosition(this.cachedPos);
}
this.clickFilter = undefined;
} else if ((!enabledFlag) && (wasEnabled)) {
this.textField.removeListener(this);
this.cachedPos = this.getScrollPosition();
this.cachedMinPos = this.minPos;
this.cachedMaxPos = this.maxPos;
if (this.clickFilter == undefined) {
this.setScrollProperties(this.pageSize, 0, 0);
} else {
this.clickFilter = true;
}
this.enable = enabledFlag;
}
};
FScrollBarClass.prototype.setSize = function (hgt) {
if (this._height == 1) {
return(undefined);
}
this.width = hgt;
this.scrollTrack_mc._yscale = 100;
this.scrollTrack_mc._yscale = (100 * this.width) / this.scrollTrack_mc._height;
if (this.upArrow_mc == undefined) {
this.attachMovie("UpArrow", "upArrow_mc", 1);
this.attachMovie("DownArrow", "downArrow_mc", 2);
this.downArrow_mc.controller = (this.upArrow_mc.controller = this);
this.upArrow_mc.useHandCursor = (this.downArrow_mc.useHandCursor = false);
this.upArrow_mc._x = (this.upArrow_mc._y = 0);
this.downArrow_mc._x = 0;
}
this.scrollTrack_mc.controller = this;
this.downArrow_mc._y = this.width - this.downArrow_mc._height;
this.trackSize = this.width - (2 * this.downArrow_mc._height);
if (this.textField != undefined) {
this.onTextChanged();
} else {
this.setScrollProperties(this.pageSize, this.minPos, this.maxPos);
}
};
FScrollBarClass.prototype.scrollIt = function (inc, mode) {
var delt = this.smallScroll;
if (inc != "one") {
delt = ((this.largeScroll == 0) ? (this.pageSize) : (this.largeScroll));
}
var newPos = (this.getScrollPosition() + (mode * delt));
if (newPos > this.maxPos) {
newPos = this.maxPos;
} else if (newPos < this.minPos) {
newPos = this.minPos;
}
this.setScrollPosition(newPos);
};
FScrollBarClass.prototype.startDragThumb = function () {
this.lastY = this._ymouse;
this.onMouseMove = this.controller.dragThumb;
};
FScrollBarClass.prototype.dragThumb = function () {
this.scrollMove = this._ymouse - this.lastY;
this.scrollMove = this.scrollMove + this._y;
if (this.scrollMove < this.controller.scrollTop) {
this.scrollMove = this.controller.scrollTop;
} else if (this.scrollMove > this.controller.scrollBot) {
this.scrollMove = this.controller.scrollBot;
}
this._y = this.scrollMove;
var c = this.controller;
c.scrollPosition = Math.round(((c.maxPos - c.minPos) * (this._y - c.scrollTop)) / c.trackHeight) + c.minPos;
this.controller.isScrolling = true;
updateAfterEvent();
this.controller.executeCallBack();
};
FScrollBarClass.prototype.stopDragThumb = function () {
this.controller.isScrolling = false;
this.onMouseMove = null;
};
FScrollBarClass.prototype.startTrackScroller = function () {
this.controller.trackScroller();
this.controller.scrolling = setInterval(this.controller, "scrollInterval", 500, "page", -1);
};
FScrollBarClass.prototype.scrollInterval = function (inc, mode) {
clearInterval(this.scrolling);
if (inc == "page") {
this.trackScroller();
} else {
this.scrollIt(inc, mode);
}
this.scrolling = setInterval(this, "scrollInterval", 35, inc, mode);
};
FScrollBarClass.prototype.trackScroller = function () {
if ((this.scrollThumb_mc._y + this.thumbHeight) < this._ymouse) {
this.scrollIt("page", 1);
} else if (this.scrollThumb_mc._y > this._ymouse) {
this.scrollIt("page", -1);
}
};
FScrollBarClass.prototype.stopScrolling = function () {
this.controller.downArrow_mc.gotoAndStop(1);
this.controller.upArrow_mc.gotoAndStop(1);
clearInterval(this.controller.scrolling);
};
FScrollBarClass.prototype.startUpScroller = function () {
this.controller.upArrow_mc.gotoAndStop(2);
this.controller.scrollIt("one", -1);
this.controller.scrolling = setInterval(this.controller, "scrollInterval", 500, "one", -1);
};
FScrollBarClass.prototype.startDownScroller = function () {
this.controller.downArrow_mc.gotoAndStop(2);
this.controller.scrollIt("one", 1);
this.controller.scrolling = setInterval(this.controller, "scrollInterval", 500, "one", 1);
};
FScrollBarClass.prototype.setScrollTarget = function (tF) {
if (tF == undefined) {
this.textField.removeListener(this);
delete this.textField[(this.horizontal ? "hScroller" : "vScroller")];
if ((this.textField.hScroller != undefined) && (this.textField.vScroller != undefined)) {
this.textField.unwatch("text");
this.textField.unwatch("htmltext");
}
}
this.textField = undefined;
if (!(tF instanceof TextField)) {
return(undefined);
}
this.textField = tF;
this.textField[(this.horizontal ? "hScroller" : "vScroller")] = this;
this.onTextChanged();
this.onChanged = function () {
this.onTextChanged();
};
this.onScroller = function () {
if (!this.isScrolling) {
if (!this.horizontal) {
this.setScrollPosition(this.textField.scroll);
} else {
this.setScrollPosition(this.textField.hscroll);
}
}
};
this.textField.addListener(this);
this.textField.watch("text", this.callback);
this.textField.watch("htmlText", this.callback);
};
FScrollBarClass.prototype.callback = function (prop, oldVal, newVal) {
clearInterval(this.hScroller.synchScroll);
clearInterval(this.vScroller.synchScroll);
this.hScroller.synchScroll = setInterval(this.hScroller, "onTextChanged", 50);
this.vScroller.synchScroll = setInterval(this.vScroller, "onTextChanged", 50);
return(newVal);
};
FScrollBarClass.prototype.onTextChanged = function () {
if ((!this.enable) || (this.textField == undefined)) {
return(undefined);
}
clearInterval(this.synchScroll);
if (this.horizontal) {
var pos = this.textField.hscroll;
this.setScrollProperties(this.textField._width, 0, this.textField.maxhscroll);
this.setScrollPosition(Math.min(pos, this.textField.maxhscroll));
} else {
var pos = this.textField.scroll;
var pageSize = (this.textField.bottomScroll - this.textField.scroll);
this.setScrollProperties(pageSize, 1, this.textField.maxscroll);
this.setScrollPosition(Math.min(pos, this.textField.maxscroll));
}
};
FScrollBarClass.prototype.executeCallBack = function () {
if (this.textField == undefined) {
super.executeCallBack();
} else if (this.horizontal) {
this.textField.hscroll = this.getScrollPosition();
} else {
this.textField.scroll = this.getScrollPosition();
}
};
Object.registerClass("FScrollBarSymbol", FScrollBarClass);
#endinitclip
Symbol 259 MovieClip [FBoundingBoxSymbol] Frame 1
var component = _parent;
component.registerSkinElement(boundingBox, "background");
stop();
Symbol 259 MovieClip [FBoundingBoxSymbol] Frame 2
component.registerSkinElement(boundingBox2, "backgroundDisabled");
stop();
Symbol 263 MovieClip [FScrollPaneSymbol] Frame 1
#initclip 8
function FScrollPaneClass() {
function boolToString(str) {
if (str == "false") {
return(false);
}
if (str == "true") {
return(true);
}
return(str);
}
this.init();
this.width = this._width;
this.height = this._height;
this._xscale = (this._yscale = 100);
this.contentWidth = (this.contentHeight = 0);
if (this.hScroll == undefined) {
this.hScroll = (this.vScroll = "auto");
this.dragContent = false;
}
this.offset = new Object();
this.vScroll = boolToString(this.vScroll);
this.hScroll = boolToString(this.hScroll);
this.attachMovie("FScrollBarSymbol", "hScrollBar_mc", 100, {hostStyle:this.styleTable});
this.hScrollBar_mc.setHorizontal(true);
this.hScrollBar_mc.setSmallScroll(5);
this.hScrollBar_mc.setChangeHandler("onScroll", this);
this.attachMovie("FScrollBarSymbol", "vScrollBar_mc", 99, {hostStyle:this.styleTable});
this.vScrollBar_mc.setSmallScroll(5);
this.vScrollBar_mc.setChangeHandler("onScroll", this);
this.setSize(this.width, this.height);
if (this.scrollContent != "") {
this.setScrollContent(this.scrollContent);
}
this.setDragContent(this.dragContent);
}
FScrollPaneClass.prototype = new FUIComponentClass();
Object.registerClass("FScrollPaneSymbol", FScrollPaneClass);
FScrollPaneClass.prototype.getScrollContent = function () {
return(this.content_mc);
};
FScrollPaneClass.prototype.getPaneWidth = function () {
return(this.width);
};
FScrollPaneClass.prototype.getPaneHeight = function () {
return(this.height);
};
FScrollPaneClass.prototype.getScrollPosition = function () {
var xPos = ((this.hScrollBar_mc == undefined) ? 0 : (this.hScrollBar_mc.getScrollPosition()));
var yPos = ((this.vScrollBar_mc == undefined) ? 0 : (this.vScrollBar_mc.getScrollPosition()));
return({x:xPos, y:yPos});
};
FScrollPaneClass.prototype.setScrollContent = function (target) {
this.offset.x = 0;
this.offset.y = 0;
if (this.content_mc != undefined) {
if (target != this.content_mc) {
this.content_mc._visible = false;
this.content_mc.removeMovieClip();
this.content_mc.unloadMovie();
}
}
if (typeof(target) == "string") {
this.attachMovie(target, "tmp_mc", 3);
this.content_mc = this.tmp_mc;
} else if (target == undefined) {
this.content_mc.unloadMovie();
} else {
this.content_mc = target;
}
this.localToGlobal(this.offset);
this.content_mc._parent.globalToLocal(this.offset);
this.content_mc._x = this.offset.x;
this.content_mc._y = this.offset.y;
var contentBounds = this.content_mc.getBounds(this);
this.offset.x = -contentBounds.xMin;
this.offset.y = -contentBounds.yMin;
this.localToGlobal(this.offset);
this.content_mc._parent.globalToLocal(this.offset);
this.content_mc._x = this.offset.x;
this.content_mc._y = this.offset.y;
this.contentWidth = this.content_mc._width;
this.contentHeight = this.content_mc._height;
this.content_mc.setMask(this.mask_mc);
this.setSize(this.width, this.height);
};
FScrollPaneClass.prototype.setSize = function (w, h) {
if (((arguments.length < 2) || (isNaN(w))) || (isNaN(h))) {
return(undefined);
}
super.setSize(w, h);
this.width = Math.max(w, 60);
this.height = Math.max(h, 60);
this.boundingBox_mc._xscale = 100;
this.boundingBox_mc._yscale = 100;
this.boundingBox_mc._width = this.width;
this.boundingBox_mc._height = this.height;
this.setHandV();
this.initScrollBars();
if (this.mask_mc == undefined) {
this.attachMovie("FBoundingBoxSymbol", "mask_mc", 3000);
}
this.mask_mc._xscale = 100;
this.mask_mc._yscale = 100;
this.mask_mc._width = this.hWidth;
this.mask_mc._height = this.vHeight;
this.mask_mc._alpha = 0;
};
FScrollPaneClass.prototype.setScrollPosition = function (x, y) {
x = Math.max(this.hScrollBar_mc.minPos, x);
x = Math.min(this.hScrollBar_mc.maxPos, x);
y = Math.max(this.vScrollBar_mc.minPos, y);
y = Math.min(this.vScrollBar_mc.maxPos, y);
this.hScrollBar_mc.setScrollPosition(x);
this.vScrollBar_mc.setScrollPosition(y);
};
FScrollPaneClass.prototype.refreshPane = function () {
this.setScrollContent(this.content_mc);
};
FScrollPaneClass.prototype.loadScrollContent = function (url, handler, location) {
this.content_mc.removeMovieClip();
this.content_mc.unloadMovie();
this.content_mc._visible = 0;
this.loadContent.duplicateMovieClip("loadTemp", 3);
this.dupeFlag = true;
this.contentLoaded = function () {
this.loadReady = false;
this.content_mc = this.loadTemp;
this.refreshPane();
this.executeCallBack();
};
this.setChangeHandler(handler, location);
this.loadTemp.loadMovie(url);
};
FScrollPaneClass.prototype.setHScroll = function (prop) {
this.hScroll = prop;
this.setSize(this.width, this.height);
};
FScrollPaneClass.prototype.setVScroll = function (prop) {
this.vScroll = prop;
this.setSize(this.width, this.height);
};
FScrollPaneClass.prototype.setDragContent = function (dragFlag) {
if (dragFlag) {
this.boundingBox_mc.useHandCursor = true;
this.boundingBox_mc.onPress = function () {
this._parent.startDragLoop();
};
this.boundingBox_mc.tabEnabled = false;
this.boundingBox_mc.onRelease = (this.boundingBox_mc.onReleaseOutside = function () {
this._parent.pressFocus();
this._parent.onMouseMove = null;
});
} else {
delete this.boundingBox_mc.onPress;
this.boundingBox_mc.useHandCursor = false;
}
};
FScrollPaneClass.prototype.setSmallScroll = function (x, y) {
this.hScrollBar_mc.setSmallScroll(x);
this.vScrollBar_mc.setSmallScroll(y);
};
FScrollPaneClass.prototype.setHandV = function () {
if ((((this.contentHeight - this.height) > 2) && (this.vScroll != false)) || (this.vScroll == true)) {
this.hWidth = this.width - this.vScrollBar_mc._width;
} else {
this.hWidth = this.width;
}
if ((((this.contentWidth - this.width) > 2) && (this.hScroll != false)) || (this.hScroll == true)) {
this.vHeight = this.height - this.hScrollBar_mc._height;
} else {
this.vHeight = this.height;
}
};
FScrollPaneClass.prototype.startDragLoop = function () {
this.tabFocused = false;
this.myOnSetFocus();
this.lastX = this._xmouse;
this.lastY = this._ymouse;
this.onMouseMove = function () {
this.scrollXMove = this.lastX - this._xmouse;
this.scrollYMove = this.lastY - this._ymouse;
this.scrollXMove = this.scrollXMove + this.hScrollBar_mc.getScrollPosition();
this.scrollYMove = this.scrollYMove + this.vScrollBar_mc.getScrollPosition();
this.setScrollPosition(this.scrollXMove, this.scrollYMove);
if ((this.scrollXMove < this.hScrollBar_mc.maxPos) && (this.scrollXMove > this.hScrollBar_mc.minPos)) {
this.lastX = this._xmouse;
}
if ((this.scrollYMove < this.vScrollBar_mc.maxPos) && (this.scrollYMove > this.vScrollBar_mc.minPos)) {
this.lastY = this._ymouse;
}
this.updateAfterEvent();
};
};
FScrollPaneClass.prototype.initScrollBars = function () {
this.hScrollBar_mc._y = this.height - this.hScrollBar_mc._height;
this.hScrollBar_mc.setSize(this.hWidth);
this.hScrollBar_mc.setScrollProperties(this.hWidth, 0, this.contentWidth - this.hWidth);
this.vScrollBar_mc._visible = ((this.hWidth == this.width) ? false : true);
this.vScrollBar_mc._x = this.width - this.vScrollBar_mc._width;
this.vScrollBar_mc.setSize(this.vHeight);
this.vScrollBar_mc.setScrollProperties(this.vHeight, 0, this.contentHeight - this.vHeight);
this.hScrollBar_mc._visible = ((this.vHeight == this.height) ? false : true);
};
FScrollPaneClass.prototype.onScroll = function (component) {
var pos = component.getScrollPosition();
var XorY = ((component._name == "hScrollBar_mc") ? "x" : "y");
if (component._name == "hScrollBar_mc") {
this.content_mc._x = (-pos) + this.offset.x;
} else {
this.content_mc._y = (-pos) + this.offset.y;
}
};
FScrollPaneClass.prototype.myOnKeyDown = function () {
var posX = this.hScrollBar_mc.getScrollPosition();
var posY = this.vScrollBar_mc.getScrollPosition();
if (this.hScrollBar_mc.maxPos > this.hScrollBar_mc.minPos) {
if (Key.isDown(37)) {
this.setScrollPosition(posX - 3, posY);
} else if (Key.isDown(39)) {
this.setScrollPosition(posX + 3, posY);
}
}
if (this.vScrollBar_mc.maxPos > this.vScrollBar_mc.minPos) {
if (Key.isDown(38)) {
this.setScrollPosition(posX, posY - 3);
} else if (Key.isDown(40)) {
this.setScrollPosition(posX, posY + 3);
} else if (Key.isDown(34)) {
this.setScrollPosition(posX, posY + this.vScrollBar_mc.pageSize);
} else if (Key.isDown(33)) {
this.setScrollPosition(posX, posY - this.vScrollBar_mc.pageSize);
}
}
};
#endinitclip
this.deadPreview._visible = false;
Instance of Symbol 254 MovieClip [FScrollBarSymbol] "scrollBarAsset" in Symbol 263 MovieClip [FScrollPaneSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
_targetInstanceName = "";
horizontal = false;
}
Instance of Symbol 260 MovieClip "loadContent" in Symbol 263 MovieClip [FScrollPaneSymbol] Frame 1
onClipEvent (load) {
if (this._parent.loadReady) {
this._parent.contentLoaded();
delete this._parent.loadReady;
} else if (this._name != "loadContent") {
this._parent.loadReady = true;
}
}
Symbol 264 MovieClip [FListItemSymbol] Frame 1
#initclip 11
function FListItemClass() {
this.init();
}
FListItemClass.prototype = new FSelectableItemClass();
Object.registerClass("FListItemSymbol", FListItemClass);
#endinitclip
Symbol 265 MovieClip [DataProviderSymbol] Frame 1
#initclip 4
_global.DataProviderClass = function () {
this.init();
};
DataProviderClass.prototype.init = function () {
this.items = new Array();
this.uniqueID = 0;
this.views = new Array();
};
DataProviderClass.prototype.addView = function (viewRef) {
this.views.push(viewRef);
var eventObj = {event:"updateAll"};
viewRef.modelChanged(eventObj);
};
DataProviderClass.prototype.addItemAt = function (index, value) {
if (index < this.getLength()) {
this.items.splice(index, 0, "tmp");
}
this.items[index] = new Object();
if (typeof(value) == "object") {
this.items[index] = value;
} else {
this.items[index].label = value;
}
this.items[index].__ID__ = this.uniqueID++;
var eventObj = {event:"addRows", firstRow:index, lastRow:index};
this.updateViews(eventObj);
};
DataProviderClass.prototype.addItem = function (value) {
this.addItemAt(this.getLength(), value);
};
DataProviderClass.prototype.removeItemAt = function (index) {
var tmpItm = this.items[index];
this.items.splice(index, 1);
var eventObj = {event:"deleteRows", firstRow:index, lastRow:index};
this.updateViews(eventObj);
return(tmpItm);
};
DataProviderClass.prototype.removeAll = function () {
this.items = new Array();
this.updateViews({event:"deleteRows", firstRow:0, lastRow:this.getLength() - 1});
};
DataProviderClass.prototype.replaceItemAt = function (index, itemObj) {
if ((index < 0) || (index >= this.getLength())) {
return(undefined);
}
var tmpID = this.getItemID(index);
if (typeof(itemObj) == "object") {
this.items[index] = itemObj;
} else {
this.items[index].label = itemObj;
}
this.items[index].__ID__ = tmpID;
this.updateViews({event:"updateRows", firstRow:index, lastRow:index});
};
DataProviderClass.prototype.getLength = function () {
return(this.items.length);
};
DataProviderClass.prototype.getItemAt = function (index) {
return(this.items[index]);
};
DataProviderClass.prototype.getItemID = function (index) {
return(this.items[index].__ID__);
};
DataProviderClass.prototype.sortItemsBy = function (fieldName, order) {
this.items.sortOn(fieldName);
if (order == "DESC") {
this.items.reverse();
}
this.updateViews({event:"sort"});
};
DataProviderClass.prototype.updateViews = function (eventObj) {
var i = 0;
while (i < this.views.length) {
this.views[i].modelChanged(eventObj);
i++;
}
};
#endinitclip
Symbol 266 MovieClip [FSelectableItemSymbol] Frame 1
#initclip 7
function FSelectableItemClass() {
this.init();
}
FSelectableItemClass.prototype = new FUIComponentClass();
FSelectableItemClass.prototype.init = function () {
if (this._name != "itemAsset") {
this.highlighted = false;
this.layoutContent(100);
}
};
FSelectableItemClass.prototype.drawItem = function (itmObj, selected) {
this.displayContent(itmObj, selected);
if ((this.highlighted != selected) || ((this.controller.focused != this.oldFocus) && (selected))) {
this.setHighlighted(selected);
}
this.oldFocus = this.controller.focused;
};
FSelectableItemClass.prototype.setSize = function (width, height) {
var LOWEST_DEPTH = -16384;
this.width = width;
this.layoutContent(width);
this.attachMovie("FHighlightSymbol", "highlight_mc", LOWEST_DEPTH);
this.highlight_mc._x = 0.5;
this.highlight_mc._width = width - 0.5;
this.highlight_mc._height = height;
this.highlight_mc.controller = this;
this.highlight_mc._alpha = 0;
this.highlight_mc.trackAsMenu = true;
this.highlight_mc.onPress = function () {
if (this.controller.enable) {
this.controller.controller.clickHandler(this.controller.itemNum);
}
};
this.highlight_mc.onDragOver = function () {
if (this.controller.controller.focused) {
this.onPress();
}
};
this.highlight_mc.useHandCursor = false;
this.highlight_mc.trackAsMenu = true;
};
FSelectableItemClass.prototype.setEnabled = function (enabledFlag) {
this.enable = enabledFlag;
this.fLabel_mc.setEnabled(enabledFlag);
this.highlight_mc.gotoAndStop((enabledFlag ? "unfocused" : "disabled"));
};
FSelectableItemClass.prototype.layoutContent = function (width) {
this.attachMovie("FLabelSymbol", "fLabel_mc", 2, {hostComponent:this.controller});
this.fLabel_mc._x = 2;
this.fLabel_mc._y = 0;
this.fLabel_mc.setSize(width - 2);
this.fLabel_mc.labelField.selectable = false;
};
FSelectableItemClass.prototype.displayContent = function (itmObj, selected) {
var tmpLabel = "";
if (itmObj.label != undefined) {
tmpLabel = itmObj.label;
} else if (typeof(itmObj) == "object") {
for (var i in itmObj) {
if (i != "__ID__") {
tmpLabel = (itmObj[i] + ", ") + tmpLabel;
}
}
tmpLabel = tmpLabel.substring(0, tmpLabel.length - 2);
} else {
tmpLabel = itmObj;
}
if (this.fLabel_mc.labelField.text != tmpLabel) {
this.fLabel_mc.setLabel(tmpLabel);
}
var clr = (selected ? (this.controller.styleTable.textSelected.value) : (this.controller.styleTable.textColor.value));
if (clr == undefined) {
clr = (selected ? 16777215 : 0);
}
this.fLabel_mc.setColor(clr);
};
FSelectableItemClass.prototype.getItemIndex = function () {
return(this.controller.getScrollPosition() + this.itemNum);
};
FSelectableItemClass.prototype.getItemModel = function () {
return(this.controller.getItemAt(this.getItemIndex()));
};
FSelectableItemClass.prototype.getHostDataProvider = function () {
return(this.controller.dataProvider);
};
FSelectableItemClass.prototype.setHighlighted = function (flag) {
fade = this.controller.styleTable.fadeRate.value;
if (((fade == undefined) || (fade == 0)) || (!flag)) {
this.highlight_mc._alpha = (flag ? 100 : 0);
delete this.onEnterFrame;
} else {
this.fadeN = fade;
this.fadeX = 1;
this.highLight_mc._alpha = 20;
this.onEnterFrame = function () {
this.highLight_mc._alpha = (60 * Math.sqrt((this.fadeX++) / this.fadeN)) + 40;
if (this.fadeX > this.fadeN) {
delete this.onEnterFrame;
}
};
}
this.highlighted = flag;
};
#endinitclip
Symbol 267 MovieClip [FSelectableListSymbol] Frame 1
#initclip 5
function FSelectableListClass() {
this.init();
}
FSelectableListClass.prototype = new FUIComponentClass();
FSelectableListClass.prototype.init = function () {
super.init();
this.enable = true;
this.selected = new Array();
this.topDisplayed = (this.numDisplayed = 0);
this.lastSelected = 0;
this.tabChildren = false;
if (this._name != undefined) {
this.dataProvider = new DataProviderClass();
this.dataProvider.addView(this);
}
};
FSelectableListClass.prototype.addItemAt = function (index, label, data) {
if ((index < 0) || (!this.enable)) {
return(undefined);
}
this.dataProvider.addItemAt(index, {label:label, data:data});
};
FSelectableListClass.prototype.addItem = function (label, data) {
if (!this.enable) {
return(undefined);
}
this.dataProvider.addItem({label:label, data:data});
};
FSelectableListClass.prototype.removeItemAt = function (index) {
this.selectHolder = this.getSelectedIndex();
var item = this.getItemAt(index);
this.dataProvider.removeItemAt(index);
return(item);
};
FSelectableListClass.prototype.removeAll = function () {
this.dataProvider.removeAll();
};
FSelectableListClass.prototype.replaceItemAt = function (index, newLabel, newData) {
this.dataProvider.replaceItemAt(index, {label:newLabel, data:newData});
};
FSelectableListClass.prototype.sortItemsBy = function (fieldName, order) {
this.lastSelID = this.dataProvider.getItemID(this.lastSelected);
this.dataProvider.sortItemsBy(fieldName, order);
};
FSelectableListClass.prototype.getLength = function () {
return(this.dataProvider.getLength());
};
FSelectableListClass.prototype.getSelectedIndex = function () {
for (var uniqueID in this.selected) {
var tmpInd = this.selected[uniqueID].sIndex;
if (tmpInd != undefined) {
return(tmpInd);
}
}
};
FSelectableListClass.prototype.getSelectedItem = function () {
return(this.getItemAt(this.getSelectedIndex()));
};
FSelectableListClass.prototype.getItemAt = function (index) {
return(this.dataProvider.getItemAt(index));
};
FSelectableListClass.prototype.getEnabled = function () {
return(this.enable);
};
FSelectableListClass.prototype.getValue = function () {
var item = this.getSelectedItem();
return(((item.data == undefined) ? (item.label) : (item.data)));
};
FSelectableListClass.prototype.setSelectedIndex = function (index, flag) {
if (((index >= 0) && (index < this.getLength())) && (this.enable)) {
this.clearSelected();
this.selectItem(index, true);
this.lastSelected = index;
this.invalidate("updateControl");
if (flag != false) {
this.executeCallBack();
}
}
};
FSelectableListClass.prototype.setDataProvider = function (obj) {
this.setScrollPosition(0);
this.clearSelected();
if (obj instanceof Array) {
this.dataProvider = new DataProviderClass();
var i = 0;
while (i < obj.length) {
var value = ((typeof(obj[i]) == "string") ? ({label:obj[i]}) : (obj[i]));
this.dataProvider.addItem(value);
i++;
}
} else {
this.dataProvider = obj;
}
this.dataProvider.addView(this);
};
FSelectableListClass.prototype.setItemSymbol = function (linkID) {
this.tmpPos = this.getScrollPosition();
this.itemSymbol = linkID;
this.invalidate("setSize");
this.setScrollPosition(this.tmpPos);
};
FSelectableListClass.prototype.setEnabled = function (enabledFlag) {
this.cleanUI();
super.setEnabled(enabledFlag);
this.enable = enabledFlag;
this.boundingBox_mc.gotoAndStop((this.enable ? "enabled" : "disabled"));
var limit = Math.min(this.numDisplayed, this.getLength());
var i = 0;
while (i < limit) {
this.container_mc[("fListItem" + i) + "_mc"].setEnabled(this.enable);
i++;
}
if (this.enable) {
this.invalidate("updateControl");
}
};
FSelectableListClass.prototype.updateControl = function () {
var i = 0;
while (i < this.numDisplayed) {
this.container_mc[("fListItem" + i) + "_mc"].drawItem(this.getItemAt(this.topDisplayed + i), this.isSelected(this.topDisplayed + i));
i++;
}
};
FSelectableListClass.prototype.setSize = function (w, h) {
super.setSize(w, h);
this.boundingBox_mc._xscale = (this.boundingBox_mc._yscale = 100);
this.boundingBox_mc._xscale = (this.width * 100) / this.boundingBox_mc._width;
this.boundingBox_mc._yscale = (this.height * 100) / this.boundingBox_mc._height;
var i = 0;
while (i < this.numDisplayed) {
this.container_mc.attachMovie(this.itemSymbol, ("fListItem" + i) + "_mc", 10 + i, {controller:this, itemNum:i});
var item_mc = this.container_mc[("fListItem" + i) + "_mc"];
var offset = ((this.scrollOffset == undefined) ? 0 : (this.scrollOffset));
item_mc.setSize(this.width - offset, this.itmHgt);
item_mc._y = (this.itmHgt - 2) * i;
i++;
}
this.updateControl();
};
FSelectableListClass.prototype.modelChanged = function (eventObj) {
var firstRow = eventObj.firstRow;
var lastRow = eventObj.lastRow;
var event = eventObj.event;
if (event == "addRows") {
for (var i in this.selected) {
if ((this.selected[i].sIndex != undefined) && (this.selected[i].sIndex >= firstRow)) {
this.selected[i].sIndex = this.selected[i].sIndex + ((lastRow - firstRow) + 1);
this.setSelectedIndex(this.selected[i].sIndex, false);
}
}
} else if (event == "deleteRows") {
if (firstRow == lastRow) {
var index = firstRow;
if (this.selectHolder == index) {
this.selectionDeleted = true;
}
if (((this.topDisplayed + this.numDisplayed) >= this.getLength()) && (this.topDisplayed > 0)) {
this.topDisplayed--;
if (this.selectionDeleted && ((index - 1) >= 0)) {
this.setSelectedIndex(index - 1, false);
}
} else if (this.selectionDeleted) {
var len = this.getLength();
if (((index == (len - 1)) && (len > 1)) || (index > (len / 2))) {
this.setSelectedIndex(index - 1, false);
} else {
this.setSelectedIndex(index, false);
}
}
for (var i in this.selected) {
if (this.selected[i].sIndex > firstRow) {
this.selected[i].sIndex--;
}
}
} else {
this.clearSelected();
this.topDisplayed = 0;
}
} else if (event == "sort") {
var len = this.getLength();
var i = 0;
while (i < len) {
if (this.isSelected(i)) {
var id = this.dataProvider.getItemID(i);
if (id == this.lastSelID) {
this.lastSelected = i;
}
this.selected[String(id)].sIndex = i;
}
i++;
}
}
this.invalidate("updateControl");
};
FSelectableListClass.prototype.measureItmHgt = function () {
this.attachMovie(this.itemSymbol, "tmpItem_mc", 0, {controller:this});
this.tmpItem_mc.drawItem({label:"Sizer: PjtTopg"}, false);
this.itmHgt = this.tmpItem_mc._height;
this.tmpItem_mc.removeMovieClip();
};
FSelectableListClass.prototype.selectItem = function (index, selectedFlag) {
if (selectedFlag && (!this.isSelected(index))) {
this.selected[String(this.dataProvider.getItemID(index))] = {sIndex:index};
} else if (!selectedFlag) {
delete this.selected[String(this.dataProvider.getItemID(index))];
}
};
FSelectableListClass.prototype.isSelected = function (index) {
return(this.selected[String(this.dataProvider.getItemID(index))].sIndex != undefined);
};
FSelectableListClass.prototype.clearSelected = function () {
for (var uniqueID in this.selected) {
var index = this.selected[uniqueID].sIndex;
if (((index != undefined) && (this.topDisplayed <= index)) && (index < (this.topDisplayed + this.numDisplayed))) {
this.container_mc[("fListItem" + (index - this.topDisplayed)) + "_mc"].drawItem(this.getItemAt(index), false);
}
}
delete this.selected;
this.selected = new Array();
};
FSelectableListClass.prototype.selectionHandler = function (itemNum) {
var tmpInd = (this.topDisplayed + itemNum);
if (this.getItemAt(tmpInd == undefined)) {
this.changeFlag = false;
return(undefined);
}
this.changeFlag = true;
this.clearSelected();
this.selectItem(tmpInd, true);
this.container_mc[("fListItem" + itemNum) + "_mc"].drawItem(this.getItemAt(tmpInd), this.isSelected(tmpInd));
};
FSelectableListClass.prototype.moveSelBy = function (incr) {
var itmNum = this.getSelectedIndex();
var newItm = (itmNum + incr);
newItm = Math.max(0, newItm);
newItm = Math.min(this.getLength() - 1, newItm);
if (newItm == itmNum) {
return(undefined);
}
if ((itmNum < this.topDisplayed) || (itmNum >= (this.topDisplayed + this.numDisplayed))) {
this.setScrollPosition(itmNum);
}
if ((newItm >= (this.topDisplayed + this.numDisplayed)) || (newItm < this.topDisplayed)) {
this.setScrollPosition(this.topDisplayed + incr);
}
this.selectionHandler(newItm - this.topDisplayed);
};
FSelectableListClass.prototype.clickHandler = function (itmNum) {
this.focusRect.removeMovieClip();
if (!this.focused) {
this.pressFocus();
}
this.selectionHandler(itmNum);
this.onMouseUp = this.releaseHandler;
};
FSelectableListClass.prototype.releaseHandler = function () {
if (this.changeFlag) {
this.executeCallBack();
}
this.changeFlag = false;
this.onMouseUp = undefined;
};
FSelectableListClass.prototype.myOnSetFocus = function () {
super.myOnSetFocus();
var i = 0;
while (i < this.numDisplayed) {
this.container_mc[("fListItem" + i) + "_mc"].highlight_mc.gotoAndStop("enabled");
i++;
}
};
FSelectableListClass.prototype.myOnKillFocus = function () {
super.myOnKillFocus();
var i = 0;
while (i < this.numDisplayed) {
this.container_mc[("fListItem" + i) + "_mc"].highlight_mc.gotoAndStop("unfocused");
i++;
}
};
#endinitclip
Instance of Symbol 265 MovieClip [DataProviderSymbol] "dPAsset" in Symbol 267 MovieClip [FSelectableListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Instance of Symbol 266 MovieClip [FSelectableItemSymbol] "ItemAsset" in Symbol 267 MovieClip [FSelectableListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Symbol 268 MovieClip [FScrollSelectListSymbol] Frame 1
#initclip 9
function FScrollSelectListClass() {
this.init();
}
FScrollSelectListClass.prototype = new FSelectableListClass();
FScrollSelectListClass.prototype.getScrollPosition = function () {
return(this.topDisplayed);
};
FScrollSelectListClass.prototype.setScrollPosition = function (pos) {
if (this.enable) {
pos = Math.min(pos, this.getLength() - this.numDisplayed);
pos = Math.max(pos, 0);
this.scrollBar_mc.setScrollPosition(pos);
}
};
FScrollSelectListClass.prototype.setAutoHideScrollBar = function (flag) {
this.permaScrollBar = !flag;
this.setSize(this.width, this.height);
};
FScrollSelectListClass.prototype.setEnabled = function (enabledFlag) {
super.setEnabled(enabledFlag);
this.scrollBar_mc.setEnabled(this.enable);
};
FScrollSelectListClass.prototype.setSize = function (w, h) {
var pos = this.getScrollPosition();
super.setSize(w, h);
if (this.scrollBar_mc != undefined) {
this.removed = true;
}
this.scrollBar_mc = undefined;
this.initScrollBar();
this.setScrollPosition(pos);
};
FScrollSelectListClass.prototype.modelChanged = function (eventObj) {
super.modelChanged(eventObj);
this.invalidate("initScrollBar");
};
FScrollSelectListClass.prototype.initScrollBar = function () {
if ((!this.permaScrollBar) && (this.getLength() <= this.numDisplayed)) {
if (this.removed) {
this.scrollBar_mc.removeMovieClip();
this.scrollBar_mc = undefined;
this.scrollOffset = undefined;
this.invalidate("setSize");
}
} else {
if (this.scrollBar_mc == undefined) {
this.container_mc.attachMovie("FScrollBarSymbol", "scrollBar_mc", 3000, {hostStyle:this.styleTable});
this.scrollBar_mc = this.container_mc.scrollBar_mc;
this.scrollBar_mc.setChangeHandler("scrollHandler", this);
this.scrollBar_mc.setSize(this.height);
this.scrollBar_mc._x = this.width - this.scrollBar_mc._width;
this.scrollBar_mc._y = 0;
this.scrollBar_mc.setLargeScroll(this.numDisplayed - 1);
this.scrollOffset = this.scrollBar_mc._width;
this.invalidate("setSize");
}
this.scrollBar_mc.setScrollProperties(this.numDisplayed, 0, this.getLength() - this.numDisplayed);
}
};
FScrollSelectListClass.prototype.scrollHandler = function (scrollBar) {
var pos = scrollBar.getScrollPosition();
this.topDisplayed = pos;
if (this.lastPosition != pos) {
this.updateControl();
}
this.lastPosition = pos;
};
FScrollSelectListClass.prototype.clickHandler = function (itmNum) {
super.clickHandler(itmNum);
if ((this.dragScrolling == undefined) && (this.scrollBar_mc != undefined)) {
this.dragScrolling = setInterval(this, "dragScroll", 15);
}
};
FScrollSelectListClass.prototype.releaseHandler = function () {
clearInterval(this.dragScrolling);
this.dragScrolling = undefined;
super.releaseHandler();
};
FScrollSelectListClass.prototype.dragScroll = function () {
clearInterval(this.dragScrolling);
if (this.container_mc._ymouse < 0) {
this.setScrollPosition(this.getScrollPosition() - 1);
this.selectionHandler(0);
this.scrollInterval = Math.max(25, (-23.8 * (-this.container_mc._ymouse)) + 500);
this.dragScrolling = setInterval(this, "dragScroll", this.scrollInterval);
} else if (this.container_mc._ymouse > ((this.itmHgt - 2) * this.numDisplayed)) {
this.setScrollPosition(this.getScrollPosition() + 1);
this.selectionHandler(this.numDisplayed - 1);
this.scrollInterval = Math.max(25, (-23.8 * Math.abs((this.container_mc._ymouse - ((this.itmHgt - 2) * this.numDisplayed)) - 2)) + 500);
this.dragScrolling = setInterval(this, "dragScroll", this.scrollInterval);
} else {
this.dragScrolling = setInterval(this, "dragScroll", 15);
}
};
FScrollSelectListClass.prototype.myOnKeyDown = function () {
if (this.focused) {
this.keyCodes = new Array(40, 38, 34, 33, 36, 35);
this.keyIncrs = new Array(1, -1, this.numDisplayed - 1, -(this.numDisplayed - 1), -this.getLength(), this.getLength());
var i = 0;
while (i < this.keyCodes.length) {
if (Key.isDown(this.keyCodes[i])) {
this.moveSelBy(this.keyIncrs[i]);
return(undefined);
}
i++;
}
this.findInputText();
}
};
FScrollSelectListClass.prototype.findInputText = function () {
var tmpCode = Key.getAscii();
if ((tmpCode >= 33) && (tmpCode <= 126)) {
this.findString(String.fromCharCode(tmpCode));
}
};
FScrollSelectListClass.prototype.findString = function (str) {
if (this.getLength() == 0) {
return(undefined);
}
var itemNum = this.getSelectedIndex();
var jump = 0;
var i = (itemNum + 1);
while (i != itemNum) {
var itmStr = this.getItemAt(i).label.substring(0, str.length);
if ((str == itmStr) || (str.toUpperCase() == itmStr.toUpperCase())) {
var jump = (i - itemNum);
break;
}
if (i >= (this.getLength() - 1)) {
i = -1;
}
i++;
}
if (jump != 0) {
this.moveSelBy(jump);
}
};
#endinitclip
Instance of Symbol 254 MovieClip [FScrollBarSymbol] "scrollBarAsset" in Symbol 268 MovieClip [FScrollSelectListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
_targetInstanceName = "";
horizontal = false;
}
onClipEvent (load) {
this._width = (this._height = 1);
}
Instance of Symbol 267 MovieClip [FSelectableListSymbol] "superClassAsset" in Symbol 268 MovieClip [FScrollSelectListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Symbol 271 MovieClip [FListBoxSymbol] Frame 1
#initclip 10
function FListBoxClass() {
this.itemSymbol = "FListItemSymbol";
this.init();
this.permaScrollBar = true;
var i = 0;
while (i < this.labels.length) {
this.addItem(this.labels[i], this.data[i]);
i++;
}
this.boundingBox_mc.gotoAndStop(1);
this.width = this._width;
this.height = this._height;
this._yscale = (this._xscale = 100);
this.setSize(this.width, this.height);
if (this.changeHandler.length > 0) {
this.setChangeHandler(this.changeHandler);
}
}
FListBoxClass.prototype = new FScrollSelectListClass();
Object.registerClass("FListBoxSymbol", FListBoxClass);
FListBoxClass.prototype.getSelectedIndices = function () {
var tmpArray = new Array();
for (var i in this.selected) {
tmpArray.push(this.selected[i].sIndex);
}
return(((tmpArray.length > 0) ? (tmpArray) : undefined));
};
FListBoxClass.prototype.getSelectedItems = function () {
var indices = this.getSelectedIndices();
var tmpArray = new Array();
var i = 0;
while (i < indices.length) {
tmpArray.push(this.getItemAt(indices[i]));
i++;
}
return(((tmpArray.length > 0) ? (tmpArray) : undefined));
};
FListBoxClass.prototype.getSelectMultiple = function () {
return(this.selectMultiple);
};
FListBoxClass.prototype.getRowCount = function () {
return(this.numDisplayed);
};
FListBoxClass.prototype.setSelectedIndices = function (indexArray) {
this.clearSelected();
var i = 0;
while (i < indexArray.length) {
this.selectItem(indexArray[i], true);
i++;
}
this.updateControl();
};
FListBoxClass.prototype.setSelectMultiple = function (flag) {
this.selectMultiple = flag;
};
FListBoxClass.prototype.setRowCount = function (count) {
var hgt = ((count * (this.itmHgt - 2)) + 2);
this.setSize(this.width, hgt);
};
FListBoxClass.prototype.setWidth = function (wdt) {
this.setSize(wdt, this.height);
};
FListBoxClass.prototype.setSize = function (w, h) {
if (!this.enable) {
return(undefined);
}
w = Math.max(w, 20);
h = Math.max(h, 40);
this.container_mc.removeMovieClip();
this.container_mc = this.createEmptyMovieClip("container", 3);
this.measureItmHgt();
this.numDisplayed = Math.floor(h / (this.itmHgt - 2));
this.height = (this.numDisplayed * (this.itmHgt - 2)) + 2;
super.setSize(w, this.height);
};
FListBoxClass.prototype.removeItemAt = function (index) {
this.selectHolder = this.getSelectedIndices();
return(super.removeItemAt(index));
};
FListBoxClass.prototype.selectionHandler = function (itemNum) {
if (this.clickFilter) {
var index = (this.topDisplayed + itemNum);
if (this.getItemAt(index) == undefined) {
this.changeFlag = false;
return(undefined);
}
this.changeFlag = true;
if (((!this.selectMultiple) && (!Key.isDown(17))) || ((!Key.isDown(16)) && (!Key.isDown(17)))) {
this.clearSelected();
this.selectItem(index, true);
this.lastSelected = index;
this.container_mc[("fListItem" + itemNum) + "_mc"].drawItem(this.getItemAt(index), this.isSelected(index));
} else if (Key.isDown(16) && (this.selectMultiple)) {
if (this.lastSelected == -1) {
this.lastSelected = index;
}
var incr = ((this.lastSelected < index) ? 1 : -1);
this.clearSelected();
var i = this.lastSelected;
while (i != index) {
this.selectItem(i, true);
if ((i >= this.topDisplayed) && (i < (this.topDisplayed + this.numDisplayed))) {
this.container_mc[("fListItem" + (i - this.topDisplayed)) + "_mc"].drawItem(this.getItemAt(i), this.isSelected(i));
}
i = i + incr;
}
this.selectItem(index, true);
this.container_mc[("fListItem" + (index - this.topDisplayed)) + "_mc"].drawItem(this.getItemAt(index), this.isSelected(index));
} else if (key.isDown(17)) {
var selectedFlag = this.isSelected(index);
if (!this.selectMultiple) {
this.clearSelected();
}
if (!((!this.selectMultiple) && (selectedFlag))) {
this.selectItem(index, !selectedFlag);
this.container_mc[("fListItem" + itemNum) + "_mc"].drawItem(this.getItemAt(this.topDisplayed + itemNum), this.isSelected(this.topDisplayed + itemNum));
}
this.lastSelected = index;
}
} else {
this.clickFilter = true;
}
};
FListBoxClass.prototype.moveSelBy = function (itemNum) {
super.moveSelBy(itemNum);
this.releaseHandler();
};
#endinitclip
this.deadPreview._visible = false;
Instance of Symbol 268 MovieClip [FScrollSelectListSymbol] "superClassAsset" in Symbol 271 MovieClip [FListBoxSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Symbol 278 MovieClip Frame 1
stop();
Symbol 279 MovieClip [chain] Frame 66
this.removeMovieClip();
Symbol 282 MovieClip [flyD] Frame 21
this.removeMovieClip();
Symbol 287 MovieClip Frame 1
stop();
Symbol 289 MovieClip [hPar] Frame 55
this.removeMovieClip();
Symbol 297 MovieClip [shatter] Frame 25
this.removeMovieClip();
Symbol 309 MovieClip Frame 1
stop();
Symbol 310 MovieClip [pu] Frame 1
stop();
Symbol 323 MovieClip Frame 1
stop();
Symbol 324 MovieClip [puText] Frame 72
this.removeMovieClip();
Symbol 327 MovieClip [puGet] Frame 21
this.removeMovieClip();
Symbol 339 MovieClip Frame 1
stop();
Instance of Symbol 263 MovieClip [FScrollPaneSymbol] in Symbol 339 MovieClip Frame 2
//component parameters
onClipEvent (initialize) {
scrollContent = "";
hScroll = "auto";
vScroll = "auto";
dragContent = false;
}
Instance of Symbol 254 MovieClip [FScrollBarSymbol] in Symbol 339 MovieClip Frame 2
//component parameters
onClipEvent (initialize) {
_targetInstanceName = "";
horizontal = false;
}
Instance of Symbol 271 MovieClip [FListBoxSymbol] in Symbol 339 MovieClip Frame 2
//component parameters
onClipEvent (initialize) {
selectMultiple = false;
changeHandler = "";
}
Symbol 437 MovieClip Frame 25
stop();
if (this._parent._parent._parent._parent._parent.beginCharge == true) {
this._parent._parent._parent._parent._parent.beginCharge = false;
this._parent._parent._parent._parent._parent.charge = true;
this._parent._parent._parent._parent.powerBar.gotoAndStop("show");
}
this._parent._parent._parent._parent._parent.reloading = false;
this._parent._parent._parent._parent._parent.loadArrow();
Symbol 444 MovieClip Frame 1
stop();
Symbol 445 MovieClip Frame 1
stop();
Symbol 450 MovieClip Frame 1
stop();
Symbol 455 MovieClip Frame 1
stop();
this.txt = 3;
Symbol 455 MovieClip Frame 2
this.txtDisp.txt = this.txt;
Symbol 455 MovieClip Frame 24
if (this.txt == 3) {
this.txt = 2;
} else if (this.txt == 2) {
this.txt = 1;
} else if (this.txt == 1) {
this.txt = "GO!";
} else if (this.txt == "GO!") {
this.txt = "done";
}
if (this.txt == "done") {
this._parent._parent.gamePlay = true;
this.gotoAndStop("blank");
} else {
this.gotoAndPlay("count");
}
Symbol 456 MovieClip Frame 1
stop();
Instance of Symbol 450 MovieClip "quitBtn" in Symbol 456 MovieClip Frame 1
on (release) {
this._parent._parent.quitGame();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 464 MovieClip Frame 1
stop();
Symbol 486 MovieClip Frame 1
stop();
Symbol 489 MovieClip Frame 1
stop();
Symbol 492 MovieClip Frame 1
stop();
Symbol 495 MovieClip Frame 1
stop();
Symbol 495 MovieClip Frame 2
if (this._parent.mainDisplay.mode == "login") {
this._parent.updateGamesCompleted();
}
this.aF = this._parent.arrowsFired;
this.hH = this._parent.heartsHit;
this.fH = this._parent.fliesHit;
trace("Arrows fired = " + this._parent.arrowsFired);
trace("Misses = " + this._parent.misses);
if (this._parent.arrowsFired != 0) {
this.acc = Math.round((100 * (this._parent.arrowsFired - this._parent.misses)) / this._parent.arrowsFired);
} else {
this.acc = 0;
}
if ((this._parent.arrowsFired != 0) and (this._parent.arrowsFired != this._parent.misses)) {
this.aC = Math.ceil((this._parent.heartsHit + this._parent.fliesHit) / (this._parent.arrowsFired - this._parent.misses));
} else {
this.aC = 0;
}
this.mC = this._parent.maxHits;
this.mP = this._parent.maxPts;
this.fS = this._parent.score;
this.nameInst.onSetFocus = function () {
if (this.text == "Type your name here") {
this.text = "";
}
};
this.updateData = function () {
var t = this;
var p = this._parent;
if (Number(p.userSavedDataA[16]) > 1) {
var naacc = Math.round((Number(p.userSavedDataA[1]) + t.acc) / 2);
var namC = Math.round((Number(p.userSavedDataA[3]) + t.mC) / 2);
var naaC = Math.round((Number(p.userSavedDataA[5]) + t.aC) / 2);
var namP = Math.round((Number(p.userSavedDataA[7]) + t.mP) / 2);
t.nafS = Math.round((Number(p.userSavedDataA[9]) + t.fS) / 2);
} else {
var naacc = t.acc;
var namC = t.mC;
var naaC = t.aC;
var namP = t.mP;
t.nafS = t.fS;
}
if (t.fS > Number(p.userSavedDataA[10])) {
t._parent.updateScores("better", naacc, t.acc, namC, t.mC, naaC, t.aC, namP, t.mP, t.nafS, t.fS);
t.personalBest.gotoAndStop("show");
} else {
t._parent.updateScores("worse", naacc, namC, naaC, namP, t.nafS);
t.personalBest.gotoAndStop("blank");
}
};
if (this._parent.mainDisplay.mode == "login") {
this.updateData();
}
this.acc = this.acc + "%";
this.sendScores = function () {
var t = this;
t.retryBtn.enabled = false;
t.notify = "Sending score...";
var s1 = new LoadVars();
var s2 = new LoadVars();
s1.username = t._parent.globalUserName;
s1.userscore = t.fS;
s1.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/snscore.php?id=1", s2, "POST");
s2.onLoad = function (success) {
if (success) {
t.notify = "Scores updated!";
trace("Send Score Return Text = " + s2.ctext);
if (created == 1) {
trace("Higher Score");
} else if (created == 0) {
trace("lower score");
}
} else {
t.notify = "*Connection failed. Click here to retry.*";
t.retryBtn.enabled = true;
trace("Failed Send Score");
}
};
var s1a = new LoadVars();
var s2a = new LoadVars();
s1a.username = t._parent.globalUserName;
s1a.userscore = t.nafS;
s1a.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/snscore.php?id=2", s2a, "POST");
s2a.onLoad = function (success) {
if (success) {
t.notify = "Scores updated!";
trace("Send Score Return Text = " + s2a.ctext);
if (created == 1) {
trace("Higher Score");
} else if (created == 0) {
trace("lower score");
}
} else {
t.notify = "*Connection failed. Click here to retry.*";
t.retryBtn.enabled = true;
trace("Failed Send Score");
}
};
};
if (this._parent.mainDisplay.mode == "login") {
this.sendScores();
}
Instance of Symbol 486 MovieClip in Symbol 495 MovieClip Frame 2
on (release) {
this._parent._parent.startGame("real");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 489 MovieClip in Symbol 495 MovieClip Frame 2
on (release) {
var p = this._parent;
if (p._parent.mainDisplay.mode == "login") {
p._parent.reset();
p._parent.mainDisplay.gotoAndStop("hs");
p.gotoAndStop("blank");
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 492 MovieClip in Symbol 495 MovieClip Frame 2
on (release) {
var p = this._parent;
p._parent.quitGame();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 494 MovieClip "retryBtn" in Symbol 495 MovieClip Frame 2
on (release) {
if (this._parent.notify == "*Connection failed. Click here to retry.*") {
this._parent.sendScores();
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 500 MovieClip Frame 1
stop();
Symbol 502 MovieClip Frame 1
stop();
Symbol 504 MovieClip Frame 1
stop();
Symbol 505 MovieClip Frame 1
stop();
Symbol 506 MovieClip Frame 1
stop();
Instance of Symbol 500 MovieClip in Symbol 506 MovieClip Frame 2
on (release) {
this._parent._parent.startGame("real");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 502 MovieClip "resumeBtn" in Symbol 506 MovieClip Frame 2
on (release) {
this._parent._parent.pauseFunc(false);
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 504 MovieClip "optionsBtn" in Symbol 506 MovieClip Frame 2
on (release) {
this._parent._parent.gameDisplay.quitBtn.enabled = false;
this._parent._parent.mainDisplay.gotoAndStop("options");
this._parent._parent.togglePauseBtns(false);
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 505 MovieClip "quitBtn" in Symbol 506 MovieClip Frame 2
on (release) {
this._parent._parent.quitGame();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 520 MovieClip Frame 1
stop();
Symbol 522 MovieClip Frame 1
stop();
Symbol 525 MovieClip Frame 1
stop();
Symbol 529 MovieClip Frame 1
stop();
Symbol 532 MovieClip Frame 1
stop();
Symbol 535 MovieClip Frame 1
stop();
Symbol 540 MovieClip Frame 1
stop();
Symbol 543 MovieClip Frame 1
stop();
Symbol 545 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 545 MovieClip Frame 2
on (release) {
var t = this;
var p = t._parent;
p._parent.note = "Deleting...";
var s1 = new LoadVars();
var s2 = new LoadVars();
s1.username = p.name;
trace("Name to be deleted = " + p.name);
s1.cake = _global.pie;
s1.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/delplayer.php", s2, "POST");
t.enabled = false;
s2.onLoad = function (success) {
if (success) {
p._parent.note = "";
t.enabled = true;
p._parent.userNameInst.text = "";
p._parent.passInst.text = "";
p._parent.remNameBtn.stat = "no";
p._parent.remNameBtn.ch.gotoAndStop("blank");
p._parent._parent.updateRemName("none");
p._parent.remPassBtn.stat = "no";
p._parent.remPassBtn.ch.gotoAndStop("blank");
p._parent._parent.updateRemPass("none");
p._parent.remPassBtn._visible = false;
p._parent._parent.togglePlayerBtns(true);
p.gotoAndStop("blank");
} else {
p._parent.note = "Connection Error";
t.enabled = true;
}
};
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 543 MovieClip in Symbol 545 MovieClip Frame 2
on (release) {
var p = this._parent;
p._parent._parent.togglePlayerBtns(true);
p.gotoAndStop("blank");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 559 MovieClip Frame 1
stop();
Symbol 566 MovieClip Frame 1
stop();
Symbol 567 MovieClip Frame 1
stop();
Symbol 569 MovieClip Frame 1
stop();
Symbol 571 MovieClip Frame 1
stop();
Symbol 573 MovieClip Frame 1
stop();
Symbol 575 MovieClip Frame 1
stop();
Symbol 577 MovieClip Frame 1
stop();
Symbol 580 MovieClip Frame 1
stop();
Symbol 590 MovieClip Frame 1
stop();
Symbol 597 MovieClip Frame 372
stop();
Symbol 608 MovieClip Frame 133
this.gotoAndPlay(random(30) + 1);
Symbol 608 MovieClip Frame 190
this.gotoAndPlay(random(20) + 1);
Symbol 608 MovieClip Frame 245
this.gotoAndPlay(random(20) + 1);
Symbol 612 MovieClip Frame 1
stop();
Symbol 612 MovieClip Frame 2
stop();
this.tut.eyes.gotoAndPlay("wink");
this.tut.mouth.gotoAndPlay(280);
this.tut.right.gotoAndStop("wave");
Instance of Symbol 543 MovieClip in Symbol 612 MovieClip Frame 2
on (release) {
var p = this._parent;
p._parent.genListBox = false;
p._parent._parent.promptHelp = "false";
if (p._parent.mode == "login") {
p._parent._parent.updatePrompt();
}
p._parent._parent.toggleTitleBtns(true);
p._parent._parent.startGame("real");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 540 MovieClip in Symbol 612 MovieClip Frame 2
on (release) {
var p = this._parent;
p._parent.genListBox = false;
p._parent._parent.promptHelp = "false";
if (this._parent.mainDisplay.mode == "login") {
p._parent._parent.updatePrompt();
}
p._parent._parent.toggleTitleBtns(true);
p._parent._parent.helpMC.gotoAndStop("start");
p._parent._parent.startGame("help");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 633 MovieClip Frame 1
stop();
Symbol 664 MovieClip Frame 1
stop();
Symbol 666 MovieClip Frame 1
stop();
Symbol 668 MovieClip Frame 1
stop();
Symbol 670 MovieClip Frame 1
stop();
Symbol 677 MovieClip Frame 1
stop();
Symbol 688 MovieClip Frame 1
stop();
Symbol 690 MovieClip Frame 1
stop();
Symbol 694 MovieClip Frame 1
stop();
Symbol 709 MovieClip Frame 1
stop();
this._parent.selectPlayer = true;
this._parent.logIn = true;
this._parent.startSounds();
this.note = "";
this.userNameInst.onSetFocus = function () {
var p = this._parent;
p.note = "";
p._parent.typing = true;
p._parent.typeName = true;
};
this.userNameInst.onKillFocus = function () {
this._parent._parent.typing = false;
this._parent._parent.typeName = true;
this._parent.userNameGuide.text = "";
this._parent.accept = "";
};
this.passInst.onSetFocus = function () {
var p = this._parent;
p.note = "";
p._parent.typing = true;
};
this.passInst.onKillFocus = function () {
this._parent._parent.typing = false;
};
this.userNameInst.tabIndex = 1;
this.remNameBtn.tabIndex = 2;
this.passInst.tabIndex = 3;
this.remPassBtn.tabIndex = 4;
this.proceedBtn.tabIndex = 5;
this.deleteBtn.tabIndex = 6;
this.npBtn.tabIndex = 7;
this.recAccountBtn.tabIndex = 8;
this.agBtn.tabIndex = 9;
Instance of Symbol 520 MovieClip "npBtn" in Symbol 709 MovieClip Frame 1
on (release) {
this._parent.gotoAndStop("new");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 522 MovieClip "proceedBtn" in Symbol 709 MovieClip Frame 1
on (release) {
var t = this;
var p = t._parent;
if (p.userNameInst.text != "") {
t.enabled = false;
p.note = "Logging In...";
getdat_lv = new LoadVars();
getdat_lv.username = p.userNameInst.text;
getdat_lv.cake = _global.pie;
recdat_lv = new LoadVars();
getdat_lv.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/loaddata.php", recdat_lv, "POST");
recdat_lv.onLoad = function (success) {
if (success) {
p._parent.userSavedDataA = recdat_lv.mydata.split("*");
trace("Loaded saved data: " + p._parent.userSavedDataA);
if (p.passInst.text == p._parent.userSavedDataA[0]) {
if (p._parent.userSavedDataA[1] != null) {
p.note = "";
p._parent.globalUserName = p.userNameInst.text;
if (p.remNameBtn.stat == "yes") {
p._parent.updateRemName(p.userNameInst.text);
if (p.remPassBtn.stat == "yes") {
p._parent.updateRemPass(p.passInst.text);
}
}
p.mode = "login";
p.gotoAndStop("title");
} else {
p.note = "This account doesn't exist.";
}
} else {
p.note = "Please provdie a valid password.";
}
} else {
p.note = "Connection Error";
}
t.enabled = true;
};
} else {
p.note = "Please enter a username.";
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 525 MovieClip "deleteBtn" in Symbol 709 MovieClip Frame 1
on (release) {
var t = this;
var p = t._parent;
if (p.userNameInst.text != "") {
t.enabled = false;
p.note = "Verifying...";
getdat2_lv = new LoadVars();
getdat2_lv.username = p.userNameInst.text;
getdat2_lv.cake = _global.pie;
recdat2_lv = new LoadVars();
getdat2_lv.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/loaddata.php", recdat2_lv, "POST");
recdat2_lv.onLoad = function (success) {
if (success) {
p._parent.userSavedDataA = recdat2_lv.mydata.split("*");
if (p.passInst.text == p._parent.userSavedDataA[0]) {
if (p._parent.userSavedDataA[1] != null) {
p.confirm.gotoAndStop("show");
p.confirm.name = p.userNameInst.text;
p.note = "";
p._parent.togglePlayerBtns(false);
t.gotoAndStop(1);
} else {
p.note = "This account doesn't exist.";
t.enabled = true;
}
} else {
p.note = "Please provdie a valid password.";
t.enabled = true;
}
} else {
p.note = "Connection Error";
t.enabled = true;
}
};
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 532 MovieClip "remNameBtn" in Symbol 709 MovieClip Frame 1
onClipEvent (load) {
this._parent._parent.checkRemName();
if (this.stat == "yes") {
this._parent.remPassBtn._visible = true;
} else {
this._parent.remPassBtn._visible = false;
}
}
on (release) {
if (this.stat == "no") {
this.stat = "yes";
this.ch.gotoAndStop("show");
this._parent.remPassBtn._visible = true;
} else {
this.stat = "no";
this.ch.gotoAndStop("blank");
this._parent._parent.updateRemName("none");
this._parent.remPassBtn.stat = "no";
this._parent.remPassBtn.ch.gotoAndStop("blank");
this._parent._parent.updateRemPass("none");
this._parent.remPassBtn._visible = false;
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 532 MovieClip "remPassBtn" in Symbol 709 MovieClip Frame 1
onClipEvent (load) {
this._parent._parent.checkRemPass();
}
on (release) {
if (this.stat == "no") {
this.stat = "yes";
this.ch.gotoAndStop("show");
} else {
this.stat = "no";
this.ch.gotoAndStop("blank");
this._parent._parent.updateRemPass("none");
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 535 MovieClip "recAccountBtn" in Symbol 709 MovieClip Frame 1
on (release) {
var t = this;
var p = t._parent;
if (p.userNameInst.text != "") {
var found = false;
var i = 0;
while (i < p._parent.backUpAccountsA.length) {
if (p.userNameInst.text == p._parent.backUpAccountsA[i][0]) {
var tempA = p._parent.backUpAccountsA[i].slice(0);
trace("found array: " + tempA);
tempA.splice(0, 1);
trace("spliced found array: " + tempA);
p._parent.globalUserName = p.userNameInst.text;
p._parent.userSavedDataA = tempA;
p.note = "Recovering...";
var s1 = new LoadVars();
var s2 = new LoadVars();
s1.username = p._parent.globalUserName;
s1.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/newplayer.php", s2, "POST");
t.enabled = false;
s2.onLoad = function (success) {
if (success) {
p.note = s2.ctext;
if (s2.created == 1) {
p.note = "Account recovered!";
p._parent.updateServer();
}
} else {
p.note = "Connection Failed";
}
t.enabled = true;
};
found = true;
break;
}
i++;
}
if (found == false) {
p.note = "Cannot locate the username";
}
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 522 MovieClip in Symbol 709 MovieClip Frame 1
on (release) {
var t = this;
var p = t._parent;
p.gotoAndStop("title");
p.mode = "guest";
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 97 MovieClip "agBtn" in Symbol 709 MovieClip Frame 1
on (release) {
bot_id = 90;
getURL ("http://bot.armorstudios.com/armorgames.php?bid=" + bot_id, "_blank");
}
Instance of Symbol 549 MovieClip in Symbol 709 MovieClip Frame 1
on (release) {
getURL ("http://bot.armorstudios.com", "_blank");
}
Symbol 709 MovieClip Frame 2
this._parent.selectPlayer = true;
this._parent.logIn = false;
this._parent.startSounds();
this.noteC = "";
this.nameInst.onSetFocus = function () {
if (this.text == "Enter Your Name") {
this.text = "";
}
this._parent._parent.typing = true;
};
this.nameInst.onKillFocus = function () {
this._parent._parent.typing = false;
};
this.passInst.onSetFocus = function () {
this._parent._parent.typing = true;
this._parent.noteC = "";
};
this.passInst.onKillFocus = function () {
this._parent._parent.typing = false;
};
this.cpassInst.onSetFocus = function () {
this._parent._parent.typing = true;
this._parent.noteC = "";
};
this.cpassInst.onKillFocus = function () {
this._parent._parent.typing = false;
};
this.nameInst.tabIndex = 1;
this.passInst.tabIndex = 2;
this.cpassInst.tabIndex = 3;
this.proceedBtn.tabIndex = 4;
this.backBtn.tabIndex = 5;
this.agBtn.tabIndex = 6;
Instance of Symbol 522 MovieClip "proceedBtn" in Symbol 709 MovieClip Frame 2
on (release) {
var t = this;
var p = t._parent;
if ((p.nameInst.text != "") and (p.nameInst.text != "Enter Your Name")) {
var nameGood1 = true;
} else {
p.nameInst.text = "Enter Your Name";
var nameGood1 = false;
}
if (p.nameInst.text.indexOf(",") == -1) {
var nameGood2 = true;
} else {
p.noteC = "No commas allowed.";
var nameGood2 = false;
}
if (p.nameInst.text.indexOf("*") == -1) {
var nameGood3 = true;
} else {
p.noteC = "No * allowed.";
var nameGood3 = false;
}
if (p.passInst.text == p.cpassInst.text) {
var passGood = true;
} else {
var passGood = false;
p.noteC = "Passwords do not match!";
}
if (p.passInst.text.indexOf("*") == -1) {
var passGood2 = true;
} else {
var passGood2 = false;
p.noteC = "No * allowed.";
}
if (((((nameGood1 == true) and (nameGood2 == true)) and (nameGood3 == true)) and (passGood == true)) and (passGood2 == true)) {
t.enabled = false;
p.regbox.text = "Registering...";
var s1 = new LoadVars();
var s2 = new LoadVars();
s1.username = p.nameInst.text;
s1.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/newplayer.php", s2, "POST");
t.enabled = false;
s2.onLoad = function (success) {
if (success) {
p.regbox.text = s2.ctext;
if (s2.created == 1) {
p._parent.globalUserName = p.nameInst.text;
p._parent.newName(p.passInst.text);
p.gotoAndStop("title");
}
} else {
p.regbox.text = "Connection Failed";
}
t.enabled = true;
};
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 559 MovieClip "backBtn" in Symbol 709 MovieClip Frame 2
on (release) {
this._parent.gotoAndStop("player");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 709 MovieClip Frame 3
function sync() {
var t = this;
sync1 = new LoadVars();
sync2 = new LoadVars();
sync1.username = t.nameDisp;
sync1.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/sync.php", sync2, "POST");
sync2.onLoad = function (success) {
if (success) {
t.users_online = "Currently Active Users: " + sync2.online;
t.onlineList = sync2.list;
t.onlineA = t.onlineList.split(",");
if (t.onlineA.length > 0) {
t.loadingList.gotoAndStop("blank");
t.genListBox = true;
} else {
t.loadingList.gotoAndStop("blank");
t.genListBox = false;
}
t.updateListBox();
} else {
t.users_online = "Connection Error";
trace(">:[");
}
};
}
stop();
this._parent.selectPlayer = false;
this._parent.logIn = false;
this._parent.setNewKeys();
if (this.mode == "login") {
this.nameDisp = this._parent.globalUserName;
this._parent.checkSound();
this._parent.checkInGameSettings();
trace("Title page Loaded Saved Data: " + this._parent.userSavedDataA);
} else {
this.nameDisp = "Guest";
}
this.users_online = "Loading...";
setInterval(sync, 282000);
sync();
this.curCountIndex = 0;
this.onlineBox.setAutoHideScrollBar(true);
this.updateListBox = function () {
var t = this;
var p = t._parent;
var i = t.curCountIndex;
var count = 0;
while (i < t.onlineA.length) {
t.onlineBox.addItem(t.onlineA[i], i);
trace(t.curCountIndex);
if (t.curCountIndex == (t.onlineA.length - 1)) {
t.genListBox = false;
t.loadingList.gotoAndStop("blank");
return;
}
t.curCountIndex++;
count++;
if (count == 15) {
return;
}
i++;
}
};
var myStyleFormat = new FStyleFormat();
myStyleFormat.textColor = 4394571 /* 0x430E4B */;
myStyleFormat.textSelected = 16777215 /* 0xFFFFFF */;
myStyleFormat.selectionUnfocused = 11870389 /* 0xB520B5 */;
myStyleFormat.selection = 11870389 /* 0xB520B5 */;
myStyleFormat.addListener(onlineBox);
Instance of Symbol 271 MovieClip [FListBoxSymbol] "onlineBox" in Symbol 709 MovieClip Frame 3
//component parameters
onClipEvent (initialize) {
selectMultiple = false;
changeHandler = "";
}
Instance of Symbol 566 MovieClip "playBtn" in Symbol 709 MovieClip Frame 3
on (release) {
var p = this._parent;
if (p._parent.promptHelp == "false") {
p.genListBox = false;
p._parent.startGame("real");
} else {
p.promptHelpMC.gotoAndStop("show");
p._parent.toggleTitleBtns(false);
p.helpBtn.enabled = true;
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 567 MovieClip "optionsBtn" in Symbol 709 MovieClip Frame 3
on (release) {
var p = this._parent;
p.genListBox = false;
p.gotoAndStop("options");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 569 MovieClip "statsBtn" in Symbol 709 MovieClip Frame 3
on (release) {
if (this._parent.mode == "login") {
this._parent.genListBox = false;
this._parent.gotoAndStop("stats");
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 571 MovieClip "hsBtn" in Symbol 709 MovieClip Frame 3
on (release) {
if (this._parent.mode == "login") {
this._parent.genListBox = false;
this._parent.gotoAndStop("hs");
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 573 MovieClip "helpBtn" in Symbol 709 MovieClip Frame 3
on (release) {
var p = this._parent;
p.genListBox = false;
if (p._parent.promptHelp == "true") {
p._parent.promptHelp = "false";
p._parent.updatePrompt();
p._parent.toggleTitleBtns(true);
}
p._parent.helpMC.gotoAndStop("start");
p._parent.startGame("help");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 575 MovieClip "galleryBtn" in Symbol 709 MovieClip Frame 3
on (release) {
this._parent.genListBox = false;
this._parent.gotoAndStop("gallery");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 577 MovieClip "cpBtn" in Symbol 709 MovieClip Frame 3
on (release) {
var p = this._parent;
p.genListBox = false;
p.gotoAndStop("player");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 709 MovieClip Frame 4
letterkeys = new Array("A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z");
numberkeys = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9");
numpadkeys = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "*", "+", "Enter", "-", ".", "/");
functionkeys = new Array("F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12");
otherkeys = new Array("Space", "Page Up", "Page Down", "End", "Home", "Left", "Up", "Right", "Down");
this.setValues = function (pressed, which) {
var p = this;
if ((pressed >= 65) and (pressed <= 90)) {
p[which] = letterkeys[pressed - 65];
}
if ((pressed >= 48) and (pressed <= 57)) {
p[which] = numberkeys[pressed - 48];
}
if ((pressed >= 96) and (pressed <= 111)) {
p[which] = numpadkeys[pressed - 96];
}
if ((pressed >= 112) and (pressed <= 123)) {
p[which] = functionkeys[pressed - 112];
}
if ((pressed >= 32) and (pressed <= 40)) {
p[which] = otherkeys[pressed - 32];
}
if (pressed == 8) {
p[which] = "BackSpace";
}
if (pressed == 9) {
p[which] = "Tab";
}
if (pressed == 12) {
p[which] = "Clear";
}
if (pressed == 13) {
p[which] = "Enter";
}
if (pressed == 16) {
p[which] = "Shift";
}
if (pressed == 17) {
p[which] = "Control";
}
if (pressed == 18) {
p[which] = "Alt";
}
if (pressed == 20) {
p[which] = "Caps Lock";
}
if (pressed == 27) {
p[which] = "Esc";
}
if (pressed == 45) {
p[which] = "Insert";
}
if (pressed == 46) {
p[which] = "Delete";
}
if (pressed == 47) {
p[which] = "help";
}
if (pressed == 144) {
p[which] = "Num Lock";
}
if (pressed == 186) {
p[which] = ";:";
}
if (pressed == 187) {
p[which] = "=+";
}
if (pressed == 189) {
p[which] = "-_";
}
if (pressed == 191) {
p[which] = "/?";
}
if (pressed == 192) {
p[which] = "'@";
}
if (pressed == 219) {
p[which] = "[{";
}
if (pressed == 220) {
p[which] = "\\|";
}
if (pressed == 221) {
p[which] = "]}";
}
p[which + "Name"].autoSize = true;
if (which == "mKey") {
p.mStatInst._x = (p[which + "Name"]._x + p[which + "Name"]._width) + 20;
} else if (which == "sKey") {
p.sStatInst._x = (p[which + "Name"]._x + p[which + "Name"]._width) + 20;
}
p._parent.typing = false;
if (p.mode == "login") {
p._parent.updateKeys();
}
};
this.setValues(this._parent.uKey, "uKey");
this.setValues(this._parent.dKey, "dKey");
this.setValues(this._parent.pKey, "pKey");
this.setValues(this._parent.mKey, "mKey");
this.setValues(this._parent.sKey, "sKey");
this.releaseFunc = function (which) {
var t = this;
t.fillBlanks();
t._parent.typing = true;
t.selectkey = true;
t.whichkey = which;
t[which] = "";
};
this.fillBlanks = function () {
var t = this;
if (t.selectkey == true) {
if (t.whichkey == "uKey") {
t.setValues(t._parent.uKey, "uKey");
}
if (t.whichkey == "dKey") {
t.setValues(t._parent.dKey, "dKey");
}
if (t.whichkey == "pKey") {
t.setValues(t._parent.pKey, "pKey");
}
if (t.whichkey == "mKey") {
t.setValues(t._parent.mKey, "mKey");
}
if (t.whichkey == "sKey") {
t.setValues(t._parent.sKey, "sKey");
}
}
};
this.uKeyInst.onRelease = function () {
this._parent.releaseFunc("uKey");
};
this.dKeyInst.onRelease = function () {
this._parent.releaseFunc("dKey");
};
this.pKeyInst.onRelease = function () {
this._parent.releaseFunc("pKey");
};
this.mKeyInst.onRelease = function () {
this._parent.releaseFunc("mKey");
};
this.sKeyInst.onRelease = function () {
this._parent.releaseFunc("sKey");
};
this.qual = this._parent.inGameQuality;
this.part = this._parent.particles;
this.setSoundText = function () {
if (this._parent.globalsoundcontrol == "play") {
this.mStat = "(Currently On)";
} else if (this._parent.globalsoundcontrol == "stop") {
this.mStat = "(Currently Off)";
}
trace("options sound play: " + this._parent.soundPlay);
if (this._parent.soundPlay == "true") {
this.sStat = "(Currently On)";
} else {
this.sStat = "(Currently Off)";
}
};
this.setSoundText();
Instance of Symbol 633 MovieClip "backBtn" in Symbol 709 MovieClip Frame 4
on (release) {
var p = this._parent;
p.fillBlanks();
if (p._parent.gamePlay == false) {
p.gotoAndStop("title");
} else {
p._parent.togglePauseBtns(true);
p._parent.gameDisplay.quitBtn.enabled = true;
if (p._parent.gameType == "help") {
p._parent.pause = false;
p._parent.helpMC.nextBtn.enabled = true;
p._parent.helpMC.prevBtn.enabled = true;
p._parent.helpMC.gotoOptionsBtn.enabled = true;
}
p.gotoAndStop("blank");
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 494 MovieClip "uKeyInst" in Symbol 709 MovieClip Frame 4
on (rollOver) {
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
Instance of Symbol 494 MovieClip "dKeyInst" in Symbol 709 MovieClip Frame 4
on (rollOver) {
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
Instance of Symbol 494 MovieClip "pKeyInst" in Symbol 709 MovieClip Frame 4
on (rollOver) {
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
Instance of Symbol 494 MovieClip "mKeyInst" in Symbol 709 MovieClip Frame 4
on (rollOver) {
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
Instance of Symbol 287 MovieClip in Symbol 709 MovieClip Frame 4
on (release) {
var p = this._parent;
if (p.qual == "High") {
p.qual = "Medium";
} else if (p.qual == "Medium") {
p.qual = "Low";
}
p._parent.inGameQuality = p.qual;
p._parent.updateQuality();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 287 MovieClip in Symbol 709 MovieClip Frame 4
on (release) {
var p = this._parent;
if (p.qual == "Low") {
p.qual = "Medium";
} else if (p.qual == "Medium") {
p.qual = "High";
}
p._parent.inGameQuality = p.qual;
p._parent.updateQuality();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 287 MovieClip in Symbol 709 MovieClip Frame 4
on (release) {
var p = this._parent;
if (p.part == "On") {
p.part = "Off";
} else if (p.part == "Off") {
p.part = "On";
}
p._parent.particles = p.part;
p._parent.updateParticles();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 287 MovieClip in Symbol 709 MovieClip Frame 4
on (release) {
var p = this._parent;
if (p.part == "On") {
p.part = "Off";
} else if (p.part == "Off") {
p.part = "On";
}
p._parent.particles = p.part;
p._parent.updateParticles();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 494 MovieClip "sKeyInst" in Symbol 709 MovieClip Frame 4
on (rollOver) {
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
Symbol 709 MovieClip Frame 5
if (this._parent.userSavedDataA[16] == 1) {
this.avg = ("Average (" + Number(this._parent.userSavedDataA[16])) + " game)";
} else {
this.avg = ("Average (" + Number(this._parent.userSavedDataA[16])) + " games)";
}
this.aacc = Number(this._parent.userSavedDataA[1]) + "%";
this.acc = Number(this._parent.userSavedDataA[2]) + "%";
this.amC = Number(this._parent.userSavedDataA[3]);
this.mC = Number(this._parent.userSavedDataA[4]);
this.aaC = Number(this._parent.userSavedDataA[5]);
this.aC = Number(this._parent.userSavedDataA[6]);
this.amP = Number(this._parent.userSavedDataA[7]);
this.mP = Number(this._parent.userSavedDataA[8]);
this.afS = Number(this._parent.userSavedDataA[9]);
this.fS = Number(this._parent.userSavedDataA[10]);
this.ara = (this.ra = (this.atot = (this.tot = "Loading...")));
this.avgInst.autoSize = "center";
this.createEmptyMovieClip("lineCont", 10000000);
this.lineCont.clear();
this.lineCont.lineStyle(3, 4587871, 100);
this.lineCont.moveTo(this.avgInst._x + 15, -118);
this.lineCont.lineTo((this.avgInst._x + this.avgInst._width) - 15, -118);
this.searchRank = function (rank) {
var t = this;
getnm_lvs = new LoadVars();
getnm_lvs.rank = rank;
recNm_lvs = new LoadVars();
getnm_lvs.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getname.php?id=1", recNm_lvs, "POST");
recNm_lvs.onLoad = function (success) {
if (success) {
t.tot = recNm_lvs.score;
trace("Best Total Scores = " + recNm_lvs.score);
} else {
t.tot = "Connection Error";
}
};
};
this.searchRank("last");
this.searchRank2 = function (rank) {
var t = this;
getnm_lv2s = new LoadVars();
getnm_lv2s.rank = rank;
recNm_lv2s = new LoadVars();
getnm_lv2s.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getname.php?id=2", recNm_lv2s, "POST");
recNm_lv2s.onLoad = function (success) {
if (success) {
t.atot = recNm_lv2s.score;
} else {
t.atot = "Connection Error";
}
};
};
this.searchRank2("last");
this.searchPlayer = function (player) {
var t = this;
var s1s = new LoadVars();
var s2s = new LoadVars();
s1s.username = player;
s1s.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getrank.php?id=1", s2s, "POST");
s2s.onLoad = function (success) {
if (success) {
t.ra = s2s.rank;
} else {
t.ra = "Connection Error";
}
};
};
this.searchPlayer(this._parent.globalUserName);
this.avgBtn.enabled = false;
this.avgBtn.enabled = false;
this.searchPlayer2 = function (player) {
var t = this;
var s12s = new LoadVars();
var s22s = new LoadVars();
s12s.username = player;
s12s.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getrank.php?id=2", s22s, "POST");
s22s.onLoad = function (success) {
if (success) {
t.ara = s22s.rank;
} else {
t.ara = "Connection Error";
}
t.avgBtn.enabled = true;
t.hsBtn.enabled = true;
};
};
this.searchPlayer2(this._parent.globalUserName);
Instance of Symbol 633 MovieClip "backBtn" in Symbol 709 MovieClip Frame 5
on (release) {
this._parent.lineCont.clear();
this._parent.gotoAndStop("title");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 664 MovieClip "hsBtn" in Symbol 709 MovieClip Frame 5
on (release) {
this._parent.lineCont.clear();
this._parent.gotoAndStop("hs");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 666 MovieClip "avgBtn" in Symbol 709 MovieClip Frame 5
on (release) {
this._parent.lineCont.clear();
this._parent.gotoAndStop("hs2");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 633 MovieClip "backBtn" in Symbol 709 MovieClip Frame 6
on (release) {
this._parent.gotoAndStop("title");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 668 MovieClip in Symbol 709 MovieClip Frame 6
on (release) {
var p = this._parent;
var cont = p.pane.getScrollContent();
if (cont._currentframe < cont._totalframes) {
cont.nextFrame();
} else {
cont.gotoAndStop(1);
}
p.pane.refreshPane();
p.pane.setScrollPosition(0, 0);
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 670 MovieClip in Symbol 709 MovieClip Frame 6
on (release) {
var p = this._parent;
var cont = p.pane.getScrollContent();
if (cont._currentframe > 1) {
cont.prevFrame();
} else {
cont.gotoAndStop(cont._totalframes);
}
p.pane.refreshPane();
p.pane.setScrollPosition(0, 0);
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 263 MovieClip [FScrollPaneSymbol] "pane" in Symbol 709 MovieClip Frame 6
//component parameters
onClipEvent (initialize) {
scrollContent = "gallery";
hScroll = "auto";
vScroll = "auto";
dragContent = true;
}
Symbol 709 MovieClip Frame 7
stop();
this.onMouseDown = function () {
this.notify = "";
};
this.showScores = function (page, skip) {
var t = this;
t.pageNum = page;
t.skipNum = skip;
getsc_lv = new LoadVars();
getsc_lv.page = page;
getsc_lv.pex = skip;
rec_lv = new LoadVars();
getsc_lv.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getscore.php?id=1", rec_lv, "POST");
i = 1;
while (i < 11) {
t["e" + i].rank = "";
t["e" + i].name = "Loading...";
t["e" + i].score = "";
t["e" + i].highL.gotoAndStop("blank");
i++;
}
rec_lv.onLoad = function (success) {
if (success) {
t.pageNumDisp = (page + ".") + skip;
ths = ((t.pageNum - 1) * 10) + t.skipNum;
i = 1;
while (i < 11) {
t["e" + i].rank = (ths + i) + ".";
t["e" + i].name = rec_lv["sname" + i];
t["e" + i].score = rec_lv["sscore" + i];
i++;
}
} else {
t.pageNumDisp = "Error";
i = 1;
while (i < 11) {
t["e" + i].rank = "";
t["e" + i].name = "Connection Error...";
t["e" + i].score = "";
t["e" + i].highL.gotoAndStop("blank");
i++;
}
}
t.nextBtn._visible = true;
t.prevBtn._visible = true;
t.jumpBtn._visible = true;
};
};
this.searchRank = function (rank, typ, rank2) {
var t = this;
trace("Rank2 = " + rank2);
getnm_lv = new LoadVars();
getnm_lv.rank = rank;
trace("rank to be searched = " + rank);
recNm_lv = new LoadVars();
getnm_lv.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getname.php?id=1", recNm_lv, "POST");
recNm_lv.onLoad = function (success) {
if (success) {
if (typ == "better") {
if (recNm_lv.name != "") {
t.eBetter.rank = rank + ".";
t.eBetter.name = recNm_lv.name;
t.eBetter.score = recNm_lv.score;
t.eBetter._visible = true;
}
t.searchRank(Number(t.yourRank) + 1, "worse");
} else if (typ == "you") {
t.eYou.rank = rank + ".";
t.eYou.name = recNm_lv.name;
t.eYou.score = recNm_lv.score;
t.searchRank(t.yourRank - 1, "better");
} else if (typ == "worse") {
if (recNm_lv.name != "") {
t.eWorse.rank = rank + ".";
t.eWorse.name = recNm_lv.name;
t.eWorse.score = recNm_lv.score;
t.eWorse._visible = true;
}
t.hsBtn.enabled = true;
t.statsBtn.enabled = true;
} else if (typ == "showRank") {
trace("total scores = " + recNm_lv.score);
trace("display rank = " + rank2);
t.showRank(recNm_lv.score, rank2);
} else if (typ == "nextPage") {
t.nextPage(recNm_lv.score);
} else if (typ == "jumpPage") {
t.jumpPage(recNm_lv.score, rank2);
}
trace("retrieved name = " + recNm_lv.name);
trace("retrieved score = " + recNm_lv.score);
} else {
t.notify = "Connection Error";
t.goFindBtn._visible = true;
t.nextBtn._visible = true;
t.prevBtn._visible = true;
t.jumpBtn._visible = true;
t.hsBtn.enabled = true;
t.statsBtn.enabled = true;
}
t.goRankBtn._visible = true;
};
};
this.searchPlayer = function (player, typ) {
var t = this;
var s1 = new LoadVars();
var s2 = new LoadVars();
s1.username = player;
s1.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getrank.php?id=1", s2, "POST");
s2.onLoad = function (success) {
if (success) {
if (s2.rank != 0) {
if (typ == "small") {
t.yourRank = s2.rank;
t.searchRank(s2.rank, "you");
} else if (typ == "large") {
t.searchRank("last", "showRank", s2.rank);
}
trace("rank = " + s2.rank);
} else {
t.notify = "This player doesn't exist";
}
} else {
if (typ == "small") {
t.eYou.name = "Connection Error...";
} else if (typ == "large") {
t.notify = "Connection Error";
}
t.hsBtn.enabled = true;
t.statsBtn.enabled = true;
}
t.goFindBtn._visible = true;
};
};
this.showRank = function (total, rank) {
this["e" + this.eNum].highL.gotoAndStop("blank");
if (total > 10) {
if (rank < 6) {
var page = 1;
var skip = 0;
this.showScores(page, skip);
} else if ((total - rank) < 5) {
var page = Math.floor(total / 10);
var skip = (total - (Math.floor(total / 10) * 10));
this.showScores(page, skip);
} else {
var startR = (rank - 4);
var page = Math.ceil(startR / 10);
var skip = ((startR - 1) - ((page - 1) * 10));
trace("show rank page = " + page);
trace("show rank skip = " + skip);
this.showScores(page, skip);
}
this.eNum = rank - (((page - 1) * 10) + skip);
trace("highlight = " + this.eNum);
this["e" + this.eNum].highL.gotoAndStop("show");
} else {
this.showScores(1, 0);
this.eNum = rank;
trace("highlight = " + this.eNum);
this["e" + this.eNum].highL.gotoAndStop("show");
}
};
this.nextPage = function (total) {
var t = this;
var np = (t.pageNum + 1);
if (((np * 10) + t.skipNum) <= total) {
t.showScores(np, t.skipNum);
} else {
var page = Math.floor(total / 10);
var skip = (total - (Math.floor(total / 10) * 10));
t.showScores(page, skip);
trace("next page stop at total scores");
}
};
this.prevPage = function () {
var t = this;
if (t.pageNum > 1) {
t.showScores(t.pageNum - 1, t.skipNum);
} else {
t.showScores(1, 0);
}
};
this.jumpPage = function (total, page) {
var t = this;
if ((page * 10) < total) {
t.showScores(page, 0);
} else {
var page = Math.floor(total / 10);
var skip = (total - (Math.floor(total / 10) * 10));
t.showScores(page, skip);
}
};
this.prevBtn._visible = false;
this.nextBtn._visible = false;
this.jumpBtn._visible = false;
this.goRankBtn._visible = false;
this.goFindBtn._visible = false;
this.notify = "";
this.hsBtn.enabled = false;
this.statsBtn.enabled = false;
this.showScores(1, 0);
this.eBetter._visible = false;
this.eWorse._visible = false;
this.eYou.name = "Loading...";
this.searchPlayer(this._parent.globalUserName, "small");
this.jumpPageTextInst.onSetFocus = function () {
if (this.text == "Jump") {
this.text = "";
}
};
this.jumpPageTextInst.onKillFocus = function () {
if (this.text == "") {
this.text = "Jump";
}
};
this.dispRankInst.onSetFocus = function () {
if (this.text == "Input Here") {
this.text = "";
}
};
this.dispRankInst.onKillFocus = function () {
if (this.text == "") {
this.text = "Input Here";
}
};
this.findPlayerInst.onSetFocus = function () {
if (this.text == "Input Here") {
this.text = "";
}
};
this.findPlayerInst.onKillFocus = function () {
if (this.text == "") {
this.text = "Input Here";
}
};
Instance of Symbol 688 MovieClip "nextBtn" in Symbol 709 MovieClip Frame 7
on (release) {
var p = this._parent;
this._visible = false;
p.searchRank("last", "nextPage");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 690 MovieClip "prevBtn" in Symbol 709 MovieClip Frame 7
on (release) {
var p = this._parent;
this._visible = false;
p.prevPage();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 694 MovieClip "goRankBtn" in Symbol 709 MovieClip Frame 7
on (release) {
var p = this._parent;
if (p.dispRank > 0) {
this._visible = false;
p.searchRank("last", "showRank", p.dispRank);
} else {
p.notify = "Invalid Rank";
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 694 MovieClip "goFindBtn" in Symbol 709 MovieClip Frame 7
on (release) {
var p = this._parent;
this._visible = false;
p.searchPlayer(p.findPlayer, "large");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 694 MovieClip "jumpBtn" in Symbol 709 MovieClip Frame 7
on (release) {
var p = this._parent;
if (p.jumpPageText > 0) {
this._visible = false;
p.searchRank("last", "jumpPage", p.jumpPageText);
} else {
p.notify = "Invalid Page";
}
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 569 MovieClip "statsBtn" in Symbol 709 MovieClip Frame 7
on (release) {
this._parent.gotoAndStop("stats");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 666 MovieClip "hsBtn" in Symbol 709 MovieClip Frame 7
on (release) {
this._parent.lineCont.clear();
this._parent.gotoAndStop("hs2");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 709 MovieClip Frame 8
stop();
this.onMouseDown = function () {
this.notify = "";
};
this.showScores = function (page, skip) {
var t = this;
t.pageNum = page;
t.skipNum = skip;
getsc_lv2 = new LoadVars();
getsc_lv2.page = page;
getsc_lv2.pex = skip;
rec_lv2 = new LoadVars();
getsc_lv2.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getscore.php?id=2", rec_lv2, "POST");
i = 1;
while (i < 11) {
t["e" + i].rank = "";
t["e" + i].name = "Loading...";
t["e" + i].score = "";
t["e" + i].highL.gotoAndStop("blank");
i++;
}
rec_lv2.onLoad = function (success) {
if (success) {
t.pageNumDisp = (page + ".") + skip;
ths = ((t.pageNum - 1) * 10) + t.skipNum;
i = 1;
while (i < 11) {
t["e" + i].rank = (ths + i) + ".";
t["e" + i].name = rec_lv2["sname" + i];
t["e" + i].score = rec_lv2["sscore" + i];
i++;
}
} else {
t.pageNumDisp = "Error";
i = 1;
while (i < 11) {
t["e" + i].rank = "";
t["e" + i].name = "Connection Error...";
t["e" + i].score = "";
t["e" + i].highL.gotoAndStop("blank");
i++;
}
}
t.nextBtn._visible = true;
t.prevBtn._visible = true;
t.jumpBtn._visible = true;
};
};
this.searchRank = function (rank, typ, rank2) {
var t = this;
trace("Rank2 = " + rank2);
getnm_lv2 = new LoadVars();
getnm_lv2.rank = rank;
trace("rank to be searched = " + rank);
recNm_lv2 = new LoadVars();
getnm_lv2.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getname.php?id=2", recNm_lv2, "POST");
recNm_lv2.onLoad = function (success) {
if (success) {
if (typ == "better") {
if (recNm_lv2.name != "") {
t.eBetter.rank = rank + ".";
t.eBetter.name = recNm_lv2.name;
t.eBetter.score = recNm_lv2.score;
t.eBetter._visible = true;
}
t.searchRank(Number(t.yourRank) + 1, "worse");
} else if (typ == "you") {
t.eYou.rank = rank + ".";
t.eYou.name = recNm_lv2.name;
t.eYou.score = recNm_lv2.score;
t.searchRank(t.yourRank - 1, "better");
} else if (typ == "worse") {
if (recNm_lv2.name != "") {
t.eWorse.rank = rank + ".";
t.eWorse.name = recNm_lv2.name;
t.eWorse.score = recNm_lv2.score;
t.eWorse._visible = true;
}
t.hsBtn.enabled = true;
t.statsBtn.enabled = true;
} else if (typ == "showRank") {
trace("total scores = " + recNm_lv2.score);
trace("display rank = " + rank2);
t.showRank(recNm_lv2.score, rank2);
} else if (typ == "nextPage") {
t.nextPage(recNm_lv2.score);
} else if (typ == "jumpPage") {
t.jumpPage(recNm_lv2.score, rank2);
}
trace("retrieved name = " + recNm_lv2.name);
trace("retrieved score = " + recNm_lv2.score);
} else {
t.notify = "Connection Error";
t.goFindBtn._visible = true;
t.nextBtn._visible = true;
t.prevBtn._visible = true;
t.jumpBtn._visible = true;
t.hsBtn.enabled = true;
t.statsBtn.enabled = true;
}
t.goRankBtn._visible = true;
};
};
this.searchPlayer = function (player, typ) {
var t = this;
var s12 = new LoadVars();
var s22 = new LoadVars();
s12.username = player;
s12.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/getrank.php?id=2", s22, "POST");
s22.onLoad = function (success) {
if (success) {
if (s22.rank != 0) {
if (typ == "small") {
t.yourRank = s22.rank;
t.searchRank(s22.rank, "you");
} else if (typ == "large") {
t.searchRank("last", "showRank", s22.rank);
}
trace("rank = " + s22.rank);
} else {
t.notify = "This player doesn't exist";
}
} else {
if (typ == "small") {
t.eYou.name = "Connection Error...";
} else if (typ == "large") {
t.notify = "Connection Error";
}
t.hsBtn.enabled = true;
t.statsBtn.enabled = true;
}
t.goFindBtn._visible = true;
};
};
this.showRank = function (total, rank) {
this["e" + this.eNum].highL.gotoAndStop("blank");
if (total > 10) {
if (rank < 6) {
var page = 1;
var skip = 0;
this.showScores(page, skip);
} else if ((total - rank) < 5) {
var page = Math.floor(total / 10);
var skip = (total - (Math.floor(total / 10) * 10));
this.showScores(page, skip);
} else {
var startR = (rank - 4);
var page = Math.ceil(startR / 10);
var skip = ((startR - 1) - ((page - 1) * 10));
trace("show rank page = " + page);
trace("show rank skip = " + skip);
this.showScores(page, skip);
}
this.eNum = rank - (((page - 1) * 10) + skip);
trace("highlight = " + this.eNum);
this["e" + this.eNum].highL.gotoAndStop("show");
} else {
this.showScores(1, 0);
this.eNum = rank;
trace("highlight = " + this.eNum);
this["e" + this.eNum].highL.gotoAndStop("show");
}
};
this.nextPage = function (total) {
var t = this;
var np = (t.pageNum + 1);
if (((np * 10) + t.skipNum) <= total) {
t.showScores(np, t.skipNum);
} else {
var page = Math.floor(total / 10);
var skip = (total - (Math.floor(total / 10) * 10));
t.showScores(page, skip);
trace("next page stop at total scores");
}
};
this.prevPage = function () {
var t = this;
if (t.pageNum > 1) {
t.showScores(t.pageNum - 1, t.skipNum);
} else {
t.showScores(1, 0);
}
};
this.jumpPage = function (total, page) {
var t = this;
if ((page * 10) < total) {
t.showScores(page, 0);
} else {
var page = Math.floor(total / 10);
var skip = (total - (Math.floor(total / 10) * 10));
t.showScores(page, skip);
}
};
this.prevBtn._visible = false;
this.nextBtn._visible = false;
this.jumpBtn._visible = false;
this.goRankBtn._visible = false;
this.goFindBtn._visible = false;
this.notify = "";
this.hsBtn.enabled = false;
this.statsBtn.enabled = false;
this.showScores(1, 0);
this.eBetter._visible = false;
this.eWorse._visible = false;
this.eYou.name = "Loading...";
this.searchPlayer(this._parent.globalUserName, "small");
this.jumpPageTextInst.onSetFocus = function () {
this.text = "";
};
this.jumpPageTextInst.onKillFocus = function () {
if (this.text == "") {
this.text = "Jump";
}
};
this.dispRankInst.onSetFocus = function () {
this.text = "";
};
this.dispRankInst.onKillFocus = function () {
if (this.text == "") {
this.text = "Input Here";
}
};
this.findPlayerInst.onSetFocus = function () {
this.text = "";
};
this.findPlayerInst.onKillFocus = function () {
if (this.text == "") {
this.text = "Input Here";
}
};
Instance of Symbol 664 MovieClip "hsBtn" in Symbol 709 MovieClip Frame 8
on (release) {
this._parent.lineCont.clear();
this._parent.gotoAndStop("hs");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 709 MovieClip Frame 9
stop();
Symbol 714 MovieClip Frame 1
stop();
Symbol 717 MovieClip Frame 1
stop();
Symbol 750 MovieClip Frame 1
stop();
Symbol 750 MovieClip Frame 2
this.tut.mouth.gotoAndPlay(200);
this.tut.right.gotoAndStop("wave");
Instance of Symbol 714 MovieClip "nextBtn" in Symbol 750 MovieClip Frame 2
on (release) {
this._parent.nextFrame();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 750 MovieClip Frame 3
this.tut.mouth.gotoAndPlay(150);
this.tut.right.gotoAndStop("down");
Instance of Symbol 494 MovieClip "gotoOptionsBtn" in Symbol 750 MovieClip Frame 3
on (release) {
var p = this._parent;
p.prevBtn.enabled = false;
p.nextBtn.enabled = false;
this.enabled = false;
p._parent.pause = true;
p._parent.gameDisplay.quitBtn.enabled = false;
p._parent.mainDisplay.gotoAndStop("options");
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Instance of Symbol 717 MovieClip "prevBtn" in Symbol 750 MovieClip Frame 3
on (release) {
this._parent.prevFrame();
}
on (rollOver) {
this.gotoAndStop(2);
if (this._parent._parent.soundPlay == "true") {
this._parent._parent.beep.start();
}
}
on (releaseOutside, rollOut) {
this.gotoAndStop(1);
}
Symbol 750 MovieClip Frame 4
this.tut.mouth.gotoAndPlay(50);
this.tut.right.gotoAndStop("index");
Symbol 750 MovieClip Frame 5
this.tut.mouth.gotoAndPlay(50);
this.tut.right.gotoAndStop("down");
Symbol 750 MovieClip Frame 6
this.tut.mouth.gotoAndPlay(150);
this.tut.right.gotoAndStop("index");
Symbol 750 MovieClip Frame 7
this._parent.clearArrays();
this._parent.createHeart();
this.tut.eyes.gotoAndPlay("smile");
this.tut.mouth.gotoAndPlay(300);
this.tut.right.gotoAndStop("down");
Symbol 750 MovieClip Frame 8
this._parent.clearArrays();
this._parent.createHeart();
this.tut.mouth.gotoAndPlay(120);
this.tut.right.gotoAndStop("index");
Symbol 750 MovieClip Frame 9
this.tut.mouth.gotoAndPlay(200);
this.tut.right.gotoAndStop("down");
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(2);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(3);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(4);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(5);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(6);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(7);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(8);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(9);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(10);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(11);
}
Instance of Symbol 309 MovieClip in Symbol 750 MovieClip Frame 9
onClipEvent (load) {
this.gotoAndStop(12);
}
Symbol 750 MovieClip Frame 10
this.tut.eyes.gotoAndPlay("wink");
this.tut.mouth.gotoAndPlay(180);
this.tut.right.gotoAndStop("index");
Symbol 750 MovieClip Frame 11
this._parent.clearArrays();
this._parent.createPU(0);
this.tut.mouth.gotoAndPlay(180);
this.tut.right.gotoAndStop("down");
Symbol 750 MovieClip Frame 12
this._parent.clearArrays();
this._parent.createFly();
this._parent.createFly();
this._parent.createFly();
this.tut.mouth.gotoAndPlay(50);
this.tut.right.gotoAndStop("down");
Symbol 750 MovieClip Frame 13
this._parent.clearArrays();
this._parent.createHeart();
this._parent.createHeart();
this._parent.createFly();
this._parent.createFly();
this._parent.createFly();
this.tut.eyes.gotoAndPlay("smile");
this.tut.mouth.gotoAndPlay(200);
this.tut.right.gotoAndStop("down");
Symbol 750 MovieClip Frame 14
this.tut.mouth.gotoAndPlay(60);
this.tut.right.gotoAndStop("index");
Symbol 750 MovieClip Frame 15
this.tut.mouth.gotoAndPlay(1);
this.tut.right.gotoAndStop("down");
Symbol 750 MovieClip Frame 16
this.tut.eyes.gotoAndPlay("wink");
this.tut.mouth.gotoAndPlay(280);
this.tut.right.gotoAndStop("wave");
Symbol 750 MovieClip Frame 17
this._parent.quitGame();
this.gotoAndStop("blank");
Symbol 751 MovieClip Frame 1
this.updateServer = function () {
var t = this;
upServ_lv = new LoadVars();
upServ_lv.username = t.globalUserName;
upServ_lv.cake = _global.pie;
var str = t.userSavedDataA.join("*");
trace("String to be saved: " + str);
trace("Name to save to: " + t.globalUserName);
upServ_lv.mydata = str;
recUpServ_lv = new LoadVars();
upServ_lv.sendAndLoad("http://bot.armorstudios.com/extremeusers/DBarbarian/savedata.php", recUpServ_lv, "POST");
recUpServ_lv.onLoad = function (success) {
if (success) {
if (recUpServ_lv.success == 1) {
var tempA = t.userSavedDataA.slice(0);
tempA.splice(0, 0, t.globalUserName);
trace("shared obj to be saved: " + tempA);
trace("original array: " + t.userSavedDataA);
_root.mySO.data.accounts.push(tempA);
_root.mySO.flush();
trace("update success");
}
} else {
trace("update failed");
}
};
};
this.updateQuality = function () {
this.userSavedDataA[19] = this.inGameQuality;
this.updateServer();
};
this.updateParticles = function () {
this.userSavedDataA[20] = this.particles;
this.updateServer();
};
this.updatePrompt = function () {
this.userSavedDataA[21] = this.promptHelp;
this.updateServer();
};
this.updateMusic = function () {
this.userSavedDataA[17] = this.globalsoundcontrol;
this.updateServer();
};
this.updateSound = function () {
this.userSavedDataA[18] = this.soundPlay;
this.updateServer();
};
this.updateKeys = function () {
var t = this;
t.userSavedDataA[11] = t.uKey;
t.userSavedDataA[12] = t.dKey;
t.userSavedDataA[13] = t.pKey;
t.userSavedDataA[14] = t.mKey;
t.userSavedDataA[15] = t.sKey;
t.updateServer();
};
this.updateGamesCompleted = function () {
var t = this;
var gc = (Number(t.userSavedDataA[16]) + 1);
t.userSavedDataA[16] = gc;
t.updateServer();
};
this.updateScores = function (typ, i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
var t = this;
if (typ == "better") {
t.userSavedDataA[1] = i1;
t.userSavedDataA[2] = i2;
t.userSavedDataA[3] = i3;
t.userSavedDataA[4] = i4;
t.userSavedDataA[5] = i5;
t.userSavedDataA[6] = i6;
t.userSavedDataA[7] = i7;
t.userSavedDataA[8] = i8;
t.userSavedDataA[9] = i9;
t.userSavedDataA[10] = i10;
} else if (typ == "worse") {
t.userSavedDataA[1] = i1;
t.userSavedDataA[3] = i2;
t.userSavedDataA[5] = i3;
t.userSavedDataA[7] = i4;
t.userSavedDataA[9] = i5;
}
t.updateServer();
};
this.newName = function (pass) {
this.userSavedDataA = new Array(pass, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 38, 40, 32, 77, 78, 0, "play", "true", "High", "On", "true");
this.updateServer();
};
_root.mySO = sharedobject.getLocal("heartsCookie");
if (_root.mySO.data.accounts == undefined) {
_root.mySO.data.accounts = new Array();
_root.mySO.flush();
}
this.backUpAccountsA = _root.mySO.data.accounts;
this.backUpAccountsA.sort();
this.updateBeginMusic = function () {
_root.mySO.data.music = this.globalsoundcontrol;
_root.mySO.flush();
};
this.updateBeginSounds = function () {
_root.mySO.data.sounds = this.soundPlay;
_root.mySO.flush();
};
this.checkRemName = function () {
trace("check rem name");
var md = this.mainDisplay;
if (_root.mySO.data.remName == undefined) {
md.remNameBtn.ch.gotoAndStop("blank");
md.remNameBtn.stat = "no";
} else {
md.remNameBtn.ch.gotoAndStop("show");
md.remNameBtn.stat = "yes";
md.userNameInst.text = _root.mySO.data.remName;
}
};
this.checkRemPass = function () {
trace("check rem pass");
var md = this.mainDisplay;
if (_root.mySO.data.remPass == undefined) {
md.remPassBtn.ch.gotoAndStop("blank");
md.remPassBtn.stat = "no";
trace("no pass");
} else {
md.remPassBtn.ch.gotoAndStop("show");
md.remPassBtn.stat = "yes";
md.passInst.text = _root.mySO.data.remPass;
trace("pass = " + _root.mySO.data.remPass);
}
};
this.updateRemName = function (name) {
trace("update rem name");
if (name == "none") {
_root.mySO.data.remName = undefined;
} else {
_root.mySO.data.remName = name;
}
_root.mySO.flush();
trace("updated rem name = " + _root.mySO.data.remName);
};
this.updateRemPass = function (pass) {
trace("update rem pass");
if (pass == "none") {
_root.mySO.data.remPass = undefined;
} else {
_root.mySO.data.remPass = pass;
}
_root.mySO.flush();
};
this.clearSO = function () {
_root.mySO.data.music = undefined;
_root.mySO.data.sounds = undefined;
_root.mySO.data.remName = undefined;
_root.mySO.data.remPass = undefined;
_root.mySO.data.accounts = undefined;
this.quitGame();
_root.mySO.flush();
};
this.stageW = 585;
this.stageH = 385;
this.startX = this.launcher._width + 50;
this.heartStageW = this.stageW - this.startX;
this.rc = (Math.PI/180);
this.typing = false;
this.gamePlay = false;
this.pause = false;
this.gameDisplay.quitBtn.enabled = false;
this.checkInGameSettings = function () {
if (this.userSavedDataA[19] == undefined) {
this.inGameQuality = "High";
this.updateQuality();
} else {
this.inGameQuality = this.userSavedDataA[19];
}
if (this.userSavedDataA[20] == undefined) {
this.particles = "On";
this.updateParticles();
} else {
this.particles = this.userSavedDataA[20];
}
if (this.userSavedDataA[21] == undefined) {
this.promptHelp = "true";
this.updatePrompt();
} else {
this.promptHelp = this.userSavedDataA[21];
}
};
this.resetVars = function () {
var t = this;
t.clearArrays();
t.ad = t.ads;
t.hd = t.hds;
t.grav = (t.initGrav = 0.2);
t.f = 0.95;
t.score = 0;
t.gameDisplay.scoreTxt = "Score: 0";
t.gameDisplay.countDown.gotoAndStop("blank");
t.numLives = 10;
t.launcher.my = 0;
t.launcer.hoverAng = 0;
t.launcher.maxS = (t.launcher.initMaxS = 3);
t.power = 0;
t.charge = false;
t.beginCharge = false;
t.chargeS = (t.initChargeS = 0.7);
t.curArrow = new Array();
t.numShots = 1;
t.launcher.powerBar.gotoAndStop("blank");
t.reloading = false;
t.launcher.cupid.body.arms.anim.gotoAndPlay("reload");
t.curAng = 0;
t.hdel = 10;
t.htim = 0;
t.hmyc = (t.inithmyc = 1);
t.heartSize = (t.initHeartSize = 100);
t.comboCount = 0;
t.puTim = 0;
t.puDel = 200;
t.launcher.hSpuTim = 0;
t.launcher.gpuTim = 0;
t.launcher.cpuTim = 0;
t.launcher.mSpuTim = 0;
t.launcher.hSIpuTim = 0;
t.launcher.tSpuTim = 0;
t.arrowsFired = 0;
t.misses = 0;
t.heartsHit = 0;
t.fliesHit = 0;
t.accuracy = 0;
t.maxHits = 0;
t.maxPts = 0;
t.timer = 0;
};
this.resetVars();
this.clearArrays = function () {
var t = this;
var i = (t.curArrow.length - 1);
while (i >= 0) {
t.curArrow[i].removeMovieClip();
t.curArrow.splice(i, 1);
i--;
}
var i = (t.arrowA.length - 1);
while (i >= 0) {
t.arrowA[i].removeMovieClip();
t.arrowA.splice(i, 1);
i--;
}
var i = (t.heartA.length - 1);
while (i >= 0) {
t.heartA[i].removeMovieClip();
t.heartA.splice(i, 1);
i--;
}
var i = (t.flyA.length - 1);
while (i >= 0) {
t.flyA[i].removeMovieClip();
t.flyA.splice(i, 1);
i--;
}
};
this.oads = (this.oad = 400);
this.oadm = 700;
this.ads = (this.ad = 800);
this.adm = 1000;
this.hds = (this.hd = 1100);
this.hdm = 3100;
this.fds = (this.fd = 3150);
this.fdm = 3250;
this.puds = (this.pud = 3300);
this.pudm = 3800;
this.tds = (this.td = 4000);
this.tdm = 5000;
this.trds = (this.trd = 6010);
this.trdm = 6050;
this.wall.swapDepths(6100);
this.gameDisplay.swapDepths(7000);
this.helpMC.swapDepths(7003);
this.pauseDisplay.swapDepths(7005);
this.gameOver.swapDepths(7010);
this.mainDisplay.swapDepths(7100);
this.addD = function (what) {
var t = this;
t[what + "d"]++;
if (t[what + "d"] > t[what + "dm"]) {
t[what + "d"] = t[what + "ds"];
}
};
this.setNewKeys = function () {
if (this.mainDisplay.mode == "login") {
this.uKey = Number(this.userSavedDataA[11]);
this.dKey = Number(this.userSavedDataA[12]);
this.pKey = Number(this.userSavedDataA[13]);
this.mKey = Number(this.userSavedDataA[14]);
this.sKey = Number(this.userSavedDataA[15]);
} else {
this.uKey = 38;
this.dKey = 40;
this.pKey = 32;
this.mKey = 77;
this.sKey = 78;
}
};
if (this.uKey == undefined) {
this.uKey = 38;
this.dKey = 40;
this.pKey = 32;
this.mKey = 77;
this.sKey = 78;
}
this.cHeartPar = function (x, y, s) {
var t = this;
var i = 0;
while (i < 20) {
t.attachMovie("hPar", "hp" + t.hd, t.hd);
var n = t["hp" + t.hd];
n._x = x;
n._y = y;
n._rotation = random(360);
n._xscale = (n._yscale = ((random(80) + 10) * s) / 100);
n.gotoAndPlay(random(10) + 1);
n.graphic.graphic._xscale = (n.graphic.graphic._yscale = random(100) + 100);
n.graphic.graphic._rotation = random(360);
t.addD("h");
i++;
}
};
this.cTremor = function (x, y) {
var t = this;
t.attachMovie("tremor", "t" + t.trd, t.trd);
var n = t["t" + t.trd];
n._x = x;
n._y = y;
t.addD("tr");
};
this.launcher.acc = 0.2;
this.launcher.hitDy = this.launcher.hit._y;
this.maxPower = 17;
this.arrowA = new Array();
this.loadArrow = function () {
var t = this;
var diffAng = 10;
var totAng = (diffAng * (t.numShots - 1));
var sAng = ((-totAng) / 2);
var point = new Object();
point.x = t.launcher.cupid.body.arms.tPoint._x;
point.y = t.launcher.cupid.body.arms.tPoint._y;
t.launcher.cupid.body.arms.localToGlobal(point);
var i = 0;
while (i < t.numShots) {
t.attachMovie("arrow", "a" + t.ad, t.ad);
var n = t["a" + t.ad];
n._x = point.x;
n._y = point.y;
n.ang = sAng + (diffAng * i);
if (n.ang == 0) {
n.t = "primary";
}
n.hits = 0;
n.score = 0;
t.curArrow.push(n);
t.addD("a");
i++;
}
};
this.launchArrow = function (power) {
var t = this;
var i = (t.curArrow.length - 1);
while (i >= 0) {
var n = t.curArrow[i];
var rot = (n._rotation * t.rc);
n.mx = power * Math.cos(rot);
n.my = power * Math.sin(rot);
var dx = n.graphic._x;
n.graphic._x = 0;
n._x = n._x + (dx * Math.cos(rot));
n._y = n._y + (dx * Math.sin(rot));
n.tip._x = n.graphic._width / 2;
t.arrowsFired++;
t.arrowA.push(n);
i--;
}
if (t.soundPlay == "true") {
var which = (random(1) + 1);
t["shoot" + which].start();
}
};
this.moveA = function () {
var t = this;
var i = (t.arrowA.length - 1);
while (i >= 0) {
var n = t.arrowA[i];
n.my = n.my + t.grav;
n._x = n._x + n.mx;
n._y = n._y + n.my;
var ang = Math.atan2(n.my, n.mx);
n._rotation = ang / t.rc;
var point = {x:n.tip._x, y:n.tip._y};
n.localToGlobal(point);
var j = (t.heartA.length - 1);
while (j >= 0) {
var h = t.heartA[j];
if (h.typ != "hf") {
if (h.hitTest(point.x, point.y)) {
if (h.typ == "heart") {
n.hits++;
t.heartsHit++;
var distB = Math.round(((point.x - t.startX) * 10) / t.heartStageW);
if (h._xscale > 99) {
var sizeB = 0;
} else {
var sizeB = 10;
}
n.score = n.score + (n.hits * ((10 + distB) + sizeB));
t.score = t.score + (n.hits * ((10 + distB) + sizeB));
t.gameDisplay.scoreTxt = "Score: " + t.score;
if (n.hits > 1) {
t.chainBonus(h._x, h._y, (n.hits - 1) * ((10 + distB) + sizeB), "add");
}
if (t.particles == "On") {
t.cHeartPar(h._x, h._y, h._xscale);
}
if (t.soundPlay == "true") {
var which = (random(2) + 1);
t["hHit" + which].start();
}
} else if (h.typ == "pu") {
n.hits++;
t["puFunc" + h.val](true);
t.gameDisplay["p" + h.val]._alpha = 100;
t.cPuText(h._x, h._y, h.val);
t.attachMovie("puGet", "pug" + t.oad, t.oad);
var m = t["pug" + t.oad];
m._x = h._x;
m._y = h._y;
t.addD("oa");
}
h.removeMovieClip();
t.heartA.splice(j, 1);
}
}
j--;
}
var j = (t.flyA.length - 1);
while (j >= 0) {
var f = t.flyA[j];
if (f.hitTest(point.x, point.y)) {
n.hits = n.hits + 3;
t.fliesHit++;
var diffScore = ((n.hits * (20 + n.score)) - n.score);
n.score = n.score + diffScore;
t.score = t.score + diffScore;
t.gameDisplay.scoreTxt = "Score: " + t.score;
t.chainBonus(f._x, f._y, diffScore, "add");
if (t.soundPlay == "true") {
t.flyHitSound.start();
}
t.attachMovie("flyD", "fd" + t.oad, t.oad);
var m = t["fd" + t.oad];
m._x = f._x;
m._y = f._y;
t.addD("oa");
t.createFly();
f.removeMovieClip();
t.flyA.splice(j, 1);
}
j--;
}
if (n._x > ((t.stageW - (n._width / 2)) + 5)) {
n.remove = true;
if ((n.hits > 0) and (point.y > 0)) {
var dy = ((point.y - (Math.floor(point.y / 100) * 100)) - 50);
if (Math.abs(dy) <= 12) {
t.score = t.score + n.score;
n.score = n.score + n.score;
t.gameDisplay.scoreTxt = "Score: " + t.score;
if (n._rotation < 0) {
var dir = -1;
} else {
var dir = 1;
}
t.chainBonus(t.stageW - 25, point.y, "2", "mul");
var cry = (point.y - dy);
t.cTremor(t.stageW + 7, cry);
}
}
} else if (n._y > ((t.stageH - (n._height / 2)) + 5)) {
n.remove = true;
if (n.hits > 0) {
var dx = (((t.stageW - point.x) - (Math.floor((t.stageW - point.x) / 100) * 100)) - 50);
if (Math.abs(dx) <= 12) {
t.score = t.score + n.score;
n.score = n.score + n.score;
t.gameDisplay.scoreTxt = "Score: " + t.score;
t.chainBonus(point.x, n._y, "2", "mul");
var crx = (point.x + dx);
t.cTremor(crx, t.stageH + 7);
}
}
}
if (n.remove == true) {
n._x = n._x + (10 * Math.cos(n._rotation * t.rc));
n._y = n._y + (10 * Math.sin(n._rotation * t.rc));
if (t.soundPlay == "true") {
var which = (random(2) + 1);
t["hit" + which].start();
}
t.attachMovie("fadeA", "f" + t.oad, t.oad);
var m = t["f" + t.oad];
m._x = n._x;
m._y = n._y;
m._rotation = n._rotation;
t.addD("oa");
if (n.hits == 0) {
t.misses++;
} else if (n.hits > t.maxHits) {
t.maxHits = n.hits;
}
if (n.score > t.maxPts) {
t.maxPts = n.score;
}
n.removeMovieClip();
t.arrowA.splice(i, 1);
}
i--;
}
};
this.heartA = new Array();
this.createHeartFlakes = function () {
var t = this;
var i = 1;
while (i < 10) {
t.bg.attachMovie("heart", "h" + i, i);
var n = t.bg["h" + i];
n._x = random(t.stageW);
n._y = random(t.stageH);
n._xscale = (n._yscale = random(200) + 400);
n._alpha = 15;
n._rotation = random(60) - 30;
n.w2 = n._width / 2;
n.h2 = n._height / 2;
n.mx = (Math.random() * 2) - 1;
n.typ = "hf";
t.heartA.push(n);
i++;
}
};
this.createHeart = function () {
var t = this;
t.attachMovie("heart", "h" + t.hd, t.hd);
var n = t["h" + t.hd];
n._y = (-n._height) / 2;
n._xscale = (n._yscale = t.heartSize);
n.typ = "heart";
t.htim = 0;
if (t.comboCount == 0) {
if (t.gameType == "real") {
n._x = (random(t.stageW - t.startX) + t.startX) - (n._width / 2);
} else {
n._x = (t.startX + random(80)) + 30;
}
var distB = (0.15 * Math.round((point.x - t.startX) / t.heartStageW));
n.my = (((Math.random() * 0.6) + 0.25) + (t.timer / 20000)) - distB;
var c = (t.timer / 300);
t.hdel = (150 - c) - random(30);
if (t.hdel < 0) {
t.hdel = 20;
}
} else {
t.hdel = (35 - (2 * t.comboCount)) - (t.timer / 300);
n._x = ((t.comboCount * 50) + t.startX) - 90;
n._xscale = (n._yscale = 130);
n.my = 0.4 + (t.timer / 20000);
t.comboCount++;
if (t.comboCount > 10) {
t.comboCount = 0;
t.gameDisplay.p6._alpha = t.initPUAlpha;
}
}
t.addD("h");
t.heartA.push(n);
};
this.moveH = function () {
var t = this;
var i = (t.heartA.length - 1);
while (i >= 0) {
var n = t.heartA[i];
n._y = n._y + (t.hmyc * n.my);
if (n.typ == "hf") {
n._x = n._x + n.mx;
if (t.grav != 0) {
n.my = (Math.random() * 2) + t.grav;
} else {
n.my = 0;
}
if (n._y > (t.stageH + n.h2)) {
n._x = random(t.stageW);
n._y = -n.h2;
n._xscale = (n._yscale = random(200) + 400);
n._alpha = 20;
n._rotation = random(60) - 30;
n.w2 = n._width / 2;
n.h2 = n._height / 2;
n.mx = (Math.random() * 2) - 1;
}
if (n._x < (-n.w2)) {
n._x = t.stageW + n.w2;
} else if (n._x > (t.stageW + n.w2)) {
n._x = -n.w2;
}
} else if (n.typ == "heart") {
if (n._y > (t.stageH - (n._height / 2))) {
n._y = t.stageH - (n._height / 2);
t.numLives--;
t.gameDisplay["h" + t.numLives]._visible = false;
if (t.soundPlay == "true") {
t.breakSound.start();
}
t.attachMovie("shatter", "s" + t.hd, t.hd);
var m = t["s" + t.hd];
m._xscale = (m._yscale = n._xscale);
m._x = n._x;
m._y = n._y;
t.addD("h");
n.removeMovieClip();
t.heartA.splice(i, 1);
if (t.numLives == 0) {
t.gameOverFunc();
}
}
} else if (n.typ == "pu") {
if (n._y > (t.stageH + (n._height / 2))) {
n.removeMovieClip();
t.heartA.splice(i, 1);
}
} else if (n.typ == "fly") {
n._x = n._x + (t.hmyc * n.my);
}
i--;
}
};
this.maxFlyS = 1.5;
this.maxFlyR = 100;
this.flyA = new Array();
this.createFly = function () {
var t = this;
t.attachMovie("fly", "f" + t.fd, t.fd);
var n = t["f" + t.fd];
n.rad = 30;
n.ang = random(360);
n.arriveAng = false;
n.angDS = 0;
n.angS = 0;
var side = random(4);
if (side == 0) {
n.cx = random(t.stageW);
n.cy = ((-n._height) / 2) - 30;
} else if (side == 1) {
n.cx = (600 + (n._width / 2)) + 30;
n.cy = random(t.stageH);
} else if (side == 2) {
n.cx = random(t.stageW);
n.cy = ((t.stageH + 15) + (n._height / 2)) + 30;
} else if (side == 3) {
n.cx = ((-n._width) / 2) - 30;
n.cy = random(t.stageH);
}
n._x = n.cx + (n.rad * Math.cos(n.ang * t.rc));
n._y = n.cy + (n.rad * Math.sin(n.ang * t.rc));
n.mx = (Math.random() * 1) + 0.1;
n.my = (Math.random() * 1) + 0.1;
t.flyA.push(n);
t.addD("f");
};
this.moveFly = function () {
var t = this;
var i = (t.flyA.length - 1);
while (i >= 0) {
var n = t.flyA[i];
n.cx = n.cx + n.mx;
n.cy = n.cy + n.my;
n.mx = n.mx + ((Math.random() * 0.3) - 0.15);
n.my = n.my + ((Math.random() * 0.3) - 0.15);
if (n.mx > t.maxFlyS) {
n.mx = t.maxFlyS;
} else if (n.mx < (-t.maxFlyS)) {
n.mx = -t.maxFlyS;
}
if (n.my > t.maxFlyS) {
n.my = t.maxFlyS;
} else if (n.my < (-t.maxFlyS)) {
n.my = -t.maxFlyS;
}
if (n._x < t.startX) {
n.mx = n.mx + 0.05;
} else if (n._x > t.stageW) {
n.mx = n.mx - 0.05;
}
if (n._y < 0) {
n.my = n.my + 0.05;
} else if (n._y > t.stageH) {
n.my = n.my - 0.05;
}
n.rad = n.rad + ((Math.random() * 2) - 1);
if (n.rad > t.maxFlyR) {
n.rad = t.maxFlyR;
} else if (n.rad < 0) {
n.rad = 0;
}
if (Math.abs(n.angS) < 1) {
var dir = random(2);
if (dir == 0) {
dir = -1;
}
n.angDS = (random(10) + 3) * dir;
n.arriveAng = false;
}
if ((n.arriveAng == false) and (Math.abs(n.angDS - n.angS) > 1)) {
n.angS = n.angS + ((n.angDS - n.angS) / 10);
if (Math.abs(n.angDS - n.angS) <= 1) {
n.arriveAng = true;
}
} else {
n.angS = n.angS * 0.9;
}
n.ang = n.ang + n.angS;
n._x = n.cx + (n.rad * Math.cos(n.ang * t.rc));
n._y = n.cy + (n.rad * Math.sin(n.ang * t.rc));
i--;
}
};
this.chainBonus = function (x, y, val, typ) {
var t = this;
t.attachMovie("chain", "c" + t.td, t.td);
var n = t["c" + t.td];
n._x = x;
n._y = y;
n.txtMC.gotoAndStop(typ);
if (n._x > (t.stageW - (n._width / 2))) {
n._x = t.stageW - (n._width / 2);
}
if (typ == "mul") {
n.txtMC.txt = val;
if (t.soundPlay == "true") {
t.orb.start();
}
} else if (typ == "add") {
n.txtMC.txt = val;
}
t.addD("t");
};
this.initPUAlpha = 12;
this.puHaveMax = 600;
this.createPU = function (val) {
var t = this;
t.attachMovie("pu", "pu" + t.pud, t.pud);
var n = t["pu" + t.pud];
if (t.gameType == "real") {
n._x = random((t.stageW - t.startX) - (n._width / 2)) + t.startX;
} else {
n._x = (t.startX + random(80)) + 30;
}
n._y = (-n._height) / 2;
n._xscale = (n._yscale = 120);
n.my = (Math.random() * 1) + 0.2;
n.typ = "pu";
if (val == 0) {
val = random(n.graphic._totalframes) + 1;
}
n.graphic.gotoAndStop(val);
n.val = val;
t.heartA.push(n);
t.addD("pu");
t.puDel = random(300) + 250;
};
this.cPuText = function (x, y, typ) {
var t = this;
t.attachMovie("puText", "pt" + t.td, t.td);
var n = t["pt" + t.td];
n.txtMC.gotoAndStop("pu" + typ);
n.txtMC2.gotoAndStop("pu" + typ);
n._x = x;
n._y = y;
if (n._x > (t.stageW - (n._width / 2))) {
n._x = t.stageW - (n._width / 2);
}
if (t.soundPlay == "true") {
t.puSound.start();
}
t.addD("t");
};
this.puFunc1 = function (which) {
var t = this;
if (which == true) {
t.launcher.hSpuTim = 0;
t.hmyc = 0.6;
t.gameDisplay.p1._alpha = 100;
t.gameDisplay.p10._alpha = t.initPUAlpha;
} else {
t.launcher.hSpuTim = 0;
t.hmyc = t.inithmyc;
t.gameDisplay.p1._alpha = t.initPUAlpha;
t.gameDisplay.p10._alpha = t.initPUAlpha;
}
};
this.puFunc2 = function (which) {
var t = this;
if (which == true) {
t.launcher.gpuTim = 0;
t.grav = 0;
t.gameDisplay.p2._alpha = 100;
t.gameDisplay.p9._alpha = t.initPUAlpha;
} else {
t.launcher.gpuTim = 0;
t.grav = t.initGrav;
t.gameDisplay.p2._alpha = t.initPUAlpha;
t.gameDisplay.p9._alpha = t.initPUAlpha;
}
};
this.puFunc3 = function (which) {
var t = this;
if (which == true) {
t.launcher.cpuTim = 0;
t.chargeS = t.maxPower;
t.gameDisplay.p3._alpha = 100;
t.gameDisplay.p8._alpha = t.initPUAlpha;
} else {
t.launcher.cpuTim = 0;
t.chargeS = t.initChargeS;
t.gameDisplay.p3._alpha = t.initPUAlpha;
t.gameDisplay.p8._alpha = t.initPUAlpha;
}
};
this.puFunc4 = function (which) {
var t = this;
if (which == true) {
t.launcher.mSpuTim = 0;
t.launcher.maxS = 5;
t.gameDisplay.p4._alpha = 100;
t.gameDisplay.p12._alpha = t.initPUAlpha;
} else {
t.launcher.mSpuTim = 0;
t.launcher.maxS = t.launcher.initMaxS;
t.gameDisplay.p4._alpha = t.initPUAlpha;
t.gameDisplay.p12._alpha = t.initPUAlpha;
}
};
this.puFunc5 = function (which) {
var t = this;
if (which == true) {
t.launcher.hSIpuTim = 0;
t.heartSize = 150;
t.gameDisplay.p5._alpha = 100;
t.gameDisplay.p11._alpha = t.initPUAlpha;
} else {
t.launcher.hSIpuTim = 0;
t.heartSize = t.initHeartSize;
t.gameDisplay.p5._alpha = t.initPUAlpha;
t.gameDisplay.p11._alpha = t.initPUAlpha;
}
};
this.puFunc6 = function (which) {
var t = this;
if (which == true) {
t.comboCount = 1;
t.gameDisplay.p6._alpha = 100;
}
};
this.puFunc7 = function (which) {
var t = this;
if (which == true) {
t.launcher.tSpuTim = 0;
t.numShots = 3;
t.gameDisplay.p7._alpha = 100;
} else {
t.launcher.tSpuTim = 0;
t.numShots = 1;
t.gameDisplay.p7._alpha = t.initPUAlpha;
}
};
this.puFunc8 = function (which) {
var t = this;
if (which == true) {
t.launcher.cpuTim = 0;
t.chargeS = t.initChargeS * 0.7;
t.gameDisplay.p8._alpha = 100;
t.gameDisplay.p3._alpha = t.initPUAlpha;
}
};
this.puFunc9 = function (which) {
var t = this;
if (which == true) {
t.launcher.gpuTim = 0;
t.grav = t.initGrav * 1.5;
t.gameDisplay.p9._alpha = 100;
t.gameDisplay.p2._alpha = t.initPUAlpha;
}
};
this.puFunc10 = function (which) {
var t = this;
if (which == true) {
t.launcher.hSpuTim = 0;
t.hmyc = 1.3;
t.gameDisplay.p10._alpha = 100;
t.gameDisplay.p1._alpha = t.initPUAlpha;
}
};
this.puFunc11 = function (which) {
var t = this;
if (which == true) {
t.launcher.hSIpuTim = 0;
t.heartSize = 70;
t.gameDisplay.p11._alpha = 100;
t.gameDisplay.p5._alpha = t.initPUAlpha;
}
};
this.puFunc12 = function (which) {
var t = this;
if (which == true) {
t.launcher.mSpuTim = 0;
t.launcher.maxS = 1;
t.gameDisplay.p12._alpha = 100;
t.gameDisplay.p4._alpha = t.initPUAlpha;
}
};
this.onEnterFrame = function () {
var t = this;
if (t.mainDisplay.genListBox == true) {
t.mainDisplay.updateListBox();
}
if (t.fade == "in") {
if (t.loopvolume < t.initLoopVolume) {
t.loopvolume = t.loopvolume + 5;
t.loop.setVolume(t.loopvolume);
} else if (t.loopvolume > t.initLoopVolume) {
t.loopvolume = t.initLoopVolume;
t.loop.setVolume(t.loopvolume);
}
} else if (t.fade == "out") {
if (t.loopvolume > 0) {
t.loopvolume = t.loopvolume - 5;
t.loop.setVolume(t.loopvolume);
} else if (t.loopvolume < 0) {
t.loopvolume = 0;
t.loop.setVolume(t.loopvolume);
}
}
if (t.gamePlay == true) {
if (t.pause == false) {
t.timer++;
if (Key.isDown(t.dKey)) {
if (t.launcher.my < t.launcher.maxS) {
t.launcher.my = t.launcher.my + t.launcher.acc;
if (t.launcher.my > t.launcher.maxS) {
t.launcher.my = t.launcher.maxS;
}
}
} else if (Key.isDown(t.uKey)) {
if (t.launcher.my > (-t.launcher.maxS)) {
t.launcher.my = t.launcher.my - t.launcher.acc;
if (t.launcher.my < (-t.launcher.maxS)) {
t.launcher.my = -t.launcher.maxS;
}
}
} else {
t.launcher.my = t.launcher.my * t.f;
t.launcher.hoverAng = t.launcher.hoverAng + 5;
t.launcher.my = t.launcher.my + (Math.sin(t.launcher.hoverAng * t.rc) / 17);
}
t.launcher._y = t.launcher._y + t.launcher.my;
if (t.launcher._y < ((t.launcher.hit._height / 2) - t.launcher.hitDy)) {
t.launcher._y = (t.launcher.hit._height / 2) - t.launcher.hitDy;
t.launcher.my = t.launcher.my * -0.5;
} else if (t.launcher._y > ((t.stageH - (t.launcher.hit._height / 2)) - t.launcher.hitDy)) {
t.launcher._y = (t.stageH - (t.launcher.hit._height / 2)) - t.launcher.hitDy;
t.launcher.my = t.launcher.my * -0.5;
}
if (t.reloading == true) {
ang = 0;
} else {
var dx = (t._xmouse - t.launcher._x);
var dy = (t._ymouse - t.launcher._y);
var ang = (Math.atan2(dy, dx) / t.rc);
if (ang < -70) {
ang = -70;
} else if (ang > 50) {
ang = 50;
}
}
t.curAng = t.curAng + ((ang - t.curAng) / 8);
t.launcher.cupid.body._rotation = t.curAng * 0.3;
t.launcher.cupid.body.belt._rotation = (-t.curAng) * 0.3;
if (t.curAng > 40) {
var headAng = 40;
} else {
var headAng = t.curAng;
}
t.launcher.cupid.head._rotation = headAng;
t.launcher.cupid.body.arms._rotation = t.curAng * 0.7;
t.launcher.cupid.body.arms2._rotation = t.launcher.cupid.body.arms._rotation;
if (t.curAng < 0) {
var legAng = ((-t.curAng) * 0.1);
} else {
var legAng = ((-t.curAng) * 0.5);
}
t.launcher.cupid.legs._rotation = legAng;
var i = (t.curArrow.length - 1);
while (i >= 0) {
var n = t.curArrow[i];
n._rotation = t.curAng + n.ang;
var point = new Object();
point.x = t.launcher.cupid.body.arms.tPoint._x;
point.y = t.launcher.cupid.body.arms.tPoint._y;
t.launcher.cupid.body.arms.localToGlobal(point);
n._x = point.x;
n._y = point.y;
i--;
}
if (t.charge == true) {
if (t.power < t.maxPower) {
t.power = t.power + t.chargeS;
if (t.power > t.maxPower) {
t.power = t.maxPower;
}
}
t.launcher.powerBar._rotation = t.curAng;
t.launcher.powerBar.bar._xscale = (100 * t.power) / t.maxPower;
}
if (t.gameType == "real") {
if (t.htim > (t.hdel / t.hmyc)) {
t.createHeart();
} else {
t.htim++;
}
if (t.puTim > (t.puDel / t.hmyc)) {
t.createPU(0);
t.puTim = 0;
} else {
t.puTim++;
}
}
if (t.hmyc != t.inithmyc) {
t.launcher.hSpuTim++;
if (t.launcher.hSpuTim == t.puHaveMax) {
t.puFunc1(false);
}
}
if (t.grav != t.initGrav) {
t.launcher.gpuTim++;
if (t.launcher.gpuTim == t.puHaveMax) {
t.puFunc2(false);
}
}
if (t.chargeS != t.initChargeS) {
t.launcher.cpuTim++;
if (t.launcher.cpuTim == t.puHaveMax) {
t.puFunc3(false);
}
}
if (t.launcher.maxS != t.launcher.initMaxS) {
t.launcher.mSpuTim++;
if (t.launcher.mSpuTim == t.puHaveMax) {
t.puFunc4(false);
}
}
if (t.heartSize != t.initHeartSize) {
t.launcher.hSIpuTim++;
if (t.launcher.hSIpuTim == t.puHaveMax) {
t.puFunc5(false);
}
}
if (t.numShots != 1) {
t.launcher.tSpuTim++;
if (t.launcher.tSpuTim == t.puHaveMax) {
t.puFunc7(false);
}
}
t.moveA();
t.moveH();
t.moveFly();
}
} else if (t.gameOver._alpha < 100) {
t.gameOver._alpha = t.gameOver._alpha + 3;
if (t.gameOver._alpha > 100) {
t.gameOver._alpha = 100;
}
}
};
this.onMouseDown = function () {
var t = this;
if (t.gamePlay == true) {
if (t.pause == false) {
if (t.reloading == false) {
t.charge = true;
t.beginCharge = false;
t.launcher.powerBar.gotoAndStop("show");
} else {
t.beginCharge = true;
}
}
}
};
this.onMouseUp = function () {
var t = this;
if (t.gamePlay == true) {
if (t.pause == false) {
if (t.charge == true) {
t.launchArrow(t.power);
t.power = 0;
t.charge = false;
t.curArrow = new Array();
t.launcher.powerBar.gotoAndStop("blank");
t.reloading = true;
t.launcher.cupid.body.arms.anim.gotoAndPlay("reload");
}
}
}
};
this.launcher.onKeyDown = function () {
var t = this;
var p = t._parent;
if (p.gamePlay == true) {
if (p.gameType == "real") {
if (Key.isDown(p.pKey)) {
if (p.pause == false) {
p.pauseFunc(true);
} else {
p.pauseFunc(false);
}
}
}
}
if (p.typing == false) {
if (Key.isDown(p.mKey)) {
if (p.globalsoundcontrol == "play") {
p.globalsoundcontrol = "stop";
p.fade = "out";
} else if (p.globalsoundcontrol == "stop") {
p.globalsoundcontrol = "play";
p.fade = "in";
}
if (p.selectPlayer == false) {
p.updateMusic();
} else {
p.updateBeginMusic();
}
p.mainDisplay.setSoundText();
}
}
if (p.typing == false) {
if (Key.isDown(p.sKey)) {
if (p.soundPlay == "true") {
p.soundPlay = "false";
} else {
p.soundPlay = "true";
}
if (p.selectPlayer == false) {
p.updateSound();
} else {
p.updateBeginSounds();
}
p.mainDisplay.setSoundText();
}
}
d = p.mainDisplay;
if (d.selectkey == true) {
d.selectkey = false;
pressed = Key.getCode();
p[d.whichkey] = pressed;
d.setValues(pressed, d.whichkey);
}
if (d.userNameGuide.text != "") {
if (Key.isDown(13)) {
d.userNameInst.text = d.userNameGuide.text;
d.userNameGuide.text = "";
d.accept = "";
}
}
};
this.launcher.onKeyUp = function () {
var t = this;
var p = t._parent;
if (p.logIn == true) {
if (p.typing == true) {
if (p.typeName == true) {
var len = d.userNameInst.text.length;
if (len > 0) {
var i = 0;
while (i < p.backUpAccountsA.length) {
var name = p.backUpAccountsA[i][0];
var parName = name.substring(0, len);
trace("length: " + len);
trace("text within textbox: " + d.userNameInst.text);
trace("partial name: " + parName);
if ((parName == d.userNameInst.text) and (len != name.length)) {
trace("Found Name: " + name);
d.userNameGuide.text = name;
d.accept = "Press ENTER to accept name";
break;
}
d.userNameGuide.text = "";
d.accept = "";
i++;
}
} else {
d.userNameGuide.text = "";
d.accept = "";
}
}
}
}
};
Key.addListener(this.launcher);
this.pauseFunc = function (what) {
var t = this;
var c = t.launcher.cupid;
if (what == true) {
t.pause = true;
_quality = "high";
c.body.arms.anim.stop();
c.skirt.stop();
c.body.wing1.stop();
c.body.wing2.stop();
c.body.top.stop();
c.body.head.anim.stop();
t.fade = "out";
t.pauseDisplay.gotoAndStop("show");
} else {
t.pause = false;
if (t.gameType == "real") {
_quality = t.inGameQuality;
}
if (c.body.arms.anim._currentframe != c.body.arms.anim._totalframes) {
c.body.arms.anim.play();
}
c.skirt.play();
c.body.wing1.play();
c.body.wing2.play();
c.body.top.play();
c.body.head.anim.play();
if (t.globalsoundcontrol == "play") {
t.fade = "in";
}
t.mainDisplay.fillBlanks();
t.mainDisplay.gotoAndStop("blank");
t.pauseDisplay.gotoAndStop("blank");
}
};
this.startGame = function (what) {
var t = this;
t.gameType = what;
t.resetVars();
t.gamePlay = false;
t.pauseFunc(false);
t.launcher.gotoAndStop("show");
t.gameDisplay.quitBtn.enabled = true;
var i = 0;
while (i < t.numLives) {
t.gameDisplay.attachMovie("heart", "h" + i, i);
var n = t.gameDisplay["h" + i];
n._x = (i * 33) + 22;
n._y = 427;
i++;
}
var i = 0;
while (i < 12) {
t.gameDisplay.attachMovie("pu", "p" + (i + 1), i + 100);
var n = t.gameDisplay["p" + (i + 1)];
n._x = (i * 40) + 22;
n._y = 460;
n._xscale = (n._yscale = 120);
n.graphic.gotoAndStop(i + 1);
n._alpha = t.initPUAlpha;
i++;
}
if (what == "real") {
var n = 3;
while (n > 0) {
t.createFly();
n--;
}
}
t.launcher._y = 150;
t.launcher.cupid.body.arms.anim.gotoAndStop("done");
t.launcher.cupid.body._rotation = 0;
t.launcher.cupid.body.belt._rotation = 0;
t.launcher.cupid.head._rotation = 0;
t.launcher.cupid.body.arms._rotation = 0;
t.launcher.cupid.body.arms2._rotation = 0;
t.launcher.cupid.legs._rotation = 0;
if (what == "real") {
t.gameDisplay.countDown.gotoAndPlay("count");
_quality = t.inGameQuality;
} else {
t.gamePlay = true;
}
t.mainDisplay.gotoAndStop("blank");
t.mainDisplay.promptHelpMC.gotoAndStop("blank");
t.gameOver.gotoAndStop("blank");
};
this.gameOverFunc = function () {
var t = this;
var c = t.launcher.cupid;
_quality = "high";
t.gamePlay = false;
t.gameOver._alpha = 0;
t.gameOver.gotoAndStop("show");
c.body.arms.anim.stop();
c.skirt.stop();
c.body.wing1.stop();
c.body.wing2.stop();
c.body.top.stop();
c.body.head.anim.stop();
trace("lose");
};
this.quitGame = function () {
var t = this;
_quality = "high";
t.resetVars();
t.gamePlay = false;
t.gameDisplay.quitBtn.enabled = false;
t.pauseFunc(false);
_quality = "high";
t.launcher.gotoAndStop("blank");
t.helpMC.gotoAndStop("blank");
t.gameOver.gotoAndStop("blank");
t.launcher._y = 150;
t.mainDisplay.gotoAndStop("title");
};
this.launcher.gotoAndStop("blank");
this.toggleTitleBtns = function (what) {
var t = this.mainDisplay;
t.playBtn.enabled = what;
t.helpBtn.enabled = what;
t.optionsBtn.enabled = what;
t.statsBtn.enabled = what;
t.galleryBtn.enabled = what;
t.hsBtn.enabled = what;
t.cpBtn.enabled = what;
};
this.togglePauseBtns = function (what) {
var t = this.mainDisplay;
t.resumeBtn.enabled = what;
t.optionsBtn.enabled = what;
t.quitBtn.enabled = what;
};
this.togglePlayerBtns = function (what) {
var t = this.mainDisplay;
t.npBtn.enabled = what;
t.proceedBtn.enabled = what;
t.deleteBtn.enabled = what;
t.recAccountBtn.enabled = what;
};
this.startSounds = function () {
if (_root.mySO.data.music == undefined) {
this.globalsoundcontrol = "play";
this.updateBeginMusic();
} else {
this.globalsoundcontrol = _root.mySO.data.music;
}
if (this.globalsoundcontrol == "play") {
this.fade = "in";
} else {
this.fade = "out";
}
if (_root.mySO.data.sounds == undefined) {
this.soundPlay = "true";
this.updateBeginSounds();
} else {
this.soundPlay = _root.mySO.data.sounds;
}
};
this.checkSound = function () {
if (this.userSavedDataA[17] == undefined) {
this.globalsoundcontrol = "play";
this.updateMusic();
} else {
this.globalsoundcontrol = this.userSavedDataA[17];
}
if (this.globalsoundcontrol == "play") {
this.fade = "in";
} else {
this.fade = "out";
}
if (this.userSavedDataA[18] == undefined) {
this.soundPlay = "true";
this.updateSound();
} else {
this.soundPlay = this.userSavedDataA[18];
}
};
this.createEmptyMovieClip("loop", 10000000);
this.loop = new Sound(loop);
this.loop.attachSound("loop");
this.loop.start();
this.loop.onSoundComplete = function () {
this.start();
};
this.initLoopVolume = 80;
this.loopvolume = 0;
this.loop.setVolume(0);
this.createEmptyMovieClip("shoot1", 10000001);
this.shoot1 = new Sound(shoot1);
this.shoot1.attachSound("shoot1");
this.shoot1.setVolume(24);
this.createEmptyMovieClip("hit1", 10000003);
this.hit1 = new Sound(hit1);
this.hit1.attachSound("hit1");
this.hit1.setVolume(30);
this.createEmptyMovieClip("hit2", 10000004);
this.hit2 = new Sound(hit2);
this.hit2.attachSound("hit2");
this.hit2.setVolume(22);
this.createEmptyMovieClip("orb", 10000005);
this.orb = new Sound(orb);
this.orb.attachSound("orb");
this.orb.setVolume(110);
this.createEmptyMovieClip("puSound", 10000006);
this.puSound = new Sound(puSound);
this.puSound.attachSound("puSound");
this.puSound.setVolume(160);
this.createEmptyMovieClip("breakSound", 10000007);
this.breakSound = new Sound(breakSound);
this.breakSound.attachSound("breakSound");
this.breakSound.setVolume(40);
this.createEmptyMovieClip("flyHitSound", 10000008);
this.flyHitSound = new Sound(flyHitSound);
this.flyHitSound.attachSound("flyHitSound");
this.flyHitSound.setVolume(80);
this.createEmptyMovieClip("hHit1", 10000009);
this.hHit1 = new Sound(hHit1);
this.hHit1.attachSound("hHit1");
this.hHit1.setVolume(120);
this.createEmptyMovieClip("hHit2", 10000010);
this.hHit2 = new Sound(hHit2);
this.hHit2.attachSound("hHit2");
this.hHit2.setVolume(120);
this.createEmptyMovieClip("beep", 10000011);
this.beep = new Sound(beep);
this.beep.attachSound("beep");
this.beep.setVolume(80);
Symbol 752 MovieClip Frame 41
stop();