| 1 |
if (global.mnfight == 3) |
| 2 |
attacked = 0; |
| 3 |
scr_blconmatchscr_blconmatchif (alarm[5] > 0)
{
if (global.monster[0] == 1)
{
if (global.monsterinstance[0].alarm[5] >alarm[5]
alarm[5]
}
if (global.monster[1] == 1)
{
if (global.monsterinstance[1].alarm[5] >alarm[5]
alarm[5]
}
if (global.monster[2] == 1)
{
if (global.monsterinstance[2].alarm[5] >alarm[5]
alarm[5]
}
} (); |
| 4 |
if (global.mnfight == 1) |
| 5 |
{ |
| 6 |
if (talked == 0) |
| 7 |
{ |
| 8 |
alarm[5] = 60; |
| 9 |
alarm[6] = 1;gml_Object_obj_whimsun_Alarm_6.gmlblcon = instance_create((x + sprite_width) - 8, ystart, obj_blconsm);
mycommand = round(random(100));
if (mycommand >= 0 && mycommand < 30)
global.msg[0] = ;
if (mycommand >= 30 && mycommand < 50)
global.msg[0] = ;
if (mycommand >= 50 && mycommand < 80)
global.msg[0] = ;
if (mycommand >= 80 && mycommand <= 100)
global.msg[0] = ;
if (whatiheard == 1 || whatiheard == 3)
global.msg[0] = ;
global.msg[1] = Close MessageClose MessageClose Message ;
global.typer = 2;
blconwd = instance_create(blcon.x + 15, blcon.y + 10, OBJ_NOMSCWRITER);
global.border = 3;
obj_heart.x = round((global.idealborder[0] + global.idealborder[1]) / 2) - 8;
obj_heart.y = round((global.idealborder[2] + global.idealborder[3]) / 2) - 8; |
| 10 |
talked = 1; |
| 11 |
global.heard = 0; |
| 12 |
} |
| 13 |
} |
| 14 |
if (control_check_pressed(0)) |
| 15 |
{ |
| 16 |
if (alarm[5] > 5 && obj_lborder.x == global.idealborder[0] && alarm[6] < 0)gml_Object_obj_whimsun_Alarm_6.gmlblcon = instance_create((x + sprite_width) - 8, ystart, obj_blconsm);
mycommand = round(random(100));
if (mycommand >= 0 && mycommand < 30)
global.msg[0] = ;
if (mycommand >= 30 && mycommand < 50)
global.msg[0] = ;
if (mycommand >= 50 && mycommand < 80)
global.msg[0] = ;
if (mycommand >= 80 && mycommand <= 100)
global.msg[0] = ;
if (whatiheard == 1 || whatiheard == 3)
global.msg[0] = ;
global.msg[1] = Close MessageClose MessageClose Message ;
global.typer = 2;
blconwd = instance_create(blcon.x + 15, blcon.y + 10, OBJ_NOMSCWRITER);
global.border = 3;
obj_heart.x = round((global.idealborder[0] + global.idealborder[1]) / 2) - 8;
obj_heart.y = round((global.idealborder[2] + global.idealborder[3]) / 2) - 8; |
| 17 |
alarm[5] = 2; |
| 18 |
} |
| 19 |
if (global.hurtanim[myself] == 1) |
| 20 |
{ |
| 21 |
shudder = 16; |
| 22 |
alarm[3] = global.damagetimer;gml_Object_obj_whimsun_Alarm_3.gmlif (sprite_index != spr_whimsunhurt)
{
dmgwriter = instance_create((x + (sprite_width / 2)) - 48, y + 80, obj_dmgwriter);
global.damage = takedamage;
with (dmgwriter)
dmg = global.damage;
sprite_index = spr_whimsunhurt;
snd_play(hurtsound);
x = xstart;
y = ystart;
path_end();
gravity = 0;
}
x += shudder;
if (shudder < 0)
shudder = -(shudder + 2);
else
shudder = -shudder;
if (shudder == 0)
{
global.hurtanim[myself] = 2;
exit;
}
alarm[3] = 2; |
| 23 |
global.hurtanim[myself] = 3; |
| 24 |
} |
| 25 |
if (global.hurtanim[myself] == 2) |
| 26 |
{ |
| 27 |
global.monsterhp[myself] -= takedamage; |
| 28 |
with (dmgwriter) |
| 29 |
alarm[2] |
| 30 |
if (global.monsterhp[myself] >= 1) |
| 31 |
{ |
| 32 |
global.hurtanim[myself] = 0; |
| 33 |
sprite_index = spr_whimsun; |
| 34 |
path_start(path_whimsun, 0.5, path_action_restart, 0); |
| 35 |
image_index = 0; |
| 36 |
global.myfight = 0; |
| 37 |
global.mnfight = 1; |
| 38 |
} |
| 39 |
else |
| 40 |
{ |
| 41 |
global.myfight = 0; |
| 42 |
global.mnfight = 1; |
| 43 |
killed = 1; |
| 44 |
instance_destroy(); |
| 45 |
} |
| 46 |
} |
| 47 |
if (global.hurtanim[myself] == 5) |
| 48 |
{ |
| 49 |
global.damage = 0; |
| 50 |
instance_create((x + (sprite_width / 2)) - 48, y - 24, obj_dmgwriter); |
| 51 |
with (obj_dmgwriter) |
| 52 |
alarm[2] |
| 53 |
global.myfight = 0; |
| 54 |
global.mnfight = 1; |
| 55 |
global.hurtanim[myself] = 0; |
| 56 |
} |
| 57 |
if (global.mnfight == 2) |
| 58 |
{ |
| 59 |
if (attacked == 0) |
| 60 |
{ |
| 61 |
global.turntimer = 100; |
| 62 |
if (mycommand >= 0 && mycommand <= 50) |
| 63 |
script_execute(scr_rotategen, 10, 20, 626, obj_heart.x, obj_heart.y + 42); |
| 64 |
else |
| 65 |
gen = instance_create(0, 0, obj_butterfly2gen); |
| 66 |
gen.myself = myself; |
| 67 |
if (mycommand >= 0) |
| 68 |
global.msg[0] = * Whimsun avoids eye contact.scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_383") ; |
| 69 |
if (mycommand >= 30) |
| 70 |
global.msg[0] = * Whimsun continues to mutter apologies.scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_384") ; |
| 71 |
if (mycommand >= 70) |
| 72 |
global.msg[0] = * Whimsun is fluttering.scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_385") ; |
| 73 |
if (mycommand >= 90) |
| 74 |
global.msg[0] = * It's starting to smell like lavender and mothballs.scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_386") ; |
| 75 |
if (mercymod > 100) |
| 76 |
global.msg[0] = * Whimsun is hyperventilating.scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_387") ; |
| 77 |
if (global.monsterhp[myself] < global.monstermaxhp[myself]) |
| 78 |
global.msg[0] = * Whimsun is having trouble flying.scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_388") ; |
| 79 |
attacked = 1; |
| 80 |
} |
| 81 |
} |
| 82 |
if (whatiheard == 3 && instance_exists(OBJ_WRITER) == 0) |
| 83 |
{ |
| 84 |
script_execute(scr_mercystandard); |
| 85 |
if (mercy < 0) |
| 86 |
instance_destroy(); |
| 87 |
} |
| 88 |
if (global.myfight == 2) |
| 89 |
{ |
| 90 |
if (whatiheard != -1) |
| 91 |
{ |
| 92 |
if (global.heard == 0) |
| 93 |
{ |
| 94 |
if (whatiheard == 0) |
| 95 |
{ |
| 96 |
global.msc = 0; |
| 97 |
global.msg[0] = * WHIMSUN - ATK 5 DEF 0 * This monster is too sensitive to fight...Wait for input^scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_410") ; |
| 98 |
OBJ_WRITER.halt = 3; |
| 99 |
iii = instance_create(global.idealborder[0], global.idealborder[2], OBJ_WRITER); |
| 100 |
with (iii) |
| 101 |
halt = 0; |
| 102 |
} |
| 103 |
if (whatiheard == 3) |
| 104 |
{ |
| 105 |
global.flag[131 spared_whimsun] = 1; |
| 106 |
global.msc = 0; |
| 107 |
global.msg[0] = * Halfway through your first word,Delay 11 Whimsun bursts into tears and runs away.Wait for input^scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_419") ; |
| 108 |
OBJ_WRITER.halt = 3; |
| 109 |
iii = instance_create(global.idealborder[0], global.idealborder[2], OBJ_WRITER); |
| 110 |
with (iii) |
| 111 |
halt = 0; |
| 112 |
} |
| 113 |
if (whatiheard == 1) |
| 114 |
{ |
| 115 |
global.msc = 0; |
| 116 |
global.msg[0] = * You raise your arms and wiggle your fingers. * Whimsun freaks out!Wait for input^scr_gettextscr_gettextvar text_id = argument[0];
var text = ds_map_find_value(global.text_data_en, text_id);
if (is_undefined(text))
text = "";
if (global.language == "ja")
{
var loc_text = ds_map_find_value(global.text_data_ja, text_id);
if (!is_undefined(loc_text))
text = loc_text;
}
for (var i = 1; i <= (string_length(text) - 3); i++)
{
if (string_copy(text, i, 2) == "\[" && string_char_at(text, i + 3) == "]")
{
var sel = string_char_at(text, i + 2);
var replace;
if (sel == "C")
replace = global.charname;
else if (sel == "G")
replace = string(global.gold);
else if (sel == "I")
replace = global.itemname[global.menucoord[1]];
else if (sel == "1" && argument_count > 1)
replace = argument[1];
else if (sel == "2" && argument_count > 2)
replace = argument[2];
else if (sel == "3" && argument_count > 3)
replace = argument[3];
else if (sel == "4" && argument_count > 4)
replace = argument[4];
else if (sel == "5" && argument_count > 5)
replace = argument[5];
else if (sel == "6" && argument_count > 6)
replace = argument[6];
else if (sel == "7" && argument_count > 7)
replace = argument[7];
else if (sel == "8" && argument_count > 8)
replace = argument[8];
else if (sel == "9" && argument_count > 9)
replace = argument[9];
else
replace = "";
var before = string_copy(text, 1, i - 1);
var after = string_copy(text, i + 4, string_length(text));
text = before + replace + after;
i += (string_length(replace) - 1);
}
}
return text; ("obj_whimsun_429") ; |
| 117 |
OBJ_WRITER.halt = 3; |
| 118 |
iii = instance_create(global.idealborder[0], global.idealborder[2], OBJ_WRITER); |
| 119 |
with (iii) |
| 120 |
halt = 0; |
| 121 |
mercymod = 101; |
| 122 |
} |
| 123 |
global.heard = 1; |
| 124 |
} |
| 125 |
} |
| 126 |
} |
| 127 |
if (global.myfight == 4) |
| 128 |
{ |
| 129 |
if (global.mercyuse == 0) |
| 130 |
{ |
| 131 |
script_execute(scr_mercystandard); |
| 132 |
if (mercy < 0) |
| 133 |
instance_destroy(); |
| 134 |
} |
| 135 |
} |