
function moveit(map) {
if (tmap != 1 && (map == 45 || (map == 79 && fmap != 77)) && scrNum!=4) {MsgTxt = "We're only open at night.\n\n" + MsgTxt; msgout(MsgTxt);}
else {
if (map == 121) {
fmap = 20;
HaveAr[6] = "At The Armory we carry only the best.\n\n"
HaveAr[5] = 1;
map = 3;
}
if (map == 124) {
fmap = 20;
HaveAr[6] = "We have the best Debr's Weaponry.\n\n"
HaveAr[5] = 2;
map = 3;
}
if (map == 56 && MnEventAr[21] != 0 && BossKillAr[2] == 0) {
diceit(20,1);
if (roll >= 5) {
HaveAr[6] = "The bar owner is ready for you.\n\n"
if (ItemTypeAr[wep1] != 7 && ItemTypeAr[wep2] != 7 && MapVisitAr[40] == 0) {HaveAr[4] = 7;}
else {HaveAr[4] = 8;}
map = 4;
}
}
URL = MapAr[map]
saveit(0);
window.location.href = URL;
}
}

function moveit1(map) {
URL = MapAr[map]
window.location.href = URL;
}

function msgout(MsgTxt) {
document.game.msgs.value = MsgTxt;
}

function introit(scrNum) {
if (scrNum != 9999) {
MsgTxt = IntroAr[scrNum];
if ((scrNum > 9 && scrNum != 13 && scrNum != 14 && scrNum != 16 && scrNum != 19 && scrNum != 29 && scrNum != 34 && scrNum != 36 && scrNum != 51 && scrNum != 55 && scrNum != 74 && scrNum != 76 && scrNum != 79) || scrNum == 4) {
if (scrNum != 0 && scrNum != 4) {
var x = 5;
if (BossKillAr[2] == 0 || fmap != 56) {
if (scrNum != 11 || Rented == 0) {picked();}
if (scrNum == 15 || scrNum == 23 || scrNum == 45) {x = 20;}
if (scrNum >= 60 && scrNum <= 69) {x = 0;}
if (cls == 1) {x+=15;}
diceit(100,1);
if (roll <= x) {moveit(4);}
}
}
if (tmin <= 0) {
limit = "12:00"
parselimit=limit.split(":")
parselimit=parselimit[0]*60+parselimit[1]*1
tmin = parselimit
}
if (tmap == 0) {daytimer();}
else {nightimer();}
}
}
else {
MsgTxt = "Still in Development\n\n07/17/2005 01:04 - Due to changes I've made in this update you'll have to re-create your character so your cookie can be reset. Barring any unforseen bugs this should be the last time this will be required.\nQuests 0 - 3 are complete.\n\nNote:\n\nFirst-timers need to create a character before playing the game or it won't function properly. If you want to save your games you can't delete your cookies or you'll have to re-create your character.\n\nNavigation between pages automatically saves your game at the point you select Leave in a map unless you select Leave (no save). Exiting a page by closing the window or refreshing the page will lose everything you did from the last time you selected Save or when you came into that map.";
}
msgout(MsgTxt);
}

function statit() {
chklvl();
crs = SafAr[0];
crs2 = Saf2Ar[0];
crt = crc + crs + crs2;
document.game.chp.value = hpc;
document.game.thp.value = hpt;
document.game.cmp.value = mpc;
document.game.tmp.value = mpt;
document.game.cps.value = psc;
document.game.tps.value = pst;
document.game.cst.value = stc;
document.game.tst.value = stt;
document.game.cdx.value = dxc;
document.game.tdx.value = dxt;
document.game.ccn.value = cnc;
document.game.tcn.value = cnt;
document.game.ccr.value = crc;
document.game.tcr.value = crt;
document.game.cex.value = exc;
document.game.nex.value = exn;
document.game.cin.value = inc;
document.game.tin.value = int;
document.game.lev.value = lvl;
document.game.sts.value = stsAr[sts];
document.all.nam.innerHTML = nam;
var txt = "";
txt = raceAr[race];
document.all.rac.innerHTML = txt;
var txt = "";
txt = ClassAr[cls];
document.all.cla.innerHTML = txt;
document.charimg.src = imgin;
}

