Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_ribbick_enemy_Step_0

(view raw script w/o annotations or w/e)
1
if (_init == false)
2
{
3
    if (i_ex(obj_battlecontroller) && obj_battlecontroller.rabbickvar == myself && global.flag[global.monstertype[myself] + 600] >= 1 && global.encounterno == 126???)
4
    {
5
        amirabbick = true;
6
        global.monstertype[myself] = 13Rabbick;
7
    }
8
    _init = true;
9
}
10
if (global.monster[myself] == 1)
11
{
12
    if (
scr_isphase
scr_isphase

function
scr_isphase(arg0)
{ __isphase = 0; if (arg0 == "menu" && global.myfight == 0) __isphase = 1; if (arg0 == "acting" && global.myfight == 3) __isphase = 1; if (arg0 == "victory" && global.myfight == 7) __isphase = 1; if (arg0 == "attack" || arg0 == "fight") { if (global.myfight == 1) __isphase = 1; } if (arg0 == "spell" || arg0 == "item") { if (global.myfight == 4) __isphase = 1; } if (arg0 == "enemytalk" || arg0 == "balloon") { if (global.mnfight == 1) __isphase = 1; } if (arg0 == "enemyattack" || arg0 == "bullets") { if (global.mnfight == 2) __isphase = 1; } return __isphase; }
("enemytalk") && talked == 0)
13
    {
14
        
scr_randomtarget
scr_randomtarget

function
scr_randomtarget()
{ abletotarget = 1; if (global.charcantarget[0] == 0 && global.charcantarget[1] == 0 && global.charcantarget[2] == 0) abletotarget = 0; mytarget = choose(0, 1, 2); if (abletotarget == 1) { while (global.charcantarget[mytarget] == 0) mytarget = choose(0, 1, 2); } else { mytarget = 3; } global.targeted[mytarget] = 1; if (global.chapter >= 2 && mytarget != 3) { if (global.charcantarget[0]) global.targeted[0] = 1; if (global.charcantarget[1]) global.targeted[1] = 1; if (global.charcantarget[2]) global.targeted[2] = 1; mytarget = 4; } }
();
15
        myattackchoice = choose(0, 1);
16
        if (blown && amirabbick)
17
            myattackchoice = 2;
18
        CroakOnX = false;
19
        presscount = 0;
20
        presstimer = 0;
21
        startcroaktimer = false;
22
        blow_wait = 0;
23
        myattackpriority = 1;
24
        if (myattackchoice == 2)
25
            myattackpriority = 50;
26
        
scr_attackpriority
scr_attackpriority

function
scr_attackpriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.attackpriority < arg0) { obj_battlecontroller.attackpriority = arg0; return true; } else { return false; } } else { return false; } }
(myattackpriority - 1);
27
        if (!instance_exists(obj_darkener))
28
            instance_create(0, 0, obj_darkener);
29
        global.typer = 50;
30
        rr = choose(0, 1, 2, 3);
31
        if (amirabbick == false)
32
        {
33
            if (blown && irandom(100) < 10 && blownturn > 0)
34
            {
35
                if (rr == 0 || rr == 1)
36
                    msgsetloc(0, 
A lost
and lost
and lost girl.
"A lost&and lost&and lost girl.", "obj_ribbick_enemy_slash_Step_0_gml_44_0"
);
37
                if (rr == 2 || rr == 3)
38
                    msgsetloc(0, 
A crying
and crying
and crying boy.
"A crying&and crying&and crying boy.", "obj_ribbick_enemy_slash_Step_0_gml_45_0"
);
39
            }
40
            else if (blown)
41
            {
42
                blownturn++;
43
                if (rr == 0)
44
                    msgsetloc(0, 
A messy and
unfocused girl.
"A messy and&unfocused girl.", "obj_ribbick_enemy_slash_Step_0_gml_50_0"
);
45
                if (rr == 1)
46
                    msgsetloc(0, 
A rowdy and
dirty girl.
"A rowdy and&dirty girl.", "obj_ribbick_enemy_slash_Step_0_gml_51_0"
);
47
                if (rr == 2)
48
                    msgsetloc(0, 
A poorly
trimmed boy.
"A poorly&trimmed boy.", "obj_ribbick_enemy_slash_Step_0_gml_52_0"
);
49
                if (rr == 3)
50
                    msgsetloc(0, 
A quiet and
smelly boy.
"A quiet and&smelly boy.", "obj_ribbick_enemy_slash_Step_0_gml_53_0"
);
51
            }
52
            else
53
            {
54
                if (rr == 0)
55
                    msgsetloc(0, 
Guruuuu---
"Guruuuu---", "obj_ribbick_enemy_slash_Step_0_gml_57_0"
);
56
                if (rr == 1)
57
                    msgsetloc(0, 
Woof.
"Woof.", "obj_ribbick_enemy_slash_Step_0_gml_58_0"
);
58
                if (rr == 2)
59
                    msgsetloc(0, 
Sizzy snuzz,
what's the buzz?
"Sizzy snuzz,&what's the buzz?", "obj_ribbick_enemy_slash_Step_0_gml_59_0"
);
60
                if (rr == 3)
61
                    msgsetloc(0, 
Hip, hip
"Hip, hip", "obj_ribbick_enemy_slash_Step_0_gml_60_0"
);
62
            }
63
        }
64
        else if (blown)
