Frame 1
fscommand ("trapallkeys", 1);
fscommand ("allowscale", 0);
stage.showMenu = false;
duplicateMovieClip ("fr", "frame", 26394);
Frame 2
persen = math.floor((getBytesLoaded() / getBytesTotal()) * 100);
if (getBytesLoaded() == getBytesTotal()) {
gotoAndPlay (18);
}
Frame 3
prevFrame();
play();
Frame 5
if (false) {
}
Frame 10
call("pro");
mypet = 1;
Set("/:happy", 0);
Set("/:energy", 70);
Set("/:thirst", 70);
Set("/:sleep", 70);
learn = [0, 0, 0];
gotoAndPlay (76);
Frame 18
call("fadescreen");
stop();
Frame 25
call("fadescreen");
stopAllSounds();
call("pro");
maxpets = 30;
mydate = new Date();
fso = sharedobject.getLocal("fsonetpet", "/");
fso.data.counter++;
aname = fso.data.aname;
amypet = fso.data.amypet;
abday = fso.data.avar1;
alastvisit = fso.data.avar2;
aenergy = fso.data.avar3;
asleep = fso.data.avar4;
ahappy = fso.data.avar5;
athirst = fso.data.avar6;
alearn = fso.data.avar7;
atalk = fso.data.avar8;
_x = 0;
_y = 0;
if (aname.length > 0) {
gotoAndStop (31);
} else {
aname = [];
amypet = [];
abday = [];
alastvisit = [];
aenergy = [];
asleep = [];
ahappy = [];
athirst = [];
alearn = [];
atalk = [];
}
stop();
Frame 31
stop();
Frame 38
call("fadescreen");
select = "";
if (!/:aname.length) {
gotoAndPlay (25);
}
Frame 39
mhei = m._height;
stop();
Frame 44
call("fadescreen");
stop();
Frame 51
call("fadescreen");
Set("/:select", "");
name = "";
stop();
Frame 52
call("fadescreen");
Set("/:select", "");
name = "";
stop();
Frame 60
call("fadescreen");
stop();
Frame 67
timenow = int((/:mydate.getTime() / 1000) / 60);
durasi = timenow - lastvisit;
if (durasi > 2880) {
Set("/:energy", 0);
Set("/:thirst", 0);
Set("/:happy", 0);
Set("/:talk", 0);
Set("/:learn", [0, 0, 0]);
} else if ((durasi > 60) and (durasi < 1440)) {
Set("/:energy", 90);
Set("/:thirst", 90);
Set("/:happy", 100);
}
call("fadescreen");
stop();
Frame 76
stopAllSounds();
call("fadescreen");
if (mypet < 11) {
pettipe = "dog";
_root.attachMovie("dog" + mypet, "pet", 5000);
naughty = ["", "", "sofa"];
} else {
pettipe = "cat";
_root.attachMovie("cat" + (mypet - 10), "pet", 5000);
naughty = ["", "", "scratch"];
}
pet._x = -100;
pet._y = 467;
energylow = 30;
thirstlow = 30;
sleeplow = 20;
food = 0;
water = 0;
out = [0, 0, 0];
toy = [0, 0, 0, 0, 0, 0];
menuwid = 184;
menuhei = 311;
grav = 500;
canpress = 1;
todo = "";
talknow = 0;
treatnow = 0;
beingpet = 0;
room = 1;
naughtydelay = 100;
messagedelay = 300;
xnow = xmin;
screenbumper = 100;
screenwid = 720;
screenmin = 0;
screenmax = 720;
lastclick = 999;
xmin = 0;
xmax = 720;
bumper = 80;
runspeed = 6;
walkspeed = 2;
carspeed = 2;
mousespeed = 10;
frisbeespeed = 12;
still = ["frame", "stat", "menu", "patty", "popmessage"];
phead = 1;
yball = 454;
ycar = 468;
hd = 1;
next = [];
pdo = "stand";
onesec = 25;
createEmptyMovieClip("sfx", 80000);
createEmptyMovieClip("rcsfx", 80001);
createEmptyMovieClip("tvsfx", 80002);
createEmptyMovieClip("toymechsfx", 80003);
createEmptyMovieClip("alarmsfx", 80004);
zbadcat = new sound(sfx);
zbaddog = new sound(sfx);
zdogtalk = new sound(sfx);
zcatdrink = new sound(sfx);
zcateat = new sound(sfx);
zdogdrink = new sound(sfx);
zdogeat = new sound(sfx);
zgoodcat = new sound(sfx);
zgooddog = new sound(sfx);
zcattalk = new sound(sfx);
zstop = new sound(sfx);
ztreat = new sound(sfx);
zbuk = new sound(sfx);
zbuk2 = new sound(sfx);
zboing = new sound(sfx);
zsqueek = new sound(sfx);
zgotfrisbee = new sound(sfx);
zrc1 = new sound(rcsfx);
zrc2 = new sound(rcsfx);
zrc3 = new sound(rcsfx);
ztv = new sound(tvsfx);
ztoymech = new sound(toymechsfx);
zalarm = new sound(alarmsfx);
zbadcat.attachsound("badcat");
zbaddog.attachsound("baddog");
zdogtalk.attachsound("bark");
zcatdrink.attachsound("catdrink");
zcateat.attachsound("cateat");
zdogdrink.attachsound("dogdrink");
zdogeat.attachsound("dogeat");
zgoodcat.attachsound("goodcat");
zgooddog.attachsound("gooddog");
zcattalk.attachsound("meow");
zstop.attachsound("chirp");
ztreat.attachsound("trea");
zbuk.attachsound("buk");
zbuk2.attachsound("buk2");
zboing.attachsound("boing");
zsqueek.attachsound("squeek");
zgotfrisbee.attachsound("gotfrisbee");
zrc1.attachsound("rc1");
zrc2.attachsound("rc2");
zrc3.attachsound("rc3");
ztv.attachsound("tvloop");
ztoymech.attachsound("toymech");
zalarm.attachsound("alarm");
alarmstatus = 0;
zalarm.onSoundComplete = function () {
Set("/:alarmstatus", 0);
};
zrc1.onSoundComplete = function () {
_root.zrc2.start(0, 1000);
};
stop();
Frame 85
movieclip.prototype.resetxpos = function () {
var spacing = (/:screenwid + /:screenbumper);
if (/:room > 1) {
var sign = -1;
} else if (/:room < 1) {
var sign = 1;
}
_root._x = _root._x - (sign * spacing);
var i = 0;
while (i < /:still.length) {
_root[/:still[i]]._x = _root[/:still[i]]._x + (sign * spacing);
i++;
}
};
movieclip.prototype.clrscr = function () {
removeMovieClip("pet");
removeMovieClip("bowlsdrag");
removeMovieClip("bowl1");
removeMovieClip("bowl2");
removeMovieClip("ball");
removeMovieClip("balldrag");
removeMovieClip("mous");
removeMovieClip("mousdrag");
removeMovieClip("yarndrag");
removeMovieClip("yarn");
removeMovieClip("wbdrag");
removeMovieClip("wb");
removeMovieClip("fishingdrag");
removeMovieClip("fishing");
removeMovieClip("frisbeedrag");
removeMovieClip("frisbee");
removeMovieClip("bone");
removeMovieClip("bonedrag");
removeMovieClip("cardrag");
removeMovieClip("car");
removeMovieClip("treat");
removeMovieClip("hand");
removeMovieClip("popmessage");
Mouse.show();
};
movieclip.prototype.less = function (name, value) {
Set(name, eval (name) - value);
if (eval (name) > 100) {
Set(name, 100);
} else if (eval (name) < 0) {
Set(name, 0);
}
};
movieclip.prototype.cekvital = function () {
if (((/:energy < /:energylow) and (/:food > 0)) or ((/:thirst < /:thirstlow) and (/:water > 0))) {
if (/:wait > 25) {
Set("/:wait", 25);
}
}
};
movieclip.prototype.gravity = function () {
var _local1 = this;
_local1.vy = _local1.vy + (/:grav / 10);
_local1.ny = _local1._y + (_local1.vy / 10);
if (_local1.ny > _local1.yland) {
_local1.ny = _local1.yland;
_local1.vy = -0.5 * _local1.vy;
if (_local1.vy > -20) {
_local1.fin = 1;
}
if (_local1.vy < -30) {
_root.zbuk2.start();
}
}
_local1._y = _local1.ny;
};
movieclip.prototype.followmouse = function () {
var _local1 = this;
_local1._x = /:x + ((_local1._x - /:x) / 2);
if (_local1._x < (/:xmin + 50)) {
_local1._x = /:xmin + 50;
} else if (_local1._x > (/:xmax - 50)) {
_local1._x = /:xmax - 50;
}
var _local2 = /:y;
if (_local2 > 440) {
_local2 = 440;
}
_local1._y = _local2 + ((_local1._y - _local2) / 2);
};
movieclip.prototype.onmenu = function () {
var _local1 = _root;
var mx1 = (_local1.menu._x - (0.5 * /:menuwid));
var _local3 = _local1.menu._x + (0.5 * /:menuwid);
var my1 = _local1.menu._y;
var _local2 = _local1.menu._y + /:menuhei;
if ((((/:x > mx1) and (/:x < _local3)) and (/:y > my1)) and (/:y < _local2)) {
return(1);
}
return(0);
};
movieclip.prototype.menuclick = function (no) {
Set("/:click", no);
var i = 1;
while (i <= 2) {
if (/:out[i] == 1) {
/:out[i] = 0;
removeMovieClip("bowlsdrag" + i);
}
i++;
}
var i = 1;
while (i <= 4) {
if (/:toy[i] == 1) {
/:toy[i] = 0;
removeMovieClip("toydrag" + i);
}
i++;
}
if (_root.hand._visible) {
removeMovieClip("hand");
Mouse.show();
if (no == 14) {
no = 0;
}
}
if (_root.fishing._visible) {
/:toy[3] = 0;
removeMovieClip("fishing");
if (no == 5) {
no = 0;
}
}
if (_root.treat._visible) {
removeMovieClip("treat");
if (no == 11) {
no = 0;
}
}
if ((no == 1) or (no == 2)) {
if (/:out[no] == 0) {
/:out[no] = 1;
if (no == 1) {
Set("/:food", 0);
}
if (no == 2) {
Set("/:water", 0);
}
removeMovieClip("bowl" + no);
attachMovie("bowlsdrag", "bowlsdrag" + no, 1000 + (no * 100));
var it = _root["bowlsdrag" + no];
it.tipe = no;
it._x = /:x;
} else if (/:out[no] == 1) {
/:out[no] = 0;
removeMovieClip("bowlsdrag" + no);
} else {
if (no == 1) {
Set("/:food", 0);
}
if (no == 2) {
Set("/:water", 0);
}
/:out[no] = 0;
removeMovieClip("bowl" + no);
}
}
if ((no > 2) and (no < 7)) {
var n = (no - 2);
if (/:toy[n] == 0) {
/:toy[n] = 1;
removeMovieClip("toydrag" + n);
if (n == 1) {
removeMovieClip("ball");
if (/:pettipe == "dog") {
attachMovie("balldrag", "toydrag" + n, 2000 + (n * 100));
} else {
attachMovie("yarndrag", "toydrag" + n, 2000 + (n * 100));
}
var it = _root["toydrag" + n];
it.tipe = n;
it._x = /:x;
}
if (n == 2) {
if (/:pettipe == "dog") {
attachMovie("bonedrag", "toydrag" + n, 2000 + (n * 100));
} else {
attachMovie("wbdrag", "toydrag" + n, 2000 + (n * 100));
}
var it = _root["toydrag" + n];
it.tipe = n;
it._x = /:x;
}
if (n == 3) {
if (/:pettipe == "dog") {
attachMovie("frisbeedrag", "toydrag" + n, 2000 + (n * 100));
} else {
attachMovie("fishingdrag", "toydrag" + n, 2000 + (n * 100));
}
var it = _root["toydrag" + n];
it.tipe = n;
it._x = /:x;
}
if (n == 4) {
if (/:pettipe == "dog") {
attachMovie("cardrag", "toydrag" + n, 2000 + (n * 100));
} else {
attachMovie("mousdrag", "toydrag" + n, 2000 + (n * 100));
}
var it = _root["toydrag" + n];
it.tipe = n;
it._x = /:x;
}
} else if (/:toy[n] == 1) {
/:toy[n] = 0;
removeMovieClip("toydrag" + n);
} else {
/:toy[n] = 0;
if (n == 1) {
phead = 1;
removeMovieClip("ball");
removeMovieClip("yarn");
}
if (n == 2) {
phead = 1;
removeMovieClip("bone");
removeMovieClip("wb");
}
if (n == 3) {
removeMovieClip("frisbee");
removeMovieClip("fishing");
}
if (n == 4) {
removeMovieClip("car");
removeMovieClip("remote");
removeMovieClip("mous");
_root.ztoymech.stop();
}
}
}
if (no > 6) {
if (no == 7) {
if (!/:alarmstatus) {
Set("/:alarmstatus", 1);
if ((/:pdo eq "sleep") and (/:sleep > 20)) {
Set("/:fin", 1);
}
_root.zalarm.start(0, 2);
} else {
Set("/:alarmstatus", 0);
_root.zalarm.stop();
}
}
if (no == 8) {
if (((/:pdo eq "sleep") or (/:pdo eq "stand")) or (/:pdo eq "sit")) {
} else {
Set("/:fin", 1);
if ((/:mypet < 11) and (/:toy[1] == 2)) {
/:toy[1] = 0;
}
}
_root.zstop.start();
}
if (no == 9) {
less("/:happy", 3);
_root["zbad" + /:pettipe].start();
_root.naught.click = 9;
_root.naughtytalk.click = 9;
}
if (no == 10) {
less("/:happy", -8);
_root["zgood" + /:pettipe].start();
}
if (no == 11) {
if (!_root.treat._visible) {
if ((/:pettipe == "cat") and (/:toy[3] == 2)) {
/:toy[3] = 0;
_root.fishing.removeMovieClip();
}
if (/:pdo ne "sit") {
Set("/:fin", 1);
Set("/:todo", "sit");
} else if (/:wait < 200) {
Set("/:wait", 200);
}
attachMovie("treat", "treat" + n, 5100);
var it = _root["treat" + n];
it._x = /:x;
}
}
if (no == 12) {
if (/:pdo ne "sit") {
Set("/:fin", 1);
Set("/:todo", "sit");
}
}
if (no == 13) {
if (/:pdo ne "sleep") {
if (((/:pdo eq "talk") or (/:pdo eq "sit")) or (/:pdo eq "stand")) {
Set("/:talknow", 1);
} else {
Set("/:fin", 1);
Set("/:talknow", 1);
Set("/:todo", "sit");
}
}
}
if (no == 14) {
if (!_root.hand._visible) {
attachMovie("hand", "hand", 5001);
_root.hand._x = /:x;
_root.hand._y = /:y;
Mouse.hide();
}
}
}
};
movieclip.prototype.savecookie = function () {
/:fso.data.aname = /:aname;
/:fso.data.amypet = /:amypet;
/:fso.data.avar1 = /:abday;
/:fso.data.avar2 = /:alastvisit;
/:fso.data.avar3 = /:aenergy;
/:fso.data.avar4 = /:asleep;
/:fso.data.avar5 = /:ahappy;
/:fso.data.avar6 = /:athirst;
/:fso.data.avar7 = /:alearn;
/:fso.data.avar8 = /:atalk;
/:fso.flush();
};
movieclip.prototype.savegame = function () {
var _local1 = int((/:mydate.getTime() / 1000) / 60);
/:alastvisit[/:idx] = int(_local1);
/:aenergy[/:idx] = int(/:energy);
/:asleep[/:idx] = int(/:sleep);
/:ahappy[/:idx] = int(/:happy);
/:athirst[/:idx] = int(/:thirst);
/:alearn[/:idx] = /:learn;
/:atalk[/:idx] = int(/:talk);
savecookie();
};
movieclip.prototype.petcreate = function (a, b) {
var now = int((/:mydate.getTime() / 1000) / 60);
Set("/:name", a);
Set("/:mypet", b);
Set("/:bday", now);
Set("/:lastvisit", now);
Set("/:energy", 70);
Set("/:sleep", 70);
Set("/:happy", 70);
Set("/:thirst", 70);
Set("/:learn", [0, 0, 0]);
Set("/:talk", 0);
Set("/:idx", /:aname.length);
/:aname.push(/:name);
/:amypet.push(/:mypet);
/:abday.push(now);
/:alastvisit.push(now);
/:aenergy.push(/:energy);
/:asleep.push(/:sleep);
/:ahappy.push(/:happy);
/:athirst.push(/:thirst);
/:alearn.push(/:learn);
/:atalk.push(/:talk);
savecookie();
};
movieclip.prototype.petdelete = function (id) {
var _local1 = id;
/:aname.removeElement(_local1);
/:amypet.removeElement(_local1);
/:abday.removeElement(_local1);
/:alastvisit.removeElement(_local1);
/:aenergy.removeElement(_local1);
/:asleep.removeElement(_local1);
/:ahappy.removeElement(_local1);
/:athirst.removeElement(_local1);
/:alearn.removeElement(_local1);
/:atalk.removeElement(_local1);
savecookie();
};
movieclip.prototype.popmessage = function (message) {
var _local1 = _root;
_local1.attachMovie("popmessage", "popmessage", 30012);
_local1.popmessage._x = /:xmax - 300;
_local1.popmessage._y = 47;
_local1.popmessage.message = message;
};
movieclip.prototype.popdelete = function (id) {
_root.attachMovie("popdelete", "popdelete", 30011);
_root.popdelete._x = 360;
_root.popdelete._y = 250;
_root.popdelete.p.n = /:aname[id];
};
movieclip.prototype.popexit = function () {
var _local1 = _root;
_local1.attachMovie("popexit", "popexit", 30009);
_local1.popexit._x = /:xmin + (0.5 * /:screenwid);
_local1.popexit._y = 236;
};
Array.prototype.randomize = function () {
return(this.sort(function (a, b) {
if (Math.floor(Math.random() * 2) != 0) {
} else {
return(1);
}
}));
};
Movieclip.prototype.rad = function (qdeg) {
return(qdeg * 0.0174532925199433 /* Math.PI/180 */);
};
Movieclip.prototype.deg = function (qrad) {
return(qrad * 57.2957795130823);
};
Movieclip.prototype.findang = function (dx, dy) {
return(deg(math.atan2(dy, dx)));
};
Array.prototype.removeElement = function (i) {
var _local2 = this;
var _local3 = i;
var _local1 = _local3;
while (_local1 < (_local2.length - 1)) {
_local2[_local1] = _local2[_local1 + 1];
_local1++;
}
_local2.pop();
};
String.prototype.getReplaced = function (r, w) {
var _local3 = this.split(r);
var _local2 = "";
var _local1 = 0;
while (_local1 < _local3.length) {
if (_local1 == (_local3.length - 1)) {
_local2 = _local2 + _local3[_local1];
} else {
_local2 = _local2 + (_local3[_local1] + w);
}
_local1++;
}
return(_local2);
};
Frame 93
createemptymovieclip("dark", 100001);
var d = this.dark;
with (d) {
lineStyle(1, 0, 100);
beginfill(16777215, 100);
moveto(-5000, -5000);
lineto(5000, -5000);
lineto(5000, 5000);
lineto(-5000, 5000);
endfill();
d.onEnterFrame = function () {
_alpha = _alpha - 3;
if (_alpha <= 0) {
removeMovieClip("");
stop();
}
};
}
Symbol 26 MovieClip [FHighlightSymbol] Frame 1
var component = _parent.controller;
component.registerSkinElement(highlight_mc, "selection");
stop();
Symbol 26 MovieClip [FHighlightSymbol] Frame 2
component.registerSkinElement(highlight_mc2, "selectionDisabled");
stop();
Symbol 26 MovieClip [FHighlightSymbol] Frame 3
component.registerSkinElement(highlight_mc3, "selectionUnfocused");
stop();
Symbol 39 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 49 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 58 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 59 MovieClip [DownArrow] Frame 1
stop();
Symbol 59 MovieClip [DownArrow] Frame 2
stop();
Symbol 59 MovieClip [DownArrow] Frame 3
stop();
Symbol 66 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 73 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 78 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 79 MovieClip [ScrollThumb] Frame 1
stop();
Symbol 87 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 95 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 103 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 104 MovieClip [UpArrow] Frame 1
stop();
Symbol 104 MovieClip [UpArrow] Frame 2
stop();
Symbol 104 MovieClip [UpArrow] Frame 3
stop();
Symbol 109 MovieClip [FBoundingBoxSymbol] Frame 1
var component = _parent;
component.registerSkinElement(boundingBox, "background");
stop();
Symbol 109 MovieClip [FBoundingBoxSymbol] Frame 2
component.registerSkinElement(boundingBox2, "backgroundDisabled");
stop();
Symbol 110 MovieClip [FListItemSymbol] Frame 1
#initclip 8
function FListItemClass() {
this.init();
}
FListItemClass.prototype = new FSelectableItemClass();
Object.registerClass("FListItemSymbol", FListItemClass);
#endinitclip
Symbol 113 MovieClip Frame 1
var component = _parent;
component.registerSkinElement(track_mc, "scrollTrack");
Symbol 114 MovieClip [FScrollBarSymbol] Frame 1
#initclip 3
FScrollBarClass = function () {
var _local1 = this;
if (_local1._height == 4) {
return(undefined);
}
_local1.init();
_local1.minPos = (_local1.maxPos = (_local1.pageSize = (_local1.largeScroll = 0)));
_local1.smallScroll = 1;
_local1.width = (_local1.horizontal ? (_local1._width) : (_local1._height));
_local1._xscale = (_local1._yscale = 100);
_local1.setScrollPosition(0);
_local1.tabEnabled = false;
if (_local1._targetInstanceName.length > 0) {
_local1.setScrollTarget(_local1._parent[_local1._targetInstanceName]);
}
_local1.tabChildren = false;
_local1.setSize(_local1.width);
return(undefined);
};
FScrollBarClass.prototype = new FUIComponentClass();
FScrollBarClass.prototype.setHorizontal = function (flag) {
var _local1 = this;
var _local2 = flag;
if (_local1.horizontal && (!_local2)) {
_local1._xscale = 100;
_local1._rotation = 0;
} else if (_local2 && (!_local1.horizontal)) {
_local1._xscale = -100;
_local1._rotation = -90;
}
_local1.horizontal = _local2;
};
FScrollBarClass.prototype.setScrollProperties = function (pSize, mnPos, mxPos) {
var _local1 = this;
if (!_local1.enable) {
return(undefined);
}
_local1.pageSize = pSize;
_local1.minPos = Math.max(mnPos, 0);
_local1.maxPos = Math.max(mxPos, 0);
_local1.scrollPosition = Math.max(_local1.minPos, _local1.scrollPosition);
_local1.scrollPosition = Math.min(_local1.maxPos, _local1.scrollPosition);
if ((_local1.maxPos - _local1.minPos) <= 0) {
_local1.scrollThumb_mc.removeMovieClip();
_local1.upArrow_mc.gotoAndStop(3);
_local1.downArrow_mc.gotoAndStop(3);
_local1.downArrow_mc.onPress = (_local1.downArrow_mc.onRelease = (_local1.downArrow_mc.onDragOut = null));
_local1.upArrow_mc.onPress = (_local1.upArrow_mc.onRelease = (_local1.upArrow_mc.onDragOut = null));
_local1.scrollTrack_mc.onPress = (_local1.scrollTrack_mc.onRelease = null);
_local1.scrollTrack_mc.onDragOut = (_local1.scrollTrack_mc.onRollOut = null);
_local1.scrollTrack_mc.useHandCursor = false;
} else {
var _local2 = _local1.getScrollPosition();
_local1.upArrow_mc.gotoAndStop(1);
_local1.downArrow_mc.gotoAndStop(1);
_local1.upArrow_mc.onPress = (_local1.upArrow_mc.onDragOver = _local1.startUpScroller);
_local1.upArrow_mc.onRelease = (_local1.upArrow_mc.onDragOut = _local1.stopScrolling);
_local1.downArrow_mc.onPress = (_local1.downArrow_mc.onDragOver = _local1.startDownScroller);
_local1.downArrow_mc.onRelease = (_local1.downArrow_mc.onDragOut = _local1.stopScrolling);
_local1.scrollTrack_mc.onPress = (_local1.scrollTrack_mc.onDragOver = _local1.startTrackScroller);
_local1.scrollTrack_mc.onRelease = _local1.stopScrolling;
_local1.scrollTrack_mc.onDragOut = _local1.stopScrolling;
_local1.scrollTrack_mc.onRollOut = _local1.stopScrolling;
_local1.scrollTrack_mc.useHandCursor = false;
_local1.attachMovie("ScrollThumb", "scrollThumb_mc", 3);
_local1.scrollThumb_mc._x = 0;
_local1.scrollThumb_mc._y = _local1.upArrow_mc._height;
_local1.scrollThumb_mc.onPress = _local1.startDragThumb;
_local1.scrollThumb_mc.controller = _local1;
_local1.scrollThumb_mc.onRelease = (_local1.scrollThumb_mc.onReleaseOutside = _local1.stopDragThumb);
_local1.scrollThumb_mc.useHandCursor = false;
_local1.thumbHeight = (_local1.pageSize / ((_local1.maxPos - _local1.minPos) + _local1.pageSize)) * _local1.trackSize;
_local1.thumbMid_mc = _local1.scrollThumb_mc.mc_sliderMid;
_local1.thumbTop_mc = _local1.scrollThumb_mc.mc_sliderTop;
_local1.thumbBot_mc = _local1.scrollThumb_mc.mc_sliderBot;
_local1.thumbHeight = Math.max(_local1.thumbHeight, 6);
_local1.midHeight = (_local1.thumbHeight - _local1.thumbTop_mc._height) - _local1.thumbBot_mc._height;
_local1.thumbMid_mc._yScale = (_local1.midHeight * 100) / _local1.thumbMid_mc._height;
_local1.thumbMid_mc._y = _local1.thumbTop_mc._height;
_local1.thumbBot_mc._y = _local1.thumbTop_mc._height + _local1.midHeight;
_local1.scrollTop = _local1.scrollThumb_mc._y;
_local1.trackHeight = _local1.trackSize - _local1.thumbHeight;
_local1.scrollBot = _local1.trackHeight + _local1.scrollTop;
_local2 = Math.min(_local2, _local1.maxPos);
_local1.setScrollPosition(Math.max(_local2, _local1.minPos));
}
return(undefined);
};
FScrollBarClass.prototype.getScrollPosition = function () {
return(this.scrollPosition);
};
FScrollBarClass.prototype.setScrollPosition = function (pos) {
var _local1 = this;
var _local2 = pos;
_local1.scrollPosition = _local2;
if (_local1.scrollThumb_mc != undefined) {
_local2 = Math.min(_local2, _local1.maxPos);
_local2 = Math.max(_local2, _local1.minPos);
}
_local1.scrollThumb_mc._y = (((_local2 - _local1.minPos) * _local1.trackHeight) / (_local1.maxPos - _local1.minPos)) + _local1.scrollTop;
_local1.executeCallBack();
};
FScrollBarClass.prototype.setLargeScroll = function (lScroll) {
this.largeScroll = lScroll;
};
FScrollBarClass.prototype.setSmallScroll = function (sScroll) {
this.smallScroll = sScroll;
};
FScrollBarClass.prototype.setEnabled = function (enabledFlag) {
var _local1 = this;
var _local2 = enabledFlag;
var _local3 = _local1.enable;
if (_local2 && (!_local3)) {
_local1.enable = _local2;
if (_local1.textField != undefined) {
_local1.setScrollTarget(_local1.textField);
} else {
_local1.setScrollProperties(_local1.pageSize, _local1.cachedMinPos, _local1.cachedMaxPos);
_local1.setScrollPosition(_local1.cachedPos);
}
_local1.clickFilter = undefined;
} else if ((!_local2) && (_local3)) {
_local1.textField.removeListener(_local1);
_local1.cachedPos = _local1.getScrollPosition();
_local1.cachedMinPos = _local1.minPos;
_local1.cachedMaxPos = _local1.maxPos;
if (_local1.clickFilter == undefined) {
_local1.setScrollProperties(_local1.pageSize, 0, 0);
} else {
_local1.clickFilter = true;
}
_local1.enable = _local2;
}
};
FScrollBarClass.prototype.setSize = function (hgt) {
var _local1 = this;
if (_local1._height == 1) {
return(undefined);
}
_local1.width = hgt;
_local1.scrollTrack_mc._yscale = 100;
_local1.scrollTrack_mc._yscale = (100 * _local1.width) / _local1.scrollTrack_mc._height;
if (_local1.upArrow_mc == undefined) {
_local1.attachMovie("UpArrow", "upArrow_mc", 1);
_local1.attachMovie("DownArrow", "downArrow_mc", 2);
_local1.downArrow_mc.controller = (_local1.upArrow_mc.controller = _local1);
_local1.upArrow_mc.useHandCursor = (_local1.downArrow_mc.useHandCursor = false);
_local1.upArrow_mc._x = (_local1.upArrow_mc._y = 0);
_local1.downArrow_mc._x = 0;
}
_local1.scrollTrack_mc.controller = _local1;
_local1.downArrow_mc._y = _local1.width - _local1.downArrow_mc._height;
_local1.trackSize = _local1.width - (2 * _local1.downArrow_mc._height);
if (_local1.textField != undefined) {
_local1.onTextChanged();
} else {
_local1.setScrollProperties(_local1.pageSize, _local1.minPos, _local1.maxPos);
}
return(undefined);
};
FScrollBarClass.prototype.scrollIt = function (inc, mode) {
var _local1 = this;
var _local3 = _local1.smallScroll;
if (inc != "one") {
_local3 = ((_local1.largeScroll == 0) ? (_local1.pageSize) : (_local1.largeScroll));
}
var _local2 = _local1.getScrollPosition() + (mode * _local3);
if (_local2 > _local1.maxPos) {
_local2 = _local1.maxPos;
} else if (_local2 < _local1.minPos) {
_local2 = _local1.minPos;
}
_local1.setScrollPosition(_local2);
};
FScrollBarClass.prototype.startDragThumb = function () {
var _local1 = this;
_local1.lastY = _local1._ymouse;
_local1.onMouseMove = _local1.controller.dragThumb;
};
FScrollBarClass.prototype.dragThumb = function () {
var _local1 = this;
_local1.scrollMove = _local1._ymouse - _local1.lastY;
_local1.scrollMove = _local1.scrollMove + _local1._y;
if (_local1.scrollMove < _local1.controller.scrollTop) {
_local1.scrollMove = _local1.controller.scrollTop;
} else if (_local1.scrollMove > _local1.controller.scrollBot) {
_local1.scrollMove = _local1.controller.scrollBot;
}
_local1._y = _local1.scrollMove;
var _local2 = _local1.controller;
_local2.scrollPosition = Math.round(((_local2.maxPos - _local2.minPos) * (_local1._y - _local2.scrollTop)) / _local2.trackHeight) + _local2.minPos;
_local1.controller.isScrolling = true;
updateAfterEvent();
_local1.controller.executeCallBack();
};
FScrollBarClass.prototype.stopDragThumb = function () {
this.controller.isScrolling = false;
this.onMouseMove = null;
};
FScrollBarClass.prototype.startTrackScroller = function () {
var _local1 = this;
_local1.controller.trackScroller();
_local1.controller.scrolling = setInterval(_local1.controller, "scrollInterval", 500, "page", -1);
};
FScrollBarClass.prototype.scrollInterval = function (inc, mode) {
var _local1 = this;
var _local2 = inc;
clearInterval(_local1.scrolling);
if (_local2 == "page") {
_local1.trackScroller();
} else {
_local1.scrollIt(_local2, mode);
}
_local1.scrolling = setInterval(_local1, "scrollInterval", 35, _local2, mode);
};
FScrollBarClass.prototype.trackScroller = function () {
var _local1 = this;
if ((_local1.scrollThumb_mc._y + _local1.thumbHeight) < _local1._ymouse) {
_local1.scrollIt("page", 1);
} else if (_local1.scrollThumb_mc._y > _local1._ymouse) {
_local1.scrollIt("page", -1);
}
};
FScrollBarClass.prototype.stopScrolling = function () {
var _local1 = this;
_local1.controller.downArrow_mc.gotoAndStop(1);
_local1.controller.upArrow_mc.gotoAndStop(1);
clearInterval(_local1.controller.scrolling);
};
FScrollBarClass.prototype.startUpScroller = function () {
var _local1 = this;
_local1.controller.upArrow_mc.gotoAndStop(2);
_local1.controller.scrollIt("one", -1);
_local1.controller.scrolling = setInterval(_local1.controller, "scrollInterval", 500, "one", -1);
};
FScrollBarClass.prototype.startDownScroller = function () {
var _local1 = this;
_local1.controller.downArrow_mc.gotoAndStop(2);
_local1.controller.scrollIt("one", 1);
_local1.controller.scrolling = setInterval(_local1.controller, "scrollInterval", 500, "one", 1);
};
FScrollBarClass.prototype.setScrollTarget = function (tF) {
var _local1 = this;
if (tF == undefined) {
_local1.textField.removeListener(_local1);
if (!_local1.horizontal) {
} else {
delete "vScroller".hScroller;
}
if ((_local1.textField.hScroller != undefined) && (_local1.textField.vScroller != undefined)) {
_local1.textField.unwatch("text");
_local1.textField.unwatch("htmltext");
}
}
if ((!tF) instanceof TextField) {
return(undefined);
}
if (!_local1.horizontal) {
}
_local1.onTextChanged();
_local1.textField.addListener(_local1);
_local1.textField.watch("text", _local1.callback);
_local1.textField.watch("htmlText", _local1.callback);
return(undefined);
};
FScrollBarClass.prototype.callback = function (prop, oldVal, newVal) {
var _local1 = this;
clearInterval(_local1.hScroller.synchScroll);
clearInterval(_local1.vScroller.synchScroll);
_local1.hScroller.synchScroll = setInterval(_local1.hScroller, "onTextChanged", 50);
_local1.vScroller.synchScroll = setInterval(_local1.vScroller, "onTextChanged", 50);
return(newVal);
};
FScrollBarClass.prototype.onTextChanged = function () {
var _local1 = this;
if ((!_local1.enable) || (_local1.textField == undefined)) {
return(undefined);
}
clearInterval(_local1.synchScroll);
if (_local1.horizontal) {
var _local2 = _local1.textField.hscroll;
_local1.setScrollProperties(_local1.textField._width, 0, _local1.textField.maxhscroll);
_local1.setScrollPosition(Math.min(_local2, _local1.textField.maxhscroll));
} else {
var _local2 = _local1.textField.scroll;
var _local3 = _local1.textField.bottomScroll - _local1.textField.scroll;
_local1.setScrollProperties(_local3, 1, _local1.textField.maxscroll);
_local1.setScrollPosition(Math.min(_local2, _local1.textField.maxscroll));
}
return(undefined);
};
FScrollBarClass.prototype.executeCallBack = function () {
var _local1 = this;
if (_local1.textField == undefined) {
super.executeCallBack();
} else if (_local1.horizontal) {
_local1.textField.hscroll = _local1.getScrollPosition();
} else {
_local1.textField.scroll = _local1.getScrollPosition();
}
};
Object.registerClass("FScrollBarSymbol", FScrollBarClass);
#endinitclip
Symbol 115 MovieClip [DataProviderSymbol] Frame 1
#initclip 1
_global.DataProviderClass = function () {
this.init();
};
DataProviderClass.prototype.init = function () {
var _local1 = this;
_local1.items = new Array();
_local1.uniqueID = 0;
_local1.views = new Array();
};
DataProviderClass.prototype.addView = function (viewRef) {
this.views.push(viewRef);
var _local1 = {event:"updateAll"};
viewRef.modelChanged(_local1);
};
DataProviderClass.prototype.addItemAt = function (index, value) {
var _local1 = index;
var _local2 = this;
var _local3 = value;
if (_local1 < _local2.getLength()) {
_local2.items.splice(_local1, 0, "tmp");
}
_local2.items[_local1] = new Object();
if (typeof(_local3) == "object") {
_local2.items[_local1] = _local3;
} else {
_local2.items[_local1].label = _local3;
}
_local2.items[_local1].__ID__ = _local2.uniqueID++;
var eventObj = {event:"addRows", firstRow:_local1, lastRow:_local1};
_local2.updateViews(eventObj);
};
DataProviderClass.prototype.addItem = function (value) {
this.addItemAt(this.getLength(), value);
};
DataProviderClass.prototype.removeItemAt = function (index) {
var _local1 = index;
var _local2 = this;
var tmpItm = _local2.items[_local1];
_local2.items.splice(_local1, 1);
var _local3 = {event:"deleteRows", firstRow:_local1, lastRow:_local1};
_local2.updateViews(_local3);
return(tmpItm);
};
DataProviderClass.prototype.removeAll = function () {
var _local1 = this;
_local1.items = new Array();
_local1.updateViews({event:"deleteRows", firstRow:0, lastRow:_local1.getLength() - 1});
};
DataProviderClass.prototype.replaceItemAt = function (index, itemObj) {
var _local1 = index;
var _local2 = this;
if ((_local1 < 0) || (_local1 >= _local2.getLength())) {
return(undefined);
}
var _local3 = _local2.getItemID(_local1);
if (typeof(itemObj) == "object") {
_local2.items[_local1] = itemObj;
} else {
_local2.items[_local1].label = itemObj;
}
_local2.items[_local1].__ID__ = _local3;
_local2.updateViews({event:"updateRows", firstRow:_local1, lastRow:_local1});
return(undefined);
};
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) {
var _local1 = this;
_local1.items.sortOn(fieldName);
if (order == "DESC") {
_local1.items.reverse();
}
_local1.updateViews({event:"sort"});
};
DataProviderClass.prototype.updateViews = function (eventObj) {
var _local2 = this;
var _local3 = eventObj;
var _local1 = 0;
while (_local1 < _local2.views.length) {
_local2.views[_local1].modelChanged(_local3);
_local1++;
}
};
#endinitclip
Symbol 116 MovieClip [FSelectableItemSymbol] Frame 1
#initclip 5
function FSelectableItemClass() {
this.init();
}
FSelectableItemClass.prototype = new FUIComponentClass();
FSelectableItemClass.prototype.init = function () {
var _local1 = this;
if (_local1._name != "itemAsset") {
_local1.highlighted = false;
_local1.layoutContent(100);
}
};
FSelectableItemClass.prototype.drawItem = function (itmObj, selected) {
var _local1 = this;
var _local2 = selected;
_local1.displayContent(itmObj, _local2);
if ((_local1.highlighted != _local2) || ((_local1.controller.focused != _local1.oldFocus) && (_local2))) {
_local1.setHighlighted(_local2);
}
_local1.oldFocus = _local1.controller.focused;
};
FSelectableItemClass.prototype.setSize = function (width, height) {
var _local1 = this;
var _local3 = width;
var _local2 = -16384;
_local1.width = _local3;
_local1.layoutContent(_local3);
_local1.attachMovie("FHighlightSymbol", "highlight_mc", _local2);
_local1.highlight_mc._x = 0.5;
_local1.highlight_mc._width = _local3 - 0.5;
_local1.highlight_mc._height = height;
_local1.highlight_mc.controller = _local1;
_local1.highlight_mc._alpha = 0;
_local1.highlight_mc.trackAsMenu = true;
_local1.highlight_mc.onPress = function () {
var _local1 = this;
if (_local1.controller.enable) {
_local1.controller.controller.clickHandler(_local1.controller.itemNum);
}
};
_local1.highlight_mc.onDragOver = function () {
if (this.controller.controller.focused) {
this.onPress();
}
};
_local1.highlight_mc.useHandCursor = false;
_local1.highlight_mc.trackAsMenu = true;
};
FSelectableItemClass.prototype.setEnabled = function (enabledFlag) {
var _local1 = this;
var _local2 = enabledFlag;
_local1.enable = _local2;
_local1.fLabel_mc.setEnabled(_local2);
if (!_local2) {
} else {
_local1.highlight_mc.gotoAndStop("unfocused");
}
};
FSelectableItemClass.prototype.layoutContent = function (width) {
var _local1 = this;
_local1.attachMovie("FLabelSymbol", "fLabel_mc", 2, {hostComponent:_local1.controller});
_local1.fLabel_mc._x = 2;
_local1.fLabel_mc._y = 0;
_local1.fLabel_mc.setSize(width - 2);
_local1.fLabel_mc.labelField.selectable = false;
};
FSelectableItemClass.prototype.displayContent = function (itmObj, selected) {
var _local2 = itmObj;
var _local1 = "";
if (_local2.label != undefined) {
_local1 = _local2.label;
} else if (typeof(_local2) == "object") {
for (var _local3 in _local2) {
if (_local3 != "__ID__") {
_local1 = (_local2[_local3] + ", ") + _local1;
}
}
_local1 = _local1.substring(0, _local1.length - 2);
} else {
_local1 = _local2;
}
if (this.fLabel_mc.labelField.text != _local1) {
this.fLabel_mc.setLabel(_local1);
}
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) {
var _local1 = this;
var _local2 = flag;
fade = _local1.controller.styleTable.fadeRate.value;
if (((fade == undefined) || (fade == 0)) || (!_local2)) {
_local1.highlight_mc._alpha = (_local2 ? 100 : 0);
delete _local1.onEnterFrame;
} else {
_local1.fadeN = fade;
_local1.fadeX = 1;
_local1.highLight_mc._alpha = 20;
_local1.onEnterFrame = function () {
var _local1 = this;
_local1.highLight_mc._alpha = (60 * Math.sqrt((_local1.fadeX++) / _local1.fadeN)) + 40;
if (_local1.fadeX > _local1.fadeN) {
delete _local1.onEnterFrame;
}
};
}
_local1.highlighted = _local2;
};
#endinitclip
Symbol 117 MovieClip [FSelectableListSymbol] Frame 1
#initclip 4
function FSelectableListClass() {
this.init();
}
FSelectableListClass.prototype = new FUIComponentClass();
FSelectableListClass.prototype.init = function () {
var _local1 = this;
super.init();
_local1.enable = true;
_local1.selected = new Array();
_local1.topDisplayed = (_local1.numDisplayed = 0);
_local1.lastSelected = 0;
_local1.tabChildren = false;
if (_local1._name != undefined) {
_local1.dataProvider = new DataProviderClass();
_local1.dataProvider.addView(_local1);
}
};
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) {
var _local1 = this;
_local1.selectHolder = _local1.getSelectedIndex();
var _local2 = _local1.getItemAt(index);
_local1.dataProvider.removeItemAt(index);
return(_local2);
};
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) {
var _local1 = this;
_local1.lastSelID = _local1.dataProvider.getItemID(_local1.lastSelected);
_local1.dataProvider.sortItemsBy(fieldName, order);
};
FSelectableListClass.prototype.getLength = function () {
return(this.dataProvider.getLength());
};
FSelectableListClass.prototype.getSelectedIndex = function () {
var _local2 = this;
for (var _local3 in _local2.selected) {
var _local1 = _local2.selected[_local3].sIndex;
if (_local1 != undefined) {
if (Item2(nil) == null) {
return(_local1);
}
}
}
return(undefined);
};
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 _local1 = this.getSelectedItem();
if (_local1.data != undefined) {
} else {
return(_local1.label);
}
return(undefined);
};
FSelectableListClass.prototype.setSelectedIndex = function (index, flag) {
var _local1 = this;
var _local2 = index;
if (((_local2 >= 0) && (_local2 < _local1.getLength())) && (_local1.enable)) {
_local1.clearSelected();
_local1.selectItem(_local2, true);
_local1.lastSelected = _local2;
_local1.invalidate("updateControl");
if (flag != false) {
_local1.executeCallBack();
}
}
};
FSelectableListClass.prototype.setDataProvider = function (obj) {
var _local2 = obj;
this.setScrollPosition(0);
this.clearSelected();
if (_local2 instanceof Array) {
this.dataProvider = new DataProviderClass();
var _local1 = 0;
while (_local1 < _local2.length) {
var _local3 = ((typeof(_local2[_local1]) == "string") ? ({label:_local2[_local1]}) : (_local2[_local1]));
this.dataProvider.addItem(_local3);
_local1++;
}
} else {
this.dataProvider = _local2;
}
this.dataProvider.addView(this);
};
FSelectableListClass.prototype.setItemSymbol = function (linkID) {
var _local1 = this;
_local1.tmpPos = _local1.getScrollPosition();
_local1.itemSymbol = linkID;
_local1.invalidate("setSize");
_local1.setScrollPosition(_local1.tmpPos);
};
FSelectableListClass.prototype.setEnabled = function (enabledFlag) {
var _local1 = this;
_local1.cleanUI();
super.setEnabled(enabledFlag);
_local1.enable = enabledFlag;
if (!_local1.enable) {
} else {
_local1.boundingBox_mc.gotoAndStop("enabled");
}
var _local3 = Math.min(_local1.numDisplayed, _local1.getLength());
var _local2 = 0;
while (_local2 < _local3) {
_local1.container_mc[("fListItem" + _local2) + "_mc"].setEnabled(_local1.enable);
}
if (_local1.enable) {
_local1.invalidate("updateControl");
}
};
FSelectableListClass.prototype.updateControl = function () {
var _local2 = this;
var _local1 = 0;
while (_local1 < _local2.numDisplayed) {
_local2.container_mc[("fListItem" + _local1) + "_mc"].drawItem(_local2.getItemAt(_local2.topDisplayed + _local1), _local2.isSelected(_local2.topDisplayed + _local1));
_local1++;
}
};
FSelectableListClass.prototype.setSize = function (w, h) {
var _local1 = this;
super.setSize(w, h);
_local1.boundingBox_mc._xscale = (_local1.boundingBox_mc._yscale = 100);
_local1.boundingBox_mc._xscale = (_local1.width * 100) / _local1.boundingBox_mc._width;
_local1.boundingBox_mc._yscale = (_local1.height * 100) / _local1.boundingBox_mc._height;
var _local2 = 0;
while (_local2 < _local1.numDisplayed) {
_local1.container_mc.attachMovie(_local1.itemSymbol, ("fListItem" + _local2) + "_mc", 10 + _local2, {controller:_local1, itemNum:_local2});
var _local3 = _local1.container_mc[("fListItem" + _local2) + "_mc"];
var offset = ((_local1.scrollOffset == undefined) ? 0 : (_local1.scrollOffset));
_local3.setSize(_local1.width - offset, _local1.itmHgt);
_local3._y = (_local1.itmHgt - 2) * _local2;
_local2++;
}
_local1.updateControl();
};
FSelectableListClass.prototype.modelChanged = function (eventObj) {
var _local1 = this;
var firstRow = eventObj.firstRow;
var lastRow = eventObj.lastRow;
var event = eventObj.event;
if (event == "addRows") {
for (var _local2 in _local1.selected) {
if ((_local1.selected[_local2].sIndex != undefined) && (_local1.selected[_local2].sIndex >= firstRow)) {
_local1.selected[_local2].sIndex = _local1.selected[_local2].sIndex + ((lastRow - firstRow) + 1);
_local1.setSelectedIndex(_local1.selected[_local2].sIndex, false);
}
}
} else if (event == "deleteRows") {
if (firstRow == lastRow) {
var index = firstRow;
if (_local1.selectHolder == index) {
_local1.selectionDeleted = true;
}
if (((_local1.topDisplayed + _local1.numDisplayed) >= _local1.getLength()) && (_local1.topDisplayed > 0)) {
_local1.topDisplayed--;
if (_local1.selectionDeleted && ((index - 1) >= 0)) {
_local1.setSelectedIndex(index - 1, false);
}
} else if (_local1.selectionDeleted) {
var len = _local1.getLength();
if (((index == (len - 1)) && (len > 1)) || (index > (len / 2))) {
_local1.setSelectedIndex(index - 1, false);
} else {
_local1.setSelectedIndex(index, false);
}
}
for (var _local2 in _local1.selected) {
if (_local1.selected[_local2].sIndex > firstRow) {
_local1.selected[_local2].sIndex--;
}
}
} else {
_local1.clearSelected();
_local1.topDisplayed = 0;
}
} else if (event == "sort") {
var len = _local1.getLength();
var _local2 = 0;
while (_local2 < len) {
if (_local1.isSelected(_local2)) {
var _local3 = _local1.dataProvider.getItemID(_local2);
if (_local3 == _local1.lastSelID) {
_local1.lastSelected = _local2;
}
_local1.selected[String(_local3)].sIndex = _local2;
}
_local2++;
}
}
_local1.invalidate("updateControl");
};
FSelectableListClass.prototype.measureItmHgt = function () {
var _local1 = this;
_local1.attachMovie(_local1.itemSymbol, "tmpItem_mc", 0, {controller:_local1});
_local1.tmpItem_mc.drawItem({label:"Sizer: PjtTopg"}, false);
_local1.itmHgt = _local1.tmpItem_mc._height;
_local1.tmpItem_mc.removeMovieClip();
};
FSelectableListClass.prototype.selectItem = function (index, selectedFlag) {
var _local1 = this;
var _local2 = index;
if (selectedFlag && (!_local1.isSelected(_local2))) {
_local1.selected[String(_local1.dataProvider.getItemID(_local2))] = {sIndex:_local2};
} else if (!selectedFlag) {
delete eval (_local1.selected.String(_local1.dataProvider.getItemID(_local2)));
}
};
FSelectableListClass.prototype.isSelected = function (index) {
return(this.selected[String(this.dataProvider.getItemID(index))].sIndex != undefined);
};
FSelectableListClass.prototype.clearSelected = function () {
var _local1 = this;
for (var _local3 in _local1.selected) {
var _local2 = _local1.selected[_local3].sIndex;
if (((_local2 != undefined) && (_local1.topDisplayed <= _local2)) && (_local2 < (_local1.topDisplayed + _local1.numDisplayed))) {
_local1.container_mc[("fListItem" + (_local2 - _local1.topDisplayed)) + "_mc"].drawItem(_local1.getItemAt(_local2), false);
}
}
delete _local1.selected;
_local1.selected = new Array();
};
FSelectableListClass.prototype.selectionHandler = function (itemNum) {
var _local1 = this;
var _local2 = _local1.topDisplayed + itemNum;
if (_local1.getItemAt(_local2 == undefined)) {
_local1.changeFlag = false;
return(undefined);
}
_local1.changeFlag = true;
_local1.clearSelected();
_local1.selectItem(_local2, true);
_local1.container_mc[("fListItem" + itemNum) + "_mc"].drawItem(_local1.getItemAt(_local2), _local1.isSelected(_local2));
return(undefined);
};
FSelectableListClass.prototype.moveSelBy = function (incr) {
var _local1 = this;
var _local3 = _local1.getSelectedIndex();
var _local2 = _local3 + incr;
_local2 = Math.max(0, _local2);
_local2 = Math.min(_local1.getLength() - 1, _local2);
if (_local2 == _local3) {
return(undefined);
}
if ((_local3 < _local1.topDisplayed) || (_local3 >= (_local1.topDisplayed + _local1.numDisplayed))) {
_local1.setScrollPosition(_local3);
}
if ((_local2 >= (_local1.topDisplayed + _local1.numDisplayed)) || (_local2 < _local1.topDisplayed)) {
_local1.setScrollPosition(_local1.topDisplayed + incr);
}
_local1.selectionHandler(_local2 - _local1.topDisplayed);
return(undefined);
};
FSelectableListClass.prototype.clickHandler = function (itmNum) {
var _local1 = this;
_local1.focusRect.removeMovieClip();
if (!_local1.focused) {
_local1.pressFocus();
}
_local1.selectionHandler(itmNum);
_local1.onMouseUp = _local1.releaseHandler;
};
FSelectableListClass.prototype.releaseHandler = function () {
var _local1 = this;
if (_local1.changeFlag) {
_local1.executeCallBack();
}
_local1.changeFlag = false;
_local1.onMouseUp = undefined;
};
FSelectableListClass.prototype.myOnSetFocus = function () {
var _local2 = this;
super.myOnSetFocus();
var _local1 = 0;
while (_local1 < _local2.numDisplayed) {
_local2.container_mc[("fListItem" + _local1) + "_mc"].highlight_mc.gotoAndStop("enabled");
_local1++;
}
};
FSelectableListClass.prototype.myOnKillFocus = function () {
var _local2 = this;
super.myOnKillFocus();
var _local1 = 0;
while (_local1 < _local2.numDisplayed) {
_local2.container_mc[("fListItem" + _local1) + "_mc"].highlight_mc.gotoAndStop("unfocused");
_local1++;
}
};
#endinitclip
Instance of Symbol 115 MovieClip [DataProviderSymbol] "dPAsset" in Symbol 117 MovieClip [FSelectableListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Instance of Symbol 116 MovieClip [FSelectableItemSymbol] "ItemAsset" in Symbol 117 MovieClip [FSelectableListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Symbol 118 MovieClip [FScrollSelectListSymbol] Frame 1
#initclip 6
function FScrollSelectListClass() {
this.init();
}
FScrollSelectListClass.prototype = new FSelectableListClass();
FScrollSelectListClass.prototype.getScrollPosition = function () {
return(this.topDisplayed);
};
FScrollSelectListClass.prototype.setScrollPosition = function (pos) {
var _local1 = pos;
var _local2 = this;
if (_local2.enable) {
_local1 = Math.min(_local1, _local2.getLength() - _local2.numDisplayed);
_local1 = Math.max(_local1, 0);
_local2.scrollBar_mc.setScrollPosition(_local1);
}
};
FScrollSelectListClass.prototype.setAutoHideScrollBar = function (flag) {
var _local1 = this;
_local1.permaScrollBar = !flag;
_local1.setSize(_local1.width, _local1.height);
};
FScrollSelectListClass.prototype.setEnabled = function (enabledFlag) {
super.setEnabled(enabledFlag);
this.scrollBar_mc.setEnabled(this.enable);
};
FScrollSelectListClass.prototype.setSize = function (w, h) {
var _local1 = this;
var _local2 = _local1.getScrollPosition();
super.setSize(w, h);
if (_local1.scrollBar_mc != undefined) {
_local1.removed = true;
}
_local1.scrollBar_mc = undefined;
_local1.initScrollBar();
_local1.setScrollPosition(_local2);
};
FScrollSelectListClass.prototype.modelChanged = function (eventObj) {
super.modelChanged(eventObj);
this.invalidate("initScrollBar");
};
FScrollSelectListClass.prototype.initScrollBar = function () {
var _local1 = this;
if ((!_local1.permaScrollBar) && (_local1.getLength() <= _local1.numDisplayed)) {
if (_local1.removed) {
_local1.scrollBar_mc.removeMovieClip();
_local1.scrollBar_mc = undefined;
_local1.scrollOffset = undefined;
_local1.invalidate("setSize");
}
} else {
if (_local1.scrollBar_mc == undefined) {
_local1.container_mc.attachMovie("FScrollBarSymbol", "scrollBar_mc", 3000, {hostStyle:_local1.styleTable});
_local1.scrollBar_mc = _local1.container_mc.scrollBar_mc;
_local1.scrollBar_mc.setChangeHandler("scrollHandler", _local1);
_local1.scrollBar_mc.setSize(_local1.height);
_local1.scrollBar_mc._x = _local1.width - _local1.scrollBar_mc._width;
_local1.scrollBar_mc._y = 0;
_local1.scrollBar_mc.setLargeScroll(_local1.numDisplayed - 1);
_local1.scrollOffset = _local1.scrollBar_mc._width;
_local1.invalidate("setSize");
}
_local1.scrollBar_mc.setScrollProperties(_local1.numDisplayed, 0, _local1.getLength() - _local1.numDisplayed);
}
};
FScrollSelectListClass.prototype.scrollHandler = function (scrollBar) {
var _local2 = this;
var _local1 = scrollBar.getScrollPosition();
_local2.topDisplayed = _local1;
if (_local2.lastPosition != _local1) {
_local2.updateControl();
}
_local2.lastPosition = _local1;
};
FScrollSelectListClass.prototype.clickHandler = function (itmNum) {
var _local1 = this;
super.clickHandler(itmNum);
if ((_local1.dragScrolling == undefined) && (_local1.scrollBar_mc != undefined)) {
_local1.dragScrolling = setInterval(_local1, "dragScroll", 15);
}
};
FScrollSelectListClass.prototype.releaseHandler = function () {
clearInterval(this.dragScrolling);
this.dragScrolling = undefined;
super.releaseHandler();
};
FScrollSelectListClass.prototype.dragScroll = function () {
var _local1 = this;
clearInterval(_local1.dragScrolling);
if (_local1.container_mc._ymouse < 0) {
_local1.setScrollPosition(_local1.getScrollPosition() - 1);
_local1.selectionHandler(0);
_local1.scrollInterval = Math.max(25, (-23.8 * (-_local1.container_mc._ymouse)) + 500);
_local1.dragScrolling = setInterval(_local1, "dragScroll", _local1.scrollInterval);
} else if (_local1.container_mc._ymouse > ((_local1.itmHgt - 2) * _local1.numDisplayed)) {
_local1.setScrollPosition(_local1.getScrollPosition() + 1);
_local1.selectionHandler(_local1.numDisplayed - 1);
_local1.scrollInterval = Math.max(25, (-23.8 * Math.abs((_local1.container_mc._ymouse - ((_local1.itmHgt - 2) * _local1.numDisplayed)) - 2)) + 500);
_local1.dragScrolling = setInterval(_local1, "dragScroll", _local1.scrollInterval);
} else {
_local1.dragScrolling = setInterval(_local1, "dragScroll", 15);
}
};
FScrollSelectListClass.prototype.myOnKeyDown = function () {
var _local2 = this;
if (_local2.focused) {
_local2.keyCodes = new Array(40, 38, 34, 33, 36, 35);
_local2.keyIncrs = new Array(1, -1, _local2.numDisplayed - 1, -(_local2.numDisplayed - 1), -_local2.getLength(), _local2.getLength());
var _local1 = 0;
while (_local1 < _local2.keyCodes.length) {
if (Key.isDown(_local2.keyCodes[_local1])) {
_local2.moveSelBy(_local2.keyIncrs[_local1]);
return(undefined);
}
_local1++;
}
_local2.findInputText();
}
return(undefined);
};
FScrollSelectListClass.prototype.findInputText = function () {
var _local1 = Key.getAscii();
if ((_local1 >= 33) && (_local1 <= 126)) {
this.findString(String.fromCharCode(_local1));
}
};
FScrollSelectListClass.prototype.findString = function (str) {
if (this.getLength() == 0) {
return(undefined);
}
var _local3 = this.getSelectedIndex();
var jump = 0;
var _local1 = _local3 + 1;
while (_local1 != _local3) {
var _local2 = this.getItemAt(_local1).label.substring(0, str.length);
if ((str == _local2) || (str.toUpperCase() == _local2.toUpperCase())) {
var jump = (_local1 - _local3);
break;
}
if (_local1 >= (this.getLength() - 1)) {
_local1 = -1;
}
_local1++;
}
if (jump != 0) {
this.moveSelBy(jump);
}
return(undefined);
};
#endinitclip
Instance of Symbol 114 MovieClip [FScrollBarSymbol] "scrollBarAsset" in Symbol 118 MovieClip [FScrollSelectListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
_targetInstanceName = "";
horizontal = false;
}
onClipEvent (load) {
this._width = (this._height = 1);
}
Instance of Symbol 117 MovieClip [FSelectableListSymbol] "superClassAsset" in Symbol 118 MovieClip [FScrollSelectListSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Symbol 121 MovieClip [FListBoxSymbol] Frame 1
#initclip 7
function FListBoxClass() {
var _local1 = this;
_local1.itemSymbol = "FListItemSymbol";
_local1.init();
_local1.permaScrollBar = true;
var _local2 = 0;
while (_local2 < _local1.labels.length) {
_local1.addItem(_local1.labels[_local2], _local1.data[_local2]);
_local2++;
}
_local1.boundingBox_mc.gotoAndStop(1);
_local1.width = _local1._width;
_local1.height = _local1._height;
_local1._yscale = (_local1._xscale = 100);
_local1.setSize(_local1.width, _local1.height);
if (_local1.changeHandler.length > 0) {
_local1.setChangeHandler(_local1.changeHandler);
}
}
FListBoxClass.prototype = new FScrollSelectListClass();
Object.registerClass("FListBoxSymbol", FListBoxClass);
FListBoxClass.prototype.getSelectedIndices = function () {
var _local1 = this;
var _local2 = new Array();
for (var _local3 in _local1.selected) {
_local2.push(_local1.selected[_local3].sIndex);
}
if (_local2.length <= 0) {
} else {
return(_local2);
}
return(undefined);
};
FListBoxClass.prototype.getSelectedItems = function () {
var _local2 = this.getSelectedIndices();
var _local3 = new Array();
var _local1 = 0;
while (_local1 < _local2.length) {
_local3.push(this.getItemAt(_local2[_local1]));
_local1++;
}
if (_local3.length <= 0) {
} else {
return(_local3);
}
return(undefined);
};
FListBoxClass.prototype.getSelectMultiple = function () {
return(this.selectMultiple);
};
FListBoxClass.prototype.getRowCount = function () {
return(this.numDisplayed);
};
FListBoxClass.prototype.setSelectedIndices = function (indexArray) {
var _local2 = indexArray;
var _local3 = this;
_local3.clearSelected();
var _local1 = 0;
while (_local1 < _local2.length) {
_local3.selectItem(_local2[_local1], true);
_local1++;
}
_local3.updateControl();
};
FListBoxClass.prototype.setSelectMultiple = function (flag) {
this.selectMultiple = flag;
};
FListBoxClass.prototype.setRowCount = function (count) {
var _local2 = this;
var _local1 = (count * (_local2.itmHgt - 2)) + 2;
_local2.setSize(_local2.width, _local1);
};
FListBoxClass.prototype.setWidth = function (wdt) {
this.setSize(wdt, this.height);
};
FListBoxClass.prototype.setSize = function (w, h) {
var _local1 = this;
var _local2 = h;
var _local3 = w;
if (!_local1.enable) {
return(undefined);
}
_local3 = Math.max(_local3, 20);
_local2 = Math.max(_local2, 40);
_local1.container_mc.removeMovieClip();
_local1.container_mc = _local1.createEmptyMovieClip("container", 3);
_local1.measureItmHgt();
_local1.numDisplayed = Math.floor(_local2 / (_local1.itmHgt - 2));
_local1.height = (_local1.numDisplayed * (_local1.itmHgt - 2)) + 2;
super.setSize(_local3, _local1.height);
return(undefined);
};
FListBoxClass.prototype.removeItemAt = function (index) {
this.selectHolder = this.getSelectedIndices();
return(super.removeItemAt(index));
};
FListBoxClass.prototype.selectionHandler = function (itemNum) {
var _local1 = this;
if (_local1.clickFilter) {
var _local3 = _local1.topDisplayed + itemNum;
if (_local1.getItemAt(_local3) == undefined) {
_local1.changeFlag = false;
return(undefined);
}
_local1.changeFlag = true;
if (((!_local1.selectMultiple) && (!Key.isDown(17))) || ((!Key.isDown(16)) && (!Key.isDown(17)))) {
_local1.clearSelected();
_local1.selectItem(_local3, true);
_local1.lastSelected = _local3;
_local1.container_mc[("fListItem" + itemNum) + "_mc"].drawItem(_local1.getItemAt(_local3), _local1.isSelected(_local3));
} else if (Key.isDown(16) && (_local1.selectMultiple)) {
if (_local1.lastSelected == -1) {
_local1.lastSelected = _local3;
}
var incr = ((_local1.lastSelected < _local3) ? 1 : -1);
_local1.clearSelected();
var _local2 = _local1.lastSelected;
while (_local2 != _local3) {
_local1.selectItem(_local2, true);
if ((_local2 >= _local1.topDisplayed) && (_local2 < (_local1.topDisplayed + _local1.numDisplayed))) {
_local1.container_mc[("fListItem" + (_local2 - _local1.topDisplayed)) + "_mc"].drawItem(_local1.getItemAt(_local2), _local1.isSelected(_local2));
}
_local2 = _local2 + incr;
}
_local1.selectItem(_local3, true);
_local1.container_mc[("fListItem" + (_local3 - _local1.topDisplayed)) + "_mc"].drawItem(_local1.getItemAt(_local3), _local1.isSelected(_local3));
} else if (key.isDown(17)) {
var selectedFlag = _local1.isSelected(_local3);
if (!_local1.selectMultiple) {
_local1.clearSelected();
}
if (!((!_local1.selectMultiple) && (selectedFlag))) {
_local1.selectItem(_local3, !selectedFlag);
_local1.container_mc[("fListItem" + itemNum) + "_mc"].drawItem(_local1.getItemAt(_local1.topDisplayed + itemNum), _local1.isSelected(_local1.topDisplayed + itemNum));
}
_local1.lastSelected = _local3;
}
} else {
_local1.clickFilter = true;
}
return(undefined);
};
FListBoxClass.prototype.moveSelBy = function (itemNum) {
super.moveSelBy(itemNum);
this.releaseHandler();
};
#endinitclip
this.deadPreview._visible = false;
Instance of Symbol 118 MovieClip [FScrollSelectListSymbol] "superClassAsset" in Symbol 121 MovieClip [FListBoxSymbol] Frame 1
//component parameters
onClipEvent (initialize) {
}
Symbol 122 MovieClip [FUIComponentSymbol] Frame 1
#initclip 2
function FUIComponentClass() {
this.init();
}
FUIComponentClass.prototype = new MovieClip();
FUIComponentClass.prototype.init = function () {
var _local1 = this;
var _local3 = _global;
_local1.enable = true;
_local1.focused = false;
_local1.useHandCursor = false;
_local1._accImpl = new Object();
_local1._accImpl.stub = true;
_local1.styleTable = new Array();
if (_local3.globalStyleFormat == undefined) {
_local3.globalStyleFormat = new FStyleFormat();
globalStyleFormat.isGlobal = true;
_local3._focusControl = new Object();
_local3._focusControl.onSetFocus = function (oldFocus, newFocus) {
oldFocus.myOnKillFocus();
newFocus.myOnSetFocus();
};
Selection.addListener(_local3._focusControl);
}
if (_local1._name != undefined) {
_local1._focusrect = false;
_local1.tabEnabled = true;
_local1.focusEnabled = true;
_local1.tabChildren = false;
_local1.tabFocused = true;
if (_local1.hostStyle == undefined) {
globalStyleFormat.addListener(_local1);
} else {
_local1.styleTable = _local1.hostStyle;
}
_local1.deadPreview._visible = false;
_local1.deadPreview._width = (_local1.deadPreview._height = 1);
_local1.methodTable = new Object();
_local1.keyListener = new Object();
_local1.keyListener.controller = _local1;
_local1.keyListener.onKeyDown = function () {
this.controller.myOnKeyDown();
};
_local1.keyListener.onKeyUp = function () {
this.controller.myOnKeyUp();
};
for (var _local2 in _local1.styleFormat_prm) {
_local1.setStyleProperty(_local2, _local1.styleFormat_prm[_local2]);
}
}
};
FUIComponentClass.prototype.setEnabled = function (enabledFlag) {
var _local1 = this;
_local1.enable = ((arguments.length > 0) ? (enabledFlag) : true);
_local1.tabEnabled = (_local1.focusEnabled = enabledFlag);
if ((!_local1.enable) && (_local1.focused)) {
Selection.setFocus(undefined);
}
};
FUIComponentClass.prototype.getEnabled = function () {
return(this.enable);
};
FUIComponentClass.prototype.setSize = function (w, h) {
var _local1 = this;
_local1.width = w;
_local1.height = h;
_local1.focusRect.removeMovieClip();
};
FUIComponentClass.prototype.setChangeHandler = function (chng, obj) {
var _local1 = this;
_local1.handlerObj = ((obj == undefined) ? (_local1._parent) : (obj));
_local1.changeHandler = chng;
};
FUIComponentClass.prototype.invalidate = function (methodName) {
var _local1 = this;
_local1.methodTable[methodName] = true;
_local1.onEnterFrame = _local1.cleanUI;
};
FUIComponentClass.prototype.cleanUI = function () {
var _local1 = this;
if (_local1.methodTable.setSize) {
_local1.setSize(_local1.width, _local1.height);
} else {
_local1.cleanUINotSize();
}
_local1.methodTable = new Object();
delete _local1.onEnterFrame;
};
FUIComponentClass.prototype.cleanUINotSize = function () {
var _local1 = this;
for (var _local2 in _local1.methodTable) {
_local1[_local2]();
}
};
FUIComponentClass.prototype.drawRect = function (x, y, w, h) {
var _local1 = this;
var _local2 = y;
var _local3 = x;
var inner = _local1.styleTable.focusRectInner.value;
var outer = _local1.styleTable.focusRectOuter.value;
if (inner == undefined) {
inner = 16777215 /* 0xFFFFFF */;
}
if (outer == undefined) {
outer = 0;
}
_local1.createEmptyMovieClip("focusRect", 1000);
_local1.focusRect.controller = _local1;
_local1.focusRect.lineStyle(1, outer);
_local1.focusRect.moveTo(_local3, _local2);
_local1.focusRect.lineTo(_local3 + w, _local2);
_local1.focusRect.lineTo(_local3 + w, _local2 + h);
_local1.focusRect.lineTo(_local3, _local2 + h);
_local1.focusRect.lineTo(_local3, _local2);
_local1.focusRect.lineStyle(1, inner);
_local1.focusRect.moveTo(_local3 + 1, _local2 + 1);
_local1.focusRect.lineTo((_local3 + w) - 1, _local2 + 1);
_local1.focusRect.lineTo((_local3 + w) - 1, (_local2 + h) - 1);
_local1.focusRect.lineTo(_local3 + 1, (_local2 + h) - 1);
_local1.focusRect.lineTo(_local3 + 1, _local2 + 1);
};
FUIComponentClass.prototype.pressFocus = function () {
var _local1 = this;
_local1.tabFocused = false;
_local1.focusRect.removeMovieClip();
Selection.setFocus(_local1);
};
FUIComponentClass.prototype.drawFocusRect = function () {
var _local1 = this;
_local1.drawRect(-2, -2, _local1.width + 4, _local1.height + 4);
};
FUIComponentClass.prototype.myOnSetFocus = function () {
var _local1 = this;
_local1.focused = true;
Key.addListener(_local1.keyListener);
if (_local1.tabFocused) {
_local1.drawFocusRect();
}
};
FUIComponentClass.prototype.myOnKillFocus = function () {
var _local1 = this;
_local1.tabFocused = true;
_local1.focused = false;
_local1.focusRect.removeMovieClip();
Key.removeListener(_local1.keyListener);
};
FUIComponentClass.prototype.executeCallBack = function () {
var _local1 = this;
_local1.handlerObj[_local1.changeHandler](_local1);
};
FUIComponentClass.prototype.updateStyleProperty = function (styleFormat, propName) {
this.setStyleProperty(propName, styleFormat[propName], styleFormat.isGlobal);
};
FUIComponentClass.prototype.setStyleProperty = function (propName, value, isGlobal) {
var _local1 = this;
var _local2 = propName;
if (value == "") {
return(undefined);
}
var tmpValue = parseInt(value);
if (!isNaN(tmpValue)) {
value = tmpValue;
}
var global = ((arguments.length > 2) ? (isGlobal) : false);
if (_local1.styleTable[_local2] == undefined) {
_local1.styleTable[_local2] = new Object();
_local1.styleTable[_local2].useGlobal = true;
}
if (_local1.styleTable[_local2].useGlobal || (!global)) {
_local1.styleTable[_local2].value = value;
if (_local1.setCustomStyleProperty(_local2, value)) {
} else if (_local2 == "embedFonts") {
_local1.invalidate("setSize");
} else if (_local2.subString(0, 4) == "text") {
if (_local1.textStyle == undefined) {
_local1.textStyle = new TextFormat();
}
var textProp = _local2.subString(4, _local2.length);
_local1.textStyle[textProp] = value;
_local1.invalidate("setSize");
}
for (var j in _local1.styleTable[_local2].coloredMCs) {
var _local3 = new Color(_local1.styleTable[_local2].coloredMCs[j]);
if (_local1.styleTable[_local2].value == undefined) {
var myTObj = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
_local3.setTransform(myTObj);
} else {
_local3.setRGB(value);
}
}
_local1.styleTable[_local2].useGlobal = global;
}
return(undefined);
};
FUIComponentClass.prototype.registerSkinElement = function (skinMCRef, propName) {
var _local1 = this;
var _local2 = propName;
if (_local1.styleTable[_local2] == undefined) {
_local1.styleTable[_local2] = new Object();
_local1.styleTable[_local2].useGlobal = true;
}
if (_local1.styleTable[_local2].coloredMCs == undefined) {
_local1.styleTable[_local2].coloredMCs = new Object();
}
_local1.styleTable[_local2].coloredMCs[skinMCRef] = skinMCRef;
if (_local1.styleTable[_local2].value != undefined) {
var _local3 = new Color(skinMCRef);
_local3.setRGB(_local1.styleTable[_local2].value);
}
};
_global.FStyleFormat = function () {
var _local1 = arguments;
var _local2 = this;
_local2.nonStyles = {listeners:true, isGlobal:true, isAStyle:true, addListener:true, removeListener:true, nonStyles:true, applyChanges:true};
_local2.listeners = new Object();
_local2.isGlobal = false;
if (_local1.length > 0) {
for (var _local3 in _local1[0]) {
_local2[_local3] = _local1[0][_local3];
}
}
};
_global.FStyleFormat.prototype = new Object();
FStyleFormat.prototype.addListener = function () {
var _local1 = this;
var _local2 = 0;
while (_local2 < arguments.length) {
var _local3 = arguments[_local2];
_local1.listeners[arguments[_local2]] = _local3;
for (var i in _local1) {
if (_local1.isAStyle(i)) {
_local3.updateStyleProperty(_local1, i.toString());
}
}
_local2++;
}
};
FStyleFormat.prototype.removeListener = function (component) {
var _local1 = this;
var _local2 = component;
_local1.listeners[_local2] = undefined;
for (var prop in _local1) {
if (_local1.isAStyle(prop)) {
if (_local2.styleTable[prop].useGlobal == _local1.isGlobal) {
_local2.styleTable[prop].useGlobal = true;
var _local3 = (_local1.isGlobal ? undefined : (globalStyleFormat[prop]));
_local2.setStyleProperty(prop, _local3, true);
}
}
}
};
FStyleFormat.prototype.applyChanges = function () {
var _local1 = this;
var _local2 = arguments;
var count = 0;
for (var i in _local1.listeners) {
var _local3 = _local1.listeners[i];
if (_local2.length > 0) {
var j = 0;
while (j < _local2.length) {
if (_local1.isAStyle(_local2[j])) {
_local3.updateStyleProperty(_local1, _local2[j]);
}
j++;
}
}
for (var j in _local1) {
if (_local1.isAStyle(j)) {
_local3.updateStyleProperty(_local1, j.toString());
}
}
}
};
FStyleFormat.prototype.isAStyle = function (name) {
if (!this.nonStyles[name]) {
} else {
return(false);
}
};
#endinitclip
Symbol 125 MovieClip [FLabelSymbol] Frame 1
Symbol 142 MovieClip Frame 1
onenterframe = function () {
if (/:beingpet == 1) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
};
Symbol 150 MovieClip Frame 9
Set("/:phead", 1);
Symbol 154 MovieClip Frame 12
stop();
Symbol 163 MovieClip Frame 1
_parent.stop();
d = _name;
Symbol 163 MovieClip Frame 2
d = d - 1;
Symbol 163 MovieClip Frame 3
if (d) {
prevFrame();
play();
} else {
_parent.play();
stop();
}
Symbol 164 MovieClip Frame 1
onenterframe = function () {
if (/:talknow > 0) {
Set("/:talknow", 0);
gotoAndPlay (27);
}
if (/:treatnow) {
Set("/:treatnow", 0);
gotoAndPlay (37);
}
};
Symbol 164 MovieClip Frame 26
gotoAndPlay (2);
Symbol 164 MovieClip Frame 27
_root[("z" + /:pettipe) + "talk"].start();
Symbol 164 MovieClip Frame 36
gotoAndPlay (2);
Symbol 164 MovieClip Frame 46
gotoAndPlay (2);
Symbol 171 MovieClip Frame 13
Set("/:phead", 1);
stop();
Symbol 175 MovieClip Frame 1
onenterframe = function () {
gotoAndStop(/:phead);
};
Symbol 176 MovieClip Frame 14
gotoAndPlay (1);
Symbol 178 MovieClip Frame 21
gotoAndPlay (1);
Symbol 179 MovieClip Frame 20
stop();
Symbol 181 MovieClip Frame 13
stop();
Symbol 181 MovieClip Frame 26
stop();
Symbol 186 MovieClip Frame 15
stop();
Symbol 186 MovieClip Frame 16
h.gotoAndPlay("fin");
Symbol 186 MovieClip Frame 30
stop();
Symbol 187 MovieClip Frame 15
stop();
Symbol 187 MovieClip Frame 30
stop();
Symbol 196 MovieClip Frame 26
stop();
Symbol 196 MovieClip Frame 50
stop();
Symbol 211 MovieClip Frame 1
if (/:pdo == "drink") {
gotoAndStop (2);
} else {
stop();
}
Symbol 212 MovieClip Frame 10
_root[("z" + /:pettipe) + /:pdo].start(0, 10);
stop();
Symbol 212 MovieClip Frame 11
_root[("z" + /:pettipe) + /:pdo].stop();
Symbol 212 MovieClip Frame 20
stop();
Symbol 215 MovieClip Frame 7
stop();
Symbol 215 MovieClip Frame 13
stop();
Symbol 219 MovieClip Frame 22
stop();
Symbol 220 MovieClip Frame 17
stop();
Symbol 220 MovieClip Frame 40
stop();
Symbol 220 MovieClip Frame 41
stop();
Symbol 253 MovieClip Frame 26
stop();
Symbol 253 MovieClip Frame 50
stop();
Symbol 254 MovieClip Frame 19
stop();
stop();
Symbol 254 MovieClip Frame 29
stop();
Symbol 255 MovieClip [dog2] Frame 1
stop();
Symbol 260 MovieClip Frame 1
d = random(50);
Symbol 260 MovieClip Frame 2
d = d - 1;
Symbol 260 MovieClip Frame 3
if (d) {
prevFrame();
play();
} else {
count = 2 + random(3);
}
Symbol 260 MovieClip Frame 21
count = count - 1;
if (count) {
gotoAndPlay (4);
} else {
gotoAndPlay (1);
}
Symbol 272 MovieClip Frame 1
onenterframe = function () {
if (/:beingpet == 1) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
};
Symbol 324 MovieClip Frame 12
stop();
Symbol 363 MovieClip Frame 1
_parent.stop();
d = _name;
Symbol 363 MovieClip Frame 2
d = d - 1;
Symbol 363 MovieClip Frame 3
if (d) {
prevFrame();
play();
} else {
_parent.play();
stop();
}
Symbol 364 MovieClip Frame 1
onenterframe = function () {
if (/:talknow) {
Set("/:talknow", 0);
gotoAndPlay (61);
}
if (/:treatnow) {
Set("/:treatnow", 0);
gotoAndPlay (71);
}
};
Symbol 364 MovieClip Frame 60
gotoAndPlay (2);
Symbol 364 MovieClip Frame 61
_root[("z" + /:pettipe) + "talk"].start();
Symbol 364 MovieClip Frame 70
gotoAndPlay (2);
Symbol 364 MovieClip Frame 80
gotoAndPlay (2);
Symbol 366 MovieClip Frame 14
gotoAndPlay (1);
Symbol 367 MovieClip Frame 21
gotoAndPlay (1);
Symbol 369 MovieClip Frame 15
stop();
Symbol 369 MovieClip Frame 25
stop();
Symbol 372 MovieClip Frame 1
stop();
Symbol 372 MovieClip Frame 20
stop();
Symbol 373 MovieClip Frame 15
stop();
Symbol 373 MovieClip Frame 30
stop();
Symbol 374 MovieClip Frame 15
stop();
Symbol 374 MovieClip Frame 30
stop();
Symbol 385 MovieClip Frame 26
stop();
Symbol 385 MovieClip Frame 50
stop();
Symbol 392 MovieClip Frame 1
if (/:pdo == "drink") {
gotoAndStop (2);
} else {
stop();
}
Symbol 393 MovieClip Frame 10
_root[("z" + /:pettipe) + /:pdo].start(0, 12);
stop();
Symbol 393 MovieClip Frame 11
_root[("z" + /:pettipe) + /:pdo].stop();
Symbol 393 MovieClip Frame 20
stop();
Symbol 394 MovieClip Frame 26
stop();
Symbol 395 MovieClip Frame 22
stop();
stop();
Symbol 395 MovieClip Frame 29
stop();
Symbol 412 MovieClip Frame 15
stop();
Symbol 412 MovieClip Frame 29
stop();
Symbol 414 MovieClip Frame 15
stop();
Symbol 414 MovieClip Frame 16
h.gotoAndPlay("fin");
Symbol 414 MovieClip Frame 30
stop();
Symbol 416 MovieClip Frame 13
stop();
Symbol 416 MovieClip Frame 28
stop();
Symbol 430 MovieClip Frame 35
gotoAndPlay (24);
Symbol 430 MovieClip Frame 50
stop();
Symbol 431 MovieClip [cat2] Frame 1
stop();
Symbol 437 MovieClip [fishingdrag] Frame 1
onenterframe = function () {
_x = _root._xmouse;
_y = _root._ymouse;
if (_y > 240) {
_y = 240;
}
};
onmousedown = function () {
if (!onmenu()) {
/:toy[tipe] = 2;
_root.attachMovie("fishing", "fishing", (2000 + (tipe * 100)) + 1);
var _local1 = _root.fishing;
_local1._x = _x;
_local1._y = _y;
removeMovieClip("");
}
};
Symbol 440 MovieClip [fishing] Frame 1
vx = 0;
vy = 0;
grav = 3;
range = 100;
rlength = 100;
linecolor = 16777215 /* 0xFFFFFF */;
_x = 0;
_y = 0;
oldx = ball._x;
oldy = ball._y;
pole._x = _root._xmouse;
pole._y = _root._ymouse;
ball._x = _root._xmouse;
ball._y = _root._ymouse;
onenterframe = function () {
pole._x = _root._xmouse;
pole._y = _root._ymouse;
if (pole._y > 240) {
pole._y = 240;
}
oldx = ball._x;
oldy = ball._y;
vy = vy + grav;
ball._x = ball._x + vx;
ball._y = ball._y + vy;
polepx = pole._x - range;
ball._rotation = findang(polepx - ball._x, pole._y - ball._y);
dis = Math.sqrt(((polepx - ball._x) * (polepx - ball._x)) + ((pole._y - ball._y) * (pole._y - ball._y)));
if (dis > rlength) {
ball._x = polepx - (((polepx - ball._x) / dis) * rlength);
ball._y = pole._y - (((pole._y - ball._y) / dis) * rlength);
vx = ball._x - oldx;
vy = ball._y - oldy;
clear();
lineStyle(1, linecolor, 100);
moveTo(ball._x, ball._y);
lineTo(polepx, pole._y);
} else {
clear();
lineStyle(1, linecolor, 100);
moveTo(ball._x, ball._y);
curveTo((ball._x + polepx) / 2, ((ball._y + pole._y) / 2) + (rlength - dis), polepx, pole._y);
}
};
Symbol 445 MovieClip [mousdrag] Frame 1
onenterframe = function () {
oldx = _x;
oldy = _y;
followmouse();
};
onmousedown = function () {
if (!onmenu()) {
/:toy[tipe] = 2;
_root.attachMovie("mous", "mous", (2000 + (tipe * 100)) + 1);
var _local1 = _root.mous;
_local1._x = _x;
_local1._y = _y;
removeMovieClip("");
}
};
Symbol 446 MovieClip [mous] Frame 1
yland = 460;
xmax = /:xmax;
xmin = /:xmin;
Symbol 446 MovieClip [mous] Frame 2
gravity();
Symbol 446 MovieClip [mous] Frame 3
if (!fin) {
prevFrame();
play();
} else {
this._y = yland;
_root.ztoymech.start(0, 100000);
}
Symbol 446 MovieClip [mous] Frame 5
call("targeting");
Symbol 446 MovieClip [mous] Frame 6
nx = _x + xs;
if ((xs > 0) and (nx > targ)) {
call("targeting");
} else if ((xs < 0) and (nx < targ)) {
call("targeting");
}
_x = nx;
Symbol 446 MovieClip [mous] Frame 7
prevFrame();
play();
Symbol 446 MovieClip [mous] Frame 14
if (_x < (xmin + (0.5 * /:screenwid))) {
xs = /:mousespeed;
targ = xmax - random(120);
_xscale = 100;
} else {
xs = -/:mousespeed;
targ = xmin + random(120);
_xscale = -100;
}
Symbol 465 MovieClip Frame 1
stop();
Symbol 465 MovieClip Frame 59
stop();
Symbol 466 MovieClip Frame 1
stop();
Symbol 466 MovieClip Frame 20
stop();
Symbol 471 MovieClip [wb] Frame 1
yland = 460;
Symbol 471 MovieClip [wb] Frame 2
gravity();
Symbol 471 MovieClip [wb] Frame 3
if (!fin) {
prevFrame();
play();
} else {
this._y = yland;
w.b.gotoAndPlay(2);
stop();
}
Symbol 475 MovieClip [wbdrag] Frame 1
onenterframe = function () {
oldx = _x;
oldy = _y;
followmouse();
};
onmousedown = function () {
if (!onmenu()) {
/:toy[tipe] = 2;
_root.attachMovie("wb", "wb", (2000 + (tipe * 100)) + 1);
var _local1 = _root.wb;
_local1._x = _x;
_local1._y = _y;
removeMovieClip("");
}
};
Symbol 482 MovieClip [yarndrag] Frame 1
onenterframe = function () {
oldx = _x;
oldy = _y;
followmouse();
};
onmousedown = function () {
if (!onmenu()) {
/:toy[tipe] = 2;
_root.attachMovie("yarn", "ball", (2000 + (tipe * 100)) + 1);
var _local1 = _root.ball;
_local1._x = _x;
_local1._y = _y;
_local1.vx = _x - oldx;
_local1.vy = 5 * (_y - oldy);
removeMovieClip("");
}
};
Symbol 483 Button
on (press) {
drag = 1;
/:toy[1] = 1;
startDrag (this, true, /:xmin + radius, radius, /:xmax - radius, 450);
}
on (release, releaseOutside) {
drag = 0;
/:toy[1] = 2;
vx = _x - oldx;
vy = 5 * (_y - oldy);
stopDrag();
}
Symbol 484 MovieClip [yarn] Frame 1
onenterframe = function () {
var _local1 = _root;
if (!drag) {
if (vx == 0) {
vx = 10;
}
nx = _x + vx;
if (nx < (xmin + radius)) {
vx = (-vx) * damp;
nx = xmin + radius;
if (math.abs(vx) > 5) {
_local1.zbuk.start();
}
} else if (nx > (xmax - radius)) {
vx = (-vx) * damp;
nx = xmax - radius;
if (math.abs(vx) > 5) {
_local1.zbuk.start();
}
}
_x = nx;
vy = vy + (/:grav / 7);
ny = _y + (vy / 10);
if (ny > yland) {
ny = yland;
vy = -0.5 * vy;
vx = vx * 0.9;
if (vy < -30) {
_local1.zbuk.start();
}
}
_y = ny;
b._rotation = b._rotation + (vx * 3);
} else {
oldx = _x;
oldy = _y;
}
};
xmax = /:xmax;
xmin = /:xmin;
drag = 0;
damp = 0.8;
yland = /:yball - 3;
radius = 12;
Symbol 498 MovieClip Frame 1
onenterframe = function () {
if (/:beingpet == 1) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
};
Symbol 559 MovieClip Frame 12
stop();
Symbol 594 MovieClip Frame 1
_parent.stop();
d = _name;
Symbol 594 MovieClip Frame 2
d = d - 1;
Symbol 594 MovieClip Frame 3
if (d) {
prevFrame();
play();
} else {
_parent.play();
stop();
}
Symbol 595 MovieClip Frame 1
onenterframe = function () {
if (/:talknow) {
Set("/:talknow", 0);
gotoAndPlay (61);
}
if (/:treatnow) {
Set("/:treatnow", 0);
gotoAndPlay (71);
}
};
Symbol 595 MovieClip Frame 60
gotoAndPlay (2);
Symbol 595 MovieClip Frame 61
_root[("z" + /:pettipe) + "talk"].start();
Symbol 595 MovieClip Frame 70
gotoAndPlay (2);
Symbol 595 MovieClip Frame 80
gotoAndPlay (2);
Symbol 597 MovieClip Frame 14
gotoAndPlay (1);
Symbol 598 MovieClip Frame 21
gotoAndPlay (1);
Symbol 600 MovieClip Frame 15
stop();
Symbol 600 MovieClip Frame 25
stop();
Symbol 601 MovieClip Frame 1
d = random(50);
Symbol 601 MovieClip Frame 2
d = d - 1;
Symbol 601 MovieClip Frame 3
if (d) {
prevFrame();
play();
} else {
count = 2 + random(3);
}
Symbol 601 MovieClip Frame 21
count = count - 1;
if (count) {
gotoAndPlay (4);
} else {
gotoAndPlay (1);
}
Symbol 610 MovieClip Frame 1
stop();
Symbol 610 MovieClip Frame 20
stop();
Symbol 617 MovieClip Frame 15
stop();
Symbol 617 MovieClip Frame 30
stop();
Symbol 630 MovieClip Frame 15
stop();
Symbol 630 MovieClip Frame 30
stop();
Symbol 667 MovieClip Frame 26
stop();
Symbol 667 MovieClip Frame 50
stop();
Symbol 674 MovieClip Frame 1
if (/:pdo == "drink") {
gotoAndStop (2);
} else {
stop();
}
Symbol 675 MovieClip Frame 10
_root[("z" + /:pettipe) + /:pdo].start(0, 12);
stop();
Symbol 675 MovieClip Frame 11
_root[("z" + /:pettipe) + /:pdo].stop();
Symbol 675 MovieClip Frame 20
stop();
Symbol 676 MovieClip Frame 26
stop();
Symbol 677 MovieClip Frame 22
stop();
stop();
Symbol 677 MovieClip Frame 29
stop();
Symbol 694 MovieClip Frame 15
stop();
Symbol 694 MovieClip Frame 29
stop();
Symbol 696 MovieClip Frame 15
stop();
Symbol 696 MovieClip Frame 16
h.gotoAndPlay("fin");
Symbol 696 MovieClip Frame 30
stop();
Symbol 698 MovieClip Frame 13
stop();
Symbol 698 MovieClip Frame 28
stop();
Symbol 712 MovieClip Frame 35
gotoAndPlay (24);
Symbol 712 MovieClip Frame 50
stop();
Symbol 713 MovieClip [cat1] Frame 1
stop();
Symbol 728 MovieClip Frame 1
onenterframe = function () {
if (/:beingpet == 1) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
};
Symbol 731 MovieClip Frame 1
stop();
Symbol 732 MovieClip Frame 1
if (int(0.5 * /:hd) != (0.5 * /:hd)) {
b.gotoAndStop(2);
} else {
b.gotoAndStop(1);
}
Symbol 732 MovieClip Frame 2
prevFrame();
play();
Symbol 741 MovieClip Frame 9
Set("/:phead", 1);
Symbol 752 MovieClip Frame 1
onenterframe = function () {
if (/:talknow > 0) {
Set("/:talknow", 0);
gotoAndPlay (27);
}
if (/:treatnow) {
Set("/:treatnow", 0);
gotoAndPlay (37);
}
};
Symbol 752 MovieClip Frame 26
gotoAndPlay (2);
Symbol 752 MovieClip Frame 27
_root[("z" + /:pettipe) + "talk"].start();
Symbol 752 MovieClip Frame 36
gotoAndPlay (2);
Symbol 752 MovieClip Frame 46
gotoAndPlay (2);
Symbol 759 MovieClip Frame 13
Set("/:phead", 1);
stop();
Symbol 763 MovieClip Frame 1
onenterframe = function () {
gotoAndStop(/:phead);
};
Symbol 764 MovieClip Frame 14
gotoAndPlay (1);
Symbol 766 MovieClip Frame 21
gotoAndPlay (1);
Symbol 767 MovieClip Frame 20
stop();
Symbol 769 MovieClip Frame 13
stop();
Symbol 769 MovieClip Frame 26
stop();
Symbol 775 MovieClip Frame 15
stop();
Symbol 775 MovieClip Frame 16
h.gotoAndPlay("fin");
Symbol 775 MovieClip Frame 30
stop();
Symbol 776 MovieClip Frame 15
stop();
Symbol 776 MovieClip Frame 30
stop();
Symbol 787 MovieClip Frame 26
stop();
Symbol 787 MovieClip Frame 50
stop();
Symbol 800 MovieClip Frame 1
if (/:pdo == "drink") {
gotoAndStop (2);
} else {
stop();
}
Symbol 801 MovieClip Frame 10
_root[("z" + /:pettipe) + /:pdo].start(0, 10);
stop();
Symbol 801 MovieClip Frame 11
_root[("z" + /:pettipe) + /:pdo].stop();
Symbol 801 MovieClip Frame 20
stop();
Symbol 804 MovieClip Frame 7
stop();
Symbol 804 MovieClip Frame 13
stop();
Symbol 823 MovieClip Frame 17
stop();
Symbol 823 MovieClip Frame 40
stop();
Symbol 823 MovieClip Frame 41
stop();
Symbol 856 MovieClip Frame 26
stop();
Symbol 856 MovieClip Frame 50
stop();
Symbol 857 MovieClip Frame 19
stop();
stop();
Symbol 857 MovieClip Frame 29
stop();
Symbol 858 MovieClip [dog1] Frame 1
stop();
Symbol 862 MovieClip Frame 1
stop();
Symbol 863 MovieClip [popmessage] Frame 1
if (message eq "") {
d = 300;
m.gotoAndStop(5);
} else {
d = 160;
m.m = message;
}
Symbol 863 MovieClip [popmessage] Frame 8
d = d - 1;
Symbol 863 MovieClip [popmessage] Frame 9
if (d) {
prevFrame();
play();
}
Symbol 863 MovieClip [popmessage] Frame 17
removeMovieClip("");
stop();
Symbol 866 Button
on (release) {
Set("/:select", no);
}
Symbol 868 MovieClip Frame 1
onenterframe = function () {
if (/:select == ../:no) {
_visible = 1;
} else {
_visible = 0;
}
};
Symbol 870 MovieClip [namebutton] Frame 1
no = Number(substring(_name, 2, 3));
n = /:aname[no];
Symbol 878 Button
on (release) {
petdelete(/:select);
_root.gotoAndPlay("visit");
removeMovieClip("../");
}
Symbol 882 Button
on (release) {
_parent.gotoAndPlay("hide");
}
Symbol 902 MovieClip [popdelete] Frame 1
_root.but1.enabled = 0;
_root.but2.enabled = 0;
_root.but3.enabled = 0;
Symbol 902 MovieClip [popdelete] Frame 10
stop();
Symbol 902 MovieClip [popdelete] Frame 19
_root.but1.enabled = 1;
_root.but2.enabled = 1;
_root.but3.enabled = 1;
removeMovieClip("");
stop();
Symbol 906 MovieClip [treat] Frame 1
onenterframe = function () {
followmouse();
if (/:pdo eq "sit") {
if (_root.pet.hittest(_x, _y)) {
Set("/:treatnow", 1);
_root.ztreat.start();
less("/:happy", -10);
less("/:energy", -3);
removeMovieClip("");
}
}
};
Symbol 934 MovieClip [hand] Frame 1
onenterframe = function () {
_x = /:x;
_y = /:y;
if (/:hd == 2) {
_xscale = -100;
} else {
_xscale = 100;
}
if (_root.pet.hittest(_x, _y)) {
Set("/:beingpet", 1);
less("/:happy", -0.3);
gotoAndStop (2);
} else {
Set("/:beingpet", 0);
gotoAndStop (1);
}
};
Symbol 936 MovieClip [bone] Frame 1
yland = 460;
b.gotoAndStop(tipe);
Symbol 936 MovieClip [bone] Frame 2
gravity();
Symbol 936 MovieClip [bone] Frame 3
if (!fin) {
prevFrame();
play();
} else {
this._y = yland;
stop();
}
Symbol 940 MovieClip [bonedrag] Frame 1
onenterframe = function () {
oldx = _x;
oldy = _y;
followmouse();
};
onmousedown = function () {
if (!onmenu()) {
/:toy[tipe] = 2;
_root.attachMovie("bone", "bone", (2000 + (tipe * 100)) + 1);
var _local1 = _root.bone;
_local1._x = _x;
_local1._y = _y;
removeMovieClip("");
}
};
Symbol 946 MovieClip [frisbeedrag] Frame 1
onenterframe = function () {
oldx = _x;
oldy = _y;
followmouse();
if (_y > 330) {
_y = 330;
}
};
onmousedown = function () {
if (!onmenu()) {
Set("/:canpress", 0);
if (/:dogroom == /:room) {
/:toy[tipe] = 2;
}
_root.attachMovie("frisbee", "frisbee", (2000 + (tipe * 100)) + 1);
var _local1 = _root.frisbee;
_local1._x = _x;
_local1._y = _y;
_local1.tipe = tipe;
removeMovieClip("");
}
};
Symbol 952 MovieClip [frisbee] Frame 1
if (((/:pdo ne "eat") and (/:pdo ne "drink")) and (/:pdo ne "sleep")) {
Set("/:fin", 1);
}
xmax = /:xmax;
xmin = /:xmin;
if (_x > (/:xmin + (0.5 * /:screenwid))) {
xs = -/:frisbeespeed;
} else {
xs = /:frisbeespeed;
}
d = 10;
Symbol 952 MovieClip [frisbee] Frame 2
onenterframe = function () {
d--;
if (d == 0) {
Set("/:canpress", 1);
}
_x = (_x + xs);
if ((_x < (xmin - 30)) or (_x > (xmax + 30))) {
Set("/:fin", 1);
/:toy[tipe] = 0;
removeMovieClip("");
}
_y = (_y + 0.5);
};
stop();
Symbol 958 MovieClip [cardrag] Frame 1
onenterframe = function () {
oldx = _x;
oldy = _y;
followmouse();
};
onmousedown = function () {
var _local2 = _root;
if (!onmenu()) {
/:toy[tipe] = 2;
_local2.attachMovie("remote", "remote", (2000 + (tipe * 100)) + 2);
var _local1 = _local2.remote;
_local1._x = _x;
_local1._y = -100;
_local1.tipe = tipe;
_local2.attachMovie("car", "car", (2000 + (tipe * 100)) + 1);
_local1 = _local2.car;
_local1._x = _x;
_local1._y = _y + 10;
_local1.tipe = tipe;
removeMovieClip("");
}
};
Symbol 972 Button
on (release) {
Set("/:canpress", 1);
/:toy[tipe] = 0;
removeMovieClip("/car");
removeMovieClip("");
}
Symbol 974 Button
on (press) {
Set("/:cardir", -1);
_root.zrc1.start();
}
on (release, releaseOutside) {
Set("/:cardir", 0);
_root.zrc1.stop();
_root.zrc3.start();
}
Symbol 975 Button
on (press) {
Set("/:cardir", 1);
_root.zrc1.start();
}
on (release, releaseOutside) {
Set("/:cardir", 0);
_root.zrc1.stop();
_root.zrc3.start();
}
Symbol 978 MovieClip [remote] Frame 1
ontop = 1;
Set("/:cardir", 0);
Set("/:canpress", 0);
onenterframe = function () {
if (ontop) {
if (!z.hittest(/:x, /:y)) {
ontop = 0;
}
} else {
_x = (/:x + ((_x - /:x) / 1.2));
var _local1 = /:y;
if (_local1 > 300) {
_local1 = 300;
}
_y = (_local1 + ((_y - _local1) / 1.2));
dis = ((_x - /:x) * (_x - /:x)) + ((_y - _local1) * (_y - _local1));
if (dis < 400) {
ontop = 1;
}
}
};
Symbol 981 MovieClip [car] Frame 1
yland = /:ycar;
fin = 0;
Symbol 981 MovieClip [car] Frame 2
gravity();
Symbol 981 MovieClip [car] Frame 3
if (!fin) {
prevFrame();
play();
} else {
this._y = yland;
}
Symbol 981 MovieClip [car] Frame 6
bumper = 20;
xs = 0;
Symbol 981 MovieClip [car] Frame 7
nx = _x + xs;
if (/:cardir > 0) {
xs = xs + /:carspeed;
_xscale = 100;
} else if (/:cardir < 0) {
xs = xs - /:carspeed;
_xscale = -100;
}
xs = xs * 0.95;
if (xs < 0) {
if (nx < (/:xmin + bumper)) {
nx = /:xmin + bumper;
xs = -0.7 * xs;
if (math.abs(xs) > 4) {
_root.zbuk2.start();
}
}
} else if (xs > 0) {
if (nx > (/:xmax - bumper)) {
nx = /:xmax - bumper;
xs = -0.7 * xs;
if (math.abs(xs) > 4) {
_root.zbuk2.start();
}
}
}
_x = nx;
Symbol 981 MovieClip [car] Frame 8
prevFrame();
play();
Symbol 992 MovieClip Frame 1
stop();
Symbol 996 MovieClip Frame 1
stop();
Symbol 997 MovieClip Frame 1
onenterframe = function () {
food.gotoAndStop(1 + math.floor((100 - /:food) / 10));
};
Symbol 999 MovieClip Frame 1
onenterframe = function () {
water.gotoAndStop(1 + math.floor((100 - /:water) / 10));
};
Symbol 1001 MovieClip Frame 1
stop();
Symbol 1002 MovieClip [bowldrop] Frame 1
yland = 453;
b.gotoAndStop(tipe);
Symbol 1002 MovieClip [bowldrop] Frame 2
gravity();
Symbol 1002 MovieClip [bowldrop] Frame 3
if (!fin) {
prevFrame();
play();
} else {
this._y = yland;
b.gotoAndStop(tipe + 10);
if (tipe == 1) {
Set("/:food", 100);
}
if (tipe == 2) {
Set("/:water", 100);
}
stop();
}
Symbol 1005 MovieClip [ball] Frame 1
onenterframe = function () {
var _local1 = _root;
if (!drag) {
if (vx == 0) {
vx = 10;
}
nx = _x + vx;
if (nx < (xmin + radius)) {
vx = (-vx) * damp;
nx = xmin + radius;
if (math.abs(vx) > 6) {
_local1.zbuk.start();
}
} else if (nx > (xmax - radius)) {
vx = (-vx) * damp;
nx = xmax - radius;
if (math.abs(vx) > 6) {
_local1.zbuk.start();
}
}
_x = nx;
vy = vy + (/:grav / 10);
ny = _y + (vy / 10);
if (ny > yland) {
ny = yland;
vy = -0.5 * vy;
vx = vx * 0.95;
if (vy < -30) {
_local1.zbuk.start();
}
}
_y = ny;
b._rotation = b._rotation + (vx * 3);
} else {
oldx = _x;
oldy = _y;
}
};
xmax = /:xmax;
xmin = /:xmin;
drag = 0;
damp = 0.8;
yland = /:yball;
radius = 12;
Symbol 1011 MovieClip [balldrag] Frame 1
onenterframe = function () {
oldx = _x;
oldy = _y;
followmouse();
};
onmousedown = function () {
if (!onmenu()) {
/:toy[tipe] = 2;
_root.attachMovie("ball", "ball", (2000 + (tipe * 100)) + 1);
var _local1 = _root.ball;
_local1._x = _x;
_local1._y = _y;
_local1.vx = _x - oldx;
_local1.vy = 5 * (_y - oldy);
removeMovieClip("");
}
};
Symbol 1020 MovieClip Frame 1
stop();
Symbol 1021 MovieClip [bowlsdrag] Frame 1
onenterframe = function () {
followmouse();
};
onmousedown = function () {
var _local1 = _root;
if (!onmenu()) {
/:out[tipe] = 2;
_local1.attachMovie("bowldrop", "bowl" + tipe, (1000 + (tipe * 100)) + 1);
_local1["bowl" + tipe]._x = _x;
_local1["bowl" + tipe]._y = _y;
_local1["bowl" + tipe].tipe = tipe;
removeMovieClip("");
}
};
b.gotoAndStop(tipe);
Symbol 1024 Button
on (release) {
savegame();
resetxpos();
clrscr();
_root.gotoAndPlay("menu");
removeMovieClip("../");
}
Symbol 1035 MovieClip [popexit] Frame 1
Set("/:canpress", 0);
Symbol 1035 MovieClip [popexit] Frame 10
stop();
Symbol 1035 MovieClip [popexit] Frame 19
Set("/:canpress", 1);
removeMovieClip("");
stop();
Symbol 1041 MovieClip Frame 1
onenterframe = function () {
b._xscale = /:persen;
};
Symbol 1053 MovieClip Frame 1
stop();
Symbol 1070 Button
on (release) {
gotoAndStop (25);
}
Symbol 1083 Button
on (release) {
gotoAndStop (52);
}
Symbol 1085 Button
on (release) {
gotoAndStop (51);
}
Symbol 1093 Button
on (release) {
gotoAndPlay (38);
}
Symbol 1094 Button
on (release) {
if (/:aname.length >= /:maxpets) {
gotoAndStop (44);
} else {
gotoAndStop (52);
}
}
Symbol 1095 Button
on (release) {
if (/:aname.length >= /:maxpets) {
gotoAndStop (44);
} else {
gotoAndStop (51);
}
}
Symbol 1099 Button
on (release) {
popdelete(/:select);
}
Symbol 1101 Button
on (release) {
gotoAndPlay (25);
}
Symbol 1103 Button
on (release) {
if (/:select ne "") {
Set("/:idx", /:select);
Set("/:name", /:aname[/:idx]);
Set("/:mypet", /:amypet[/:idx]);
Set("/:bday", /:abday[/:idx]);
Set("/:lastvisit", /:alastvisit[/:idx]);
Set("/:energy", /:aenergy[/:idx]);
Set("/:sleep", /:asleep[/:idx]);
Set("/:happy", /:ahappy[/:idx]);
Set("/:thirst", /:athirst[/:idx]);
Set("/:learn", /:alearn[/:idx]);
Set("/:talk", /:atalk[/:idx]);
gotoAndPlay (67);
}
}
Symbol 1104 MovieClip Frame 1
spacing = 32;
y = 15;
var i = 0;
while (i < /:aname.length) {
attachMovie("namebutton", "n" + i, i);
this["n" + i]._y = y + (i * spacing);
i++;
}
stop();
Symbol 1105 MovieClip Frame 2
if (n._height > /:mhei) {
this.setmask(_root.m);
onenterframe = function () {
y = _ymouse;
ys = 10;
range = 60;
if (math.abs(_xmouse) < 200) {
if ((y > -50) and (y < range)) {
n._y = n._y + (ys * ((range - y) / range));
if (n._y > 0) {
n._y = 0;
}
} else if ((y > (/:mhei - range)) and (y < (/:mhei + 50))) {
n._y = n._y - (ys * ((range - (/:mhei - y)) / range));
if (n._y < (-(n._height - /:mhei))) {
n._y = -(n._height - /:mhei);
}
}
}
};
}
Symbol 1109 Button
on (release) {
gotoAndPlay (25);
}
Symbol 1121 Button
on (release) {
if ((select ne "") and (name ne "")) {
Set("/:name", (substring(/:name.toUpperCase(), 1, 1)) + /:name.slice(1));
petcreate(/:name, /:select);
Set("/:firsttime", 1);
gotoAndPlay (60);
}
}
Symbol 1123 Button
on (release) {
Set("/:select", no);
}
Symbol 1125 MovieClip Frame 1
onenterframe = function () {
if (/:select == ../:no) {
_visible = 1;
} else {
_visible = 0;
}
};
Symbol 1126 MovieClip Frame 1
no = Number(substring(_name, 2, 3));
n = /:name[no];
Symbol 1138 Button
on (release) {
gotoAndPlay (67);
}
Symbol 1166 Button
on (release) {
gotoAndPlay (76);
}
Symbol 1169 MovieClip Frame 1
happy = [];
upset = [];
happy.push("[n] has been really easy to take care of since your last visit. You have a happy pet. That means you're doing a great job as a pet owner! Give [n] a treat today as a reward for being so well behaved.");
happy.push("[n] is healthy and happy and ready to go! You must be a wonderful pet owner. Keep up the good work!");
happy.push("[n] has been looking out the windows, waiting for you to arrive. I'd say you and [n] have become really good friends and a good friend deserves a reward, like playtime or a treat!");
happy.push("[n] has been waiting at the door for you. Only a really good pet owner gets that kind of devotion. Give yourself-and [n]-a pat on the back as a reward!");
upset.push("While you were away, a thunderstorm upset your pet. It was very loud! [n] will probably need some extra cuddling today.");
upset.push("Your pet slept almost the whole time you were gone. [n] isn't getting enough attention and seems bored. Try spending more time playing with [n] today.");
upset.push("[n] was a bit naughty while you were gone. Remember that you have to keep up your playtimes and training sessions or [n] may fall back into bad habits.");
upset.push("[n] has been very quiet lately. I think [n] missed you. Give your pet a good workout today, and use different toys to keep [n] interested.");
upset.push("Most pets, including [n], like to be stroked. It makes them feel happy and loved. So don't forget to pet your pet!");
if (!/:firsttime) {
if (/:happy > 30) {
var ta = happy[random(happy.length)];
} else {
var ta = upset[random(upset.length)];
}
t = ta.getReplaced("[n]", /:name);
createTextField("tf", 10, -159, -54, 355, 156);
tf.text = t;
tf.embedFonts = true;
tf.wordWrap = true;
tf.border = false;
tf.selectable = false;
fnt = new TextFormat();
fnt.size = 20;
fnt.font = "Libel Suit";
fnt.color = 12145190 /* 0xB95226 */;
fnt.bold = 1;
tf.setTextFormat(fnt);
stop();
} else {
Set("/:firsttime", 0);
ta = "Your new pet isn't going to behave perfectly right away. You will have to be patient and spend time training [n]. It's natural for a pet to misbehave now and then, just remember to praise [n] after a good trick and scold [n] after something naughty.";
t = ta.getReplaced("[n]", /:name);
createTextField("tf", 10, -163, -89, 357, 318);
tf.text = t;
tf.embedFonts = true;
tf.wordWrap = true;
tf.border = false;
tf.selectable = false;
fnt = new TextFormat();
fnt.size = 20;
fnt.font = "Libel Suit";
fnt.color = 12145190 /* 0xB95226 */;
fnt.bold = 1;
tf.setTextFormat(fnt);
gotoAndStop (2);
}
Symbol 1189 MovieClip Frame 11
gotoAndPlay (1);
Symbol 1226 MovieClip Frame 50
stop();
Symbol 1227 MovieClip Frame 156
d = 250 + random(250);
Symbol 1227 MovieClip Frame 157
d = d - 1;
Symbol 1227 MovieClip Frame 158
if (d) {
prevFrame();
play();
} else {
gotoAndPlay (1);
}
Symbol 1230 MovieClip Frame 35
gotoAndPlay (1);
Symbol 1233 MovieClip Frame 1
xs = 0.55 + (random(10) * 0.1);
setProperty("b", _y , random(100));
sk = 50 + random(50);
b._xscale = sk;
b._yscale = sk;
Symbol 1233 MovieClip Frame 2
b._x = b._x - xs;
Symbol 1233 MovieClip Frame 3
if (getProperty("b", _x) > -740) {
prevFrame();
play();
}
Symbol 1233 MovieClip Frame 5
gotoAndPlay (1);
Symbol 1235 Button
on (rollOver) {
getURL ("http://www.minikperi.com", "_blank");
}
Symbol 1237 MovieClip Frame 1
onenterframe = function () {
t = _root[substring(_name, 2, 100)];
if (t._visible) {
_visible = 1;
dis = int(_y - t._y);
if (dis > 100) {
_alpha = 0;
} else {
_alpha = (100 - dis);
}
_x = t._x;
} else {
_visible = 0;
}
};
Symbol 1239 MovieClip Frame 1
onenterframe = function () {
var _local1 = _root.pet;
_x = _local1._x;
dis = int(_y - _local1._y);
if (dis > 100) {
_alpha = 0;
} else {
_alpha = (100 - dis);
}
_x = _local1._x;
};
Symbol 1240 MovieClip Frame 1
d = 40 + random(40);
Symbol 1240 MovieClip Frame 2
d = d - 1;
Symbol 1240 MovieClip Frame 3
if (d > 0) {
prevFrame();
play();
} else if ((/:talk < 3) and (/:happy < 30)) {
if (((random(100) > 50) and (/:pdo eq "sit")) or (/:pdo eq "stand")) {
Set("/:talknow", 2);
_root.patty.naughty = "talk";
gotoAndPlay (7);
} else {
gotoAndPlay (1);
}
} else {
gotoAndPlay (1);
}
Symbol 1240 MovieClip Frame 11
d = 100;
click = 0;
Symbol 1240 MovieClip Frame 12
d = d - 1;
if (click == 9) {
Set("/:talk", /:talk + 1);
d = 0;
}
Symbol 1240 MovieClip Frame 13
if (d > 0) {
prevFrame();
play();
} else {
click = 0;
gotoAndPlay (1);
}
Symbol 1241 MovieClip Frame 1
onenterframe = function () {
Set("/:x", _root._xmouse);
Set("/:y", _root._ymouse);
};
var p = _root.pet;
Symbol 1241 MovieClip Frame 2
if (!begin) {
begin = 1;
xs = /:runspeed;
sd = 1;
Set("/:hd", 1);
p.gotoAndStop("run" + /:hd);
targ = 150;
Set("/:fin", 0);
gotoAndPlay (18);
} else {
call("cek");
}
Symbol 1241 MovieClip Frame 5
p.gotoAndStop(/:pdo + /:hd);
if ((/:pdo == "sleep") and (/:sleep < 50)) {
Set("/:wait", (100 - /:sleep) * 3);
} else {
Set("/:wait", 50 + random(50));
}
Symbol 1241 MovieClip Frame 6
cekvital();
Set("/:wait", /:wait - 1);
less("/:energy", 0.005);
less("/:thirst", 0.005);
less("/:happy", 0.1);
if (/:pdo == "sleep") {
less("/:sleep", -0.3);
} else {
less("/:sleep", 0.01);
}
if (/:wait < 0) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 7
if (/:fin) {
if (/:pdo == "sit") {
p.g.gotoAndPlay("finsit");
Set("/:wait", 23);
gotoAndPlay (230);
} else if (/:pdo == "sleep") {
p.g.gotoAndPlay("fin");
Set("/:wait", 24);
gotoAndPlay (230);
} else {
call("cek");
}
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 9
if (p._x > /:screenwid) {
Set("/:dogroom", 2);
Set("/:dxmin", /:screenwid + 100);
Set("/:dxmax", (/:screenwid + 100) + /:screenwid);
} else if (p._x < 0) {
Set("/:dogroom", 0);
Set("/:dxmin", -100 - /:screenwid);
Set("/:dxmax", -100);
} else {
Set("/:dogroom", 1);
Set("/:dxmin", 0);
Set("/:dxmax", /:screenwid);
}
Set("/:prev", /:pdo);
Set("/:fin", 0);
savegame();
if ((/:naughty[/:dogroom] ne "") and (random(100) > 50)) {
if (((/:learn[/:dogroom] < 3) and (/:happy < 30)) and (/:prev ne /:naughty[/:dogroom])) {
Set("/:todo", /:naughty[/:dogroom]);
}
}
if (/:todo ne "") {
op = [];
op.push(/:todo);
Set("/:todo", "");
} else {
op = [];
if (/:toy[3] == 2) {
op.push("toy3");
} else {
var i = 1;
while (i <= /:toy.length) {
if (/:toy[i] == 2) {
op.push("toy" + i);
}
i++;
}
}
if (op.length == 0) {
op = ["wander", "sit", "stand"];
}
if (/:sleep < /:sleeplow) {
op = ["sleep"];
}
if (/:energy < /:energylow) {
if (/:food > 0) {
op = ["eat"];
} else {
call("ceksleep");
}
}
if ((/:thirst < /:thirstlow) and (op[0] ne "eat")) {
if (/:water > 0) {
op = ["drink"];
} else {
call("ceksleep");
}
}
}
op.randomize();
Set("/:pdo", op.pop());
while ((/:pdo eq /:prev) and (op.length > 0)) {
Set("/:pdo", op.pop());
}
if (((/:pdo eq "sleep") or (/:pdo eq "sit")) or (/:pdo eq "stand")) {
gotoAndPlay (5);
} else if ((substring(/:pdo, 1, 3)) == "toy") {
gotoAndPlay(/:pettipe + /:pdo);
} else {
gotoAndPlay(/:pdo);
}
Symbol 1241 MovieClip Frame 17
if ((/:energy > /:energylow) and (/:thirst > /:thirstlow)) {
xs = /:runspeed;
tipe = "run";
} else {
xs = /:walkspeed;
tipe = "walk";
}
var right = ((/:dxmax - p._x) - /:bumper);
var left = ((p._x - /:dxmin) - /:bumper);
ran = [];
if (right > 200) {
ran.push("right");
}
if (left > 200) {
ran.push("left");
}
if (ran.length > 1) {
if (right > left) {
ran.push("right");
} else {
ran.push("left");
}
}
ran.randomize();
direction = ran.pop();
if (tipe eq "run") {
if (direction eq "left") {
targ = (p._x - 200) - random(left - 200);
} else {
targ = (p._x + 200) + random(right - 200);
}
} else if (direction eq "left") {
targ = (p._x - 100) - random(100);
} else {
targ = (p._x + 100) + random(100);
}
if ((targ > -100) and (targ < 0)) {
if (/:dogroom < 1) {
targ = -100 - /:bumper;
} else {
targ = /:bumper;
}
} else if ((targ > /:screenwid) and (targ < (/:screenwid + 100))) {
if (/:dogroom > 1) {
targ = (/:screenwid + 100) + /:bumper;
} else {
targ = /:screenwid - /:bumper;
}
}
if (p._x > targ) {
Set("/:hd", 2);
sd = -1;
} else {
Set("/:hd", 1);
sd = 1;
}
p.gotoAndStop(tipe + /:hd);
Symbol 1241 MovieClip Frame 18
less("/:energy", 0.01 * xs);
less("/:thirst", 0.01 * xs);
less("/:happy", 0.02 * (/:runspeed / xs));
less("/:sleep", 0.05);
nx = p._x + (xs * sd);
if (((sd > 0) and (nx > targ)) or ((sd < 0) and (nx < targ))) {
nx = targ;
Set("/:fin", 1);
}
p._x = nx;
Symbol 1241 MovieClip Frame 19
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 24
Set("/:fin", 0);
xs = /:walkspeed;
item = "bowl1";
var it = _root[item];
range = 50;
call("targeting");
p.gotoAndStop("walk" + /:hd);
Symbol 1241 MovieClip Frame 25
call("move");
if (!it._visible) {
Set("/:wait", 1);
gotoAndPlay (230);
}
Symbol 1241 MovieClip Frame 26
if (!/:fin) {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 27
if (it._x < p._x) {
Set("/:hd", 2);
} else {
Set("/:hd", 1);
}
p.gotoAndStop("eat" + /:hd);
Set("/:wait", 2500);
Set("/:fin", 0);
Symbol 1241 MovieClip Frame 28
less("/:happy", -0.1);
Set("/:wait", /:wait - 1);
if (/:wait < 0) {
Set("/:fin", 1);
}
if (/:pdo eq "eat") {
less("/:energy", -0.4);
Set("/:food", /:food - 0.5);
if (/:food <= 0) {
Set("/:food", 0);
Set("/:fin", 1);
}
}
if (/:pdo eq "drink") {
less("/:thirst", -0.4);
Set("/:water", /:water - 0.5);
if (/:water <= 0) {
Set("/:water", 0);
Set("/:fin", 1);
}
}
Symbol 1241 MovieClip Frame 29
if (/:fin) {
p.g.gotoAndPlay("fineat");
Set("/:wait", 15);
gotoAndPlay (230);
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 33
Set("/:fin", 0);
xs = /:walkspeed;
item = "bowl2";
var it = _root[item];
range = 50;
call("targeting");
p.gotoAndStop("walk" + /:hd);
gotoAndPlay (25);
Symbol 1241 MovieClip Frame 40
Set("/:fin", 0);
if ((/:energy > /:energylow) and (/:thirst > /:thirstlow)) {
xs = /:runspeed;
tipe = "run";
} else {
xs = /:walkspeed;
tipe = "walk";
}
item = "sofa";
var it = _root[item];
range = 0;
call("targeting");
p.gotoAndStop(tipe + /:hd);
Symbol 1241 MovieClip Frame 41
call("move2");
Symbol 1241 MovieClip Frame 42
if (math.abs(p._x - targ) > 20) {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 43
p.gotoAndStop("sofa" + /:hd);
playtime = 0;
playenough = /:naughtydelay;
_root.naught.gotoAndPlay(2);
vy = -300;
yland = getProperty("/sofa", _y);
yland2 = p._y;
next = 0;
Set("/:canpress", 0);
Symbol 1241 MovieClip Frame 44
less("/:energy", 0.005);
less("/:thirst", 0.005);
vy = vy + (/:grav / 20);
ny = p._y + (vy / 10);
if ((vy > 0) and (ny > yland)) {
ny = yland;
vy = 0;
next = 1;
}
p._y = ny;
Symbol 1241 MovieClip Frame 45
if (!next) {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 46
Set("/:canpress", 1);
Set("/:fin", 0);
_root.patty.naughty = "sofa";
Symbol 1241 MovieClip Frame 47
less("/:energy", 0.005);
less("/:thirst", 0.005);
playtime = playtime + 1;
if (playtime > playenough) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 48
if (/:fin) {
p.g.gotoAndPlay("fin");
vy = 2;
Set("/:canpress", 0);
Set("/:fin", 0);
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 49
vy = vy + (/:grav / 20);
ny = p._y + (vy / 10);
if (ny > yland2) {
ny = yland2;
Set("/:fin", 1);
}
p._y = ny;
Symbol 1241 MovieClip Frame 50
if (/:fin) {
p._y = yland2;
Set("/:canpress", 1);
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 57
Set("/:fin", 0);
if ((/:energy > /:energylow) and (/:thirst > /:thirstlow)) {
xs = /:runspeed;
tipe = "run";
} else {
xs = /:walkspeed;
tipe = "walk";
}
item = "sofaleg";
var it = _root[item];
range = 50;
call("targeting");
p.gotoAndStop(tipe + /:hd);
Symbol 1241 MovieClip Frame 58
call("move");
Symbol 1241 MovieClip Frame 59
if (!/:fin) {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 60
if (it._x < p._x) {
Set("/:hd", 2);
} else {
Set("/:hd", 1);
}
p.gotoAndStop("scratch" + /:hd);
playtime = 0;
playenough = 1.5 * /:naughtydelay;
_root.naught.gotoAndPlay(2);
Set("/:fin", 0);
Symbol 1241 MovieClip Frame 61
less("/:energy", 0.005);
less("/:thirst", 0.005);
playtime = playtime + 1;
if (playtime == 30) {
_root.patty.naughty = "scratch";
}
if (playtime > playenough) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 62
if (/:fin) {
p.g.gotoAndPlay("fin");
Set("/:wait", 15);
gotoAndPlay (230);
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 66
item = "ball";
xs = /:runspeed;
var it = _root[item];
range = 0;
closedis = 60;
playtime = 0;
playenough = 400 + random(200);
Set("/:fin", 0);
Symbol 1241 MovieClip Frame 67
call("targeting");
call("move2");
p.gotoAndStop("run" + /:hd);
less("/:happy", -0.15);
playtime = playtime + 1;
if ((playtime > playenough) or (/:toy[1] != 2)) {
Set("/:fin", 1);
}
if ((it._y > (/:yball - 7)) and math.abs(it.vx < 1)) {
dis = p._x - it._x;
if (math.abs(dis) < closedis) {
gotoAndPlay (74);
}
}
Symbol 1241 MovieClip Frame 68
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 74
if (it._x > p._x) {
Set("/:hd", 1);
} else {
Set("/:hd", 2);
}
p.gotoAndStop("yarn" + /:hd);
d = 40;
Symbol 1241 MovieClip Frame 75
less("/:happy", -0.15);
d = d - 1;
if (d == 20) {
it.vy = -150 - random(100);
it.vx = ((-dis) / 2) - random(10);
if (math.abs(it.vx) < 10) {
if (it.vx < 0) {
it.vx = -10;
} else if (it.vx > 0) {
it.vx = 10;
}
}
}
Symbol 1241 MovieClip Frame 76
if (d) {
prevFrame();
play();
} else {
gotoAndPlay (67);
}
Symbol 1241 MovieClip Frame 82
item = "wb";
xs = /:runspeed;
var it = _root[item];
range = 40;
Set("/:fin", 0);
call("targeting");
Symbol 1241 MovieClip Frame 83
call("move2");
p.gotoAndStop("run" + /:hd);
less("/:happy", -0.15);
if (/:toy[2] != 2) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 84
if (math.abs(p._x - targ) > 5) {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 87
if (it._x > p._x) {
Set("/:hd", 1);
it.w.b._xscale = -100;
} else {
Set("/:hd", 2);
it.w.b._xscale = 100;
}
p.gotoAndStop("whack" + /:hd);
playtime = 0;
playenough = 400 + random(200);
Symbol 1241 MovieClip Frame 89
d = 60;
p.g.h.gotoAndPlay(2);
Symbol 1241 MovieClip Frame 90
less("/:happy", -0.15);
d = d - 1;
if (d == 52) {
it.w.b.b.gotoAndPlay(2);
}
playtime = playtime + 1;
if ((playtime > playenough) or (/:toy[2] != 2)) {
Set("/:fin", 1);
}
if (/:fin) {
/:toy[2] = 0;
it.removeMovieClip();
p.g.gotoAndPlay("fin");
Set("/:wait", 15);
gotoAndPlay (230);
}
Symbol 1241 MovieClip Frame 91
if (d) {
prevFrame();
play();
} else {
gotoAndPlay (89);
}
Symbol 1241 MovieClip Frame 98
xs = /:runspeed;
var it = _root.fishing.ball;
closedis = 80;
Set("/:fin", 0);
yland = p._y;
Symbol 1241 MovieClip Frame 99
targ = it._x;
if (targ > (/:dxmax - /:bumper)) {
targ = /:dxmax - /:bumper;
} else if (targ < (/:dxmin + /:bumper)) {
targ = /:dxmin + /:bumper;
}
if (p._x > targ) {
Set("/:hd", 2);
sd = -1;
} else {
Set("/:hd", 1);
sd = 1;
}
call("move2");
p.gotoAndStop("run" + /:hd);
if (math.abs(targ - p._x) < closedis) {
gotoAndPlay (103);
}
less("/:happy", -0.01);
if (/:toy[3] != 2) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 100
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 103
got = 0;
fall = 0;
div = 330 - it._y;
if (div > 50) {
div = 50;
}
vy = -220 - div;
p._y = yland - 1;
p.gotoAndStop("fishing" + /:hd);
if (/:hd == 1) {
xs = 0.5 * /:runspeed;
} else {
xs = -0.5 * /:runspeed;
}
Symbol 1241 MovieClip Frame 104
less("/:energy", 0.05);
less("/:thirst", 0.05);
nx = p._x + xs;
if (nx > (/:dxmax - /:bumper)) {
nx = /:dxmax - /:bumper;
} else if (nx < (/:dxmin + /:bumper)) {
nx = /:dxmin + /:bumper;
}
vy = vy + (/:grav / 20);
if ((vy > 0) and (!fall)) {
fall = 1;
p.g.gotoAndPlay("fin");
}
ny = p._y + (vy / 10);
if (ny > yland) {
ny = yland;
}
p._y = ny;
p._x = nx;
if (p.g.foot.hittest(_root.fishing.ball)) {
less("/:happy", -5);
if (p._x > _root.fishing.ball._x) {
_root.fishing.vx = _root.fishing.vx - 10;
_root.fishing.vy = _root.fishing.vy - 15;
} else {
_root.fishing.vx = _root.fishing.vx + 10;
_root.fishing.vy = _root.fishing.vy - 15;
}
if (sque <= 0) {
var sque = 30;
_root.zsqueek.start();
}
got = 1;
}
sque--;
Symbol 1241 MovieClip Frame 105
if (p._y != yland) {
prevFrame();
play();
} else {
p.gotoAndStop("stand" + /:hd);
gotoAndPlay (1);
}
Symbol 1241 MovieClip Frame 113
item = "mous";
xs = /:runspeed;
var it = _root[item];
range = 0;
lam = 0;
playtime = 0;
playenough = 300 + random(200);
Set("/:fin", 0);
Symbol 1241 MovieClip Frame 114
call("targeting");
call("move2");
p.gotoAndStop("run" + /:hd);
less("/:happy", -0.15);
playtime = playtime + 1;
if ((playtime > playenough) or (/:toy[4] != 2)) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 115
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 122
gotoAndPlay (199);
Symbol 1241 MovieClip Frame 132
item = "ball";
xs = /:runspeed;
var it = _root[item];
range = 0;
closedis = 50;
playtime = 0;
playenough = 400 + random(200);
Set("/:fin", 0);
Symbol 1241 MovieClip Frame 133
call("targeting");
call("move2");
p.gotoAndStop("run" + /:hd);
if (it._y > (/:yball - 2)) {
dis = p._x - it._x;
if (math.abs(dis) < closedis) {
Set("/:phead", 2);
it.vy = -300 - random(300);
it.vx = ((-dis) / 2) - random(10);
if (math.abs(it.vx) < 10) {
if (it.vx < 0) {
it.vx = -10;
} else if (it.vx > 0) {
it.vx = 10;
}
}
}
}
less("/:happy", -0.15);
playtime = playtime + 1;
if ((playtime > playenough) or (/:toy[1] != 2)) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 134
if (/:fin) {
Set("/:phead", 1);
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 141
Set("/:fin", 0);
xs = /:runspeed;
item = "bone";
var it = _root[item];
range = 50;
call("targeting");
_root.pet.gotoAndStop("run" + /:hd);
Symbol 1241 MovieClip Frame 142
call("move2");
if (/:toy[2] != 2) {
Set("/:wait", 1);
gotoAndPlay (230);
}
Symbol 1241 MovieClip Frame 143
if (math.abs(p._x - targ) > 5) {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 144
if (it._x < p._x) {
Set("/:hd", 2);
} else {
Set("/:hd", 1);
}
p.gotoAndStop("bone" + /:hd);
playtime = 0;
playenough = 300 + random(100);
boneout = 26;
Set("/:fin", 0);
Symbol 1241 MovieClip Frame 145
less("/:energy", 0.005);
less("/:thirst", 0.005);
less("/:happy", -0.1);
playtime = playtime + 1;
if ((playtime > playenough) or (/:toy[2] != 2)) {
Set("/:fin", 1);
}
if (playtime == boneout) {
it._visible = 0;
}
Symbol 1241 MovieClip Frame 146
if (/:fin) {
/:toy[2] = 0;
p.g.gotoAndPlay("fin");
Set("/:wait", 15);
gotoAndPlay (230);
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 152
item = "frisbee";
xs = /:runspeed;
var it = _root[item];
range = 0;
closedis = 50;
fx = it._x;
call("targeting");
p.gotoAndStop("run" + /:hd);
Set("/:fin", 0);
yland = p._y;
Symbol 1241 MovieClip Frame 153
if ((it._x - fx) > 0) {
fx = 1;
} else {
fx = -1;
}
Symbol 1241 MovieClip Frame 154
targ = it._x;
if (targ > (/:dxmax - /:bumper)) {
targ = /:dxmax - /:bumper;
} else if (targ < (/:dxmin + /:bumper)) {
targ = /:dxmin + /:bumper;
}
if (p._x > targ) {
Set("/:hd", 2);
sd = -1;
} else {
Set("/:hd", 1);
sd = 1;
}
call("move2");
p.gotoAndStop("run" + /:hd);
if (fx > 0) {
if (((p._x > it._x) and ((p._x - it._x) < 150)) and ((p._x - it._x) > 130)) {
Set("/:hd", 2);
gotoAndPlay (157);
}
} else if (((p._x < it._x) and ((it._x - p._x) < 150)) and ((it._x - p._x) > 130)) {
Set("/:hd", 1);
gotoAndPlay (157);
}
less("/:happy", -0.01);
if (/:toy[3] != 2) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 155
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 157
got = 0;
less("/:energy", 3);
less("/:thirst", 3);
div = 330 - it._y;
if (div > 50) {
div = 50;
}
vy = -200 - div;
p._y = yland - 1;
p.gotoAndStop("frisbee" + /:hd);
if (/:hd == 1) {
xs = 0.5 * /:runspeed;
} else {
xs = -0.5 * /:runspeed;
}
Symbol 1241 MovieClip Frame 158
less("/:energy", 0.01 * xs);
less("/:thirst", 0.01 * xs);
nx = p._x + xs;
if (nx > (/:dxmax - /:bumper)) {
nx = /:dxmax - /:bumper;
} else if (nx < (/:dxmin + /:bumper)) {
nx = /:dxmin + /:bumper;
}
vy = vy + (/:grav / 20);
ny = p._y + (vy / 10);
if (ny > yland) {
ny = yland;
}
p._y = ny;
p._x = nx;
if (p.g.head.hittest(it)) {
less("/:happy", -10);
got = 1;
Set("/:phead", 3);
_root.zgotfrisbee.start();
removeMovieClip(it);
}
Symbol 1241 MovieClip Frame 159
if (p._y != yland) {
prevFrame();
play();
} else {
Set("/:phead", 1);
if (got) {
p.g.gotoAndPlay("got");
Set("/:wait", 45);
/:toy[3] = 0;
gotoAndPlay (230);
} else {
p.g.gotoAndPlay("nogot");
}
}
Symbol 1241 MovieClip Frame 161
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 167
item = "car";
xs = /:runspeed;
var it = _root[item];
range = 0;
closedis = 100;
lam = 0;
playtime = 0;
playenough = 400 + random(200);
Set("/:fin", 0);
Symbol 1241 MovieClip Frame 168
call("targeting");
call("move2");
p.gotoAndStop("run" + /:hd);
dis = p._x - it._x;
itspeed = it._x - olditx;
olditx = it._x;
if (math.abs(itspeed) < 2) {
if (math.abs(dis) < closedis) {
gotoAndPlay (172);
}
}
less("/:happy", -0.15);
playtime = playtime + 1;
if ((playtime > playenough) or (/:toy[4] != 2)) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 169
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 172
p.gotoAndStop("car" + /:hd);
less("/:energy", 5);
less("/:thirst", 5);
less("/:happy", -0.05);
Symbol 1241 MovieClip Frame 184
dis = p._x - it._x;
if (math.abs(dis) > closedis) {
p.g.gotoAndPlay("fincar");
gotoAndPlay (186);
}
playtime = playtime + 5;
if ((playtime > playenough) or (/:toy[4] != 2)) {
Set("/:fin", 1);
}
Symbol 1241 MovieClip Frame 185
if (/:fin) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 195
gotoAndPlay (168);
Symbol 1241 MovieClip Frame 199
Set("/:fin", 0);
if ((/:energy > /:energylow) and (/:thirst > /:thirstlow)) {
xs = /:runspeed;
tipe = "run";
} else {
xs = /:walkspeed;
tipe = "walk";
}
item = "tv";
var it = _root[item];
range = 0;
call("targeting");
_root.pet.gotoAndStop(tipe + /:hd);
Symbol 1241 MovieClip Frame 200
call("move2");
Symbol 1241 MovieClip Frame 201
if (math.abs(p._x - targ) > 20) {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 202
_root.pet.gotoAndStop("tv" + /:hd);
playtime = 0;
playenough = 140;
Symbol 1241 MovieClip Frame 203
less("/:energy", 0.005);
less("/:thirst", 0.005);
less("/:happy", 0.05);
playtime = playtime + 1;
if ((playtime > playenough) or (/:toy[5] != 2)) {
Set("/:fin", 1);
_root.tv.t.gotoAndStop(1);
/:toy[5] = 0;
}
Symbol 1241 MovieClip Frame 204
if (/:fin) {
p.g.gotoAndPlay("fin");
Set("/:wait", 15);
gotoAndPlay (230);
} else {
prevFrame();
play();
}
Symbol 1241 MovieClip Frame 213
dis = it._x - p._x;
if (math.abs(dis) < range) {
if (dis > 0) {
targ = it._x + range;
if (targ > (/:dxmax - /:bumper)) {
targ = it._x - range;
}
} else {
targ = it._x - range;
if (targ < (/:dxmin + /:bumper)) {
targ = it._x + range;
}
}
} else if (dis > 0) {
targ = it._x - range;
} else {
targ = it._x + range;
}
if (p._x > targ) {
Set("/:hd", 2);
sd = -1;
} else {
Set("/:hd", 1);
sd = 1;
}
Symbol 1241 MovieClip Frame 217
op = ["sit", "sit", "sit", "sleep", "sleep", "sleep", "wander"];
if ((/:sleep > /:sleeplow) or (/:prev eq "sleep")) {
if ((/:prev eq "sit") or (/:prev eq "sleep")) {
op = ["wander", "stand"];
} else {
op = ["sit", "sit", "sit", "sleep", "sleep", "sleep", "wander"];
}
} else {
op = ["sleep"];
}
Symbol 1241 MovieClip Frame 220
less("/:energy", 0.01 * xs);
less("/:thirst", 0.01 * xs);
less("/:happy", 0.02);
less("/:sleep", 0.07);
nx = p._x + (xs * sd);
if (((sd > 0) and (nx > targ)) or ((sd < 0) and (nx < targ))) {
nx = targ;
}
p._x = nx;
Symbol 1241 MovieClip Frame 230
Set("/:wait", /:wait - 1);
Symbol 1241 MovieClip Frame 231
if (/:wait <= 0) {
call("cek");
} else {
prevFrame();
play();
}
Symbol 1242 MovieClip Frame 1
onenterframe = function () {
if (/:happy < 3) {
unhappy = unhappy + 1;
if (unhappy > 2000) {
Set("/:talk", 0);
var i = 0;
while (i < /:learn.length) {
/:learn[i] = 0;
i++;
}
unhappy = 0;
}
} else {
unhappy = 0;
}
if ((/:energy < 20) or (/:thirst < 20)) {
hungry = hungry + 1;
if (hungry > 750) {
Set("/:talk", 0);
hungry = 0;
}
} else {
hungry = 0;
}
};
stop();
Symbol 1242 MovieClip Frame 2
d = /:naughtydelay + 100;
click = 0;
Symbol 1242 MovieClip Frame 3
d = d - 1;
if (click == 9) {
/:learn[/:dogroom] = /:learn[/:dogroom] + 1;
d = 0;
}
Symbol 1242 MovieClip Frame 4
if (d > 0) {
prevFrame();
play();
} else {
click = 0;
stop();
}
Symbol 1250 MovieClip Frame 1
duplicateMovieClip ("pic", "pic2", 16386);
wid = pic._width;
pic2._x = wid;
startx = _x;
xs = Number(_name);
Symbol 1250 MovieClip Frame 2
nx = _x + xs;
if (nx < (startx - wid)) {
nx = nx + wid;
}
if (nx > startx) {
nx = nx - wid;
}
_x = nx;
Symbol 1250 MovieClip Frame 3
prevFrame();
play();
Symbol 1259 MovieClip Frame 1
duplicateMovieClip ("pic", "pic2", 16386);
wid = pic._width;
pic2._x = wid;
startx = _x;
xs = Number(_name);
Symbol 1259 MovieClip Frame 2
nx = _x + xs;
if (nx < (startx - wid)) {
nx = nx + wid;
}
if (nx > startx) {
nx = nx - wid;
}
_x = nx;
Symbol 1259 MovieClip Frame 3
prevFrame();
play();
Symbol 1260 MovieClip Frame 7
stop();
Symbol 1263 MovieClip Frame 1
_root.ztv.stop();
stop();
Symbol 1263 MovieClip Frame 2
_root.ztv.start(0, 1000);
stop();
Symbol 1264 Button
on (release) {
if (/:toy[5] == 2) {
t.gotoAndStop(1);
/:toy[5] = 0;
} else {
t.gotoAndStop(2);
/:toy[5] = 2;
}
}
Symbol 1269 Button
on (rollOver) {
if (/:canpress) {
play();
}
}
Symbol 1272 Button
on (release) {
if (/:canpress) {
n = Number(substring(_name, 2, 2));
menuclick(n);
}
}
Symbol 1275 Button
on (release) {
if (_root.hand._visible) {
removeMovieClip(_root.hand);
Mouse.show();
}
_parent.play();
savegame();
popexit();
}
Symbol 1276 Button
on (release) {
_parent.play();
}
Symbol 1303 MovieClip Frame 1
if (/:pettipe == "dog") {
stop();
} else {
nextFrame();
stop();
}
Symbol 1304 MovieClip Frame 1
stop();
Symbol 1304 MovieClip Frame 17
stop();
Symbol 1304 MovieClip Frame 30
gotoAndStop (1);
Symbol 1308 Button
on (release) {
if (/:canpress) {
Set("/:room", /:room + sign);
_root._x = _root._x - (sign * spacing);
Set("/:xnow", /:xnow + (sign * spacing));
Set("/:xmin", /:xmin + (sign * spacing));
Set("/:xmax", /:xmax + (sign * spacing));
var i = 0;
while (i < /:still.length) {
_root[/:still[i]]._x = _root[/:still[i]]._x + (sign * spacing);
i++;
}
}
}
Symbol 1310 MovieClip Frame 1
stop();
Symbol 1311 MovieClip Frame 1
onenterframe = function () {
if (sign < 0) {
if ((/:x < (_x + 30)) and (!onmenu())) {
if (_alpha < 100) {
_alpha = (_alpha + al);
}
} else if (_alpha > 0) {
_alpha = (_alpha - al);
}
} else if (/:x > (_x - 30)) {
if (_alpha < 100) {
_alpha = (_alpha + al);
}
} else if (_alpha > 0) {
_alpha = (_alpha - al);
}
};
spacing = /:screenwid + /:screenbumper;
sign = Number(_name);
a.gotoAndStop(sign + 2);
_alpha = 0;
al = 10;
Symbol 1314 MovieClip Frame 1
d = /:messagedelay;
Symbol 1314 MovieClip Frame 2
d = d - 1;
Symbol 1314 MovieClip Frame 3
if (d > 0) {
if (naughty ne "") {
if (naughty == "sofa") {
popmessage(/:name + " shouldn't jump on the couch. Scold your pet.");
naughty = "";
d = 200;
} else if (naughty == "scratch") {
popmessage(/:name + " shouldn't scratch the couch. Scold your pet.");
naughty = "";
d = 200;
} else if (naughty == "talk") {
popmessage(/:name + " shouldn't be noisy. You need to scold your pet.");
naughty = "";
d = 200;
}
}
prevFrame();
play();
} else {
if ((/:energy < /:energylow) and (/:pdo ne "eat")) {
popmessage(/:name + " is hungry.");
} else if ((/:thirst < /:thirstlow) and (/:pdo ne "drink")) {
popmessage(/:name + " is thirsty.");
} else if ((substring(/:pdo, 1, 3)) ne "toy") {
if ((/:happy > 10) and (/:happy < 80)) {
if (random(100) > 30) {
if (/:pettipe == "dog") {
m = [" likes to play with a ball.", " wants a chew bone.", " likes to catch a frisbee.", " likes to chase the toy car."];
} else {
m = [" likes to play with a ball of yarn.", " likes to play with the whack toy.", " likes to chase the toy mouse."];
}
m.randomize();
popmessage(/:name + m.pop());
}
} else if (/:happy <= 10) {
m = [" is bored.", " wants to play.", " needs your attention."];
m.randomize();
popmessage(/:name + m.pop());
}
} else {
hints = ["Give treats when your pet is being good.", "Scold your pet only if you catch them doing something naughty.", "Playtime gives your pet important exercise."];
if (random(100) > 40) {
popmessage(hints[random(hints.length)]);
}
}
gotoAndPlay (1);
}