Frame 1
debagMode = false;
if (debagMode == true) {
gotoAndStop ("loading");
}
stop();
Frame 20
this.gotoAndStop("title");
Frame 30
gamePlaying = false;
gameStage = 0;
gameScore = 0;
Frame 50
gamePlaying = false;
gamePause = true;
Frame 60
gamePlaying = false;
gamePause = true;
Frame 70
gamePlaying = false;
gamePause = true;
Frame 80
gamePlaying = false;
gamePause = true;
Frame 90
gamePlaying = false;
gamePause = true;
Frame 100
gamePlaying = false;
Frame 110
stop();
Symbol 10 MovieClip [water1] Frame 1
_alpha = 80;
_rotation = Math.floor(Math.random() * 360);
pausing = false;
_x = _parent._parent.tobby._x;
_y = _parent._parent.tobby._y;
target = [_parent._parent._xmouse, _parent._parent._ymouse];
speed = 20;
rad = Math.atan2(target[1] - _y, target[0] - _x);
xmove = Math.cos(rad) * speed;
ymove = Math.sin(rad) * speed;
if (Math.abs(xmove) > Math.abs(ymove)) {
if (xmove > 0) {
moveH = "R";
} else {
moveH = "L";
}
} else if (ymove > 0) {
moveH = "D";
} else {
moveH = "U";
}
this.onEnterFrame = function () {
var _local1 = _parent;
var _local2 = this;
if (_local1._parent._parent._parent.gamePause == true) {
if (pausing == false) {
pausing = true;
stop();
}
} else {
if (pausing == true) {
play();
}
if ((_y < (target[1] + 1)) && (moveH == "U")) {
endCheck = true;
} else if ((_y > (target[1] - 1)) && (moveH == "D")) {
endCheck = true;
} else if ((_x < (target[0] + 1)) && (moveH == "L")) {
endCheck = true;
} else if ((_x > (target[0] - 1)) && (moveH == "R")) {
endCheck = true;
}
if (endCheck == true) {
_local1.housuiHitTest(_local2, 1);
depNum = Number(_local2._name.substr(5, 4)) + 1000;
_local1.attachMovie("tobitiri", "tobitiri" + depNum, depNum);
_local1["tobitiri" + depNum]._x = _local2._x;
_local1["tobitiri" + depNum]._y = _local2._y;
_local2.removeMovieClip();
} else {
if (xmove > 0) {
_x = Math.min(_x + xmove, target[0]);
} else if (xmove < 0) {
_x = Math.max(_x + xmove, target[0]);
}
if (ymove > 0) {
_y = Math.min(_y + ymove, target[1]);
} else if (ymove < 0) {
_y = Math.max(_y + ymove, target[1] - 1);
}
}
}
};
Symbol 10 MovieClip [water1] Frame 6
_parent.housuiHitTest(this, 1);
depNum = Number(this._name.substr(5, 4)) + 1000;
_parent.attachMovie("tobitiri", "tobitiri" + depNum, depNum);
_parent["tobitiri" + depNum]._x = this._x;
_parent["tobitiri" + depNum]._y = this._y;
this.removeMovieClip();
Symbol 11 MovieClip [water0] Frame 1
_alpha = 80;
_rotation = Math.floor(Math.random() * 360);
pausing = false;
_x = _parent._parent.tobby._x;
_y = _parent._parent.tobby._y;
target = [_parent._parent._xmouse, _parent._parent._ymouse];
speed = 20;
rad = Math.atan2(target[1] - _y, target[0] - _x);
xmove = Math.cos(rad) * speed;
ymove = Math.sin(rad) * speed;
if (Math.abs(xmove) > Math.abs(ymove)) {
if (xmove > 0) {
moveH = "R";
} else {
moveH = "L";
}
} else if (ymove > 0) {
moveH = "D";
} else {
moveH = "U";
}
this.onEnterFrame = function () {
var _local1 = _parent;
var _local2 = this;
if (_local1._parent._parent._parent.gamePause == true) {
if (pausing == false) {
pausing = true;
stop();
}
} else {
if (pausing == true) {
play();
}
if ((_y < (target[1] + 1)) && (moveH == "U")) {
endCheck = true;
} else if ((_y > (target[1] - 1)) && (moveH == "D")) {
endCheck = true;
} else if ((_x < (target[0] + 1)) && (moveH == "L")) {
endCheck = true;
} else if ((_x > (target[0] - 1)) && (moveH == "R")) {
endCheck = true;
}
if (endCheck == true) {
_local1.housuiHitTest(_local2, 0);
depNum = Number(_local2._name.substr(5, 4)) + 1000;
_local1.attachMovie("tobitiri", "tobitiri" + depNum, depNum);
_local1["tobitiri" + depNum]._x = _local2._x;
_local1["tobitiri" + depNum]._y = _local2._y;
_local2.removeMovieClip();
} else {
if (xmove > 0) {
_x = Math.min(_x + xmove, target[0]);
} else if (xmove < 0) {
_x = Math.max(_x + xmove, target[0]);
}
if (ymove > 0) {
_y = Math.min(_y + ymove, target[1]);
} else if (ymove < 0) {
_y = Math.max(_y + ymove, target[1]);
}
}
}
};
Symbol 11 MovieClip [water0] Frame 6
_parent.housuiHitTest(this, 1);
depNum = Number(this._name.substr(5, 4)) + 1000;
_parent.attachMovie("tobitiri", "tobitiri" + depNum, depNum);
_parent["tobitiri" + depNum]._x = this._x;
_parent["tobitiri" + depNum]._y = this._y;
this.removeMovieClip();
Symbol 15 MovieClip [fireball] Frame 1
speed = 1;
head = 0;
this.onEnterFrame = function () {
var _local1 = _parent;
if (_local1._parent._parent._parent.gamePause == true) {
} else {
_y = Math.min(_y + speed, (_local1._parent.tobby._y - head) + 1);
speed++;
if (_y < (_local1._parent.tobby._y - head)) {
} else {
if ((Math.abs(_x - _local1._parent.tobby._x) < 20) && (Math.abs(_y - (_local1._parent.tobby._y - head)) < 20)) {
_local1._parent.myMode = "koge";
_local1._parent.tobby.gotoAndStop("koge");
}
this.removeMovieClip();
}
}
};
Symbol 15 MovieClip [fireball] Frame 2
stop();
Symbol 21 Button
on (release) {
_parent.game.soundMc.soundAct(false);
_parent.game.housuiMcSet.seStop();
_parent._parent.gotoAndStop("title");
}
Symbol 23 Button
on (release) {
_parent._parent.gamePause = false;
this.removeMovieClip();
}
Symbol 24 MovieClip [pauseWindow] Frame 1
stop();
_parent.game.soundMc.soundAct(false);
Symbol 29 Button
on (release) {
pContinue = false;
play();
}
Symbol 30 Button
on (release) {
pContinue = true;
play();
}
Symbol 32 MovieClip [gameover] Frame 4
_parent.game.soundMc.soundAct(false);
Symbol 32 MovieClip [gameover] Frame 19
stop();
Symbol 32 MovieClip [gameover] Frame 30
_parent.game.housuiMcSet.seStop();
Symbol 32 MovieClip [gameover] Frame 31
if (pContinue == false) {
_parent._parent.gameScore = 0;
_parent._parent.gotoAndStop("title");
} else {
_parent._parent.gameScore = 0;
_parent._parent.gotoAndStop("stageInit");
}
Symbol 58 MovieClip Frame 1
stop();
Symbol 59 MovieClip Frame 1
function init() {
if (initCode == undefined) {
this.setNum(0, true, true);
} else {
this.setNum(initCode[0], initCode[1], initCode[2]);
}
}
function setNum(num, yose, zero) {
var _local1 = this;
var _local2 = num + "";
var zeroCheck = false;
var _local3;
if (yose == false) {
var strLen = (5 - _local2.length);
i = 0;
while (i < strLen) {
_local2 = "0" + _local2;
i++;
}
}
i = 0;
while (i < _local2.length) {
_local3 = Number(_local2.substr(i, 1));
_local1["mc" + i].gotoAndStop(_local3 + 1);
if (yose == false) {
if (_local3 > 0) {
zeroCheck = true;
_local1["mc" + i]._visible = true;
} else if ((zero == false) && (zeroCheck == false)) {
_local1["mc" + i]._visible = false;
} else {
_local1["mc" + i]._visible = true;
}
} else {
_local1["mc" + i]._visible = true;
}
i++;
}
j = i;
while (j < 5) {
_local1["mc" + j].stop();
_local1["mc" + j]._visible = false;
j++;
}
}
function zeroNone() {
var _local1 = this;
i = 0;
while (i < 5) {
if (_local1["mc" + i]._currentframe == 1) {
_local1["mc" + i]._visible = false;
} else {
return;
}
i++;
}
}
this.init();
Instance of Symbol 59 MovieClip in Symbol 62 MovieClip [clearWindow] Frame 4
onClipEvent (load) {
initCode = [60 - _parent._parent.game.gameTime, false, false];
}
Symbol 62 MovieClip [clearWindow] Frame 13
stop();
this.onEnterFrame = function () {
var _local1 = _parent;
if (_local1.game.gameTime <= 0) {
delete this.onEnterFrame;
play();
} else {
_local1.game.gameTime--;
_local1._parent.gameScore = _local1._parent.gameScore + 100;
_local1.scoreBoard.setNum(_local1._parent.gameScore, false, true);
_local1.timeBoard.setNum(_local1.game.gameTime, false, false);
}
};
Symbol 62 MovieClip [clearWindow] Frame 32
_parent.game.housuiMcSet.seStop();
Symbol 62 MovieClip [clearWindow] Frame 33
_parent._parent.gameStage++;
_parent._parent.gotoAndStop("stageInit");
Instance of Symbol 59 MovieClip in Symbol 64 MovieClip [readyWindow] Frame 12
onClipEvent (load) {
initCode = [_parent._parent._parent._parent.gameStage + 1, true, true];
}
Symbol 64 MovieClip [readyWindow] Frame 28
_parent._parent._parent.gamePlaying = true;
_parent._parent._parent.gamePause = false;
this.removeMovieClip();
Symbol 66 MovieClip [tobitiri] Frame 1
this._rotation = Math.floor(Math.random() * 360);
Symbol 66 MovieClip [tobitiri] Frame 8
this.removeMovieClip();
Symbol 88 MovieClip [inst_mc] Frame 1
stop();
Symbol 93 MovieClip Frame 9
var versionNum = getVersion().slice(4, 5);
if (Number(versionNum) >= 6) {
this.gotoAndPlay("ok");
} else {
this.gotoAndPlay("ng");
}
Symbol 93 MovieClip Frame 19
_parent.gotoAndStop("loading");
this.stop();
Symbol 93 MovieClip Frame 25
this.stop();
Symbol 96 Button
on (release) {
if (_parent.gamePlaying != true) {
return(undefined);
}
if (_parent.gamePause == false) {
_parent.gamePause = true;
_parent.main.attachMovie("inst_mc", "inst_mc", 1);
} else if (_parent.main.inst_mc != undefined) {
_parent.main.inst_mc.removeMovieClip();
_parent.gamePause = false;
}
}
on (rollOver) {
if (_parent.gamePlaying != true) {
return(undefined);
}
if (_parent.gamePause == false) {
} else if (_parent.main_mc.inst_mc != undefined) {
}
}
Symbol 98 Button
on (release) {
if (_parent.gamePlaying != true) {
return(undefined);
}
if (_parent.gamePause == false) {
_parent.gamePause = true;
_parent.main.attachMovie("pauseWindow", "pauseWindow", 1);
} else if (_parent.main.pauseWindow != undefined) {
_parent.main.pauseWindow.removeMovieClip();
_parent.gamePause = false;
}
}
on (rollOver) {
if (_parent.gamePlaying != true) {
return(undefined);
}
if (_parent.gamePause == false) {
} else if (_parent.main_mc.exit_menu != undefined) {
}
}
Symbol 106 MovieClip Frame 1
loadedSize = _root.getBytesLoaded();
totalSize = _root.getBytesTotal();
if (loadedSize >= totalSize) {
this.gotoAndPlay("ok");
} else {
parcent = (loadedsize / totalsize) * 100;
gDownloaded = Math.round(parcent);
this.bar._width = 300 * (gDownloaded / 100);
}
Symbol 106 MovieClip Frame 2
this.gotoAndPlay(_currentframe - 1);
Symbol 106 MovieClip Frame 5
this.bar._width = 300;
Symbol 106 MovieClip Frame 19
this._parent.gotoAndPlay("init");
Symbol 133 Button
on (release) {
getURL ("http://www.toshiba.co.jp/index_j.htm", "_blank");
}
Symbol 134 Button
on (release) {
getURL ("http://www.toshiba.co.jp/digital/index_j.htm", "_blank");
}
Symbol 135 Button
on (release) {
getURL ("http://www.toshiba.co.jp/c_right/index_j.htm", "_blank");
}
Symbol 142 Button
on (release) {
play();
}
Symbol 144 Button
on (release) {
_parent.gotoAndStop("inst");
}
Symbol 145 MovieClip Frame 5
stop();
Symbol 145 MovieClip Frame 14
_parent.gotoAndStop("stageInit");
Symbol 154 Button
on (release) {
this.gotoAndStop(2);
}
Symbol 155 Button
on (release) {
_parent.gameStage = 3;
_parent.gotoAndStop("stageInit");
}
Symbol 156 Button
on (release) {
_parent.gameStage = 0;
_parent.gotoAndStop("stageInit");
}
Symbol 157 Button
on (release) {
_parent.gameStage = 1;
_parent.gotoAndStop("stageInit");
}
Symbol 158 Button
on (release) {
_parent.gameStage = 2;
_parent.gotoAndStop("stageInit");
}
Symbol 159 Button
on (release) {
_parent.gameStage = 0;
_parent.gotoAndStop("ending");
}
Symbol 160 Button
on (release) {
_parent.gameStage = 4;
_parent.gotoAndStop("stageInit");
}
Symbol 162 Button
on (release) {
this.gotoAndStop(1);
}
Symbol 163 MovieClip Frame 1
stop();
if (_parent.debagMode != true) {
_visible = false;
}
Symbol 164 MovieClip Frame 2
if (_parent.gameStage == 5) {
_parent.gotoAndStop("ending");
} else {
_parent.gotoAndStop("main" + _parent.gameStage);
}
Symbol 167 MovieClip Frame 1
stop();
Symbol 167 MovieClip Frame 14
_parent._parent._parent._parent.gameScore = _parent._parent._parent._parent.gameScore + 500;
_parent._parent._parent.scoreBoard.setNum(_parent._parent._parent._parent.gameScore, false, true);
Symbol 167 MovieClip Frame 20
stop();
Symbol 168 MovieClip Frame 2
stop();
Symbol 168 MovieClip Frame 53
stop();
Symbol 177 MovieClip Frame 1
stop();
Symbol 181 MovieClip Frame 1
stop();
Symbol 186 MovieClip Frame 1
stop();
Symbol 188 MovieClip Frame 1
function volume(vol) {
bgm.setVolume(vol);
}
bgm = new Sound(this);
bgm.attachSound("se_fire");
bgm.start(0, 999);
volume(50);
stop();
Symbol 190 MovieClip Frame 1
function volume(vol) {
bgm.setVolume(vol);
}
bgm = new Sound(this);
bgm.attachSound("se_car");
bgm.start(0, 999);
volume(50);
stop();
Symbol 191 MovieClip Frame 1
function fireRandomSet(code) {
var _local3 = code;
var _local1;
var _local2;
i = 0;
while (i < _local3.length) {
j = 0;
while (j < _local3[i].length) {
_local2 = true;
while (_local2) {
_local1 = [Math.floor(Math.random() * life[buildingList[i]].length), Math.floor(Math.random() * life[buildingList[i]][0].length)];
if (life[buildingList[i]][_local1[0]][_local1[1]] == 100) {
life[buildingList[i]][_local1[0]][_local1[1]] = _local3[i][j];
_local2 = false;
}
}
j++;
}
i++;
}
}
function housuiHitTest(mine, attackLv) {
if (_parent.bull.obje.hitTest(mine) && (bullHit != true)) {
bullHit = true;
_parent.bull.stop();
_parent.bull.obje.gotoAndPlay("out");
}
var _local3;
var _local1;
var _local2;
var oldLife;
if (mine._x < 40) {
} else if ((mine._x > 508) && (mine._x < 670)) {
} else if (mine._x > 1030) {
} else {
if (mine._x <= 508) {
_local2 = "A";
} else {
_local2 = "B";
}
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (this[(((("mado" + _local2) + "") + _local1) + "_") + _local3].hitZone.hitTest(mine)) {
oldLife = Math.floor(life[_local2][_local1][_local3] / 100);
life[_local2][_local1][_local3] = Math.min(Math.max(life[_local2][_local1][_local3] - attack[attackLv], 0), 450);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (Math.floor(life[_local2][_local1][_local3] / 100) == 1) {
se_shouka.start();
this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode = false;
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st1");
}
} else {
if ((oldLife == 2) && (Math.floor(life[_local2][_local1][_local3] / 100) == 1)) {
se_shouka.start();
oldLife = undefined;
}
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + Math.floor(life[_local2][_local1][_local3] / 100));
}
}
_local1++;
}
_local3++;
}
this.clearCheck();
}
}
function addFire(fi, fj, build) {
var _local3 = fj;
life[build][_local3][fi] = 420;
var _local1 = Math.floor(Math.random() * 4);
var _local2 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
if ((life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] < 200) && (life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] >= 100)) {
life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] = 220;
}
}
function init() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
num = Math.floor(life[_local2][_local1][_local3] / 100);
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
}
_local1++;
}
_local3++;
}
z++;
}
}
function clearCheck() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (life[_local2][_local1][_local3] >= 200) {
return;
}
_local1++;
}
_local3++;
}
z++;
}
soundMc1.volume(0);
soundMc2.volume(50);
_parent.soundMc.soundAct(false);
_parent.clearSys();
}
function seStop() {
soundMc1.bgm.stop();
soundMc2.bgm.stop();
}
function bdSet() {
var _local3 = this;
var ac = 0;
var _local1;
var _local2;
while (ac < 100) {
_local2 = Math.floor(Math.random() * buildingList.length);
_local1 = [Math.floor(Math.random() * life[buildingList[_local2]].length), Math.floor(Math.random() * life[buildingList[_local2]][0].length)];
if ((life[buildingList[_local2]][_local1[0]][_local1[1]] >= 100) && (life[buildingList[_local2]][_local1[0]][_local1[1]] < 200)) {
if (((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) > 0) && ((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) < 640)) {
life[buildingList[_local2]][_local1[0]][_local1[1]] = 200;
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].fire.gotoAndStop("bd");
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].bdMode = true;
ac = 100;
}
}
ac++;
}
}
function backDraftAction(build, bj, bi) {
var _local2 = bj;
var _local3 = bi;
shakeTime = shakeTime + 8;
this[((("mado" + build) + _local2) + "_") + _local3].bdMode = false;
life[build][_local2][_local3] = 480;
var _local1 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
i = 0;
while (i < _local1.length) {
if (life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] != undefined) {
life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] = Math.max(life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]], 350);
}
i++;
}
}
se_shouka = new Sound();
se_shouka.attachSound("se_shouka");
madoH = {A:[9, 4], B:[7, 5]};
buildingList = ["A", "B"];
ballDepth = 0;
attack = [9, 5];
fireAddHp = 0.8;
bDTime = [];
shake = 1;
shakeTime = 0;
life = {A:[], B:[]};
life.A[0] = [420, 320, 240, 100, 100, 100, 100, 100, 100];
life.A[1] = [220, 100, 100, 100, 100, 100, 100, 100, 100];
life.A[2] = [100, 100, 100, 100, 100, 100, 100, 100, 100];
life.A[3] = [100, 100, 100, 100, 100, 100, 100, 100, 100];
life.B[0] = [240, 230, 100, 100, 100, 100, 100];
life.B[1] = [100, 100, 100, 100, 100, 100, 100];
life.B[2] = [100, 100, 100, 100, 100, 100, 100];
life.B[3] = [100, 100, 100, 100, 100, 100, 100];
life.B[4] = [100, 100, 100, 100, 100, 100, 100];
this.fireRandomSet([[310], [220]]);
this.onEnterFrame = function () {
if (_parent._parent._parent.gamePause == true) {
} else {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
var tobbyDistance = 999;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
if (life[_local2][_local1][_local3] >= 200) {
tobbyDistance = Math.min(tobbyDistance, Math.floor(Math.abs((_parent.tobby._x - _x) - this[((("mado" + _local2) + _local1) + "_") + _local3]._x)));
}
life[_local2][_local1][_local3] = Math.min(life[_local2][_local1][_local3] + fireAddHp, 600);
num = Math.floor(life[_local2][_local1][_local3] / 100);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (num == 3) {
this.backDraftAction(_local2, _local1, _local3);
}
} else {
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
}
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
if ((Math.floor(life[_local2][_local1][_local3]) == 500) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._y < _parent.tobby._y)) {
if (Math.floor(Math.random() * 3) > 0) {
life[_local2][_local1][_local3]++;
ballDep = ballDepth + 2500;
this.attachMovie("fireball", "fireball" + ballDep, ballDep);
this["fireball" + ballDep]._x = this[((("mado" + _local2) + _local1) + "_") + _local3]._x;
this["fireball" + ballDep]._y = this[((("mado" + _local2) + _local1) + "_") + _local3]._y;
ballDepth++;
}
}
if (life[_local2][_local1][_local3] == 600) {
this.addFire(_local3, _local1, _local2);
}
}
_local1++;
}
_local3++;
}
z++;
}
tobbyDistance = tobbyDistance / 2;
soundMc1.volume(Math.max(100 - tobbyDistance, 0));
soundMc2.volume(Math.min(tobbyDistance, 100));
if (bDTime.length > 0) {
bdTime[0]--;
if (bdTime[0] <= 0) {
this.bdSet();
bdTime.shift();
}
}
if (shakeTime > 0) {
shakeTime--;
_parent._parent._y = _parent._parent._y + (shake * 6);
shake = shake * -1;
}
}
};
stop();
this.init();
Symbol 195 MovieClip Frame 1
maxDist = 100;
baseDist = 100;
turn = 5;
nobi = 2;
this.onEnterFrame = function () {
var _local2 = _parent;
if (_local2._parent._parent._parent.gamePause == true) {
} else if (_local2._parent.myMode != "walk") {
} else {
var distance = Math.floor(Math.sqrt(Math.pow(_xmouse, 2) + Math.pow(_ymouse, 2)));
var dist = Math.max(Math.min(distance, maxDist + baseDist), baseDist);
var _local3 = Math.min(Math.max(Math.floor(((dist - baseDist) * 30) / 100), 2), _totalframes);
var addFrames = Math.max(Math.min(_local3 - _currentframe, nobi), -nobi);
var framesB = Math.min(Math.max(_currentframe + addFrames, 2), _totalframes);
gotoAndStop(framesB);
var _local1 = (Math.atan2(_local2._ymouse - _y, _local2._xmouse - _x) * 180) / Math.PI;
if ((_local1 < 0) && (_local1 > -180)) {
var kaku = Math.max(Math.min(_local1, 0), -180);
_rotation = (_rotation + Math.min(Math.max(kaku - _rotation, -turn), turn));
}
}
};
stop();
Symbol 200 MovieClip Frame 1
speed = 8;
this.onEnterFrame = function () {
var _local1 = _parent;
if (_local1._parent._parent.gamePause == true) {
} else if (_local1.myMode != "walk") {
} else {
_x = (_x + Math.max(Math.min((_local1._xmouse - _x) / 10, speed), -speed));
}
};
stop();
Symbol 204 MovieClip Frame 1
stop();
Symbol 207 MovieClip Frame 1
function soundAct(code) {
if (code == true) {
bgm.start(0, 50);
} else {
bgm.stop();
}
}
bgm = new Sound(this);
bgm.attachSound("se_housui");
bgm.setVolume(40);
stop();
Symbol 208 MovieClip Frame 1
function walkMode() {
var _local2 = this;
tobby._x = clane._x + (Math.cos((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
tobby._y = clane._y + (Math.sin((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
var _local3 = _local2._x;
if ((tobby._x - wLoc) > scrollRect[1]) {
_local2._x = Math.max(scrollRect[1] - tobby._x, -stageRect[1]);
wLoc = -_local2._x;
} else if ((tobby._x - wLoc) < scrollRect[0]) {
_local2._x = Math.min(scrollRect[0] - tobby._x, -stageRect[0]);
wLoc = -_local2._x;
}
if (_local3 != _x) {
var _local1;
_local1 = 0;
while (_local1 < 2) {
_local2["hata" + _local1]._x = _local2["hata" + _local1]._x + (_x - _local3);
_local1++;
}
}
if (mouseHold == true) {
tobby.gotoAndStop("st1");
myMode = "hou";
soundMc.soundAct(true);
}
}
function houMode() {
if (mouseHold == false) {
myMode = "walk";
soundMc.soundAct(false);
return(undefined);
}
this.housuiMcSet.attachMovie("water" + housuiMode, "water" + hDepth, hDepth);
hDepth = (hDepth + 1) % 1000;
}
function kogeMode() {
if (kogeTime == undefined) {
kogeTime = 20;
}
kogeTime--;
if (kogeTime > 0) {
return(undefined);
}
myMode = "walk";
tobby.gotoAndStop("st1");
delete kogeTime;
}
function timeKanri() {
var _local1 = _parent;
timerCount++;
if (timerCount < 15) {
} else {
timerCount = 0;
gameTime--;
_local1.timeBoard.setNum(gameTime, false, false);
if (gameTime == 30) {
bull.play();
}
if (gameTime > 0) {
} else {
_local1._parent.gamePause = true;
_local1._parent.gamePlaying = false;
this._parent.attachMovie("gameover", "gameover", 10);
}
}
}
function clearSys() {
_parent._parent.gamePause = true;
_parent._parent.gamePlaying = false;
this._parent.attachMovie("clearWindow", "clearWindow", 10);
}
myMode = "walk";
stageRect = [0, 450];
scrollRect = [170, 450];
wLoc = 0;
mouseHold = false;
housuiMode = 0;
hDepth = 0;
timerCount = 0;
gameTime = 60;
_x = 0;
this.attachMovie("readyWindow", "readyWindow", 10);
this.onEnterFrame = function () {
if (_parent._parent.gamePause == true) {
return(undefined);
}
this[myMode + "Mode"]();
this.timeKanri();
};
this.onMouseUp = function () {
mouseHold = false;
};
this.onMouseDown = function () {
mouseHold = true;
};
this.onKeyDown = function () {
if (_parent.gamePause == true) {
return(undefined);
}
if (Key.isDown(32)) {
housuiMode = (housuiMode + 1) % 2;
}
};
Key.addListener(this);
stop();
Instance of Symbol 59 MovieClip "scoreBoard" in Symbol 211 MovieClip Frame 1
onClipEvent (load) {
initCode = [_parent._parent.gameScore, false, true];
}
Instance of Symbol 59 MovieClip "timeBoard" in Symbol 211 MovieClip Frame 1
onClipEvent (load) {
initCode = [60, false, false];
}
Symbol 217 MovieClip Frame 1
stop();
Symbol 218 MovieClip Frame 1
stop();
Symbol 219 MovieClip Frame 1
function fireRandomSet(code) {
var _local3 = code;
var _local1;
var _local2;
i = 0;
while (i < _local3.length) {
j = 0;
while (j < _local3[i].length) {
_local2 = true;
while (_local2) {
_local1 = [Math.floor(Math.random() * life[buildingList[i]].length), Math.floor(Math.random() * life[buildingList[i]][0].length)];
if (life[buildingList[i]][_local1[0]][_local1[1]] == 100) {
life[buildingList[i]][_local1[0]][_local1[1]] = _local3[i][j];
_local2 = false;
}
}
j++;
}
i++;
}
}
function housuiHitTest(mine, attackLv) {
if (_parent.bull.obje.hitTest(mine) && (bullHit != true)) {
bullHit = true;
_parent.bull.stop();
_parent.bull.obje.gotoAndPlay("out");
}
var _local3;
var _local1;
var _local2;
var oldLife;
if (mine._x < 30) {
} else if ((mine._x > 460) && (mine._x < 610)) {
} else if (mine._x > 1050) {
} else {
if (mine._x <= 500) {
_local2 = "B";
} else {
_local2 = "A";
}
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (this[(((("mado" + _local2) + "") + _local1) + "_") + _local3].hitZone.hitTest(mine)) {
oldLife = Math.floor(life[_local2][_local1][_local3] / 100);
life[_local2][_local1][_local3] = Math.min(Math.max(life[_local2][_local1][_local3] - attack[attackLv], 0), 450);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (Math.floor(life[_local2][_local1][_local3] / 100) == 1) {
se_shouka.start();
this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode = false;
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st1");
}
} else {
if ((oldLife == 2) && (Math.floor(life[_local2][_local1][_local3] / 100) == 1)) {
se_shouka.start();
oldLife = undefined;
}
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + Math.floor(life[_local2][_local1][_local3] / 100));
}
}
_local1++;
}
_local3++;
}
this.clearCheck();
}
}
function addFire(fi, fj, build) {
var _local3 = fj;
life[build][_local3][fi] = 420;
var _local1 = Math.floor(Math.random() * 4);
var _local2 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
if ((life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] < 200) && (life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] >= 100)) {
life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] = 220;
}
}
function init() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
num = Math.floor(life[_local2][_local1][_local3] / 100);
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
}
_local1++;
}
_local3++;
}
z++;
}
}
function clearCheck() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (life[_local2][_local1][_local3] >= 200) {
return;
}
_local1++;
}
_local3++;
}
z++;
}
soundMc1.volume(0);
soundMc2.volume(50);
_parent.soundMc.soundAct(false);
_parent.clearSys();
}
function seStop() {
soundMc1.bgm.stop();
soundMc2.bgm.stop();
}
function bdSet() {
var _local3 = this;
var ac = 0;
var _local1;
var _local2;
while (ac < 100) {
_local2 = Math.floor(Math.random() * buildingList.length);
_local1 = [Math.floor(Math.random() * life[buildingList[_local2]].length), Math.floor(Math.random() * life[buildingList[_local2]][0].length)];
if ((life[buildingList[_local2]][_local1[0]][_local1[1]] >= 100) && (life[buildingList[_local2]][_local1[0]][_local1[1]] < 200)) {
if (((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) > 0) && ((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) < 640)) {
life[buildingList[_local2]][_local1[0]][_local1[1]] = 200;
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].fire.gotoAndStop("bd");
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].bdMode = true;
ac = 100;
}
}
ac++;
}
}
function backDraftAction(build, bj, bi) {
var _local2 = bj;
var _local3 = bi;
se_backDraft.start();
shakeTime = shakeTime + 8;
this[((("mado" + build) + _local2) + "_") + _local3].bdMode = false;
life[build][_local2][_local3] = 480;
var _local1 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
i = 0;
while (i < _local1.length) {
if (life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] != undefined) {
life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] = Math.max(life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]], 350);
}
i++;
}
}
se_shouka = new Sound();
se_shouka.attachSound("se_shouka");
se_backDraft = new Sound();
se_backDraft.attachSound("se_backDraft");
madoH = {A:[8, 4], B:[10, 2]};
buildingList = ["A", "B"];
ballDepth = 0;
attack = [9, 5];
fireAddHp = 0.8;
bDTime = [150];
shake = 1;
shakeTime = 0;
life = {A:[], B:[]};
life.A[0] = [420, 310, 220, 100, 100, 100, 100, 100];
life.A[1] = [320, 240, 100, 100, 100, 100, 100, 100];
life.A[2] = [100, 100, 100, 100, 100, 100, 100, 100];
life.A[3] = [100, 100, 100, 100, 100, 100, 100, 100];
life.B[0] = [240, 230, 100, 100, 100, 100, 100, 100, 100, 100];
life.B[1] = [100, 100, 100, 100, 320, 100, 100, 100, 100, 100];
this.fireRandomSet([[320], [220]]);
this.onEnterFrame = function () {
if (_parent._parent._parent.gamePause == true) {
} else {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
var tobbyDistance = 999;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
if (life[_local2][_local1][_local3] >= 200) {
tobbyDistance = Math.min(tobbyDistance, Math.floor(Math.abs((_parent.tobby._x - _x) - this[((("mado" + _local2) + _local1) + "_") + _local3]._x)));
}
life[_local2][_local1][_local3] = Math.min(life[_local2][_local1][_local3] + fireAddHp, 600);
num = Math.floor(life[_local2][_local1][_local3] / 100);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (num == 3) {
this.backDraftAction(_local2, _local1, _local3);
}
} else {
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
}
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
if ((Math.floor(life[_local2][_local1][_local3]) == 500) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._y < _parent.tobby._y)) {
if (Math.floor(Math.random() * 3) > 0) {
life[_local2][_local1][_local3]++;
ballDep = ballDepth + 2500;
this.attachMovie("fireball", "fireball" + ballDep, ballDep);
this["fireball" + ballDep]._x = this[((("mado" + _local2) + _local1) + "_") + _local3]._x;
this["fireball" + ballDep]._y = this[((("mado" + _local2) + _local1) + "_") + _local3]._y;
ballDepth++;
}
}
if (life[_local2][_local1][_local3] == 600) {
this.addFire(_local3, _local1, _local2);
}
}
_local1++;
}
_local3++;
}
z++;
}
tobbyDistance = tobbyDistance / 2;
soundMc1.volume(Math.max(100 - tobbyDistance, 0));
soundMc2.volume(Math.min(tobbyDistance, 100));
if (bDTime.length > 0) {
bdTime[0]--;
if (bdTime[0] <= 0) {
this.bdSet();
bdTime.shift();
}
}
if (shakeTime > 0) {
shakeTime--;
_parent._parent._y = _parent._parent._y + (shake * 6);
shake = shake * -1;
}
}
};
stop();
this.init();
Symbol 221 MovieClip Frame 2
stop();
Symbol 221 MovieClip Frame 53
stop();
Symbol 222 MovieClip Frame 1
function walkMode() {
var _local2 = this;
tobby._x = clane._x + (Math.cos((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
tobby._y = clane._y + (Math.sin((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
var _local3 = _local2._x;
if ((tobby._x - wLoc) > scrollRect[1]) {
_local2._x = Math.max(scrollRect[1] - tobby._x, -stageRect[1]);
wLoc = -_local2._x;
} else if ((tobby._x - wLoc) < scrollRect[0]) {
_local2._x = Math.min(scrollRect[0] - tobby._x, -stageRect[0]);
wLoc = -_local2._x;
}
if (_local3 != _x) {
var _local1;
_local1 = 0;
while (_local1 < 2) {
_local2["hata" + _local1]._x = _local2["hata" + _local1]._x + (_x - _local3);
_local1++;
}
}
if (mouseHold == true) {
tobby.gotoAndStop("st1");
myMode = "hou";
soundMc.soundAct(true);
}
}
function houMode() {
if (mouseHold == false) {
myMode = "walk";
soundMc.soundAct(false);
return(undefined);
}
this.housuiMcSet.attachMovie("water" + housuiMode, "water" + hDepth, hDepth);
hDepth = (hDepth + 1) % 1000;
}
function kogeMode() {
if (kogeTime == undefined) {
kogeTime = 20;
}
kogeTime--;
if (kogeTime > 0) {
return(undefined);
}
myMode = "walk";
tobby.gotoAndStop("st1");
delete kogeTime;
}
function timeKanri() {
var _local1 = _parent;
timerCount++;
if (timerCount < 15) {
} else {
timerCount = 0;
gameTime--;
_local1.timeBoard.setNum(gameTime, false, false);
if (gameTime == 30) {
bull.play();
}
if (gameTime > 0) {
} else {
_local1._parent.gamePause = true;
_local1._parent.gamePlaying = false;
this._parent.attachMovie("gameover", "gameover", 10);
}
}
}
function clearSys() {
_parent._parent.gamePause = true;
_parent._parent.gamePlaying = false;
this._parent.attachMovie("clearWindow", "clearWindow", 10);
}
myMode = "walk";
stageRect = [0, 450];
scrollRect = [170, 450];
wLoc = 0;
mouseHold = false;
housuiMode = 0;
hDepth = 0;
timerCount = 0;
gameTime = 60;
_x = 0;
this.attachMovie("readyWindow", "readyWindow", 10);
this.onEnterFrame = function () {
if (_parent._parent.gamePause == true) {
return(undefined);
}
this[myMode + "Mode"]();
this.timeKanri();
};
this.onMouseUp = function () {
mouseHold = false;
};
this.onMouseDown = function () {
mouseHold = true;
};
this.onKeyDown = function () {
if (_parent.gamePause == true) {
return(undefined);
}
if (Key.isDown(32)) {
housuiMode = (housuiMode + 1) % 2;
}
};
Key.addListener(this);
stop();
Instance of Symbol 59 MovieClip "scoreBoard" in Symbol 223 MovieClip Frame 1
onClipEvent (load) {
initCode = [_parent._parent.gameScore, false, true];
}
Instance of Symbol 59 MovieClip "timeBoard" in Symbol 223 MovieClip Frame 1
onClipEvent (load) {
initCode = [60, false, false];
}
Symbol 224 MovieClip Frame 2
stop();
Symbol 224 MovieClip Frame 59
stop();
Symbol 232 MovieClip Frame 1
stop();
Symbol 233 MovieClip Frame 1
function fireRandomSet(code) {
var _local3 = code;
var _local1;
var _local2;
i = 0;
while (i < _local3.length) {
j = 0;
while (j < _local3[i].length) {
_local2 = true;
while (_local2) {
_local1 = [Math.floor(Math.random() * life[buildingList[i]].length), Math.floor(Math.random() * life[buildingList[i]][0].length)];
if (life[buildingList[i]][_local1[0]][_local1[1]] == 100) {
life[buildingList[i]][_local1[0]][_local1[1]] = _local3[i][j];
_local2 = false;
}
}
j++;
}
i++;
}
}
function housuiHitTest(mine, attackLv) {
if (_parent.bull.obje.hitTest(mine) && (bullHit != true)) {
bullHit = true;
_parent.bull.stop();
_parent.bull.obje.gotoAndPlay("out");
}
var _local3;
var _local1;
var _local2;
var oldLife;
if (mine._x < 30) {
} else if ((mine._x > 320) && (mine._x < 480)) {
} else if ((mine._x > 600) && (mine._x < 760)) {
} else if (mine._x > 1050) {
} else {
if (mine._x <= 450) {
_local2 = "B";
} else if (mine._x >= 700) {
_local2 = "A";
} else {
_local2 = "C";
}
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (this[(((("mado" + _local2) + "") + _local1) + "_") + _local3].hitZone.hitTest(mine)) {
oldLife = Math.floor(life[_local2][_local1][_local3] / 100);
life[_local2][_local1][_local3] = Math.min(Math.max(life[_local2][_local1][_local3] - attack[attackLv], 0), 450);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (Math.floor(life[_local2][_local1][_local3] / 100) == 1) {
se_shouka.start();
this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode = false;
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st1");
}
} else {
if ((oldLife == 2) && (Math.floor(life[_local2][_local1][_local3] / 100) == 1)) {
se_shouka.start();
oldLife = undefined;
}
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + Math.floor(life[_local2][_local1][_local3] / 100));
}
}
_local1++;
}
_local3++;
}
this.clearCheck();
}
}
function addFire(fi, fj, build) {
var _local3 = fj;
life[build][_local3][fi] = 420;
var _local1 = Math.floor(Math.random() * 4);
var _local2 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
if ((life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] < 200) && (life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] >= 100)) {
life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] = 220;
}
}
function init() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
num = Math.floor(life[_local2][_local1][_local3] / 100);
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
}
_local1++;
}
_local3++;
}
z++;
}
}
function clearCheck() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (life[_local2][_local1][_local3] >= 200) {
return;
}
_local1++;
}
_local3++;
}
z++;
}
soundMc1.volume(0);
soundMc2.volume(50);
_parent.soundMc.soundAct(false);
_parent.clearSys();
}
function seStop() {
soundMc1.bgm.stop();
soundMc2.bgm.stop();
}
function bdSet() {
var _local3 = this;
var ac = 0;
var _local1;
var _local2;
while (ac < 100) {
_local2 = Math.floor(Math.random() * buildingList.length);
_local1 = [Math.floor(Math.random() * life[buildingList[_local2]].length), Math.floor(Math.random() * life[buildingList[_local2]][0].length)];
if ((life[buildingList[_local2]][_local1[0]][_local1[1]] >= 100) && (life[buildingList[_local2]][_local1[0]][_local1[1]] < 200)) {
if (((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) > 0) && ((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) < 640)) {
life[buildingList[_local2]][_local1[0]][_local1[1]] = 200;
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].fire.gotoAndStop("bd");
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].bdMode = true;
ac = 100;
}
}
ac++;
}
}
function backDraftAction(build, bj, bi) {
var _local2 = bj;
var _local3 = bi;
se_backDraft.start();
shakeTime = shakeTime + 8;
this[((("mado" + build) + _local2) + "_") + _local3].bdMode = false;
life[build][_local2][_local3] = 480;
var _local1 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
i = 0;
while (i < _local1.length) {
if (life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] != undefined) {
life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] = Math.max(life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]], 350);
}
i++;
}
}
se_shouka = new Sound();
se_shouka.attachSound("se_shouka");
se_backDraft = new Sound();
se_backDraft.attachSound("se_backDraft");
madoH = {A:[5, 4], B:[6, 2], C:[5, 1]};
buildingList = ["A", "B", "C"];
ballDepth = 0;
attack = [9, 5];
fireAddHp = 0.8;
bDTime = [120];
shake = 1;
shakeTime = 0;
life = {A:[], B:[], C:[]};
life.A[0] = [420, 320, 220, 100, 100];
life.A[1] = [340, 240, 100, 100, 100];
life.A[2] = [100, 100, 100, 100, 100];
life.A[3] = [100, 100, 100, 100, 100];
life.B[0] = [240, 230, 100, 100, 100, 100];
life.B[1] = [100, 100, 100, 100, 320, 100];
life.C[0] = [100, 100, 100, 100, 100];
this.fireRandomSet([[320], [220], [230, 340]]);
this.onEnterFrame = function () {
if (_parent._parent._parent.gamePause == true) {
} else {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
var tobbyDistance = 999;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
if (life[_local2][_local1][_local3] >= 200) {
tobbyDistance = Math.min(tobbyDistance, Math.floor(Math.abs((_parent.tobby._x - _x) - this[((("mado" + _local2) + _local1) + "_") + _local3]._x)));
}
life[_local2][_local1][_local3] = Math.min(life[_local2][_local1][_local3] + fireAddHp, 600);
num = Math.floor(life[_local2][_local1][_local3] / 100);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (num == 3) {
this.backDraftAction(_local2, _local1, _local3);
}
} else {
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
}
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
if ((Math.floor(life[_local2][_local1][_local3]) == 500) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._y < _parent.tobby._y)) {
if (Math.floor(Math.random() * 3) > 0) {
life[_local2][_local1][_local3]++;
ballDep = ballDepth + 2500;
this.attachMovie("fireball", "fireball" + ballDep, ballDep);
this["fireball" + ballDep]._x = this[((("mado" + _local2) + _local1) + "_") + _local3]._x;
this["fireball" + ballDep]._y = this[((("mado" + _local2) + _local1) + "_") + _local3]._y;
ballDepth++;
}
}
if (life[_local2][_local1][_local3] == 600) {
this.addFire(_local3, _local1, _local2);
}
}
_local1++;
}
_local3++;
}
z++;
}
tobbyDistance = tobbyDistance / 2;
soundMc1.volume(Math.max(100 - tobbyDistance, 0));
soundMc2.volume(Math.min(tobbyDistance, 100));
if (bDTime.length > 0) {
bdTime[0]--;
if (bdTime[0] <= 0) {
this.bdSet();
bdTime.shift();
}
}
if (shakeTime > 0) {
shakeTime--;
_parent._parent._y = _parent._parent._y + (shake * 6);
shake = shake * -1;
}
}
};
stop();
this.init();
Symbol 234 MovieClip Frame 1
function walkMode() {
var _local2 = this;
tobby._x = clane._x + (Math.cos((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
tobby._y = clane._y + (Math.sin((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
var _local3 = _local2._x;
if ((tobby._x - wLoc) > scrollRect[1]) {
_local2._x = Math.max(scrollRect[1] - tobby._x, -stageRect[1]);
wLoc = -_local2._x;
} else if ((tobby._x - wLoc) < scrollRect[0]) {
_local2._x = Math.min(scrollRect[0] - tobby._x, -stageRect[0]);
wLoc = -_local2._x;
}
if (_local3 != _x) {
var _local1;
_local1 = 0;
while (_local1 < 2) {
_local2["hata" + _local1]._x = _local2["hata" + _local1]._x + (_x - _local3);
_local1++;
}
}
if (mouseHold == true) {
tobby.gotoAndStop("st1");
myMode = "hou";
soundMc.soundAct(true);
}
}
function houMode() {
if (mouseHold == false) {
myMode = "walk";
soundMc.soundAct(false);
return(undefined);
}
this.housuiMcSet.attachMovie("water" + housuiMode, "water" + hDepth, hDepth);
hDepth = (hDepth + 1) % 1000;
}
function kogeMode() {
if (kogeTime == undefined) {
kogeTime = 20;
}
kogeTime--;
if (kogeTime > 0) {
return(undefined);
}
myMode = "walk";
tobby.gotoAndStop("st1");
delete kogeTime;
}
function timeKanri() {
var _local1 = _parent;
timerCount++;
if (timerCount < 15) {
} else {
timerCount = 0;
gameTime--;
_local1.timeBoard.setNum(gameTime, false, false);
if (gameTime == 30) {
bull.play();
}
if (gameTime > 0) {
} else {
_local1._parent.gamePause = true;
_local1._parent.gamePlaying = false;
this._parent.attachMovie("gameover", "gameover", 10);
}
}
}
function clearSys() {
_parent._parent.gamePause = true;
_parent._parent.gamePlaying = false;
this._parent.attachMovie("clearWindow", "clearWindow", 10);
}
myMode = "walk";
stageRect = [0, 450];
scrollRect = [170, 450];
wLoc = 0;
mouseHold = false;
housuiMode = 0;
hDepth = 0;
timerCount = 0;
gameTime = 60;
_x = 0;
this.attachMovie("readyWindow", "readyWindow", 10);
this.onEnterFrame = function () {
if (_parent._parent.gamePause == true) {
return(undefined);
}
this[myMode + "Mode"]();
this.timeKanri();
};
this.onMouseUp = function () {
mouseHold = false;
};
this.onMouseDown = function () {
mouseHold = true;
};
this.onKeyDown = function () {
if (_parent.gamePause == true) {
return(undefined);
}
if (Key.isDown(32)) {
housuiMode = (housuiMode + 1) % 2;
}
};
Key.addListener(this);
stop();
Instance of Symbol 59 MovieClip "scoreBoard" in Symbol 235 MovieClip Frame 1
onClipEvent (load) {
initCode = [_parent._parent.gameScore, false, true];
}
Instance of Symbol 59 MovieClip "timeBoard" in Symbol 235 MovieClip Frame 1
onClipEvent (load) {
initCode = [60, false, false];
}
Symbol 238 MovieClip Frame 1
function fireRandomSet(code) {
var _local3 = code;
var _local1;
var _local2;
i = 0;
while (i < _local3.length) {
j = 0;
while (j < _local3[i].length) {
_local2 = true;
while (_local2) {
_local1 = [Math.floor(Math.random() * life[buildingList[i]].length), Math.floor(Math.random() * life[buildingList[i]][0].length)];
if (life[buildingList[i]][_local1[0]][_local1[1]] == 100) {
life[buildingList[i]][_local1[0]][_local1[1]] = _local3[i][j];
_local2 = false;
}
}
j++;
}
i++;
}
}
function housuiHitTest(mine, attackLv) {
if (_parent.bull.obje.hitTest(mine) && (bullHit != true)) {
bullHit = true;
_parent.bull.stop();
_parent.bull.obje.gotoAndPlay("out");
}
var _local3;
var _local1;
var _local2;
var oldLife;
if (mine._x < 180) {
} else if (mine._x > 930) {
} else {
if (mine._x <= 724) {
_local2 = "B";
} else {
_local2 = "C";
}
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (this[(((("mado" + _local2) + "") + _local1) + "_") + _local3].hitZone.hitTest(mine)) {
oldLife = Math.floor(life[_local2][_local1][_local3] / 100);
life[_local2][_local1][_local3] = Math.min(Math.max(life[_local2][_local1][_local3] - attack[attackLv], 0), 450);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (Math.floor(life[_local2][_local1][_local3] / 100) == 1) {
se_shouka.start();
this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode = false;
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st1");
}
} else {
if ((oldLife == 2) && (Math.floor(life[_local2][_local1][_local3] / 100) == 1)) {
se_shouka.start();
oldLife = undefined;
}
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + Math.floor(life[_local2][_local1][_local3] / 100));
}
}
_local1++;
}
_local3++;
}
this.clearCheck();
}
}
function addFire(fi, fj, build) {
var _local3 = fj;
life[build][_local3][fi] = 420;
var _local1 = Math.floor(Math.random() * 4);
var _local2 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
if ((life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] < 200) && (life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] >= 100)) {
life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] = 220;
}
}
function init() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
num = Math.floor(life[_local2][_local1][_local3] / 100);
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
}
_local1++;
}
_local3++;
}
z++;
}
}
function clearCheck() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (life[_local2][_local1][_local3] >= 200) {
return;
}
_local1++;
}
_local3++;
}
z++;
}
soundMc1.volume(0);
soundMc2.volume(50);
_parent.soundMc.soundAct(false);
_parent.clearSys();
}
function seStop() {
soundMc1.bgm.stop();
soundMc2.bgm.stop();
}
function bdSet() {
var _local3 = this;
var ac = 0;
var _local1;
var _local2;
while (ac < 100) {
_local2 = Math.floor(Math.random() * buildingList.length);
_local1 = [Math.floor(Math.random() * life[buildingList[_local2]].length), Math.floor(Math.random() * life[buildingList[_local2]][0].length)];
if ((life[buildingList[_local2]][_local1[0]][_local1[1]] >= 100) && (life[buildingList[_local2]][_local1[0]][_local1[1]] < 200)) {
if (((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) > 0) && ((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) < 640)) {
life[buildingList[_local2]][_local1[0]][_local1[1]] = 200;
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].fire.gotoAndStop("bd");
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].bdMode = true;
ac = 100;
}
}
ac++;
}
}
function backDraftAction(build, bj, bi) {
var _local2 = bj;
var _local3 = bi;
se_backDraft.start();
shakeTime = shakeTime + 8;
this[((("mado" + build) + _local2) + "_") + _local3].bdMode = false;
life[build][_local2][_local3] = 480;
var _local1 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
i = 0;
while (i < _local1.length) {
if (life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] != undefined) {
life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] = Math.max(life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]], 350);
}
i++;
}
}
se_shouka = new Sound();
se_shouka.attachSound("se_shouka");
se_backDraft = new Sound();
se_backDraft.attachSound("se_backDraft");
madoH = {B:[10, 3], C:[4, 2]};
buildingList = ["B", "C"];
ballDepth = 0;
attack = [9, 5];
fireAddHp = 0.8;
bDTime = [150, 300];
shake = 1;
shakeTime = 0;
life = {B:[], C:[]};
life.B[0] = [420, 320, 240, 100, 100, 100, 100, 100, 100, 100];
life.B[1] = [340, 220, 100, 100, 100, 100, 100, 100, 100, 100];
life.B[2] = [100, 100, 100, 100, 100, 100, 100, 100, 100, 100];
life.C[0] = [240, 230, 100, 100];
life.C[1] = [100, 100, 100, 100];
this.fireRandomSet([[320, 250, 280], [220, 310]]);
this.onEnterFrame = function () {
if (_parent._parent._parent.gamePause == true) {
} else {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
var tobbyDistance = 999;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
if (life[_local2][_local1][_local3] >= 200) {
tobbyDistance = Math.min(tobbyDistance, Math.floor(Math.abs((_parent.tobby._x - _x) - this[((("mado" + _local2) + _local1) + "_") + _local3]._x)));
}
life[_local2][_local1][_local3] = Math.min(life[_local2][_local1][_local3] + fireAddHp, 600);
num = Math.floor(life[_local2][_local1][_local3] / 100);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (num == 3) {
this.backDraftAction(_local2, _local1, _local3);
}
} else {
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
}
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
if ((Math.floor(life[_local2][_local1][_local3]) == 500) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._y < _parent.tobby._y)) {
if (Math.floor(Math.random() * 3) > 0) {
life[_local2][_local1][_local3]++;
ballDep = ballDepth + 2500;
this.attachMovie("fireball", "fireball" + ballDep, ballDep);
this["fireball" + ballDep]._x = this[((("mado" + _local2) + _local1) + "_") + _local3]._x;
this["fireball" + ballDep]._y = this[((("mado" + _local2) + _local1) + "_") + _local3]._y;
ballDepth++;
}
}
if (life[_local2][_local1][_local3] == 600) {
this.addFire(_local3, _local1, _local2);
}
}
_local1++;
}
_local3++;
}
z++;
}
tobbyDistance = tobbyDistance / 2;
soundMc1.volume(Math.max(100 - tobbyDistance, 0));
soundMc2.volume(Math.min(tobbyDistance, 100));
if (bDTime.length > 0) {
bdTime[0]--;
if (bdTime[0] <= 0) {
this.bdSet();
bdTime.shift();
}
}
if (shakeTime > 0) {
shakeTime--;
_parent._parent._y = _parent._parent._y + (shake * 6);
shake = shake * -1;
}
}
};
stop();
this.init();
Symbol 240 MovieClip Frame 2
stop();
Symbol 240 MovieClip Frame 65
stop();
Symbol 241 MovieClip Frame 1
function walkMode() {
var _local2 = this;
tobby._x = clane._x + (Math.cos((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
tobby._y = clane._y + (Math.sin((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
var _local3 = _local2._x;
if ((tobby._x - wLoc) > scrollRect[1]) {
_local2._x = Math.max(scrollRect[1] - tobby._x, -stageRect[1]);
wLoc = -_local2._x;
} else if ((tobby._x - wLoc) < scrollRect[0]) {
_local2._x = Math.min(scrollRect[0] - tobby._x, -stageRect[0]);
wLoc = -_local2._x;
}
if (_local3 != _x) {
var _local1;
_local1 = 0;
while (_local1 < 2) {
_local2["hata" + _local1]._x = _local2["hata" + _local1]._x + (_x - _local3);
_local1++;
}
}
if (mouseHold == true) {
tobby.gotoAndStop("st1");
myMode = "hou";
soundMc.soundAct(true);
}
}
function houMode() {
if (mouseHold == false) {
myMode = "walk";
soundMc.soundAct(false);
return(undefined);
}
this.housuiMcSet.attachMovie("water" + housuiMode, "water" + hDepth, hDepth);
hDepth = (hDepth + 1) % 1000;
}
function kogeMode() {
if (kogeTime == undefined) {
kogeTime = 20;
}
kogeTime--;
if (kogeTime > 0) {
return(undefined);
}
myMode = "walk";
tobby.gotoAndStop("st1");
delete kogeTime;
}
function timeKanri() {
var _local1 = _parent;
timerCount++;
if (timerCount < 15) {
} else {
timerCount = 0;
gameTime--;
_local1.timeBoard.setNum(gameTime, false, false);
if (gameTime == 30) {
bull.play();
}
if (gameTime > 0) {
} else {
_local1._parent.gamePause = true;
_local1._parent.gamePlaying = false;
this._parent.attachMovie("gameover", "gameover", 10);
}
}
}
function clearSys() {
_parent._parent.gamePause = true;
_parent._parent.gamePlaying = false;
this._parent.attachMovie("clearWindow", "clearWindow", 10);
}
myMode = "walk";
stageRect = [0, 450];
scrollRect = [170, 450];
wLoc = 0;
mouseHold = false;
housuiMode = 0;
hDepth = 0;
timerCount = 0;
gameTime = 60;
_x = 0;
this.attachMovie("readyWindow", "readyWindow", 10);
this.onEnterFrame = function () {
if (_parent._parent.gamePause == true) {
return(undefined);
}
this[myMode + "Mode"]();
this.timeKanri();
};
this.onMouseUp = function () {
mouseHold = false;
};
this.onMouseDown = function () {
mouseHold = true;
};
this.onKeyDown = function () {
if (_parent.gamePause == true) {
return(undefined);
}
if (Key.isDown(32)) {
housuiMode = (housuiMode + 1) % 2;
}
};
Key.addListener(this);
stop();
Instance of Symbol 59 MovieClip "scoreBoard" in Symbol 242 MovieClip Frame 1
onClipEvent (load) {
initCode = [_parent._parent.gameScore, false, true];
}
Instance of Symbol 59 MovieClip "timeBoard" in Symbol 242 MovieClip Frame 1
onClipEvent (load) {
initCode = [60, false, false];
}
Symbol 250 MovieClip Frame 1
stop();
Symbol 250 MovieClip Frame 14
_parent._parent._parent._parent.gameScore = _parent._parent._parent._parent.gameScore + 500;
_parent._parent._parent.scoreBoard.setNum(_parent._parent._parent._parent.gameScore, false, true);
Symbol 250 MovieClip Frame 20
stop();
Symbol 251 MovieClip Frame 2
stop();
Symbol 251 MovieClip Frame 99
stop();
Symbol 261 MovieClip Frame 1
stop();
Symbol 262 MovieClip Frame 1
function fireRandomSet(code) {
var _local3 = code;
var _local1;
var _local2;
i = 0;
while (i < _local3.length) {
j = 0;
while (j < _local3[i].length) {
_local2 = true;
while (_local2) {
_local1 = [Math.floor(Math.random() * life[buildingList[i]].length), Math.floor(Math.random() * life[buildingList[i]][0].length)];
if (life[buildingList[i]][_local1[0]][_local1[1]] == 100) {
life[buildingList[i]][_local1[0]][_local1[1]] = _local3[i][j];
_local2 = false;
}
}
j++;
}
i++;
}
}
function housuiHitTest(mine, attackLv) {
if (_parent.bull.obje.hitZone.hitTest(mine) && (bullHit != true)) {
bullHit = true;
_parent.bull.stop();
_parent.bull.obje.gotoAndPlay("out");
}
var _local3;
var _local1;
var _local2;
var oldLife;
if (mine._x <= 150) {
_local2 = "A";
} else if ((mine._x > 150) && (mine._x <= 440)) {
_local2 = "B";
} else if ((mine._x > 440) && (mine._x <= 540)) {
_local2 = "E";
} else if (mine._x > 690) {
_local2 = "D";
} else {
_local2 = "C";
}
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (this[(((("mado" + _local2) + "") + _local1) + "_") + _local3].hitZone.hitTest(mine)) {
oldLife = Math.floor(life[_local2][_local1][_local3] / 100);
life[_local2][_local1][_local3] = Math.min(Math.max(life[_local2][_local1][_local3] - attack[attackLv], 0), 450);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (Math.floor(life[_local2][_local1][_local3] / 100) == 1) {
se_shouka.start();
this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode = false;
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st1");
}
} else {
if ((oldLife == 2) && (Math.floor(life[_local2][_local1][_local3] / 100) == 1)) {
se_shouka.start();
oldLife = undefined;
}
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + Math.floor(life[_local2][_local1][_local3] / 100));
}
}
_local1++;
}
_local3++;
}
this.clearCheck();
}
function addFire(fi, fj, build) {
var _local3 = fj;
life[build][_local3][fi] = 420;
var _local1 = Math.floor(Math.random() * 4);
var _local2 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
if ((life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] < 200) && (life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] >= 100)) {
life[build][_local3 + _local2[_local1][0]][fi + _local2[_local1][1]] = 220;
}
}
function init() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
num = Math.floor(life[_local2][_local1][_local3] / 100);
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
}
_local1++;
}
_local3++;
}
z++;
}
}
function clearCheck() {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if (life[_local2][_local1][_local3] >= 200) {
return;
}
_local1++;
}
_local3++;
}
z++;
}
soundMc1.volume(0);
soundMc2.volume(50);
_parent.soundMc.soundAct(false);
_parent.clearSys();
}
function seStop() {
soundMc1.bgm.stop();
soundMc2.bgm.stop();
}
function bdSet() {
var _local3 = this;
var ac = 0;
var _local1;
var _local2;
while (ac < 100) {
_local2 = Math.floor(Math.random() * buildingList.length);
_local1 = [Math.floor(Math.random() * life[buildingList[_local2]].length), Math.floor(Math.random() * life[buildingList[_local2]][0].length)];
if ((life[buildingList[_local2]][_local1[0]][_local1[1]] >= 100) && (life[buildingList[_local2]][_local1[0]][_local1[1]] < 200)) {
if (((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) > 0) && ((_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]]._x - _x) < 640)) {
life[buildingList[_local2]][_local1[0]][_local1[1]] = 200;
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].fire.gotoAndStop("bd");
_local3[((("mado" + buildingList[_local2]) + [_local1[0]]) + "_") + [_local1[1]]].bdMode = true;
ac = 100;
}
}
ac++;
}
}
function backDraftAction(build, bj, bi) {
var _local2 = bj;
var _local3 = bi;
se_backDraft.start();
shakeTime = shakeTime + 8;
this[((("mado" + build) + _local2) + "_") + _local3].bdMode = false;
life[build][_local2][_local3] = 480;
var _local1 = [[1, 0], [-1, 0], [0, 1], [0, -1]];
i = 0;
while (i < _local1.length) {
if (life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] != undefined) {
life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]] = Math.max(life[build][_local2 + _local1[i][0]][_local3 + _local1[i][1]], 350);
}
i++;
}
}
se_shouka = new Sound();
se_shouka.attachSound("se_shouka");
se_backDraft = new Sound();
se_backDraft.attachSound("se_backDraft");
madoH = {A:[2, 2], B:[3, 4], C:[2, 2], D:[8, 2], E:[2, 1]};
buildingList = ["A", "B", "C", "D", "E"];
ballDepth = 0;
attack = [9, 5];
fireAddHp = 0.8;
bDTime = [100, 200, 400];
shake = 1;
shakeTime = 0;
life = {A:[], B:[], C:[], D:[], E:[]};
life.A[0] = [420, 100];
life.A[1] = [100, 100];
life.B[0] = [240, 0, 100];
life.B[1] = [100, 100, 100];
life.B[2] = [100, 100, 100];
life.B[3] = [100, 100, 100];
life.C[0] = [410, 100];
life.C[1] = [100, 100];
life.D[0] = [430, 310, 240, 100, 100, 100, 100, 100];
life.D[1] = [320, 260, 100, 100, 100, 100, 100, 100];
life.E[0] = [400, 100];
this.fireRandomSet([[320], [220, 320, 420]]);
this.onEnterFrame = function () {
if (_parent._parent._parent.gamePause == true) {
} else {
var _local2;
var z;
var _local3;
var _local1;
var num;
var ballDep;
var tobbyDistance = 999;
z = 0;
while (z < buildingList.length) {
_local2 = buildingList[z];
_local3 = 0;
while (_local3 < madoH[_local2][0]) {
_local1 = 0;
while (_local1 < madoH[_local2][1]) {
if ((life[_local2][_local1][_local3] < 200) && (life[_local2][_local1][_local3] >= 100)) {
} else {
if (life[_local2][_local1][_local3] >= 200) {
tobbyDistance = Math.min(tobbyDistance, Math.floor(Math.abs((_parent.tobby._x - _x) - this[((("mado" + _local2) + _local1) + "_") + _local3]._x)));
}
life[_local2][_local1][_local3] = Math.min(life[_local2][_local1][_local3] + fireAddHp, 600);
num = Math.floor(life[_local2][_local1][_local3] / 100);
if (this[((("mado" + _local2) + _local1) + "_") + _local3].bdMode == true) {
if (num == 3) {
this.backDraftAction(_local2, _local1, _local3);
}
} else {
this[((("mado" + _local2) + _local1) + "_") + _local3].fire.gotoAndStop("st" + num);
}
if ((num == 3) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._currentframe < 10)) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st3");
} else if (num == 4) {
this[((("mado" + _local2) + _local1) + "_") + _local3].gotoAndStop("st4");
}
if ((Math.floor(life[_local2][_local1][_local3]) == 500) && (this[((("mado" + _local2) + _local1) + "_") + _local3]._y < _parent.tobby._y)) {
if (Math.floor(Math.random() * 3) > 0) {
life[_local2][_local1][_local3]++;
ballDep = ballDepth + 2500;
this.attachMovie("fireball", "fireball" + ballDep, ballDep);
this["fireball" + ballDep]._x = this[((("mado" + _local2) + _local1) + "_") + _local3]._x;
this["fireball" + ballDep]._y = this[((("mado" + _local2) + _local1) + "_") + _local3]._y;
ballDepth++;
}
}
if (life[_local2][_local1][_local3] == 600) {
this.addFire(_local3, _local1, _local2);
}
}
_local1++;
}
_local3++;
}
z++;
}
life.B[0][1] = 0;
tobbyDistance = tobbyDistance / 2;
soundMc1.volume(Math.max(100 - tobbyDistance, 0));
soundMc2.volume(Math.min(tobbyDistance, 100));
if (bDTime.length > 0) {
bdTime[0]--;
if (bdTime[0] <= 0) {
this.bdSet();
bdTime.shift();
}
}
if (shakeTime > 0) {
shakeTime--;
_parent._parent._y = _parent._parent._y + (shake * 6);
shake = shake * -1;
}
}
};
stop();
this.init();
Symbol 263 MovieClip Frame 1
function walkMode() {
var _local2 = this;
tobby._x = clane._x + (Math.cos((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
tobby._y = clane._y + (Math.sin((clane.arm1._rotation * Math.PI) / 180) * (clane.arm1.arm2._x + clane.arm1.baseDist));
var _local3 = _local2._x;
if ((tobby._x - wLoc) > scrollRect[1]) {
_local2._x = Math.max(scrollRect[1] - tobby._x, -stageRect[1]);
wLoc = -_local2._x;
} else if ((tobby._x - wLoc) < scrollRect[0]) {
_local2._x = Math.min(scrollRect[0] - tobby._x, -stageRect[0]);
wLoc = -_local2._x;
}
if (_local3 != _x) {
var _local1;
_local1 = 0;
while (_local1 < 2) {
_local2["hata" + _local1]._x = _local2["hata" + _local1]._x + (_x - _local3);
_local1++;
}
}
if (mouseHold == true) {
tobby.gotoAndStop("st1");
myMode = "hou";
soundMc.soundAct(true);
}
}
function houMode() {
if (mouseHold == false) {
myMode = "walk";
soundMc.soundAct(false);
return(undefined);
}
this.housuiMcSet.attachMovie("water" + housuiMode, "water" + hDepth, hDepth);
hDepth = (hDepth + 1) % 1000;
}
function kogeMode() {
if (kogeTime == undefined) {
kogeTime = 20;
}
kogeTime--;
if (kogeTime > 0) {
return(undefined);
}
myMode = "walk";
tobby.gotoAndStop("st1");
delete kogeTime;
}
function timeKanri() {
var _local1 = _parent;
timerCount++;
if (timerCount < 15) {
} else {
timerCount = 0;
gameTime--;
_local1.timeBoard.setNum(gameTime, false, false);
if (gameTime == 30) {
bull.play();
}
if (gameTime > 0) {
} else {
_local1._parent.gamePause = true;
_local1._parent.gamePlaying = false;
this._parent.attachMovie("gameover", "gameover", 10);
}
}
}
function clearSys() {
_parent._parent.gamePause = true;
_parent._parent.gamePlaying = false;
this._parent.attachMovie("clearWindow", "clearWindow", 10);
}
myMode = "walk";
stageRect = [0, 450];
scrollRect = [170, 450];
wLoc = 0;
mouseHold = false;
housuiMode = 0;
hDepth = 0;
timerCount = 0;
gameTime = 60;
_x = 0;
this.attachMovie("readyWindow", "readyWindow", 10);
this.onEnterFrame = function () {
if (_parent._parent.gamePause == true) {
return(undefined);
}
this[myMode + "Mode"]();
this.timeKanri();
};
this.onMouseUp = function () {
mouseHold = false;
};
this.onMouseDown = function () {
mouseHold = true;
};
this.onKeyDown = function () {
if (_parent.gamePause == true) {
return(undefined);
}
if (Key.isDown(32)) {
housuiMode = (housuiMode + 1) % 2;
}
};
Key.addListener(this);
stop();
Instance of Symbol 59 MovieClip "scoreBoard" in Symbol 264 MovieClip Frame 1
onClipEvent (load) {
initCode = [_parent._parent.gameScore, false, true];
}
Instance of Symbol 59 MovieClip "timeBoard" in Symbol 264 MovieClip Frame 1
onClipEvent (load) {
initCode = [60, false, false];
}
Instance of Symbol 59 MovieClip "scoreBoard" in Symbol 279 MovieClip Frame 1
onClipEvent (load) {
initCode = [_parent._parent.gameScore, false, true];
}
Symbol 279 MovieClip Frame 2
vol = 10;
pan = 20;
se = new Sound();
se.attachSound("se_car");
se.setVolume(vol);
se.setPan(pan);
se.start();
Symbol 279 MovieClip Frame 3
this.onEnterFrame = function () {
vol = Math.min(vol + 5, 50);
se.setVolume(vol);
};
Symbol 279 MovieClip Frame 15
delete this.onEnterFrame;
Symbol 279 MovieClip Frame 90
this.onEnterFrame = function () {
vol = vol + 2;
pan = pan - 2;
se.setVolume(vol);
se.setPan(pan);
};
Symbol 279 MovieClip Frame 100
this.onEnterFrame = function () {
pan = Math.max(pan - 10, -100);
se.setPan(pan);
};
Symbol 279 MovieClip Frame 115
this.onEnterFrame = function () {
vol = Math.max(vol - 4, 0);
se.setVolume(vol);
};
Symbol 279 MovieClip Frame 136
se.stop();
se.setVolume(100);
se.setPan(0);
delete this.onEnterFrame;
Symbol 279 MovieClip Frame 200
se.setVolume(0);
se.start();
vol = 0;
this.onEnterFrame = function () {
vol = Math.min(vol + 4, 50);
se.setVolume(vol);
};
Symbol 279 MovieClip Frame 214
delete this.onEnterFrame;
Symbol 279 MovieClip Frame 245
this.onEnterFrame = function () {
vol = Math.max(vol - 4, 0);
se.setVolume(vol);
};
Symbol 279 MovieClip Frame 260
se.stop();
se.setVolume(100);
se = undefined;
delete this.onEnterFrame;
Symbol 279 MovieClip Frame 271
_parent.gotoAndStop("title");
Symbol 281 Button
on (release) {
gotoAndStop ("title");
}