65
        {
66
            if (rr == 0)
67
                msgsetloc(0, 
A sweet and
fresh girl.
"A sweet and&fresh girl.", "obj_ribbick_enemy_slash_Step_0_gml_67_0"
);
68
            if (rr == 1)
69
                msgsetloc(0, 
A nice and
tidy girl.
"A nice and&tidy girl.", "obj_ribbick_enemy_slash_Step_0_gml_68_0"
);
70
            if (rr == 2)
71
                msgsetloc(0, 
A soft and
clean boy.
"A soft and&clean boy.", "obj_ribbick_enemy_slash_Step_0_gml_69_0"
);
72
            if (rr == 3)
73
                msgsetloc(0, 
A refreshing
boy.
"A refreshing&boy.", "obj_ribbick_enemy_slash_Step_0_gml_70_0"
);
74
        }
75
        else
76
        {
77
            rr = choose(0, 1, 2, 3, 4);
78
            if (rr == 0)
79
                msgsetloc(0, 
Duruuuu---
"Duruuuu---", "obj_ribbick_enemy_slash_Step_0_gml_75_0"
);
80
            if (rr == 1)
81
                msgsetloc(0, 
Meow.
"Meow.", "obj_ribbick_enemy_slash_Step_0_gml_76_0"
);
82
            if (rr == 2)
83
                msgsetloc(0, 
Snitter snatter,
what's the matter
"Snitter snatter,&what's the matter", "obj_ribbick_enemy_slash_Step_0_gml_77_0"
);
84
            if (rr == 3)
85
                msgsetloc(0, 
Hop, hop
"Hop, hop", "obj_ribbick_enemy_slash_Step_0_gml_78_0"
);
86
            if (rr == 4)
87
                msgsetloc(0, 
Bunnies are the
sequel to frogs.
"Bunnies are the&sequel to frogs.", "obj_ribbick_enemy_slash_Step_0_gml_79_0"
);
88
        }
89
        
scr_enemyblcon
scr_enemyblcon

function
scr_enemyblcon(arg0, arg1, arg2)
{ if (arg2 == 0) { mywriter = instance_create(arg0, arg1, obj_writer); return mywriter; } if (arg2 == 1) { myblcon = instance_create(arg0, arg1, obj_battleblcon); return myblcon; } if (arg2 == 2) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_v; return myblcon; } if (arg2 == 3) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_long; return myblcon; } if (arg2 == 4) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_long; myblcon.image_index = 0; myblcon.image_speed = 0; return myblcon; } if (arg2 == 5) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_long; myblcon.image_index = 1; myblcon.image_speed = 0; return myblcon; } if (arg2 == 6) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_clubs; myblcon.image_index = 2; myblcon.image_speed = 0; return myblcon; } if (arg2 == 7) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_long_r; myblcon.image_index = 2; myblcon.image_speed = 0; return myblcon; } if (arg2 == 8) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_long_tall; return myblcon; } if (arg2 == 10) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_long; myblcon.auto_length = 1; return myblcon; } if (arg2 == 11) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_v2_left; return myblcon; } if (arg2 == 12) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_v2_right; return myblcon; } if (arg2 == 12.1) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_v2_right2; return myblcon; } if (arg2 == 12.2) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_v2_right3; return myblcon; } if (arg2 == 12.3) { myblcon = instance_create(arg0, arg1, obj_battleblcon); myblcon.sprite_index = spr_battleblcon_v2_right4; return myblcon; } if (arg2 == 12.4) { ...
(x - 10, y + 60, 10);
90
        talked = 1;
91
        talktimer = 0;
92
        rtimer = 0;
93
    }
94
    if (talked == 1 && 
scr_isphase
scr_isphase

function
scr_isphase(arg0)
{ __isphase = 0; if (arg0 == "menu" && global.myfight == 0) __isphase = 1; if (arg0 == "acting" && global.myfight == 3) __isphase = 1; if (arg0 == "victory" && global.myfight == 7) __isphase = 1; if (arg0 == "attack" || arg0 == "fight") { if (global.myfight == 1) __isphase = 1; } if (arg0 == "spell" || arg0 == "item") { if (global.myfight == 4) __isphase = 1; } if (arg0 == "enemytalk" || arg0 == "balloon") { if (global.mnfight == 1) __isphase = 1; } if (arg0 == "enemyattack" || arg0 == "bullets") { if (global.mnfight == 2) __isphase = 1; } return __isphase; }
("enemytalk"))
95
        
scr_blconskip
scr_blconskip

function
scr_blconskip(arg0)
{ if (arg0 >= 0) { if (button1_p() && talktimer > arg0) talktimer = talkmax; talktimer += 1; if (talktimer >= talkmax) { with (obj_writer) instance_destroy(); global.mnfight = 1.5; } } else if (arg0 == -1) { if (instance_exists(obj_writer) == false) global.mnfight = 1.5; } else if (arg0 == -2) { talktimer += 1; if (talktimer > 15) talktimer = talkmax; if (talktimer >= talkmax) { with (obj_writer) instance_destroy(); global.mnfight = 1.5; } } }
(15);
96
    if (global.mnfight == 1.5)
97
    {
98
        if (
scr_attackpriority
scr_attackpriority

function
scr_attackpriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.attackpriority < arg0) { obj_battlecontroller.attackpriority = arg0; return true; } else { return false; } } else { return false; } }
(myattackpriority))
99
        {
100
            if (!instance_exists(obj_growtangle))
101
                instance_create(__view_get(e__VW.XView, 0) + 320, __view_get(e__VW.YView, 0) + 170, obj_growtangle);
102
            if (!instance_exists(obj_moveheart))
103
                
scr_moveheart
scr_moveheart

function
scr_moveheart()
{ global.inv = 0; return instance_create(obj_herokris.x + 10, obj_herokris.y + 40, obj_moveheart); }
();
104
            global.mnfight = 2;
105
            
scr_turntimer
scr_turntimer

function
scr_turntimer(arg0)
{ if (global.turntimer < arg0) global.turntimer = arg0; }
(200);
106
        }