function dspinv() {
var x = 0;
document.game.inam.value = "Pack Item";
document.game.icnt.value = "#";
document.game.ival.value = "Str";
document.game.itxt.value = "Actions";
sortinv();
clearinv();

for (var i=0;i<20;i++) {
if (InvAr[i] != 0) {
var Idesc = "";
Idesc = ItemDescAr[InvAr[i]];

if (x == 0) {
document.game.inam00.value = Idesc;
document.game.icnt00.value = InvCntAr[i];
document.game.ival00.value = ItemStrAr[InvAr[i]];
}
if (x == 1) {
document.game.inam01.value = Idesc;
document.game.icnt01.value = InvCntAr[i];
document.game.ival01.value = ItemStrAr[InvAr[i]];
}
if (x == 2) {
document.game.inam02.value = Idesc;
document.game.icnt02.value = InvCntAr[i];
document.game.ival02.value = ItemStrAr[InvAr[i]];
}
if (x == 3) {
document.game.inam03.value = Idesc;
document.game.icnt03.value = InvCntAr[i];
document.game.ival03.value = ItemStrAr[InvAr[i]];
}
if (x == 4) {
document.game.inam04.value = Idesc;
document.game.icnt04.value = InvCntAr[i];
document.game.ival04.value = ItemStrAr[InvAr[i]];
}
if (x == 5) {
document.game.inam05.value = Idesc;
document.game.icnt05.value = InvCntAr[i];
document.game.ival05.value = ItemStrAr[InvAr[i]];
}
if (x == 6) {
document.game.inam06.value = Idesc;
document.game.icnt06.value = InvCntAr[i];
document.game.ival06.value = ItemStrAr[InvAr[i]];
}
if (x == 7) {
document.game.inam07.value = Idesc;
document.game.icnt07.value = InvCntAr[i];
document.game.ival07.value = ItemStrAr[InvAr[i]];
}
if (x == 8) {
document.game.inam08.value = Idesc;
document.game.icnt08.value = InvCntAr[i];
document.game.ival08.value = ItemStrAr[InvAr[i]];
}
if (x == 9) {
document.game.inam09.value = Idesc;
document.game.icnt09.value = InvCntAr[i];
document.game.ival09.value = ItemStrAr[InvAr[i]];
}
if (x == 10) {
document.game.inam10.value = Idesc;
document.game.icnt10.value = InvCntAr[i];
document.game.ival10.value = ItemStrAr[InvAr[i]];
}
if (x == 11) {
document.game.inam11.value = Idesc;
document.game.icnt11.value = InvCntAr[i];
document.game.ival11.value = ItemStrAr[InvAr[i]];
}
if (x == 12) {
document.game.inam12.value = Idesc;
document.game.icnt12.value = InvCntAr[i];
document.game.ival12.value = ItemStrAr[InvAr[i]];
}
if (x == 13) {
document.game.inam13.value = Idesc;
document.game.icnt13.value = InvCntAr[i];
document.game.ival13.value = ItemStrAr[InvAr[i]];
}
if (x == 14) {
document.game.inam14.value = Idesc;
document.game.icnt14.value = InvCntAr[i];
document.game.ival14.value = ItemStrAr[InvAr[i]];
}
if (x == 15) {
document.game.inam15.value = Idesc;
document.game.icnt15.value = InvCntAr[i];
document.game.ival15.value = ItemStrAr[InvAr[i]];
}
if (x == 16) {
document.game.inam16.value = Idesc;
document.game.icnt16.value = InvCntAr[i];
document.game.ival16.value = ItemStrAr[InvAr[i]];
}
if (x == 17) {
document.game.inam17.value = Idesc;
document.game.icnt17.value = InvCntAr[i];
document.game.ival17.value = ItemStrAr[InvAr[i]];
}
if (x == 18) {
document.game.inam18.value = Idesc;
document.game.icnt18.value = InvCntAr[i];
document.game.ival18.value = ItemStrAr[InvAr[i]];
}
if (x == 19) {
document.game.inam19.value = Idesc;
document.game.icnt19.value = InvCntAr[i];
document.game.ival19.value = ItemStrAr[InvAr[i]];
}
x++;
}
}

var txt = "";
var y = 0;
txt = ItemDescAr[wep1];
document.all.wep1.innerHTML= txt;
document.all.str1.innerHTML= ItemStrAr[wep1];
txt = ItemDescAr[wep2];
document.all.wep2.innerHTML= txt;
document.all.str2.innerHTML= ItemStrAr[wep2];

if (head1 != 0) {
txt = ItemDescAr[head1];
y = ItemStrAr[head1];
}
else {
txt = "";
y=0;
}
document.all.head1.innerHTML= txt;
document.all.str3.innerHTML= y;

if (arm1 != 0) {
txt = ItemDescAr[arm1];
y=ItemStrAr[arm1];
}
else {
txt = "";
y=0;
}
document.all.arm1.innerHTML= txt;
document.all.str4.innerHTML= y;

if (arm2 != 0) {
txt = ItemDescAr[arm2];
y=ItemStrAr[arm2];
}
else {
txt = "";
y=0;
}
document.all.arm2.innerHTML= txt;
document.all.str5.innerHTML= y;

if (feet1 != 0) {
txt = ItemDescAr[feet1];
y=ItemStrAr[feet1];
}
else {
txt = "";
y=0;
}
document.all.feet1.innerHTML= txt;
document.all.str6.innerHTML= y;

txt = cyberAr[cyber1];
document.all.cyber1.innerHTML= txt;

}

