Frame 1
loadedSize = _root.getBytesLoaded();
totalSize = _root.getBytesTotal();
if (loadedSize >= totalSize) {
gotoAndStop (5);
} else {
percent = Math.round((loadedSize / totalSize) * 100);
}
type = 0;
Frame 2
gotoAndPlay (1);
Frame 5
stop();
Frame 9
stop();
Frame 14
stop();
Frame 19
stop();
Frame 24
stop();
Frame 29
stop();
Symbol 11 MovieClip Frame 1
this._yscale = random(60);
this._xscale = random(60);
this._rotation = random(360);
Symbol 12 MovieClip [hibana] Frame 11
removeMovieClip(this);
Symbol 17 MovieClip [tame] Frame 1
stop();
Symbol 20 MovieClip [yuudou] Frame 1
function tamahit(xa, ya, vxa, vya, xb, yb, vxb, vyb) {
this = new Sound(this);
this.attachSound("tamahit");
this.start();
kyoriX = xb - xa;
kyoriY = yb - ya;
katamuki = kyoriY / kyoriX;
kakudo = Math.round((Math.atan(katamuki) * 180) / Math.PI);
if (kyoriX < 0) {
kakudo = 180 + kakudo;
}
if ((-1 >= kakudo) and (kakudo >= -90)) {
kakudo = kakudo + 360;
}
theta2 = (kakudo * pi) / 180;
p = 1;
Yvb = (vxa * Math.cos(theta2)) + (vya * Math.sin(theta2));
Xva = ((-vxa) * Math.sin(theta2)) + (vya * Math.cos(theta2));
Yva = (vxb * Math.cos(theta2)) + (vyb * Math.sin(theta2));
Xvb = ((-vxb) * Math.sin(theta2)) + (vyb * Math.cos(theta2));
vx = ((-Xva) * Math.sin(theta2)) + (Yva * Math.cos(theta2));
vy = (Yva * Math.sin(theta2)) + (Xva * Math.cos(theta2));
Set("../jiki:vx", p * (((-Xvb) * Math.sin(theta2)) + (Yvb * Math.cos(theta2))));
Set("../jiki:vy", p * ((Yvb * Math.sin(theta2)) + (Xvb * Math.cos(theta2))));
R = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
handou = (wid - R) / 2;
if (xa < xb) {
this._x = xa - handou;
../:jiki._x = xb + handou;
} else if (xb < xa) {
this._x = xa + handou;
../:jiki._x = xb - handou;
}
if (ya < yb) {
this._y = ya - handou;
../:jiki._y = yb + handou;
} else if (yb < ya) {
this._y = ya + handou;
../:jiki._y = yb - handou;
}
}
kakudo = this._height;
this._height = 10;
theta = kakudo;
pi = Math.PI;
theta = (theta * pi) / 180;
speed = 5;
hspeed = 0.3;
vx = speed * Math.cos(theta);
vy = speed * Math.sin(theta);
tamahaba = getProperty(this, _width) / 2;
gotoAndPlay (2);
Symbol 20 MovieClip [yuudou] Frame 2
vx = vx + (hspeed * Math.cos(theta2));
vy = vy - (hspeed * Math.sin(theta2));
setProperty(this, _x , this._x + vx);
setProperty(this, _y , this._y + vy);
if ((((../:migiMax < this._x) or (this._x < ../:hidariMax)) or (../:sitaMax < this._y)) or (this._y < ../:ueMax)) {
removeMovieClip(this);
}
kyoriX = this._x - ../:jiki._x;
kyoriY = this._y - ../:jiki._y;
kyori = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
wid = tamahaba + ../:jiki.haba;
if ((kyori < wid) and (0 < ../jiki:life)) {
tellTarget ("../") {
attachMovie("hibana", "hitmark2", 101);
hitmark2._x = (this._x + jiki._x) / 2;
hitmark2._y = (this._y + jiki._y) / 2;
};
tamahit(this._x, this._y, vx, vy, ../:jiki._x, ../:jiki._y, ../jiki:vx, ../jiki:vy);
}
Symbol 20 MovieClip [yuudou] Frame 3
gotoAndPlay (2);
Symbol 21 MovieClip [tekitama] Frame 1
function tamahit(xa, ya, vxa, vya, xb, yb, vxb, vyb) {
this = new Sound(this);
this.attachSound("tamahit");
this.start();
kyoriX = xb - xa;
kyoriY = yb - ya;
katamuki = kyoriY / kyoriX;
kakudo = Math.round((Math.atan(katamuki) * 180) / Math.PI);
if (kyoriX < 0) {
kakudo = 180 + kakudo;
}
if ((-1 >= kakudo) and (kakudo >= -90)) {
kakudo = kakudo + 360;
}
theta2 = (kakudo * pi) / 180;
p = 1;
Yvb = (vxa * Math.cos(theta2)) + (vya * Math.sin(theta2));
Xva = ((-vxa) * Math.sin(theta2)) + (vya * Math.cos(theta2));
Yva = (vxb * Math.cos(theta2)) + (vyb * Math.sin(theta2));
Xvb = ((-vxb) * Math.sin(theta2)) + (vyb * Math.cos(theta2));
vx = ((-Xva) * Math.sin(theta2)) + (Yva * Math.cos(theta2));
vy = (Yva * Math.sin(theta2)) + (Xva * Math.cos(theta2));
Set("../jiki:vx", p * (((-Xvb) * Math.sin(theta2)) + (Yvb * Math.cos(theta2))));
Set("../jiki:vy", p * ((Yvb * Math.sin(theta2)) + (Xvb * Math.cos(theta2))));
R = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
handou = (wid - R) / 2;
if (xa < xb) {
this._x = xa - handou;
../:jiki._x = xb + handou;
} else if (xb < xa) {
this._x = xa + handou;
../:jiki._x = xb - handou;
}
if (ya < yb) {
this._y = ya - handou;
../:jiki._y = yb + handou;
} else if (yb < ya) {
this._y = ya + handou;
../:jiki._y = yb - handou;
}
}
kakudo = this._height;
this._height = 10;
theta = kakudo;
pi = Math.PI;
theta = (theta * pi) / 180;
speed = 10;
vx = speed * Math.cos(theta);
vy = speed * Math.sin(theta);
tamahaba = getProperty(this, _width) / 2;
gotoAndPlay (2);
Symbol 21 MovieClip [tekitama] Frame 2
setProperty(this, _x , this._x + vx);
setProperty(this, _y , this._y + vy);
if ((((../:migiMax < this._x) or (this._x < ../:hidariMax)) or (../:sitaMax < this._y)) or (this._y < ../:ueMax)) {
removeMovieClip(this);
}
kyoriX = this._x - ../:jiki._x;
kyoriY = this._y - ../:jiki._y;
kyori = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
wid = tamahaba + ../:jiki.haba;
if ((kyori < wid) and (0 < ../jiki:life)) {
tellTarget ("../") {
attachMovie("hibana", "hitmark2", 101);
hitmark2._x = (this._x + jiki._x) / 2;
hitmark2._y = (this._y + jiki._y) / 2;
};
tamahit(this._x, this._y, vx, vy, ../:jiki._x, ../:jiki._y, ../jiki:vx, ../jiki:vy);
}
Symbol 21 MovieClip [tekitama] Frame 3
gotoAndPlay (2);
Symbol 22 MovieClip [tama] Frame 1
function tamahit(xa, ya, vxa, vya, xb, yb, vxb, vyb) {
Set("../:hit", 1);
this = new Sound(this);
this.attachSound("tamahit");
this.start();
kyoriX = xb - xa;
kyoriY = yb - ya;
katamuki = kyoriY / kyoriX;
kakudo = Math.round((Math.atan(katamuki) * 180) / Math.PI);
if (kyoriX < 0) {
kakudo = 180 + kakudo;
}
if ((-1 >= kakudo) and (kakudo >= -90)) {
kakudo = kakudo + 360;
}
theta2 = (kakudo * pi) / 180;
p = 1;
Yvb = (vxa * Math.cos(theta2)) + (vya * Math.sin(theta2));
Xva = ((-vxa) * Math.sin(theta2)) + (vya * Math.cos(theta2));
Yva = (vxb * Math.cos(theta2)) + (vyb * Math.sin(theta2));
Xvb = ((-vxb) * Math.sin(theta2)) + (vyb * Math.cos(theta2));
vx = p * (((-Xva) * Math.sin(theta2)) + (Yva * Math.cos(theta2)));
vy = p * ((Yva * Math.sin(theta2)) + (Xva * Math.cos(theta2)));
Set("../teki:vx", p * (((-Xvb) * Math.sin(theta2)) + (Yvb * Math.cos(theta2))));
Set("../teki:vy", p * ((Yvb * Math.sin(theta2)) + (Xvb * Math.cos(theta2))));
R = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
handou = (wid - R) / 2;
if (xa < xb) {
this._x = xa - handou;
../:teki._x = xb + handou;
} else if (xb < xa) {
this._x = xa + handou;
../:teki._x = xb - handou;
}
if (ya < yb) {
this._y = ya - handou;
../:teki._y = yb + handou;
} else if (yb < ya) {
this._y = ya + handou;
../:teki._y = yb - handou;
}
}
theta = ../../mouse:kakudo;
pow = this._alpha;
this._xscale = 100 + (pow * 2);
this._yscale = 100 + (pow * 2);
this._alpha = 100;
pi = Math.PI;
theta = (theta * pi) / 180;
speed = 5 + (pow / 5);
vx = speed * Math.cos(theta);
vy = speed * Math.sin(theta);
tamahaba = getProperty(this, _width) / 2;
gotoAndPlay (2);
Symbol 22 MovieClip [tama] Frame 2
setProperty(this, _x , this._x + vx);
setProperty(this, _y , this._y + vy);
if ((((../:migiMax < this._x) or (this._x < ../:hidariMax)) or (../:sitaMax < this._y)) or (this._y < ../:ueMax)) {
removeMovieClip(this);
}
kyoriX = this._x - ../:teki._x;
kyoriY = this._y - ../:teki._y;
kyori = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
wid = tamahaba + ../:teki.haba;
if ((kyori < wid) and (0 < ../teki:life)) {
tellTarget ("../") {
attachMovie("hibana", "hitmark2", 100);
hitmark2._x = (this._x + teki._x) / 2;
hitmark2._y = (this._y + teki._y) / 2;
};
tamahit(this._x, this._y, vx, vy, ../:teki._x, ../:teki._y, ../teki:vx, ../teki:vy);
}
Symbol 22 MovieClip [tama] Frame 3
gotoAndPlay (2);
Symbol 23 MovieClip [wave] Frame 6
removeMovieClip(this);
stop();
Symbol 28 MovieClip Frame 1
this._x = random(400);
this._y = 5 - random(10);
Symbol 29 MovieClip Frame 1
tellTarget ("../") {
end = false;
hantei = false;
};
Symbol 29 MovieClip Frame 16
tellTarget ("../") {
hantei = true;
};
Symbol 29 MovieClip Frame 94
tellTarget ("../") {
hantei = false;
};
Symbol 29 MovieClip Frame 103
tellTarget ("../") {
end = true;
};
stop();
Symbol 30 MovieClip [beam] Frame 1
pow = 5;
hutosa = 10;
top = this._x - hutosa;
bottom = this._x + hutosa;
muki = this._xscale;
this._xscale = 100;
if (muki == 1) {
this._rotation = 0;
} else if (muki == 2) {
this._rotation = 180;
} else if (muki == 3) {
this._rotation = 90;
} else if (muki == 4) {
this._rotation = 270;
}
Symbol 30 MovieClip [beam] Frame 2
kyoriX = Math.abs(this._x - ../:jiki._x);
kyoriY = Math.abs(this._y - ../:jiki._y);
if (hantei) {
if (muki == 1) {
if (((kyoriY < (../:jiki.haba + hutosa)) and (this._x < (../:jiki._x + ../:jiki.haba))) and (0 < ../jiki:life)) {
../:jiki.vx = ../:jiki.vx + pow;
if (../:jiki._y < this._y) {
../:jiki.vy = ../:jiki.vy - pow;
} else {
../:jiki.vy = ../:jiki.vy + pow;
}
this = new Sound(this);
this.attachSound("razor");
this.start();
}
} else if (muki == 2) {
if (((kyoriY < (../:jiki.haba + hutosa)) and ((../:jiki._x - ../:jiki.haba) < this._x)) and (0 < ../jiki:life)) {
../:jiki.vx = ../:jiki.vx - pow;
if (../:jiki._y < this._y) {
../:jiki.vy = ../:jiki.vy - pow;
} else {
../:jiki.vy = ../:jiki.vy + pow;
}
this = new Sound(this);
this.attachSound("razor");
this.start();
}
} else if (muki == 3) {
if (((kyoriX < (../:jiki.haba + hutosa)) and (this._y < (../:jiki._y + ../:jiki.haba))) and (0 < ../jiki:life)) {
../:jiki.vy = ../:jiki.vy + pow;
if (../:jiki._x < this._x) {
../:jiki.vx = ../:jiki.vx - pow;
} else {
../:jiki.vx = ../:jiki.vx + pow;
}
this = new Sound(this);
this.attachSound("razor");
this.start();
}
} else if (muki == 4) {
if (((kyoriX < (../:jiki.haba + hutosa)) and ((../:jiki._y - ../:jiki.haba) < this._y)) and (0 < ../jiki:life)) {
../:jiki.vy = ../:jiki.vy - pow;
if (../:jiki._x < this._x) {
../:jiki.vx = ../:jiki.vx - pow;
} else {
../:jiki.vx = ../:jiki.vx + pow;
}
this = new Sound(this);
this.attachSound("razor");
this.start();
}
}
}
Symbol 30 MovieClip [beam] Frame 3
if (end) {
removeMovieClip(this);
}
gotoAndPlay (2);
Symbol 31 MovieClip [lose] Frame 60
stop();
resultscore = _root.game:score;
tellTarget (_root.game.mouse) {
removeMovieClip("ka-soru");
Mouse.hide(false);
Mouse.show(true);
};
tellTarget ("/game") {
this._x = 0;
this._y = 0;
attachMovie("dragon", "dragon2", 0);
dragon2._x = 0;
dragon2._y = 5;
};
Symbol 32 MovieClip [win] Frame 60
tellTarget (_root.game) {
stage = stage + 1;
if (stage == 1) {
nextFrame();
} else {
gotoAndStop ("nextstage");
}
};
Symbol 46 Button
on (release, keyPress "<Enter>") {
if (name ne "") {
play();
}
}
Symbol 48 MovieClip [dragon] Frame 47
resultscore = _root.game:score;
Symbol 48 MovieClip [dragon] Frame 55
stop();
Symbol 48 MovieClip [dragon] Frame 56
Set("_root:name", name);
Set("_root:score", resultscore);
stage = _root.game:stage;
Set("_root:stage", stage);
tellTarget (_root) {
loadVariablesNum ("hiscore.cgi", 0, "GET");
};
Symbol 48 MovieClip [dragon] Frame 85
tellTarget (_root) {
gotoAndStop ("title");
};
stop();
Symbol 49 MovieClip [wave] Frame 6
removeMovieClip(this);
stop();
Instance of Symbol 51 MovieClip in Symbol 63 MovieClip Frame 1
onClipEvent (load) {
speed = 0.6;
}
onClipEvent (enterFrame) {
if (Key.isDown(87)) {
vy = vy - speed;
}
if (Key.isDown(83)) {
vy = vy + speed;
}
if (Key.isDown(65)) {
vx = vx - speed;
}
if (Key.isDown(68)) {
vx = vx + speed;
}
vx = vx * 0.95;
vy = vy * 0.95;
_x = (_x + vx);
_y = (_y + vy);
}
Symbol 85 Button
on (release) {
this = new Sound(this);
this.attachSound("SE1");
this.start();
ifFrameLoaded (29) {
tellTarget ("../") {
gotoAndStop ("select");
};
}
}
Symbol 86 Button
on (release) {
tellTarget ("../") {
gotoAndStop ("asobikata");
};
}
Symbol 87 Button
on (release) {
tellTarget ("../") {
gotoAndStop ("ranking");
};
}
Symbol 93 MovieClip Frame 1
stop();
Symbol 93 MovieClip Frame 2
stop();
Symbol 93 MovieClip Frame 3
stop();
Symbol 100 MovieClip Frame 1
setProperty(this, _rotation , random(360));
Symbol 100 MovieClip Frame 31
stop();
Symbol 102 MovieClip Frame 1
setProperty(this, _rotation , random(360));
ran = 20 + random(80);
setProperty(this, _xscale , ran);
setProperty(this, _yscale , ran);
Symbol 102 MovieClip Frame 31
stop();
Symbol 104 MovieClip Frame 1
stopAllSounds();
n = 0;
while (n < 10) {
duplicateMovieClip ("bombA", "bombA" add n, n + 100);
n++;
}
m = 0;
while (m < 2) {
duplicateMovieClip ("bombB", "bombB" add m, m + 200);
m++;
}
Symbol 104 MovieClip Frame 4
while (n < 20) {
duplicateMovieClip ("bombA", "bombA" add n, n + 100);
n++;
}
while (m < 4) {
duplicateMovieClip ("bombB", "bombB" add m, m + 200);
m++;
}
Symbol 104 MovieClip Frame 7
while (n < 30) {
duplicateMovieClip ("bombA", "bombA" add n, n + 100);
n++;
}
while (m < 6) {
duplicateMovieClip ("bombB", "bombB" add m, m + 200);
m++;
}
Symbol 104 MovieClip Frame 10
stop();
Symbol 106 MovieClip Frame 1
stop();
Symbol 106 MovieClip Frame 2
stop();
attachMovie("lose", ranking, 0);
Symbol 108 MovieClip Frame 23
gotoAndPlay (1);
Symbol 114 MovieClip Frame 31
gotoAndPlay (1);
Symbol 116 Button
on (rollOver) {
tellTarget ("setumei") {
gotoAndStop ("A");
};
}
on (rollOut) {
tellTarget ("setumei") {
gotoAndStop ("null");
};
}
on (release) {
this = new Sound(this);
this.attachSound("okA");
this.start();
tellTarget ("../") {
type = 0;
};
gotoAndPlay (42);
}
Symbol 117 Button
on (rollOver) {
tellTarget ("setumei") {
gotoAndStop ("B");
};
}
on (rollOut) {
tellTarget ("setumei") {
gotoAndStop ("null");
};
}
on (release) {
this = new Sound(this);
this.attachSound("okB");
this.start();
tellTarget ("../") {
type = 1;
};
gotoAndPlay (42);
}
Symbol 118 MovieClip Frame 41
stop();
Symbol 118 MovieClip Frame 89
tellTarget ("../") {
gotoAndPlay ("game");
};
Symbol 132 MovieClip Frame 10
stop();
Symbol 135 MovieClip Frame 1
kyoriX = getProperty("ka-soru", _x) - getProperty("../jiki/jiki", _x);
kyoriY = getProperty("ka-soru", _y) - getProperty("../jiki/jiki", _y);
katamuki = kyoriY / kyoriX;
kakudo = Math.round((Math.atan(katamuki) * 180) / Math.PI);
if (kyoriX < 0) {
kakudo = 180 + kakudo;
}
if ((-1 >= kakudo) and (kakudo >= -90)) {
kakudo = kakudo + 360;
}
setProperty("ka-soru", _rotation , kakudo);
setProperty("ka-soru", _x , _xmouse);
setProperty("ka-soru", _y , _ymouse);
Symbol 135 MovieClip Frame 2
gotoAndPlay (1);
Symbol 138 MovieClip Frame 1
stageN = ../:stage;
Symbol 138 MovieClip Frame 5
removeMovieClip(this);
stop();
Symbol 147 MovieClip Frame 130
tellTarget ("../../") {
nextFrame();
};
Symbol 147 MovieClip Frame 141
stop();
removeMovieClip(this);
Symbol 148 MovieClip Frame 131
stop();
Symbol 151 MovieClip Frame 45
stop();
Symbol 152 MovieClip Frame 45
stop();
Symbol 153 MovieClip Frame 1
stop();
Symbol 153 MovieClip Frame 2
stop();
attachMovie("lose", ranking, 0);
Symbol 154 MovieClip Frame 1
stop();
Symbol 154 MovieClip Frame 2
attachMovie("win", nextstage, 0);
stop();
Symbol 157 MovieClip Frame 1
mx = 300;
my = 200;
pi = Math.PI;
kabe = 0;
hit = 0;
AI = 1;
attack = 0;
ATdire = random(50);
if (ATdire < 0) {
ATdire = 20;
}
kasokuAT = 20;
count = 0;
count2 = 0;
ueMAX = 20;
sitaMAX = 380;
migiMAX = 550;
hidariMAX = 50;
n = 1;
gotoAndPlay (2);
function move1(spd) {
Set("teki:vx", teki:vx + (spd * Math.cos((kakudo * pi) / 180)));
Set("teki:vy", teki:vy + (spd * Math.sin((kakudo * pi) / 180)));
}
function move2(spd) {
if (teki._x < (mx - 20)) {
Set("teki:vx", teki:vx + spd);
} else if ((mx + 20) < teki._x) {
Set("teki:vx", teki:vx - spd);
}
if (teki._y < (my - 20)) {
Set("teki:vy", teki:vy + spd);
} else if ((my + 20) < teki._y) {
Set("teki:vy", teki:vy - spd);
}
}
function move3(spd) {
if ((teki._x < jiki._x) and ((hidariMAX + 200) < teki._x)) {
Set("teki:vx", teki:vx - spd);
} else if ((jiki._x < teki._x) and (teki._x < (migiMAX - 200))) {
Set("teki:vx", teki:vx + spd);
}
if ((teki._y < jiki._y) and ((ueMAX + 150) < teki._y)) {
Set("teki:vy", teki:vy - spd);
} else if ((jiki._y < teki._y) and (teki._y < (sitaMAX - 150))) {
Set("teki:vy", teki:vy + spd);
}
if (teki._x < (hidariMAX + 150)) {
Set("teki:vx", teki:vx + spd);
} else if ((migiMAX - 150) < jiki._x) {
Set("teki:vx", teki:vx - spd);
}
if (teki._y < (ueMAX + 140)) {
Set("teki:vy", teki:vy + spd);
} else if ((sitaMAX - 140) < teki._y) {
Set("teki:vy", teki:vy - spd);
}
}
function move4(spd) {
if (teki._x < (hidariMAX + 100)) {
Set("teki:vx", teki:vx + spd);
} else if ((migiMAX - 100) < jiki._x) {
Set("teki:vx", teki:vx - spd);
}
if (teki._y < (ueMAX + 100)) {
Set("teki:vy", teki:vy + spd);
} else if ((sitaMAX - 100) < teki._y) {
Set("teki:vy", teki:vy - spd);
}
}
function move5(spd, houkou) {
kakudo2 = kakudo + houkou;
if ((((100 < jiki._x) and (jiki._x < 500)) and (80 < jiki._y)) and (jiki._y < 320)) {
Set("teki:vx", teki:vx + (spd * Math.cos((kakudo2 * pi) / 180)));
Set("teki:vy", teki:vy + (spd * Math.sin((kakudo2 * pi) / 180)));
}
}
function attack0() {
}
function attack1(nerai) {
tellTarget ("teki") {
attachMovie("wave", "kasoku", 0);
};
tamakakudo = kakudo + ((nerai / 2) - random(nerai));
tekitamaN = "tekitama" add n;
attachMovie("tekitama", tekitamaN, n + 30);
setProperty(tekitamaN, _x , teki._x);
setProperty(tekitamaN, _y , teki._y);
setProperty(tekitamaN, _height , tamakakudo);
n = n + 1;
if (30 < n) {
n = 1;
}
Set("teki:theta", (teki:kakudo * pi) / 180);
Set("teki:vx", teki:vx - (3 * Math.cos(teki:theta)));
Set("teki:vy", teki:vy - (3 * Math.sin(teki:theta)));
}
function attack2(nerai) {
tellTarget ("teki") {
attachMovie("wave", "kasoku", 0);
};
m = 0;
kakudo2 = kakudo + ((nerai / 2) - random(nerai));
while (m < 3) {
tamakakudo = (kakudo2 - 10) + (10 * m);
tekitamaN = "tekitama" add n;
attachMovie("tekitama", tekitamaN, n + 30);
setProperty(tekitamaN, _x , teki._x);
setProperty(tekitamaN, _y , teki._y);
setProperty(tekitamaN, _height , tamakakudo);
n = n + 1;
if (30 < n) {
n = 1;
}
m = m + 1;
}
Set("teki:theta", (teki:kakudo * pi) / 180);
Set("teki:vx", teki:vx - (10 * Math.cos(teki:theta)));
Set("teki:vy", teki:vy - (10 * Math.sin(teki:theta)));
}
function attack3(ATpow) {
tellTarget ("../../") {
attachMovie("wave", "kasoku", 0);
};
../../:kasoku._rotation = kakudo;
../../:kasoku._x = teki._x;
../../:kasoku._y = teki._y;
Set("teki:theta", (teki:kakudo * pi) / 180);
Set("teki:vx", ATpow * Math.cos(teki:theta));
Set("teki:vy", ATpow * Math.sin(teki:theta));
}
function attack4() {
if (teki:kakudo < 45) {
houkou = 1;
} else if (teki:kakudo < 135) {
houkou = 3;
} else if (teki:kakudo < 225) {
houkou = 2;
} else if (teki:kakudo < 315) {
houkou = 4;
} else {
houkou = 1;
}
razorN = "razor" add n;
attachMovie("beam", razorN, n + 100);
setProperty(razorN, _x , teki._x);
setProperty(razorN, _y , teki._y);
setProperty(razorN, _xscale , houkou);
n = n + 1;
if (30 < n) {
n = 1;
}
}
function attack5() {
tellTarget ("teki") {
attachMovie("wave", "kasoku", 0);
kasoku._rotation = hosoku;
};
tamakakudo = teki:kakudo + teki:hosoku;
tekitamaN = "tekitama" add n;
attachMovie("tekitama", tekitamaN, n + 30);
setProperty(tekitamaN, _x , teki._x);
setProperty(tekitamaN, _y , teki._y);
setProperty(tekitamaN, _height , tamakakudo);
n = n + 1;
if (30 < n) {
n = 1;
}
Set("teki:theta", (teki:kakudo * pi) / 180);
Set("teki:vx", teki:vx - (3 * Math.cos(teki:theta)));
Set("teki:vy", teki:vy - (3 * Math.sin(teki:theta)));
}
function attack6() {
tellTarget ("teki") {
attachMovie("wave", "kasoku", 0);
kasoku._rotation = hosoku;
};
m = 0;
while (m < 3) {
tamakakudo = ((teki:kakudo - 10) + (10 * m)) + teki:hosoku;
tekitamaN = "tekitama" add n;
attachMovie("tekitama", tekitamaN, n + 30);
setProperty(tekitamaN, _x , teki._x);
setProperty(tekitamaN, _y , teki._y);
setProperty(tekitamaN, _height , tamakakudo);
n = n + 1;
if (30 < n) {
n = 1;
}
m = m + 1;
}
Set("teki:theta", (teki:kakudo * pi) / 180);
Set("teki:vx", teki:vx - (10 * Math.cos(teki:theta)));
Set("teki:vy", teki:vy - (10 * Math.sin(teki:theta)));
}
Instance of Symbol 153 MovieClip "jiki" in Symbol 157 MovieClip Frame 1
onClipEvent (load) {
life = 100;
this._x = 200;
this._y = 200;
haba = this._width / 2;
vx = 0;
vy = 0;
type = ../../../:type;
speed = 0.6;
tamadire = 0;
pi = Math.PI;
}
onClipEvent (mouseDown) {
if ((tamadire == 0) & (0 < life)) {
pow = true;
attachMovie("tame", "aura", 0);
}
}
onClipEvent (mouseUp) {
if (type == 0) {
this = new Sound(this);
this.attachSound("shot");
this.setVolume(../../:pow);
this.start();
if (pow & (0 < life)) {
theta = (kakudo * pi) / 180;
pow = false;
removeMovieClip("aura");
attachMovie("wave", "hassya", 0);
vx = vx - ((1 + (../../:pow / 10)) * Math.cos(theta));
vy = vy - ((1 + (../../:pow / 10)) * Math.sin(theta));
tellTarget ("../") {
jitamaN = "jitama" add n;
attachMovie("tama", jitamaN, n);
setProperty(jitamaN, _x , jiki._x);
setProperty(jitamaN, _y , jiki._y);
setProperty(jitamaN, _alpha , ../:pow);
n = n + 1;
if (30 < n) {
n = 1;
}
};
../../:shot();
tamadire = 10;
}
}
if (type == 1) {
if (pow & (0 < life)) {
theta = (kakudo * pi) / 180;
pow = false;
removeMovieClip("aura");
tellTarget ("../../../") {
attachMovie("wave", "kasoku", 0);
};
../../../:kasoku._x = this._x;
../../../:kasoku._y = this._y;
../../../:kasoku._rotation = this._rotation;
vx = vx + ((10 + (../../:pow / 10)) * Math.cos(theta));
vy = vy + ((10 + (../../:pow / 10)) * Math.sin(theta));
this = new Sound(this);
this.attachSound("speed");
this.setVolume(../../:pow);
this.start();
../../:shot();
tamadire = 10;
}
}
}
onClipEvent (enterFrame) {
if (0 < life) {
if (0 < tamadire) {
tamadire = tamadire - 1;
}
if (pow) {
../../:tame();
}
kakudo = ../../mouse:kakudo;
setProperty(this, _rotation , kakudo);
if (Key.isDown(87)) {
vy = vy - speed;
}
if (Key.isDown(83)) {
vy = vy + speed;
}
if (Key.isDown(65)) {
vx = vx - speed;
}
if (Key.isDown(68)) {
vx = vx + speed;
}
vx = vx * 0.95;
vy = vy * 0.95;
this._x = this._x + vx;
this._y = this._y + vy;
if (getProperty(this, _x) < (../:hidariMAX + haba)) {
vx = -vx;
this._x = (../:hidariMAX + 1) + haba;
../../:kabeatari(vx);
}
if ((../:migiMAX - haba) < getProperty(this, _x)) {
vx = -vx;
this._x = (../:migiMAX - 1) - haba;
../../:kabeatari(vx);
}
if (getProperty(this, _y) < (../:ueMAX + haba)) {
vy = -vy;
this._y = (../:ueMAX + 1) + haba;
../../:kabeatari(vy);
}
if ((../:sitaMAX - haba) < getProperty(this, _y)) {
vy = -vy;
this._y = (../:sitaMAX - 1) - haba;
../../:kabeatari(vy);
}
} else {
removeMovieClip("aura");
gotoAndStop (2);
}
}
Instance of Symbol 154 MovieClip "teki" in Symbol 157 MovieClip Frame 1
onClipEvent (load) {
life = 100;
this._x = 400;
this._y = 200;
haba = this._width / 2;
vx = 0;
vy = 0;
if (random(2) == 1) {
vy = vy + 1;
} else {
vy = vy - 1;
}
speed = 0.4;
pi = Math.PI;
AI = 1;
attack = -1;
ATdire = 100;
kasokuAT = 20;
kakudo = 0;
}
onClipEvent (enterFrame) {
kakudosa = ../:kakudo - kakudo;
kakudo = ../:kakudo;
hosoku = (kakudosa * ../:kyori) / 15;
if (0 < life) {
../:tekiAI(_root.game:stage);
vx = vx * 0.95;
vy = vy * 0.95;
this._x = this._x + vx;
this._y = this._y + vy;
setProperty(this, _rotation , kakudo);
if (this._x < (../:hidariMAX + haba)) {
vx = -vx;
this._x = (../:hidariMAX + 1) + haba;
../../:tekikabeatari(vx);
}
if ((../:migiMAX - haba) < this._x) {
vx = -vx;
this._x = (../:migiMAX - 1) - haba;
../../:tekikabeatari(vx);
}
if (this._y < (../:ueMAX + haba)) {
vy = -vy;
this._y = (../:ueMAX + 1) + haba;
../../:tekikabeatari(vy);
}
if ((../:sitaMAX - haba) < this._y) {
vy = -vy;
this._y = (../:sitaMAX - 1) - haba;
../../:tekikabeatari(vy);
}
} else {
gotoAndStop (2);
}
}
Symbol 157 MovieClip Frame 2
function tekihit(xa, ya, vxa, vya, xb, yb, vxb, vyb) {
hit2 = 1;
this = new Sound(this);
this.attachSound("hit");
this.start();
p = 1.5;
pi = Math.PI;
theta = (kakudo * pi) / 180;
Yvb = (vxa * Math.cos(theta)) + (vya * Math.sin(theta));
Xva = ((-vxa) * Math.sin(theta)) + (vya * Math.cos(theta));
Yva = (vxb * Math.cos(theta)) + (vyb * Math.sin(theta));
Xvb = ((-vxb) * Math.sin(theta)) + (vyb * Math.cos(theta));
Set("jiki:vx", p * (((-Xva) * Math.sin(theta)) + (Yva * Math.cos(theta))));
Set("jiki:vy", p * ((Yva * Math.sin(theta)) + (Xva * Math.cos(theta))));
Set("teki:vx", p * (((-Xvb) * Math.sin(theta)) + (Yvb * Math.cos(theta))));
Set("teki:vy", p * ((Yvb * Math.sin(theta)) + (Xvb * Math.cos(theta))));
R = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
handou = (haba - R) / 2;
if (xa < xb) {
jiki._x = xa - handou;
teki._x = xb + handou;
} else if (xb < xa) {
jiki._x = xa + handou;
teki._x = xb - handou;
}
if (ya < yb) {
jiki._y = ya - handou;
teki._y = yb + handou;
} else if (yb < ya) {
jiki._y = ya + handou;
teki._y = yb - handou;
}
}
function tekiAI(stage) {
if (stage == 1) {
if (../:tekilife < 30) {
if (hit == 0) {
move3(teki:speed / 1.5);
}
if (kabe == 1) {
kabe = 0;
hit = 0;
}
} else if (../:tekilife < 70) {
if (hit == 0) {
move2(teki:speed / 3);
}
if (kabe == 1) {
kabe = 0;
hit = 0;
}
} else {
if (hit == 0) {
move3(teki:speed / 6);
}
if (kabe == 1) {
kabe = 0;
hit = 0;
}
}
} else if (stage == 2) {
if (50 < ../:tekilife) {
move2(teki:speed / 3);
if (ATdire == 0) {
attack1(30);
ATdire = 50;
}
} else {
count = count + 1;
if (count < 200) {
move1(teki:speed);
if (ATdire == 0) {
if (random(10) == 0) {
attack2(50);
ATdire = 40;
} else {
attack1(50);
ATdire = 30;
}
}
} else {
move2(teki:speed / 3);
}
if (count == 300) {
count = 0;
}
}
} else if (stage == 3) {
count = count + 1;
if (40 < ../:tekilife) {
if (count < 200) {
move1(teki:speed);
} else {
move2(teki:speed);
}
if (ATdire == 0) {
attack2(20);
ATdire = 60;
}
if (400 < count) {
count = 0;
}
} else {
count2 = count2 + 1;
if (70 < count2) {
move2(teki:speed * 2);
if (ATdire == 0) {
attack1(60);
ATdire = 2;
}
} else {
move2(teki:speed);
}
if (80 < count2) {
count2 = 0;
}
}
} else if (stage == 4) {
if (../:tekilife < 30) {
if (hit == 0) {
move5(speed);
move3(speed);
}
if ((hit2 == 1) and (_root:type == 1)) {
hit2 = 0;
speed = speed * 0.8;
}
if (ATdire == 0) {
attack3(kasokuAT);
ATdire = 50;
hit = 0;
}
} else {
speed = teki:speed + ((100 - ../:tekilife) / 80);
if (hit == 1) {
move3(speed);
} else {
move1(speed);
}
if (kabe == 1) {
kabe = 0;
hit = 0;
}
}
} else if (stage == 5) {
count = count + 1;
if (../:tekilife < 40) {
if (ATdire < 100) {
if (count < 200) {
move1(teki:speed);
} else {
move2(teki:speed);
}
}
if (ATdire == 120) {
attack4();
} else if (ATdire == 100) {
attack4();
} else if (ATdire == 80) {
attack2();
} else if (ATdire == 60) {
attack1();
} else if (ATdire == 40) {
attack2();
} else if (ATdire == 20) {
attack1();
} else if (ATdire == 0) {
attack3(kasokuAT);
ATdire = 200;
}
} else if (../:tekilife < 80) {
if (ATdire < 100) {
if (count < 200) {
move1(teki:speed);
} else {
move2(teki:speed);
}
}
if (ATdire == 100) {
attack4();
} else if (ATdire == 80) {
attack2();
} else if (ATdire == 60) {
attack1();
} else if (ATdire == 40) {
attack2();
} else if (ATdire == 20) {
attack1();
} else if (ATdire == 0) {
attack3(kasokuAT);
ATdire = 200;
}
} else {
if (ATdire < 100) {
if (count < 200) {
move1(teki:speed);
} else {
move2(teki:speed);
}
}
if (ATdire == 100) {
attack1();
} else if (ATdire == 80) {
attack2();
} else if (ATdire == 60) {
attack1();
} else if (ATdire == 40) {
attack2();
} else if (ATdire == 20) {
attack1();
} else if (ATdire == 0) {
attack3(kasokuAT);
ATdire = 150;
}
}
if (400 < count) {
count = 0;
}
} else if (stage == 6) {
count = count + 1;
if (count < 200) {
move2(teki:speed);
if (ATdire == 0) {
attack5();
ATdire = 10;
}
} else if (count < 250) {
move3(teki:speed);
if (ATdire == 0) {
attack4();
ATdire = 20;
}
} else if (count < 350) {
move2(teki:speed / 2);
if (ATdire == 0) {
attack6();
ATdire = 30;
}
} else if (count < 600) {
move4(teki:speed);
if (ATdire == 0) {
attack = random(6) + 1;
if (attack == 1) {
attack1();
ATdire = 10;
} else if (attack == 2) {
attack2();
ATdire = 10;
} else if (attack == 3) {
attack3(kasokuAT);
ATdire = 10;
} else if (attack == 4) {
attack4();
ATdire = 10;
} else if (attack == 5) {
attack5();
ATdire = 10;
} else if (attack == 6) {
attack6();
ATdire = 10;
}
}
} else {
count = 0;
}
} else {
if (AI == 1) {
move2(teki:speed);
}
if (ATdire == 0) {
attack = random(6) + 1;
if (attack == 1) {
attack1();
ATdire = 10;
} else if (attack == 2) {
attack2();
ATdire = 10;
} else if (attack == 3) {
attack3(kasokuAT);
ATdire = 10;
} else if (attack == 4) {
attack4();
ATdire = 10;
} else if (attack == 5) {
attack5();
ATdire = 10;
} else if (attack == 6) {
attack6();
ATdire = 10;
}
}
}
}
if (0 < ATdire) {
ATdire = ATdire - 1;
}
Instance of Symbol 156 MovieClip "script" in Symbol 157 MovieClip Frame 2
onClipEvent (load) {
kakudo = 0;
}
onClipEvent (enterFrame) {
if ((0 < ../jiki:life) and (0 < ../teki:life)) {
tellTarget ("../") {
kyoriX = jiki._x - teki._x;
kyoriY = jiki._y - teki._y;
kyori = Math.sqrt((kyoriX * kyoriX) + (kyoriY * kyoriY));
katamuki = kyoriY / kyoriX;
kakudo = Math.round((Math.atan(katamuki) * 180) / Math.PI);
if (kyoriX < 0) {
kakudo = 180 + kakudo;
}
if ((-1 >= kakudo) and (kakudo >= -90)) {
kakudo = kakudo + 360;
}
haba = jiki.haba + teki.haba;
if (kyori < haba) {
attachMovie("hibana", "hitmark", 0);
hitmark._x = (jiki._x + teki._x) / 2;
hitmark._y = (jiki._y + teki._y) / 2;
tekihit(jiki._x, jiki._y, jiki:vx, jiki:vy, teki._x, teki._y, teki:vx, teki:vy);
}
};
}
}
Symbol 157 MovieClip Frame 3
gotoAndPlay (2);
Symbol 164 MovieClip Frame 3
stop();
Symbol 165 MovieClip Frame 4
stop();
tellTarget ("../") {
gotoAndPlay (1);
};
Symbol 166 MovieClip Frame 1
stop();
Symbol 166 MovieClip Frame 2
stop();
Symbol 168 MovieClip Frame 1
life = 100;
tekilife = 100;
score = 0;
pow = 0;
stage = 1;
Instance of Symbol 135 MovieClip "mouse" in Symbol 168 MovieClip Frame 1
onClipEvent (load) {
Mouse.hide();
}
Symbol 168 MovieClip Frame 35
stop();
function kabeatari(va) {
tellTarget ("flash") {
play();
};
if (va < 0) {
va = -va;
}
va = Math.round(va);
if (0 < tekilife) {
life = life - va;
}
if (life < 0) {
life = 0;
if (0 < jiki/teki:life) {
Set("jiki/jiki:life", 0);
setProperty("pow", _height , 0);
}
}
setProperty("life", _height , life);
}
function tekikabeatari(va) {
Set("jiki/:kabe", 1);
tellTarget ("flash") {
play();
};
if (va < 0) {
va = -va;
}
va = Math.round(va);
if (0 < life) {
tekilife = Math.round(tekilife - (va + 5));
}
if (0 >= tekilife) {
tekilife = 0;
if (0 < jiki/jiki:life) {
Set("jiki/teki:life", 0);
}
}
setProperty("tekilife", _height , tekilife);
if (0 < life) {
score = Number(score) + ((va + 3) * (va + 3));
}
}
function tame() {
pow = Math.round((pow + 1) * 1.09);
if (life < pow) {
pow = life;
}
setProperty("pow", _height , pow);
}
function shot() {
pow = 0;
setProperty("pow", _height , pow);
}
Symbol 168 MovieClip Frame 36
setProperty("tekilife", _height , tekilife);
setProperty("life", _height , life);
setProperty("pow", _height , 0);
stop();
Symbol 168 MovieClip Frame 37
play();
Symbol 168 MovieClip Frame 38
pow = 0;
life = 100;
tekilife = 100;
setProperty("tekilife", _height , tekilife);
setProperty("life", _height , life);
setProperty("pow", _height , 0);
stop();
Symbol 168 MovieClip Frame 39
stop();
Symbol 207 Button
on (release) {
tellTarget ("../") {
gotoAndStop ("title");
};
}
Symbol 230 MovieClip Frame 1
this.loadVariables("hiscore.txt");
Symbol 230 MovieClip Frame 2
stop();
Symbol 232 Button
on (release) {
tellTarget (_root) {
gotoAndStop ("title");
};
}