107
    }
108
    if (
scr_isphase
scr_isphase

function
scr_isphase(arg0)
{ __isphase = 0; if (arg0 == "menu" && global.myfight == 0) __isphase = 1; if (arg0 == "acting" && global.myfight == 3) __isphase = 1; if (arg0 == "victory" && global.myfight == 7) __isphase = 1; if (arg0 == "attack" || arg0 == "fight") { if (global.myfight == 1) __isphase = 1; } if (arg0 == "spell" || arg0 == "item") { if (global.myfight == 4) __isphase = 1; } if (arg0 == "enemytalk" || arg0 == "balloon") { if (global.mnfight == 1) __isphase = 1; } if (arg0 == "enemyattack" || arg0 == "bullets") { if (global.mnfight == 2) __isphase = 1; } return __isphase; }
("bullets") && attacked == 0)
109
    {
110
        rtimer += 1;
111
        if (rtimer == 12)
112
        {
113
            if (i_ex(obj_volumeup))
114
                myattackchoice = 1;
115
            if (myattackchoice == 0)
116
            {
117
                global.monsterattackname[myself] = "RibbickJump";
118
                dc = 
scr_bulletspawner
scr_bulletspawner

function
scr_bulletspawner(arg0, arg1, arg2)
{ __dc = instance_create(arg0, arg1, arg2); __dc.creator = myself; __dc.creatorid = id; __dc.target = mytarget; __dc.damage = global.monsterat[myself] * 5; return __dc; }
(x, y, obj_dbulletcontroller);
119
                dc.type = 110;
120
            }
121
            else if (myattackchoice == 1)
122
            {
123
                global.monsterattackname[myself] = "RibbickFly";
124
                dc = 
scr_bulletspawner
scr_bulletspawner

function
scr_bulletspawner(arg0, arg1, arg2)
{ __dc = instance_create(arg0, arg1, arg2); __dc.creator = myself; __dc.creatorid = id; __dc.target = mytarget; __dc.damage = global.monsterat[myself] * 5; return __dc; }
(x, y, obj_dbulletcontroller);
125
                dc.type = 111;
126
            }
127
            else if (myattackchoice == 2)
128
            {
129
                global.monsterattackname[myself] = "RabbickBounce";
130
                dc = 
scr_bulletspawner
scr_bulletspawner

function
scr_bulletspawner(arg0, arg1, arg2)
{ __dc = instance_create(arg0, arg1, arg2); __dc.creator = myself; __dc.creatorid = id; __dc.target = mytarget; __dc.damage = global.monsterat[myself] * 5; return __dc; }
(x, y, obj_dbulletcontroller);
131
                dc.type = 112;
132
            }
133
            
scr_turntimer
scr_turntimer

function
scr_turntimer(arg0)
{ if (global.turntimer < arg0) global.turntimer = arg0; }
(140);
134
            attackanim = true;
135
            turns += 1;
136
            noballoon = false;
137
            bet = false;
138
            fixedbet = false;
139
            cheat = false;
140
            global.typer = 6;
141
            global.fc = 0;
142
            rr = choose(0, 1, 2, 3, 4);
143
            if (amirabbick == false || (amirabbick == true && blown == false))
144
            {
145
                if (
scr_messagepriority
scr_messagepriority

function
scr_messagepriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.messagepriority < arg0) { obj_battlecontroller.messagepriority = arg0; return true; } else { return false; } } else { return false; } }
(random(2)))
146
                {
147
                    if (rr == 0)
148
                        global.battlemsg[0] = stringsetloc(
* Ribbick wants to be friends with a dancing trash can.
"* Ribbick wants to be friends with a dancing trash can.", "obj_ribbick_enemy_slash_Step_0_gml_155_0"
);
149
                    if (rr == 1)
150
                        global.battlemsg[0] = stringsetloc(
* The battlefield is filled with the smell of pungent mustard.
"* The battlefield is filled with the smell of pungent mustard.", "obj_ribbick_enemy_slash_Step_0_gml_156_0"
);
151
                    if (rr == 2)
152
                        global.battlemsg[0] = stringsetloc(
* Ribbick enriches the back stage floor with nutrients.
"* Ribbick enriches the back stage floor with nutrients.", "obj_ribbick_enemy_slash_Step_0_gml_157_0"
);
153
                    if (rr == 3)
154
                        global.battlemsg[0] = stringsetloc(
* Ribbick emits a groany must.
"* Ribbick emits a groany must.", "obj_ribbick_enemy_slash_Step_0_gml_158_0"
);
155
                }
156
                if (global.monsterhp[myself] <= (global.monstermaxhp[myself] / 3) && 
scr_messagepriority
scr_messagepriority

function
scr_messagepriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.messagepriority < arg0) { obj_battlecontroller.messagepriority = arg0; return true; } else { return false; } } else { return false; } }
(100 + random(2)))
157
                    global.battlemsg[0] = stringsetloc(
* Ribbick's getting dangerously clean.
"* Ribbick's getting dangerously clean.", "obj_ribbick_enemy_slash_Step_0_gml_160_0"
);
158
                if (global.mercymod[myself] >= global.mercymax[myself] && 
scr_messagepriority
scr_messagepriority

function
scr_messagepriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.messagepriority < arg0) { obj_battlecontroller.messagepriority = arg0; return true; } else { return false; } } else { return false; } }
(100 + random(2)))
159
                    global.battlemsg[0] = stringsetloc(
* Ribbick is dirtier than ever, but that's fine.
"* Ribbick is dirtier than ever, but that's fine.", "obj_ribbick_enemy_slash_Step_0_gml_161_0"
);
160
            }