function popit(xit) {
if (yit != "") {
if (xit != yit) {
OpenWin.close();
OpenWin="";
}
};
OpenWin = this.open(xit, "game", "directories=no,location=no,menubar=no,resizable=yes,toolbar=no,scrollbars=yes,status=yes,left=220,top=110,width=900,height=400");
yit = xit;
}

function popitj(jit) {
if (kit != "") {
if (jit != kit) {
OpenWin.close();
OpenWin="";
}
};
OpenWin = this.open(jit, "help", "directories=no,location=no,menubar=no,resizable=yes,toolbar=no,scrollbars=yes,status=yes,left=200,top=110,width=900,height=400");
kit = jit;
}

function popitv(vit,wit) {
OpenWin = this.open(vit, wit, "directories=no,location=no,menubar=no,resizable=yes,toolbar=no,scrollbars=yes,status=yes,left=200,top=110,width=900,height=400");
}

function jumpit() {
var ActNum = window.document.game.site.options[document.game.site.selectedIndex].value;
if (ActNum != 0 && ActNum != 30 && ActNum != 60 && ActNum != 80 && ActNum != 90) {
moveit(ActNum);
}
else {msgout("You can't jump there at this time.");} 
}

function chklvl() {
if (exn <= 0) {
lvl++;
exn = (((lvl + 1) * 1000) * lvl) - exc;
var x = (lvl + 1) * 5;
hpc+=x;
hpt+=x;
MsgTxt = "Your hit points went up " + x + "\n\nYour experience has caused you to go up a level.\n\n" + MsgTxt;
msgout(MsgTxt);
}
exn = (((lvl + 1) * 1000) * lvl) - exc;
}

function stealit() {
MsgTxt = "You just can't resist going for someone's pockets." + "\n\n" + MsgTxt
var y = HaveAr[2];
if (steals == 0) {
var x = 10;
if (cls == 0) {x=20;}
stealcnt = Math.floor(Math.random()*x) + 1;
}
steals++;
var r1 = Math.floor(Math.random()*6) + 1;
var r2 = Math.floor(Math.random()*6) + 1;
var r3 = Math.floor(Math.random()*6) + 1;
var vstat = r1 + r2 + r3;
var r1 = Math.floor(Math.random()*6) + 1;
var r2 = Math.floor(Math.random()*6) + 1;
var r3 = Math.floor(Math.random()*6) + 1;
vstat = vstat + r1 + r2 + r3;
var ystat = inc + dxc;
if ((ystat > vstat) && (steals < stealcnt)) {
var r1 = Math.floor(Math.random()*50) + 1;

if (MnEventAr[8] != 0 && MnEventAr[9] == 0 && y == 15) {
MnEventAr[8] = 1;
crc = crc +  2000;
crt = crt +  2000;
HaveAr[4] = 2;
HaveAr[2] = 0;
moveit(4);
}

crc = crc + r1;
crt = crt + r1;
MsgTxt = "Smooth. You got " + r1 + " credits." + "\n\n" + MsgTxt
MnEventAr[0] = 1;
}
else {
var r1 = Math.floor(Math.random()*3);
MsgTxt = "Busted! You got nothing." + "\n\n" + MsgTxt

if (r1 == 1 && cls != 0) {
var r2 = Math.floor(Math.random()*25) + 1;
if (r2 > crc) {r1 = crc;}
crc = crc - r2;
crt = crt - r2;
if (crc < 0) {crc = 0;}
if (crt < 0) {crt = 0;}
MsgTxt = "Busted! You lost " + r2 + " credits." + "\n\n" + MsgTxt
}

if (r1 >= 2) {
moveit(4);
}
if (steals >= stealcnt) {
steals = 0;
}
}
statit();
msgout(MsgTxt);
}

function picked() {

if (cls != 0) {
diceit(100,1);

if (roll > 60) {
diceit(6,3);
var vstat = roll;
diceit(6,3);
vstat += roll;
diceit(20,1);
vstat += roll;
if (fmap == 50) {
diceit(10,1);
vstat += roll;
}
diceit(20,1);
var ystat = dxc + inc + roll;

if (vstat > ystat){
diceit(50,1);
if (roll > crc) {roll = crc;}
crc = crc - roll;
crt = crt - roll;
if (crc < 0) {crc = 0;}
if (crt < 0) {crt = 0;}
MsgTxt = "You feel a hand on your pocket and try to stop the thief but, too late, they got away with " + roll + " credits.\n\n" + MsgTxt
}

}

}

statit();
msgout(MsgTxt);
}

