|
1
|
function scr_nextactscr_nextact
function scr_nextact()
{
global.acting[0] = 0;
global.acting[1] = 0;
global.acting[2] = 0;
global.actingsingle[global.currentactingchar] = 0;
__minstance = global.monsterinstance[global.actingtarget[global.currentactingchar]];
with (__minstance)
{
acting = 0;
actcon = 0;
actconsus = 0;
actconral = 0;
actconnoe = 0;
}
var singleactcomplete = 0;
while (global.currentactingchar < 3)
{
global.currentactingchar++;
if (global.currentactingchar < 3)
{
if (global.actingsingle[global.currentactingchar] == 1)
{
__minstance = global.monsterinstance[global.actingtarget[global.currentactingchar]];
if (global.char[global.currentactingchar] == 2)
{
with (__minstance)
actconsus = 1;
if (global.actingsimul[global.currentactingchar] == 0)
singleactcomplete = 1;
break;
}
if (global.char[global.currentactingchar] == 3)
{
with (__minstance)
actconral = 1;
if (global.actingsimul[global.currentactingchar] == 0)
singleactcomplete = 1;
break;
}
if (global.char[global.currentactingchar] == 4)
{
with (__minstance)
actconnoe = 1;
if (global.actingsimul[global.currentactingchar] == 0)
singleactcomplete = 1;
break;
}
}
}
}
if (global.currentactingchar >= 3)
{
with (obj_monsterparent)
{
acting = 0;
actingsus = 0;
actingral = 0;
actingnoe = 0;
}
global.currentactingchar = 0;
scr_attackphase();
}
else if (!singleactcomplete)
{
scr_act_simul();
}
}
()
|
|
2
|
{
|
|
3
|
global.acting[0] = 0;
|
|
4
|
global.acting[1] = 0;
|
|
5
|
global.acting[2] = 0;
|
|
6
|
global.actingsingle[global.currentactingchar] = 0;
|
|
7
|
__minstance = global.monsterinstance[global.actingtarget[global.currentactingchar]];
|
|
8
|
with (__minstance)
|
|
9
|
{
|
|
10
|
acting = 0;
|
|
11
|
actcon = 0;
|
|
12
|
actconsus = 0;
|
|
13
|
actconral = 0;
|
|
14
|
actconnoe = 0;
|
|
15
|
}
|
|
16
|
var singleactcomplete = 0;
|
|
17
|
while (global.currentactingchar < 3)
|
|
18
|
{
|
|
19
|
global.currentactingchar++;
|
|
20
|
if (global.currentactingchar < 3)
|
|
21
|
{
|
|
22
|
if (global.actingsingle[global.currentactingchar] == 1)
|
|
23
|
{
|
|
24
|
__minstance = global.monsterinstance[global.actingtarget[global.currentactingchar]];
|
|
25
|
if (global.char[global.currentactingchar] == 2)
|
|
26
|
{
|
|
27
|
with (__minstance)
|
|
28
|
actconsus = 1;
|
|
29
|
if (global.actingsimul[global.currentactingchar] == 0)
|
|
30
|
singleactcomplete = 1;
|
|
31
|
break;
|
|
32
|
}
|
|
33
|
if (global.char[global.currentactingchar] == 3)
|
|
34
|
{
|
|
35
|
with (__minstance)
|
|
36
|
actconral = 1;
|
|
37
|
if (global.actingsimul[global.currentactingchar] == 0)
|
|
38
|
singleactcomplete = 1;
|
|
39
|
break;
|
|
40
|
}
|
|
41
|
if (global.char[global.currentactingchar] == 4)
|
|
42
|
{
|
|
43
|
with (__minstance)
|
|
44
|
actconnoe = 1;
|
|
45
|
if (global.actingsimul[global.currentactingchar] == 0)
|
|
46
|
singleactcomplete = 1;
|
|
47
|
break;
|
|
48
|
}
|
|
49
|
}
|
|
50
|
}
|
|
51
|
}
|
|
52
|
if (global.currentactingchar >= 3)
|
|
53
|
{
|
|
54
|
with (obj_monsterparent)
|
|
55
|
{
|
|
56
|
acting = 0;
|
|
57
|
actingsus = 0;
|
|
58
|
actingral = 0;
|
|
59
|
actingnoe = 0;
|
|
60
|
}
|
|
61
|
global.currentactingchar = 0;
|
|
62
|
scr_attackphasescr_attackphase
function scr_attackphase()
{
with (obj_battlecontroller)
{
techwon = 0;
if (scr_monsterpop() == 0)
techwon = 1;
if (global.chapter == 2 && i_ex(obj_berdlyb_enemy) && obj_berdlyb_enemy.endcon == 1)
techwon = 1;
else if (techwon == 1)
scr_wincombat();
if (techwon == 0)
{
for (__hiti = 0; __hiti < 3; __hiti++)
global.hittarget[__hiti] = 0;
fightphase = 1;
global.charturn = 3;
if (global.charaction[0] == 4 || global.charaction[0] == 2)
fightphase = 0;
if (global.charaction[1] == 4 || global.charaction[1] == 2)
fightphase = 0;
if (global.charaction[2] == 4 || global.charaction[2] == 2)
fightphase = 0;
if (global.myfight == 4)
fightphase = 1;
if (fightphase == 1)
{
global.myfight = 1;
instance_create(xx + 2, yy + 365, obj_attackpress);
}
else
{
global.myfight = 4;
instance_create(0, 0, obj_spellphase);
}
}
}
}
();
|
|
63
|
}
|
|
64
|
else if (!singleactcomplete)
|
|
65
|
{
|
|
66
|
scr_act_simulscr_act_simul
function scr_act_simul()
{
__simulcount = 0;
for (__ii = global.currentactingchar; __ii < 3; __ii++)
{
__foundsimul = 0;
if (global.actingsingle[__ii] == 1 && instance_exists(obj_monsterparent))
{
if (global.char[__ii] == 1 && global.actsimul[global.actingtarget[__ii]][global.actingchoice[__ii]] == 1)
{
obj_monsterparent.simulorderkri = __simulcount;
with (global.monsterinstance[global.actingtarget[__ii]])
actcon = 0;
__foundsimul = 1;
}
if (global.char[__ii] == 2 && global.actsimulsus[global.actingtarget[__ii]][global.actingchoice[__ii]] == 1)
{
obj_monsterparent.simulordersus = __simulcount;
with (global.monsterinstance[global.actingtarget[__ii]])
actconsus = 1;
__foundsimul = 1;
}
if (global.char[__ii] == 3 && global.actsimulral[global.actingtarget[__ii]][global.actingchoice[__ii]] == 1)
{
obj_monsterparent.simulorderral = __simulcount;
with (global.monsterinstance[global.actingtarget[__ii]])
actconral = 1;
__foundsimul = 1;
}
if (global.char[__ii] == 4 && global.actsimulnoe[global.actingtarget[__ii]][global.actingchoice[__ii]] == 1)
{
obj_monsterparent.simulordernoe = __simulcount;
with (global.monsterinstance[global.actingtarget[__ii]])
actconnoe = 1;
__foundsimul = 1;
}
if (__foundsimul)
{
global.actingsingle[__ii] = 0;
__simulcount++;
}
obj_monsterparent.simultotal = __simulcount;
}
}
}
();
|
|
67
|
}
|
|
68
|
}
|