161
            else
162
            {
163
                if (
scr_messagepriority
scr_messagepriority

function
scr_messagepriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.messagepriority < arg0) { obj_battlecontroller.messagepriority = arg0; return true; } else { return false; } } else { return false; } }
(200 + random(2)))
164
                {
165
                    if (rr == 0)
166
                        global.battlemsg[0] = stringsetloc(
* Rabbick is looking for a couch to get stuck under.
"* Rabbick is looking for a couch to get stuck under.", "obj_ribbick_enemy_slash_Step_0_gml_177_0"
);
167
                    if (rr == 1)
168
                        global.battlemsg[0] = stringsetloc(
* The battlefield is filled with the smell of dusty mustard.
"* The battlefield is filled with the smell of dusty mustard.", "obj_ribbick_enemy_slash_Step_0_gml_178_0"
);
169
                    if (rr == 2)
170
                        global.battlemsg[0] = stringsetloc(
* Rabbick ambiently damages the soil.
"* Rabbick ambiently damages the soil.", "obj_ribbick_enemy_slash_Step_0_gml_179_0"
);
171
                    if (rr == 3)
172
                        global.battlemsg[0] = stringsetloc(
* Rabbick emits a musty groan.
"* Rabbick emits a musty groan.", "obj_ribbick_enemy_slash_Step_0_gml_180_0"
);
173
                }
174
                if (global.mercymod[myself] >= global.mercymax[myself] && 
scr_messagepriority
scr_messagepriority

function
scr_messagepriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.messagepriority < arg0) { obj_battlecontroller.messagepriority = arg0; return true; } else { return false; } } else { return false; } }
(300 + random(2)))
175
                    global.battlemsg[0] = stringsetloc(
* Rabbick is now nice and clean.
"* Rabbick is now nice and clean. ", "obj_ribbick_enemy_slash_Step_0_gml_183_0"
);
176
                if (global.monsterhp[myself] <= (global.monstermaxhp[myself] / 3) && 
scr_messagepriority
scr_messagepriority

function
scr_messagepriority(arg0)
{ if (i_ex(obj_battlecontroller)) { if (obj_battlecontroller.messagepriority < arg0) { obj_battlecontroller.messagepriority = arg0; return true; } else { return false; } } else { return false; } }
(300 + random(2)))
177
                    global.battlemsg[0] = stringsetloc(
* Rabbick is starting to look wispy.
"* Rabbick is starting to look wispy.", "obj_ribbick_enemy_slash_Step_0_gml_182_0"
);
178
            }
179
            attacked = 1;
180
        }
181
    }
182
    if (global.mnfight == 2 && global.turntimer > 1)
183
    {
184
        if (revealed == true && justrevealedtoberabbick == false)
185
        {
186
            justrevealedtoberabbick = true;
187
            global.battlemsg[0] = stringsetloc(
* Underneath the dust, it was really Rabbick!
"* Underneath the dust, it was really Rabbick!", "obj_ribbick_enemy_slash_Step_0_gml_172_0"
);
188
        }
189
    }