function InvAct(SlotNum) {
var Xnum = 0;
msgout("");

if (SlotNum == 0) {
Xnum = document.game.iact00.value;
}
if (SlotNum == 1) {
Xnum = document.game.iact01.value;
}
if (SlotNum == 2) {
Xnum = document.game.iact02.value;
}
if (SlotNum == 3) {
Xnum = document.game.iact03.value;
}
if (SlotNum == 4) {
Xnum = document.game.iact04.value;
}
if (SlotNum == 5) {
Xnum = document.game.iact05.value;
}
if (SlotNum == 6) {
Xnum = document.game.iact06.value;
}
if (SlotNum == 7) {
Xnum = document.game.iact07.value;
}
if (SlotNum == 8) {
Xnum = document.game.iact08.value;
}
if (SlotNum == 9) {
Xnum = document.game.iact09.value;
}
if (SlotNum == 10) {
Xnum = document.game.iact10.value;
}
if (SlotNum == 11) {
Xnum = document.game.iact11.value;
}
if (SlotNum == 12) {
Xnum = document.game.iact12.value;
}
if (SlotNum == 13) {
Xnum = document.game.iact13.value;
}
if (SlotNum == 14) {
Xnum = document.game.iact14.value;
}
if (SlotNum == 15) {
Xnum = document.game.iact15.value;
}
if (SlotNum == 16) {
Xnum = document.game.iact16.value;
}
if (SlotNum == 17) {
Xnum = document.game.iact17.value;
}
if (SlotNum == 18) {
Xnum = document.game.iact18.value;
}
if (SlotNum == 19) {
Xnum = document.game.iact19.value;
}

if (Xnum == 1) {
useit(SlotNum);
}

if (Xnum == 2) {
HaveAr[8] = InvAr[SlotNum];
subinv(SlotNum);
saveit(0);
popitv("popgive.html","give");
statit();
dspinv();
}

if (Xnum == 3) {
sellit(SlotNum);
}

if (Xnum == 4) {
youtrade(SlotNum);
}

if (Xnum == 5) {
subinv(SlotNum);
}
if (Xnum == 6) {
buyit(SlotNum);
}


if (Xnum == 7) {
addsaf(SlotNum);
statit();
dspinv();
dspsaf();
}

}

function bar() {
MsgTxt = "Chug.\n\n" + MsgTxt;
diceit(6,3)
roll+=5;
var upper = cnc;
if (race == 2) {upper = cnc - 5;}
if (race == 6) {upper = cnc + 5;}
if (roll > upper || drunk > 0) {
drunk = drunk + 60;
dxc--;
hpc--
if (sts != 1 && sts != 3) {MapVisitAr[1] = sts; sts = 1;}
MsgTxt = "You've had one drink too many.\n\n" + MsgTxt;
}
statit();
msgout(MsgTxt);
}

function diceit(dice,times) {
roll = 0;
for (var i=0;i<times;i++) {
roll = roll + Math.floor(Math.random()*dice) + 1;
}
}

function pissit() {
MsgTxt = "You take a leak." + "\n\n" + MsgTxt;
if (drunk > 5) {drunk=drunk-5;}
}

function useit(SlotNum) {
var x = InvAr[SlotNum];
var typ = ItemTypeAr[x];
var istr = ItemStrAr[x];
var pcnt = InvCntAr[SlotNum];

if (pcnt <= 0) {
if (x == 0) {
MsgTxt = "You have nothing in that slot." + "\n\n" + MsgTxt
}
else {
txt = ItemDescAr[x];
MsgTxt = "You don't have another " + txt + "\n\n" + MsgTxt;
}
msgout(MsgTxt);
sortinv();
dspinv();
return;
}

if ((typ == 0 || typ ==7) && pcnt > 0) {

if (wep1 == 0) {
wep1 = x;
pcnt--;
subinv(SlotNum);
}

else {

if (wep2 == 0) {
wep2 = x;
pcnt--;
subinv(SlotNum);
}

else {
var confirmit = confirm("Both your hands are full. Select Yes to replace Weapon 1 with new choice otherwise Weapon 2 will be replaced.")
if (confirmit == true) {
var oldx = wep1;
wep1 = x;
pcnt--;
subinv(SlotNum);
}
else {
var oldx = wep2;
wep2 = x;
pcnt--;
subinv(SlotNum);
}
addinv(oldx);
}
}
}

if (typ == 1 && pcnt > 0) {
if (arm1 == 0) {
arm1 = x;
pcnt--;
subinv(SlotNum);
}
else {
if (arm2 == 0) {
arm2 = x;
pcnt--;
subinv(SlotNum);
}
else {
var confirmit = confirm("You have all your armor on. Select Yes to replace Armor 1 with new choice otherwise Armor 2 will be replaced.")
if (confirmit == true) {
var oldx = arm1;
arm1 = x;
pcnt--;
subinv(SlotNum);
}
else {
var oldx = arm2;
arm2 = x;
pcnt--;
subinv(SlotNum);
}
addinv(oldx);
}
}
}

if (typ == 2 && pcnt > 0) {
if (head1 == 0) {
head1 = x;
pcnt--;
subinv(SlotNum);
}
else {
var confirmit = confirm("You already have something on your head. Select Yes to replace with new choice.")
if (confirmit == true) {
var oldx = head1;
head1 = x;
pcnt--;
subinv(SlotNum);
addinv(oldx);
}
}
}

if (typ == 3 && pcnt > 0) {
if (feet1 == 0) {
feet1 = x;
pcnt--;
subinv(SlotNum);
}
else {
var confirmit = confirm("You already have something on your feet. Select Yes to replace with new choice.")
if (confirmit == true) {
var oldx = feet1;
feet1 = x;
pcnt--;
subinv(SlotNum);
addinv(oldx);
}
}
}

if (typ == 5 && pcnt > 0) {
if (hpc < hpt || x == 8) {
hpc+=istr; subinv(SlotNum);
if (scrNum == 4) {
var yhlth = Math.round((hpc/hpt) * 100);
document.all.yhlth.innerHTML = yhlth;
var mhlth = Math.round((monhitc/monhit) * 100);
document.all.mhlth.innerHTML = mhlth;
}
}
else {MsgTxt = "You don't need that now.\n\n" + MsgTxt;}
}

msgout(MsgTxt);
statit();
sortinv();
dspinv();
}