190
}
191
if (global.myfight == 3)
192
{
193
    xx = __view_get(e__VW.XView, 0);
194
    yy = __view_get(e__VW.YView, 0);
195
    if (acting == 1 && actcon == 0)
196
    {
197
        actcon = 1;
198
        if (amirabbick && blown)
199
            msgsetloc(0, 
* RABBICK - This dusty bunny needs a bit of spring cleaning.Wait for inputClose Message
"* RABBICK - This dusty bunny needs a bit of spring cleaning./%", "obj_ribbick_enemy_slash_Step_0_gml_213_0"
);
200
        else
201
            msgsetloc(0, 
* RIBBICK - This dusty frog needs a bit of an autumn dirtying.Wait for inputClose Message
"* RIBBICK - This dusty frog needs a bit of an autumn dirtying./%", "obj_ribbick_enemy_slash_Step_0_gml_198_0"
);
202
        
scr_battletext_default
scr_battletext_default

function
scr_battletext_default()
{ global.fc = 0; global.typer = 4;
scr_battletext();
return battlewriter; }
();
203
    }
204
    if (acting == 2 && actcon == 0)
205
        acting = 100;
206
    if (acting == 3 && actcon == 0)
207
    {
208
        CroakOnX = true;
209
        acting = 100;
210
    }
211
    if (acting == 100)
212
    {
213
        msgsetsubloc(0, "* Press ~1 repeatedly!", 
scr_get_input_name
scr_get_input_name

function
scr_get_input_name(arg0)
{ var _control = "[?]"; if (global.is_console || obj_gamecontroller.gamepad_active) { _control = global.input_g[arg0]; if (_control == gp_padr) return "\\*D "; if (_control == gp_padl) return "\\*A "; if (_control == gp_padu) return "\\*W "; if (_control == gp_padd) return "\\*S "; if (_control == global.button0) return "\\*Z "; if (_control == global.button1) return "\\*X "; if (_control == global.button2) return "\\*C "; } var left_bracket = (global.lang == "en") ? "[" : "["; var right_bracket = (global.lang == "en") ? "]" : "]"; _control = left_bracket + global.asc_def[global.input_k[arg0]] + right_bracket; if (!is_string(_control)) _control = "[?]"; else return _control; }
(6), "obj_ribbick_enemy_slash_Step_0_gml_231_0");
214
        
scr_battletext_default
scr_battletext_default

function
scr_battletext_default()
{ global.fc = 0; global.typer = 4;
scr_battletext();
return battlewriter; }
();
215
        acting = 101;
216
        clocktimer = 11;
217
    }
218
    if (acting == 101)
219
    {
220
        if (blowamt > 0 && blowanimtimer <= 0)
221
            blowamt--;
222
        if (button3_p() == 1)
223
            presscount++;
224
        if (button3_p() == 1 && presscount < 5)
225
        {
226
            snd_stop(snd_whistlebreath);
227
            snd_play_x(snd_whistlebreath, 1, 1 + (blowamt / 100));
228
            onoff = 0;
229
            shakeamt = 5;
230
            blowamt += 12;
231
            blowbuffer = 2;
232
            blowanimtimer = 20;
233
            blow_wait = 1;
234
            if (CroakOnX == true)
235
            {
236
                with (obj_ribbick_enemy)
237
                {
238
                    if (image_alpha != 0)
239
                    {
240
                        blowanimtimer = 20;
241
                        shakeamt = 5;
242
                        onoff = 0;
243
                        repeat (6)
244
                            event_user(2);
245
                    }
246
                }
247
            }
248
            else
249
            {
250
                repeat (6)
251
                    event_user(2);
252
            }
253
        }
254
        presstimer++;
255
        if (presstimer == 30)
256
        {
257
            presstimer = 0;
258
            presscount = 0;
259
        }
260
        if (blow_wait == 1)
261
            blowtimer += 1.58;
262
        if (blowtimer > 100)
263
            blowtimer = 100;
264
        if (blowtimer == 100 || blowamt >= 100)
265
            acting = 102;
266
        if (blowamt >= 0)
267
            croakonsuccess = true;
268
    }
269
    if (acting == 102)
270
    {
271
        with (obj_writer)
272
            instance_destroy();
273
        if (blowamt > 100)
274
            blowamt = 100;
275
        with (obj_ribbick_enemy)
276
        {
277
            blowing = 0;
278
            blowanimtimer = 0;
279
            blowtimer = 0;
280
            if (global.mercymod[myself] >= 100)
281
            {
282
                if (other.CroakOnX == true || other.id == id)
283
                {
284
                    if (image_alpha != 0)
285
                        blownaway = true;
286
                    for (var __i = 1; __i < 3; __i++)
287
                    {
288
                        if (global.monster[myself] == 1)
289
                        {
290
                            global.acting[__i] = 0;
291
                            global.actingsimul[__i] = 0;
292
                            global.actingsingle[__i] = 0;
293
                            global.faceaction[__i] = 0;
294
                        }
295
                    }
296
                    if (other.CroakOnX == true && id != other.id && image_alpha != 0)
297
                    {
298
                        event_user(10);
299
                    }
300
                    else if (image_alpha != 0)
301
                    {
302
                        sparedsprite = spr_ribbick_small;
303
                        if (amirabbick)
304
                            sparedsprite = spr_rabbick_enemy_spared;
305
                        image_alpha = 0;
306
                        
scr_spareanim
scr_spareanim

function
scr_spareanim()
{ spareanim = instance_create(x, y, obj_spareanim); spareanim.sprite_index = sprite_index; spareanim.sprite_index = sparedsprite; spareanim.image_index = 0; spareanim.image_xscale = image_xscale; spareanim.image_yscale = image_yscale; if (global.chapter == 3 && i_ex(obj_tennabattleconvo_controller)) { obj_tennabattleconvo_controller.enemyspared = true; snd_play(snd_crowd_ooh); } }
();
307
                        
scr_recruit
scr_recruit

function
scr_recruit()
{ if (recruitable == 1 && global.flag[61 disable_recruiting] == 0) { if (global.flag[global.monstertype[myself] + 600] >= 0(None) && global.flag[global.monstertype[myself] + 600] < 1 && recruitcount > 0) { if (recruitcount == -1) {
scr_recruit_info(global.monstertype[myself]);
recruitcount = _recruitcount; } global.flag[global.monstertype[myself] + 600] += 1Enemy (placeholder/G-BODY) / recruitcount; if (global.flag[global.monstertype[myself] + 600] > 1) global.flag[global.monstertype[myself] + 600] = 1Enemy (placeholder/G-BODY); snd_play(snd_sparkle_gem); _recruitanim = instance_create(global.monsterx[myself], global.monstery[myself] - 40, obj_recruitanim); _recruitanim.firstnumber = round(global.flag[global.monstertype[myself] + 600] / (1 / recruitcount)); _recruitanim.secondnumber = recruitcount; } } }
();
308
                        
scr_monsterdefeat
scr_monsterdefeat

function
scr_monsterdefeat()
{ if (global.monster[myself] == 1) { global.monstergold[3] += global.monstergold[myself]; global.monsterexp[3] += global.monsterexp[myself]; global.monster[myself] = 0; if (global.flag[51 + myself] == 0) { global.flag[51 + myself] = 2; if (global.monsterhp[myself] <= 0) global.flag[51 + myself] = 1; } if (global.flag[51 + myself] == 1) { global.flag[40 violences] += 1; if (fatal == 1) global.flag[44 kills]++; } if (global.flag[51 + myself] == 2) global.flag[41 spares] += 1; if (global.flag[51 + myself] == 3) global.flag[42 pacifies] += 1; if (global.flag[51 + myself] == 5) global.flag[43 autosusie_violences] += 1; if (global.flag[51 + myself] == 6) { global.flag[45 freezes] += 1; global.monstergold[3] += 24; } if (
scr_monsterpop() == 0)
{ _amt_add = 0; _frozened = 0; _violenced = 0; _spared = 0; _pacified = 0; for (d_i = 0; d_i < 3; d_i += 1) { if (global.flag[51 + d_i] != 0) _amt_add += 1; if (global.flag[51 + d_i] == 1) _violenced += 1; if (global.flag[51 + d_i] == 2) _spared += 1; if (global.flag[51 + d_i] == 3) _pacified += 1; if (global.flag[51 + d_i] == 6) _frozened += 1; } if (_frozened > 0) global.flag[50 last_encounter_end] = 6; if (_pacified > 0) global.flag[50 last_encounter_end] = 3; if (_spared > 0) global.flag[50 last_encounter_end] = 2; if (_violenced > 0) global.flag[50 last_encounter_end] = 1; if (global.flag[50 last_encounter_end] == 6) global.flag[926 iceshocked_encounters]++; if (global.flag[54 encounter_pointer] != 0) { global.flag[global.flag[54 encounter_pointer]] = global.flag[50 last_encounter_end]; debug_message("=====Encounter Results====="); debug_message("encounter flag: global.flag[" + string(global.flag[54 encounter_pointer]) + "]=" + string(global.flag[50 last_encounter_end])); debug_message("======="); global.flag[54 encounter_pointer] = 0; } } event_user(11); } }
();
309
                    }
310
                }
311
            }
312
        }
313
        if (CroakOnX == true)
314
        {
315
            with (obj_ribbick_enemy)
316
            {
317
                if (sparedsprite == spr_ribbick_spare)
318
                {
319
                    var _blowamt = round(other.blowamt * 0.64);
320
                    if (_blowamt > 100)
321
                        _blowamt = 100;
322
                    
scr_mercyadd
scr_mercyadd

function
scr_mercyadd(arg0, arg1)
{ global.mercymod[arg0] += arg1; if (global.mercymod[arg0] < 0) global.mercymod[arg0] = 0; if (global.mercymod[arg0] >= 100) global.mercymod[arg0] = 100; var _playsound = 1; if (arg1 <= 0) _playsound = 0; with (obj_dmgwriter) { if (type == 5 && mercytimer < 8) _playsound = 0; } if (_playsound) { var _pitch = 0.8; if (arg1 < 99) _pitch = 1; if (arg1 <= 50) _pitch = 1.2; if (arg1 <= 25) _pitch = 1.4; snd_play_x(snd_mercyadd, 0.8, _pitch); } __mercydmgwriter = instance_create(global.monsterx[arg0], (global.monstery[arg0] + 20) - (global.hittarget[arg0] * 20), obj_dmgwriter); __mercydmgwriter.damage = arg1; __mercydmgwriter.type = 5; global.hittarget[arg0]++; }
(myself, _blowamt);
323
                }
324
            }
325
        }
326
        else if (sparedsprite == spr_ribbick_spare)
327
        {
328
            var _blowamt = round(other.blowamt * 0.64);
329
            if (_blowamt > 100)
330
                _blowamt = 100;
331
            
scr_mercyadd
scr_mercyadd

function
scr_mercyadd(arg0, arg1)
{ global.mercymod[arg0] += arg1; if (global.mercymod[arg0] < 0) global.mercymod[arg0] = 0; if (global.mercymod[arg0] >= 100) global.mercymod[arg0] = 100; var _playsound = 1; if (arg1 <= 0) _playsound = 0; with (obj_dmgwriter) { if (type == 5 && mercytimer < 8) _playsound = 0; } if (_playsound) { var _pitch = 0.8; if (arg1 < 99) _pitch = 1; if (arg1 <= 50) _pitch = 1.2; if (arg1 <= 25) _pitch = 1.4; snd_play_x(snd_mercyadd, 0.8, _pitch); } __mercydmgwriter = instance_create(global.monsterx[arg0], (global.monstery[arg0] + 20) - (global.hittarget[arg0] * 20), obj_dmgwriter); __mercydmgwriter.damage = arg1; __mercydmgwriter.type = 5; global.hittarget[arg0]++; }
(myself, _blowamt);
332
        }
333
        if (croakonsuccess == true)
334
        {
335
            var rabbick_name = stringsetloc(
Rabbick
"Rabbick", "obj_ribbick_enemy_slash_Step_0_gml_291_0"
);
336
            if (CroakOnX == true)
337
            {
338
                with (obj_ribbick_enemy)
339
                {
340
                    if (global.mercymod[myself] >= 100)
341
                    {
342
                        if (amirabbick == true)
343
                        {
344
                            event_user(1);
345
                            sparedsprite = spr_rabbick_enemy_spared;
346
                            hurtsprite = spr_rabbick_enemy_spared_hurt;
347
                            global.monstername[myself] = rabbick_name;
348
                        }
349
                        if (amirabbick == false)
350
                        {
351
                            sparedsprite = spr_ribbick_small;
352
                            hurtsprite = spr_ribbick_small_hurt;
353
                        }
354
                        blown = 1;
355
                    }
356
                }
357
            }
358
            else if (global.mercymod[myself] >= 100)
359
            {
360
                if (amirabbick == true)
361
                {
362
                    event_user(1);
363
                    sparedsprite = spr_rabbick_enemy_spared;
364
                    hurtsprite = spr_rabbick_enemy_spared_hurt;
365
                    global.monstername[myself] = rabbick_name;
366
                }
367
                if (amirabbick == false)
368
                {
369
                    sparedsprite = spr_ribbick_small;
370
                    hurtsprite = spr_ribbick_small_hurt;
371
                }
372
                blown = 1;
373
            }
374
            repeat (15)
375
                event_user(2);
376
        }
377
        acting = 103;
378
    }
379
    if (acting == 103 && !i_ex(obj_writer))
380
    {
381
        extimer++;
382
        if (extimer == 30)
383
        {
384
            if (blownaway)
385
                msgsetloc(0, 
* The enemy was blown away!Wait for inputClose Message
"* The enemy was blown away!/%", "obj_ribbick_enemy_slash_Step_0_gml_340_0"
);
386
            else if (global.mercymod[myself] >= 100 && amirabbick == true)
387
                msgsetloc(0, 
* What the!? It was an imposter!Wait for inputClose Message
"* What the!? It was an imposter!/%", "obj_ribbick_enemy_slash_Step_0_gml_343_0"
);
388
            else if (global.mercymod[myself] >= 100)
389
                msgsetloc(0, 
* It revealed its dirtier self!Wait for inputClose Message
"* It revealed its dirtier self!/%", "obj_ribbick_enemy_slash_Step_0_gml_344_0"
);
390
            else if (blowamt == 0)
391
                msgsetloc(0, 
* Nothing happened!Wait for inputClose Message
"* Nothing happened!/%", "obj_ribbick_enemy_slash_Step_0_gml_345_0"
);
392
            else
393
                msgsetloc(0, 
* It became even dirtier!Wait for inputClose Message
"* It became even dirtier!/%", "obj_ribbick_enemy_slash_Step_0_gml_346_0"
);
394
            
scr_battletext_default
scr_battletext_default

function
scr_battletext_default()
{ global.fc = 0; global.typer = 4;
scr_battletext();
return battlewriter; }
();
395
            acting = 0;
396
            actcon = 1;
397
            extimer = 0;
398
            with (obj_ribbick_enemy)
399
                blowamt = 0;
400
        }
401
    }
402
    if (actingsus == 1 && actconsus == 1)
403
    {
404
        
scr_mercyadd
scr_mercyadd

function
scr_mercyadd(arg0, arg1)
{ global.mercymod[arg0] += arg1; if (global.mercymod[arg0] < 0) global.mercymod[arg0] = 0; if (global.mercymod[arg0] >= 100) global.mercymod[arg0] = 100; var _playsound = 1; if (arg1 <= 0) _playsound = 0; with (obj_dmgwriter) { if (type == 5 && mercytimer < 8) _playsound = 0; } if (_playsound) { var _pitch = 0.8; if (arg1 < 99) _pitch = 1; if (arg1 <= 50) _pitch = 1.2; if (arg1 <= 25) _pitch = 1.4; snd_play_x(snd_mercyadd, 0.8, _pitch); } __mercydmgwriter = instance_create(global.monsterx[arg0], (global.monstery[arg0] + 20) - (global.hittarget[arg0] * 20), obj_dmgwriter); __mercydmgwriter.damage = arg1; __mercydmgwriter.type = 5; global.hittarget[arg0]++; }
(myself, 50);
405
        if (simultotal == 1)
406
        {
407
            msgsetloc(0, 
* Susie dirties the enemy further! It seemed to like it!Wait for inputClose Message
"* Susie dirties the enemy further! It seemed to like it!/%", "obj_ribbick_enemy_slash_Step_0_gml_364_0"
);
408
            
scr_battletext_default
scr_battletext_default

function
scr_battletext_default()
{ global.fc = 0; global.typer = 4;
scr_battletext();
return battlewriter; }
();
409
            actconsus = 20;
410
        }
411
        else
412
        {
413
            var rand = choose(0, 1, 2);
414
            if (rand == 0)
415
                msgsetloc(0, 
* Susie generates filth!
"* Susie generates filth!", "obj_ribbick_enemy_slash_Step_0_gml_371_0"
);
416
            if (rand == 1)
417
                msgsetloc(0, 
* Susie shows gum from her shoe!!
"* Susie shows gum from her shoe!!", "obj_ribbick_enemy_slash_Step_0_gml_372_0"
);
418
            if (rand == 2)
419
                msgsetloc(0, 
* Susie says dirty words!
"* Susie says dirty words!", "obj_ribbick_enemy_slash_Step_0_gml_373_0"
);
420
            
scr_simultext
scr_simultext

function
scr_simultext(arg0)
{ __simulorder = 0; if (arg0 == "kris") __simulorder = simulorderkri; if (arg0 == "susie") __simulorder = simulordersus; if (arg0 == "ralsei") __simulorder = simulorderral; if (arg0 == "noelle") __simulorder = simulordernoe; __yoffset = __simulorder * 30; global.typer = 4; battlewriter = instance_create(xx + 30, yy + 376 + __yoffset, obj_writer); }
("susie");
421
            if (simulordersus == 0)
422
                actconsus = 20;
423
            else
424
                actconsus = 0;
425
        }
426
        actingsus = 0;
427
    }
428
    if (actingral == 1 && actconral == 1)
429
    {
430
        extimer++;
431
        if (extimer == 1)
432
            
scr_mercyadd
scr_mercyadd

function
scr_mercyadd(arg0, arg1)
{ global.mercymod[arg0] += arg1; if (global.mercymod[arg0] < 0) global.mercymod[arg0] = 0; if (global.mercymod[arg0] >= 100) global.mercymod[arg0] = 100; var _playsound = 1; if (arg1 <= 0) _playsound = 0; with (obj_dmgwriter) { if (type == 5 && mercytimer < 8) _playsound = 0; } if (_playsound) { var _pitch = 0.8; if (arg1 < 99) _pitch = 1; if (arg1 <= 50) _pitch = 1.2; if (arg1 <= 25) _pitch = 1.4; snd_play_x(snd_mercyadd, 0.8, _pitch); } __mercydmgwriter = instance_create(global.monsterx[arg0], (global.monstery[arg0] + 20) - (global.hittarget[arg0] * 20), obj_dmgwriter); __mercydmgwriter.damage = arg1; __mercydmgwriter.type = 5; global.hittarget[arg0]++; }
(myself, 25);
433
        if (extimer == 2)
434
        {
435
            if (simultotal == 1)
436
            {
437
                msgsetloc(0, 
* Ralsei tried to clean the enemy! It became TIRED...Wait for inputClose Message
"* Ralsei tried to clean the enemy! It became TIRED.../%", "obj_ribbick_enemy_slash_Step_0_gml_391_0"
);
438
                
scr_battletext_default
scr_battletext_default

function
scr_battletext_default()
{ global.fc = 0; global.typer = 4;
scr_battletext();
return battlewriter; }
();
439
                actconral = 20;
440
            }
441
            else
442
            {
443
                var rand = choose(0, 1, 2);
444
                if (rand == 0)
445
                    msgsetloc(0, 
* Ralsei tries tidying up!
"* Ralsei tries tidying up!", "obj_ribbick_enemy_slash_Step_0_gml_398_0"
);
446
                if (rand == 1)
447
                    msgsetloc(0, 
* Ralsei uses a feather duster!
"* Ralsei uses a feather duster!", "obj_ribbick_enemy_slash_Step_0_gml_399_0"
);
448
                if (rand == 2)
449
                    msgsetloc(0, 
* Ralsei croaks sympathetically!
"* Ralsei croaks sympathetically!", "obj_ribbick_enemy_slash_Step_0_gml_400_0"
);
450
                
scr_simultext
scr_simultext

function
scr_simultext(arg0)
{ __simulorder = 0; if (arg0 == "kris") __simulorder = simulorderkri; if (arg0 == "susie") __simulorder = simulordersus; if (arg0 == "ralsei") __simulorder = simulorderral; if (arg0 == "noelle") __simulorder = simulordernoe; __yoffset = __simulorder * 30; global.typer = 4; battlewriter = instance_create(xx + 30, yy + 376 + __yoffset, obj_writer); }
("ralsei");
451
                if (simulorderral == 0)
452
                    actconral = 20;
453
                else
454
                    actconral = 0;
455
            }
456
            if (global.monsterstatus[myself] != 1)
457
                
scr_monster_make_tired
scr_monster_make_tired

function
scr_monster_make_tired(arg0)
{ if (image_alpha > 0) { if (global.monsterstatus[arg0] == 0) { __tiredwriter = instance_create(global.monsterx[arg0], (global.monstery[arg0] - (global.hittarget[arg0] * 20)) + 20, obj_dmgwriter); __tiredwriter.type = 13; global.hittarget[arg0] += 1; snd_play_x(snd_spellcast, 0.5, 0.9); } global.monstercomment[arg0] = stringsetloc(
(Tired)
"(Tired)", "scr_monster_make_tired_slash_scr_monster_make_tired_gml_1_0"
);
global.monsterstatus[arg0] = 1; } }
(myself);
458
            actingral = 0;
459
            extimer = 0;
460
        }
461
    }
462
    if (actcon == 20 || actconsus == 20 || actconral == 20)
463
    {
464
        if (
scr_terminate_writer
scr_terminate_writer

function
scr_terminate_writer()
{ __writerkilled = 0; __writerkillable = 0; __writerended = 0; if (instance_exists(obj_writer)) { obj_writer.__endcheckid = id; with (obj_writer) { if (reachedend == 1) { with (__endcheckid) __writerended++; } } if (__writerended == instance_number(obj_writer)) __writerkillable = 1; } else { __writerkilled = 1; } if (button1_p() && __writerkillable == 1) { with (obj_writer) instance_destroy(); __writerkilled = 1; } return __writerkilled; }
())
465
        {
466
            actconsus = -1;
467
            actconral = -1;
468
            actcon = 1;
469
        }
470
    }
471
    if (actcon == 1 && !instance_exists(obj_writer))
472
        
scr_nextact
scr_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();
} }
();
473
}
474
if (state == 3)
475
{
476
    
scr_enemyhurt_tired_after_damage
scr_enemyhurt_tired_after_damage

function
scr_enemyhurt_tired_after_damage(arg0)
{ if (global.monsterhp[myself] <= (global.monstermaxhp[myself] * arg0))
scr_monster_make_tired(myself);
}
(0.5);
477
    
scr_enemy_hurt
scr_enemy_hurt

function
scr_enemy_hurt()
{ hurttimer -= 1; if (hurttimer < 0) { state = 0; } else { if (global.monster[myself] == 0)
scr_defeatrun();
hurtshake += 1; if (hurtshake > 1) { if (shakex > 0) shakex -= 1; if (shakex < 0) shakex += 1; shakex = -shakex; hurtshake = 0; } } }
();
478
}
479
480
enum e__VW
481
{
482
    XView,
483
    YView,
484
    WView,
485
    HView,
486
    Angle,
487
    HBorder,
488
    VBorder,
489
    HSpeed,
490
    VSpeed,
491
    Object,
492
    Visible,
493
    XPort,
494
    YPort,
495
    WPort,
496
    HPort,
497
    Camera,
498
    SurfaceID
499
}