function addinv(LNum) {
var hit = 0;
for (var i=0;i<20;i++) {
if (InvAr[i] == LNum) {
hit = 1;
InvCntAr[i]++;
i = 21;
}
}

if (hit == 0) {
if (InvAr[19] != 0) {MsgTxt = "Your pack is full.\n\n" + MsgTxt;}
else {
for (var i=0;i<20;i++) {
if (InvAr[i] == 0) {
InvAr[i] = LNum;
InvCntAr[i] = 1;
i = 21;
}
}
}
}

}

function subinv(SlotNum) {
InvCntAr[SlotNum]--;
if (InvCntAr[SlotNum] <= 0) {
InvCntAr[SlotNum] = 0;
InvAr[SlotNum] = 0;
}
sortinv();
dspinv();
}

function sortinv() {
var sar1=new Array()
var sar2=new Array()
var x = 0;
clearinv();

for (var i=0;i<20;i++) {
sar1[i] = 0;
sar2[i] = 0;
}

for (var i=0;i<20;i++) {
if (InvAr[i] != 0) {
if (InvCntAr[i] != 0) {
sar1[x] = InvAr[i];
sar2[x] = InvCntAr[i];
x++;
}
}
}

for (var i=0;i<20;i++) {
InvAr[i] = 0;
InvCntAr[i] = 0;
}

for (var i=0;i<20;i++) {
InvAr[i] = sar1[i];
InvCntAr[i] = sar2[i];
}
}

function clearinv() {
document.game.inam00.value = "";
document.game.icnt00.value = "";
document.game.ival00.value = "";
document.game.inam01.value = "";
document.game.icnt01.value = "";
document.game.ival01.value = "";
document.game.inam02.value = "";
document.game.icnt02.value = "";
document.game.ival02.value = "";
document.game.inam03.value = "";
document.game.icnt03.value = "";
document.game.ival03.value = "";
document.game.inam04.value = "";
document.game.icnt04.value = "";
document.game.ival04.value = "";
document.game.inam05.value = "";
document.game.icnt05.value = "";
document.game.ival05.value = "";
document.game.inam06.value = "";
document.game.icnt06.value = "";
document.game.ival06.value = "";
document.game.inam07.value = "";
document.game.icnt07.value = "";
document.game.ival07.value = "";
document.game.inam08.value = "";
document.game.icnt08.value = "";
document.game.ival08.value = "";
document.game.inam09.value = "";
document.game.icnt09.value = "";
document.game.ival09.value = "";
document.game.inam10.value = "";
document.game.icnt10.value = "";
document.game.ival10.value = "";
document.game.inam11.value = "";
document.game.icnt11.value = "";
document.game.ival11.value = "";
document.game.inam12.value = "";
document.game.icnt12.value = "";
document.game.ival12.value = "";
document.game.inam13.value = "";
document.game.icnt13.value = "";
document.game.ival13.value = "";
document.game.inam14.value = "";
document.game.icnt14.value = "";
document.game.ival14.value = "";
document.game.inam15.value = "";
document.game.icnt15.value = "";
document.game.ival15.value = "";
document.game.inam16.value = "";
document.game.icnt16.value = "";
document.game.ival16.value = "";
document.game.inam17.value = "";
document.game.icnt17.value = "";
document.game.ival17.value = "";
document.game.inam18.value = "";
document.game.icnt18.value = "";
document.game.ival18.value = "";
document.game.inam19.value = "";
document.game.icnt19.value = "";
document.game.ival19.value = "";
}

function teleport(Rnum) {
var y = Rnum;
if (y == 0) {
var r1 = Math.floor(Math.random()*100);
var x = MapAr[r1];
if (x != undefined && r1 != 2 && r1 != 6 && r1 != 9 && r1 != 19 && r1 != 22) {moveit1(r1);}
else {HaveAr[6] = ""; saveit(0);}
}
}

function packit(useno) {

if (useno == 1) {
if (wep1 != 0) {
addinv(wep1);
wep1 = 0;
}
}
if (useno == 2) {
if (wep2 != 0) {
addinv(wep2);
wep2 = 0;
}
}
if (useno == 3) {
if (head1 != 0) {
addinv(head1);
head1 = 0;
}
}
if (useno == 4) {
if (arm1 != 0) {
addinv(arm1);
arm1 = 0;
}
}
if (useno == 5) {
if (arm2 != 0) {
addinv(arm2);
arm2 = 0;
}
}
if (useno == 6) {
if (feet1 != 0) {
addinv(feet1);
feet1 = 0;
}
}
dspinv();
}

function newchar() {
tmin = 0
fmap = 0
tmap = 1
hpc = 10
hpt = 10
mpc = 0
mpt = 0
psc = 0
pst = 0
stc = 0
stt = 0
dxc = 0
dxt = 0
cnc = 0
cnt = 0
inc = 0
int = 0
exc = 0
exn = 1000
lvl = 1
sts = 0
cls = 0
race = 0
nam = "Phredd"
wep1 = 0
wep2 = 0
head1 = 0
arm1 = 0
arm2 = 0
feet1 = 0
cyber1 = 0
imgin = "b120x120.jpg"
Rented = 0
crc = 0
crt = 0
crs = 0

InvAr[0] = 1
InvAr[1] = 4
InvAr[2] = 0
InvAr[3] = 0
InvAr[4] = 0
InvAr[5] = 0
InvAr[6] = 0
InvAr[7] = 0
InvAr[8] = 0
InvAr[9] = 0
InvAr[10] = 0
InvAr[11] = 0
InvAr[12] = 0
InvAr[13] = 0
InvAr[14] = 0
InvAr[15] = 0
InvAr[16] = 0
InvAr[17] = 0
InvAr[18] = 0
InvAr[19] = 0

InvCntAr[0] = 1
InvCntAr[1] = 1
InvCntAr[2] = 0
InvCntAr[3] = 0
InvCntAr[4] = 0
InvCntAr[5] = 0
InvCntAr[6] = 0
InvCntAr[7] = 0
InvCntAr[8] = 0
InvCntAr[9] = 0
InvCntAr[10] = 0
InvCntAr[11] = 0
InvCntAr[12] = 0
InvCntAr[13] = 0
InvCntAr[14] = 0
InvCntAr[15] = 0
InvCntAr[16] = 0
InvCntAr[17] = 0
InvCntAr[18] = 0
InvCntAr[19] = 0

SafAr[0] = 0
SafAr[1] = 0
SafAr[2] = 0
SafAr[3] = 0
SafAr[4] = 0
SafAr[5] = 0
SafAr[6] = 0
SafAr[7] = 0
SafAr[8] = 0
SafAr[9] = 0

SafCntAr[0] = 0
SafCntAr[1] = 0
SafCntAr[2] = 0
SafCntAr[3] = 0
SafCntAr[4] = 0
SafCntAr[5] = 0
SafCntAr[6] = 0
SafCntAr[7] = 0
SafCntAr[8] = 0
SafCntAr[9] = 0

HaveAr[0] = 0
HaveAr[1] = ""
HaveAr[2] = 0
HaveAr[3] = ""
HaveAr[4] = 0
HaveAr[5] = 0
HaveAr[6] = ""
HaveAr[7] = 0
HaveAr[8] = 0
HaveAr[9] = 0

BossKillAr[0] = 0
BossKillAr[1] = 0
BossKillAr[2] = 0
BossKillAr[3] = 0
BossKillAr[4] = 0
BossKillAr[5] = 0
BossKillAr[6] = 0
BossKillAr[7] = 0
BossKillAr[8] = 0
BossKillAr[9] = 0

MapVisitAr[0] = 1
MapVisitAr[1] = 0
MapVisitAr[2] = 0
MapVisitAr[3] = 0
MapVisitAr[4] = 0
MapVisitAr[5] = 0
MapVisitAr[6] = 0
MapVisitAr[7] = 0
MapVisitAr[8] = 0
MapVisitAr[9] = 0
MapVisitAr[10] = 0
MapVisitAr[11] = 0
MapVisitAr[12] = 0
MapVisitAr[13] = 0
MapVisitAr[14] = 0
MapVisitAr[15] = 0
MapVisitAr[16] = 0
MapVisitAr[17] = 0
MapVisitAr[18] = 0
MapVisitAr[19] = 0
MapVisitAr[20] = 0
MapVisitAr[21] = 0
MapVisitAr[22] = 0
MapVisitAr[23] = 0
MapVisitAr[24] = 0
MapVisitAr[25] = 0
MapVisitAr[26] = 0
MapVisitAr[27] = 0
MapVisitAr[28] = 0
MapVisitAr[29] = 0
MapVisitAr[30] = 0
MapVisitAr[31] = ""
MapVisitAr[32] = 0
MapVisitAr[33] = 0
MapVisitAr[34] = 0
MapVisitAr[35] = 0
MapVisitAr[36] = 0
MapVisitAr[37] = 0
MapVisitAr[38] = 0
MapVisitAr[39] = 0
MapVisitAr[40] = 0
MapVisitAr[41] = ""
MapVisitAr[42] = 0
MapVisitAr[43] = 0
MapVisitAr[44] = 0
MapVisitAr[45] = 0
MapVisitAr[46] = 0
MapVisitAr[47] = 0
MapVisitAr[48] = 0
MapVisitAr[49] = 0
MapVisitAr[50] = 0
MapVisitAr[51] = ""
MapVisitAr[52] = 0
MapVisitAr[53] = 0
MapVisitAr[54] = 0
MapVisitAr[55] = 0
MapVisitAr[56] = 0
MapVisitAr[57] = 0
MapVisitAr[58] = 0
MapVisitAr[59] = 0
MapVisitAr[60] = 0
MapVisitAr[61] = 0
MapVisitAr[62] = 0
MapVisitAr[63] = ""
MapVisitAr[64] = 0
MapVisitAr[65] = 0
MapVisitAr[66] = 0
MapVisitAr[67] = ""
MapVisitAr[68] = ""
MapVisitAr[69] = ""
MapVisitAr[70] = ""
MapVisitAr[71] = ""
MapVisitAr[72] = ""
MapVisitAr[73] = 1
MapVisitAr[74] = 0
MapVisitAr[75] = 0
MapVisitAr[76] = 0
MapVisitAr[77] = ""
MapVisitAr[78] = ""
MapVisitAr[79] = 0
MapVisitAr[80] = 0
MapVisitAr[81] = 0
MapVisitAr[82] = 0
MapVisitAr[83] = 0
MapVisitAr[84] = 0
MapVisitAr[85] = 0
MapVisitAr[86] = ""
MapVisitAr[87] = 0
MapVisitAr[88] = 0
MapVisitAr[89] = 0
MapVisitAr[90] = 0
MapVisitAr[91] = 0
MapVisitAr[92] = 0
MapVisitAr[93] = 0
MapVisitAr[94] = 0
MapVisitAr[95] = 0
MapVisitAr[96] = 0
MapVisitAr[97] = 0
MapVisitAr[98] = 0
MapVisitAr[99] = 0

MnEventAr[0] = 0
MnEventAr[1] = 0
MnEventAr[2] = 0
MnEventAr[3] = 0
MnEventAr[4] = 0
MnEventAr[5] = 0
MnEventAr[6] = 0
MnEventAr[7] = 0
MnEventAr[8] = 0
MnEventAr[9] = 0
MnEventAr[10] = 0
MnEventAr[11] = 0
MnEventAr[12] = 0
MnEventAr[13] = 0
MnEventAr[14] = 0
MnEventAr[15] = 0
MnEventAr[16] = 0
MnEventAr[17] = 0
MnEventAr[18] = 0
MnEventAr[19] = 0
MnEventAr[20] = 0
MnEventAr[21] = 0
MnEventAr[22] = 0
MnEventAr[23] = 0
MnEventAr[24] = 0
MnEventAr[25] = 0
MnEventAr[26] = 0
MnEventAr[27] = 0
MnEventAr[28] = 0
MnEventAr[29] = 0
MnEventAr[30] = 0
MnEventAr[31] = 0
MnEventAr[32] = 0
MnEventAr[33] = 0
MnEventAr[34] = 0
MnEventAr[35] = 0
MnEventAr[36] = 0
MnEventAr[37] = 0
MnEventAr[38] = 0
MnEventAr[39] = 0
MnEventAr[40] = 0
MnEventAr[41] = 0
MnEventAr[42] = 0
MnEventAr[43] = 0
MnEventAr[44] = 0
MnEventAr[45] = 0
MnEventAr[46] = 0
MnEventAr[47] = 0
MnEventAr[48] = 0
MnEventAr[49] = 0
MnEventAr[50] = 0
MnEventAr[51] = 0
MnEventAr[52] = 0
MnEventAr[53] = 0
MnEventAr[54] = 0
MnEventAr[55] = 0
MnEventAr[56] = 0
MnEventAr[57] = 0
MnEventAr[58] = 0
MnEventAr[59] = 0
MnEventAr[60] = 0
MnEventAr[61] = 0
MnEventAr[62] = 0
MnEventAr[63] = 0
MnEventAr[64] = 0
MnEventAr[65] = 0
MnEventAr[66] = 0
MnEventAr[67] = 0
MnEventAr[68] = 0
MnEventAr[69] = 0
MnEventAr[70] = 0
MnEventAr[71] = 0
MnEventAr[72] = 0
MnEventAr[73] = 0
MnEventAr[74] = 0
MnEventAr[75] = 0
MnEventAr[76] = 0
MnEventAr[77] = 0
MnEventAr[78] = 0
MnEventAr[79] = 0
MnEventAr[80] = 0
MnEventAr[81] = 0
MnEventAr[82] = 0
MnEventAr[83] = 0
MnEventAr[84] = 0
MnEventAr[85] = 0
MnEventAr[86] = 0
MnEventAr[87] = 0
MnEventAr[88] = 0
MnEventAr[89] = 0
MnEventAr[90] = 0
MnEventAr[91] = 0
MnEventAr[92] = 0
MnEventAr[93] = 0
MnEventAr[94] = 0
MnEventAr[95] = 0
MnEventAr[96] = 0
MnEventAr[97] = 0
MnEventAr[98] = 0
MnEventAr[99] = 0

Saf2Ar[0] = 0
Saf2Ar[1] = 0
Saf2Ar[2] = 0
Saf2Ar[3] = 0
Saf2Ar[4] = 0
Saf2Ar[5] = 0
Saf2Ar[6] = 0
Saf2Ar[7] = 0
Saf2Ar[8] = 0
Saf2Ar[9] = 0

Saf2CntAr[0] = 0
Saf2CntAr[1] = 0
Saf2CntAr[2] = 0
Saf2CntAr[3] = 0
Saf2CntAr[4] = 0
Saf2CntAr[5] = 0
Saf2CntAr[6] = 0
Saf2CntAr[7] = 0
Saf2CntAr[8] = 0
Saf2CntAr[9] = 0

SbEventAr[0] = 0
SbEventAr[1] = 0
SbEventAr[2] = 0
SbEventAr[3] = 0
SbEventAr[4] = 0
SbEventAr[5] = 0
SbEventAr[6] = 0
SbEventAr[7] = 0
SbEventAr[8] = 0
SbEventAr[9] = 0
SbEventAr[10] = 0
SbEventAr[11] = 0
SbEventAr[12] = 0
SbEventAr[13] = 0
SbEventAr[14] = 0
SbEventAr[15] = 0
SbEventAr[16] = 0
SbEventAr[17] = 0
SbEventAr[18] = 0
SbEventAr[19] = 0
SbEventAr[20] = 0
SbEventAr[21] = 0
SbEventAr[22] = 0
SbEventAr[23] = 0
SbEventAr[24] = 0
SbEventAr[25] = 0
SbEventAr[26] = 0
SbEventAr[27] = 0
SbEventAr[28] = 0
SbEventAr[29] = 0
SbEventAr[30] = 0
SbEventAr[31] = 0
SbEventAr[32] = 0
SbEventAr[33] = 0
SbEventAr[34] = 0
SbEventAr[35] = 0
SbEventAr[36] = 0
SbEventAr[37] = 0
SbEventAr[38] = 0
SbEventAr[39] = 0
SbEventAr[40] = 0
SbEventAr[41] = 0
SbEventAr[42] = 0
SbEventAr[43] = 0
SbEventAr[44] = 0
SbEventAr[45] = 0
SbEventAr[46] = 0
SbEventAr[47] = 0
SbEventAr[48] = 0
SbEventAr[49] = 0
SbEventAr[50] = 0

miscAr[0] = 0
miscAr[1] = 0
miscAr[2] = 4
miscAr[3] = 0
miscAr[4] = 0
miscAr[5] = 0
miscAr[6] = 0
miscAr[7] = 0
miscAr[8] = 0
miscAr[9] = 0
miscAr[10] = 0
miscAr[11] = 0
miscAr[12] = 0
miscAr[13] = 0
miscAr[14] = 0
miscAr[15] = 0
miscAr[16] = 0
miscAr[17] = 0
miscAr[18] = 0
miscAr[19] = 0

Log = ""

saved = 0
}

function backflash() {
var i = 0;
var j = 0;
while (j <= 5){
document.bgColor = "yellow";
while (i <= 5){i++;}
document.bgColor = "red";
i = 0;
while (i <= 5){i++;}
document.bgColor = "aqua";
i = 0;
while (i <= 5){i++;}
document.bgColor = "black"
j++;}
}
