From 70adc42c045cc081185f0ddb256d2f4896ad7b50 Mon Sep 17 00:00:00 2001 From: coffee Date: Sat, 3 Sep 2011 08:59:32 -0300 Subject: Tab converting and reformating scripts related to the battlecaves in rossy quest. --- world/map/npc/025-3/barriers.txt | 474 +++++++++++++++++++++++------------- world/map/npc/025-4/battlecaves.txt | 409 ++++++++++++++++++++----------- 2 files changed, 569 insertions(+), 314 deletions(-) diff --git a/world/map/npc/025-3/barriers.txt b/world/map/npc/025-3/barriers.txt index 8377c5f3..28148ab0 100644 --- a/world/map/npc/025-3/barriers.txt +++ b/world/map/npc/025-3/barriers.txt @@ -2,21 +2,24 @@ // -----------------------------------Warp to Cave 1 --------------------------------------- -025-3.gat,78,127,0 script #WarpBattleCave1 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 26, 63, 60, 97) >= 1 || $@battlecave1 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE1) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,78,127,0|script|#WarpBattleCave1|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 26, 63, 60, 97) >= 1 || $@battlecave1 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE1) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave1, 1; warp "025-4.gat", 41, 95; set $@cave1fighter$, strcharinfo(0); set $@cave1fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave1start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -36,24 +39,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave1 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave1fighter$))==0) goto L_CleaningNorid; + if ($@battlecave1 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave1fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave1fighter$)); - if (getareausers("025-4.gat", 26, 63, 60, 97) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave1fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE1) goto L_Win; - if (gettimetick(2) - $@cave1start >= $@CAVE1_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 26, 63, 60, 97) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave1fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE1) + goto L_Win; + if (gettimetick(2) - $@cave1start >= $@CAVE1_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave1fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave1start) < 60) set $@cave1start, $@cave1start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave1start) < 60) + set $@cave1start, $@cave1start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave1_timer, $@cave1_timer + 5; - if ($@cave1_timer >= 60) goto L_BadAir; + if ($@cave1_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -113,21 +125,24 @@ L_AlreadyClean: // ---------------------------- Warp to Cave 2 ---------------------------- -025-3.gat,53,107,0 script #WarpBattleCave2 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 97, 62, 126, 96) >= 1 || $@battlecave2 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE2) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,53,107,0|script|#WarpBattleCave2|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 97, 62, 126, 96) >= 1 || $@battlecave2 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE2) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave2, 1; warp "025-4.gat", 110, 94; set $@cave2fighter$, strcharinfo(0); set $@cave2fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave2start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -147,24 +162,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave2 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave2fighter$))==0) goto L_CleaningNorid; + if ($@battlecave2 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave2fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave2fighter$)); - if (getareausers("025-4.gat", 97, 62, 126, 96) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave2fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE2) goto L_Win; - if (gettimetick(2) - $@cave2start >= $@CAVE2_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 97, 62, 126, 96) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave2fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE2) + goto L_Win; + if (gettimetick(2) - $@cave2start >= $@CAVE2_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave2fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave2start) < 60) set $@cave2start, $@cave2start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave2start) < 60) + set $@cave2start, $@cave2start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave2_timer, $@cave2_timer + 5; - if ($@cave2_timer >= 60) goto L_BadAir; + if ($@cave2_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -223,21 +247,24 @@ L_AlreadyClean: // --------------------------------- Warp to Cave 3 ---------------------------------------- -025-3.gat,71,83,0 script #WarpBattleCave3 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 150, 84, 177, 117) >= 1 || $@battlecave3 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE3) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,71,83,0|script|#WarpBattleCave3|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 150, 84, 177, 117) >= 1 || $@battlecave3 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE3) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave3, 1; warp "025-4.gat", 168, 115; set $@cave3fighter$, strcharinfo(0); set $@cave3fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave3start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -257,24 +284,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave3 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave3fighter$))==0) goto L_CleaningNorid; + if ($@battlecave3 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave3fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave3fighter$)); - if (getareausers("025-4.gat", 150, 84, 177, 117) < 1) goto L_Ranaway; - if (cavefights & BATTLE_CAVE3) goto L_Win; - if (PC_DIE_COUNTER > $@cave3fighterdeaths) goto L_CleaningDead; - if (gettimetick(2) - $@cave3start >= $@CAVE3_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 150, 84, 177, 117) < 1) + goto L_Ranaway; + if (cavefights & BATTLE_CAVE3) + goto L_Win; + if (PC_DIE_COUNTER > $@cave3fighterdeaths) + goto L_CleaningDead; + if (gettimetick(2) - $@cave3start >= $@CAVE3_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave3fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave3start) < 60) set $@cave3start, $@cave3start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave3start) < 60) + set $@cave3start, $@cave3start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave3_timer, $@cave3_timer + 5; - if ($@cave3_timer >= 60) goto L_BadAir; + if ($@cave3_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -333,21 +369,24 @@ L_AlreadyClean: // --------------------------- Warp to Cave 4 -------------------------------------- -025-3.gat,80,83,0 script #WarpBattleCave4 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 28, 124, 57, 156) >= 1 || $@battlecave4 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE4) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,80,83,0|script|#WarpBattleCave4|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 28, 124, 57, 156) >= 1 || $@battlecave4 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE4) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave4, 1; warp "025-4.gat", 32, 154; set $@cave4fighter$, strcharinfo(0); set $@cave4fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave4start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -367,24 +406,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave4 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave4fighter$))==0) goto L_CleaningNorid; + if ($@battlecave4 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave4fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave4fighter$)); - if (getareausers("025-4.gat", 28, 124, 57, 156) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave4fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE4) goto L_Win; - if (gettimetick(2) - $@cave4start >= $@CAVE4_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 28, 124, 57, 156) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave4fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE4) + goto L_Win; + if (gettimetick(2) - $@cave4start >= $@CAVE4_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave4fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave4start) < 60) set $@cave4start, $@cave4start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave4start) < 60) + set $@cave4start, $@cave4start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave4_timer, $@cave4_timer + 5; - if ($@cave4_timer >= 60) goto L_BadAir; + if ($@cave4_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -443,21 +491,24 @@ L_AlreadyClean: // --------------------------- Warp to Cave 5 ---------------------------------------- -025-3.gat,71,30,0 script #WarpBattleCave5 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 91, 131, 124, 160) >= 1 || $@battlecave5 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE5) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,71,30,0|script|#WarpBattleCave5|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 91, 131, 124, 160) >= 1 || $@battlecave5 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE5) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave5, 1; warp "025-4.gat", 100, 158; set $@cave5fighter$, strcharinfo(0); set $@cave5fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave5start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -477,24 +528,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave5 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave5fighter$))==0) goto L_CleaningNorid; + if ($@battlecave5 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave5fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave5fighter$)); - if (getareausers("025-4.gat", 91, 131, 124, 160) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave5fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE5) goto L_Win; - if (gettimetick(2) - $@cave5start >= $@CAVE5_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 91, 131, 124, 160) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave5fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE5) + goto L_Win; + if (gettimetick(2) - $@cave5start >= $@CAVE5_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave5fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave5start) < 60) set $@cave5start, $@cave5start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave5start) < 60) + set $@cave5start, $@cave5start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave5_timer, $@cave5_timer + 5; - if ($@cave5_timer >= 60) goto L_BadAir; + if ($@cave5_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -553,21 +613,24 @@ L_AlreadyClean: // -------------------------------- Warp to Cave 6 ----------------------------------------- -025-3.gat,128,35,0 script #WarpBattleCave6 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 153, 143, 178, 174) >= 1 || $@battlecave6 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE6) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,128,35,0|script|#WarpBattleCave6|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 153, 143, 178, 174) >= 1 || $@battlecave6 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE6) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave6, 1; warp "025-4.gat", 159, 172; set $@cave6fighter$, strcharinfo(0); set $@cave6fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave6start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -587,24 +650,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave6 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave6fighter$))==0) goto L_CleaningNorid; + if ($@battlecave6 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave6fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave6fighter$)); - if (getareausers("025-4.gat", 153, 143, 178, 174) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave6fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE6) goto L_Win; - if (gettimetick(2) - $@cave6start >= $@CAVE6_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 153, 143, 178, 174) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave6fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE6) + goto L_Win; + if (gettimetick(2) - $@cave6start >= $@CAVE6_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave6fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave6start) < 60) set $@cave6start, $@cave6start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave6start) < 60) + set $@cave6start, $@cave6start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave6_timer, $@cave6_timer + 5; - if ($@cave6_timer >= 60) goto L_BadAir; + if ($@cave6_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -663,21 +735,24 @@ L_AlreadyClean: // ---------------------------- Warp to Cave 7 ------------------------------------------ -025-3.gat,70,57,0 script #WarpBattleCave7 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 27, 185, 61, 219) >= 1 || $@battlecave7 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE7) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,70,57,0|script|#WarpBattleCave7|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 27, 185, 61, 219) >= 1 || $@battlecave7 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE7) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave7, 1; warp "025-4.gat", 42, 217; set $@cave7fighter$, strcharinfo(0); set $@cave7fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave7start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -697,24 +772,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave7 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave7fighter$))==0) goto L_CleaningNorid; + if ($@battlecave7 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave7fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave7fighter$)); - if (getareausers("025-4.gat", 27, 185, 61, 219) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave7fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE7) goto L_Win; - if (gettimetick(2) - $@cave7start >= $@CAVE7_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 27, 185, 61, 219) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave7fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE7) + goto L_Win; + if (gettimetick(2) - $@cave7start >= $@CAVE7_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave7fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave7start) < 60) set $@cave7start, $@cave7start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave7start) < 60) + set $@cave7start, $@cave7start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave7_timer, $@cave7_timer + 5; - if ($@cave7_timer >= 60) goto L_BadAir; + if ($@cave7_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -773,21 +857,24 @@ L_AlreadyClean: // -----------------------------------------------Warp to Cave 8------------------------------------------------------------- -025-3.gat,138,92,0 script #WarpBattleCave8 45,1,1,{ - - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 90, 193, 119, 216) >= 1 || $@battlecave8 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE8) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; +025-3.gat,138,92,0|script|#WarpBattleCave8|45,1,1,{ + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 90, 193, 119, 216) >= 1 || $@battlecave8 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE8) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave8, 1; warp "025-4.gat", 105, 214; set $@cave8fighter$, strcharinfo(0); set $@cave8fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave8start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -807,24 +894,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave8 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave8fighter$))==0) goto L_CleaningNorid; + if ($@battlecave8 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave8fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave8fighter$)); - if (getareausers("025-4.gat", 90, 193, 119, 216) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave8fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE8) goto L_Win; - if (gettimetick(2) - $@cave8start >= $@CAVE8_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 90, 193, 119, 216) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave8fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE8) + goto L_Win; + if (gettimetick(2) - $@cave8start >= $@CAVE8_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave8fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave8start) < 60) set $@cave8start, $@cave8start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave8start) < 60) + set $@cave8start, $@cave8start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave8_timer, $@cave8_timer + 5; - if ($@cave8_timer >= 60) goto L_BadAir; + if ($@cave8_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -883,21 +979,25 @@ L_AlreadyClean: // ------------------------------ Warp to Cave 9 ---------------------------------------- -025-3.gat,138,160,0 script #WarpBattleCave9 45,1,1,{ +025-3.gat,138,160,0|script|#WarpBattleCave9|45,1,1,{ - if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) goto L_AlreadyHelped; - if (getareausers("025-4.gat", 144, 192, 173, 226) >= 1 || $@battlecave9 > 0) goto L_SomeoneInside; - if (cavefights & BATTLE_CAVE9) goto L_AlreadyDone; - if (Rossy_Quest < 15) goto L_Block; + if (Rossy_Quest >= 16 || FLAGS & FLAG_ROSSI_COMPLETED) + goto L_AlreadyHelped; + if (getareausers("025-4.gat", 144, 192, 173, 226) >= 1 || $@battlecave9 > 0) + goto L_SomeoneInside; + if (cavefights & BATTLE_CAVE9) + goto L_AlreadyDone; + if (Rossy_Quest < 15) + goto L_Block; L_StartFight: set $@battlecave9, 1; warp "025-4.gat", 157, 222; set $@cave9fighter$, strcharinfo(0); set $@cave9fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave9start, gettimetick(2); message strcharinfo(0), "As you enter, you feel an evil force filling up the cave."; + startnpctimer; end; L_SomeoneInside: @@ -917,24 +1017,33 @@ L_Block: end; OnTimer5000: - if ($@battlecave9 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave9fighter$))==0) goto L_CleaningNorid; + if ($@battlecave9 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave9fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave9fighter$)); - if (getareausers("025-4.gat", 144, 192, 173, 226) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave9fighterdeaths) goto L_CleaningDead; - if (cavefights & BATTLE_CAVE9) goto L_Win; - if (gettimetick(2) - $@cave9start >= $@CAVE9_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 144, 192, 173, 226) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave9fighterdeaths) + goto L_CleaningDead; + if (cavefights & BATTLE_CAVE9) + goto L_Win; + if (gettimetick(2) - $@cave9start >= $@CAVE9_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave9fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave9start) < 60) set $@cave9start, $@cave9start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave9start) < 60) + set $@cave9start, $@cave9start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave9_timer, $@cave9_timer + 5; - if ($@cave9_timer >= 60) goto L_BadAir; + if ($@cave9_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -993,22 +1102,36 @@ L_AlreadyClean: // ----------------------------- Warp to Boss Cave ------------------------------- -025-3.gat,77,170,0 script #WarpBossCave 45,1,1,{ - if (Rossy_Quest > 16 || FLAGS & FLAG_ROSSI_COMPLETED) end; - if (Rossy_Quest == 16) goto L_AlreadyHelped; +025-3.gat,77,170,0|script|#WarpBossCave|45,1,1,{ + if (Rossy_Quest > 16 || FLAGS & FLAG_ROSSI_COMPLETED) + end; + if (Rossy_Quest == 16) + goto L_AlreadyHelped; set @barrier_force, -9; - if (cavefights & BATTLE_CAVE1) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE2) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE3) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE4) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE5) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE6) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE7) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE8) set @barrier_force, @barrier_force + 1; - if (cavefights & BATTLE_CAVE9) set @barrier_force, @barrier_force + 1; - if (@barrier_force != 0) goto L_Hurt; - if (getareausers("025-4.gat", 142, 24, 172, 48) >= 1 || $@battlecave10 > 0) goto L_SomeoneInside; - if (@barrier_force == 0) goto L_StartFight; + if (cavefights & BATTLE_CAVE1) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE2) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE3) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE4) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE5) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE6) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE7) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE8) + set @barrier_force, @barrier_force + 1; + if (cavefights & BATTLE_CAVE9) + set @barrier_force, @barrier_force + 1; + if (@barrier_force != 0) + goto L_Hurt; + if (getareausers("025-4.gat", 142, 24, 172, 48) >= 1 || $@battlecave10 > 0) + goto L_SomeoneInside; + if (@barrier_force == 0) + goto L_StartFight; end; L_Hurt: @@ -1023,8 +1146,8 @@ L_StartFight: warp "025-4.gat", 157, 44; set $@cave10fighter$, strcharinfo(0); set $@cave10fighterdeaths, PC_DIE_COUNTER; - startnpctimer; set $@cave10start, gettimetick(2); + startnpctimer; end; L_SomeoneInside: @@ -1037,24 +1160,33 @@ L_AlreadyHelped: end; OnTimer5000: - if ($@battlecave10 == 0) goto L_AlreadyClean; - if (isloggedin(getcharid(3,$@cave10fighter$))==0) goto L_CleaningNorid; + if ($@battlecave10 == 0) + goto L_AlreadyClean; + if (isloggedin(getcharid(3,$@cave10fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave10fighter$)); - if (getareausers("025-4.gat", 142, 24, 172, 48) < 1) goto L_Ranaway; - if (PC_DIE_COUNTER > $@cave10fighterdeaths) goto L_CleaningDead; - if (Rossy_Quest == 16) goto L_Win; - if (gettimetick(2) - $@cave10start >= $@CAVE10_TIME) goto L_Cleaning; + if (getareausers("025-4.gat", 142, 24, 172, 48) < 1) + goto L_Ranaway; + if (PC_DIE_COUNTER > $@cave10fighterdeaths) + goto L_CleaningDead; + if (Rossy_Quest == 16) + goto L_Win; + if (gettimetick(2) - $@cave10start >= $@CAVE10_TIME) + goto L_Cleaning; setnpctimer 0; end; L_Win: attachrid(getcharid(3,$@cave10fighter$)); message strcharinfo(0), "It is getting harder to breathe inside this cave... You feel like you are almost passing out."; - if ((gettimetick(2) - $@cave10start) < 60) set $@cave10start, $@cave10start + 60; - if (Hp - (MaxHp*5)/100 <= 0) goto L_BadAir; + if ((gettimetick(2) - $@cave10start) < 60) + set $@cave10start, $@cave10start + 60; + if (Hp - (MaxHp*5)/100 <= 0) + goto L_BadAir; percentheal -5, 0; set $@cave10_timer, $@cave10_timer + 5; - if ($@cave10_timer >= 60) goto L_BadAir; + if ($@cave10_timer >= 60) + goto L_BadAir; setnpctimer 0; end; @@ -1092,8 +1224,10 @@ L_Cleaning: L_CleaningDead: attachrid(getcharid(3,$@cave10fighter$)); warp "025-3.gat", 77, 168; - if ($@wave_cave10 < 5) message strcharinfo(0), "You were not strong enough to eliminate this power source."; - if ($@wave_cave10 == 5) message strcharinfo(0), "This horrible monster is probably too powerful for you right now."; + if ($@wave_cave10 < 5) + message strcharinfo(0), "You were not strong enough to eliminate this power source."; + if ($@wave_cave10 == 5) + message strcharinfo(0), "This horrible monster is probably too powerful for you right now."; callsub S_Cleaning; end; diff --git a/world/map/npc/025-4/battlecaves.txt b/world/map/npc/025-4/battlecaves.txt index 411e2026..89a16305 100644 --- a/world/map/npc/025-4/battlecaves.txt +++ b/world/map/npc/025-4/battlecaves.txt @@ -2,11 +2,15 @@ // --------------------------------- Cave 1 ----------------------------------- -025-4.gat,41,85,0 script #StartCaveFight1 324,{ - if ($@battlecave1 == 2 && $@cave1fighter$ == strcharinfo(0)) end; - if ($@battlecave1 == 2 && $@cave1fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave1 == 1) goto L_Start; +025-4.gat,41,85,0|script|#StartCaveFight1|324,{ + if ($@battlecave1 == 2 && $@cave1fighter$ == strcharinfo(0)) + end; + if ($@battlecave1 == 2 && $@cave1fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave1 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -17,7 +21,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -26,7 +31,8 @@ L_Start: L_Summon: set $@cave1_loop, $@cave1_loop + 1; areamonster "025-4.gat",26,63,60,97,"",$@CAVE1_MONSTERS_IDS[$@cave1_loop],$@CAVE1_MONSTERS_QTY[$@cave1_loop],"#StartCaveFight1::OnMonsterDeath"; - if ($@cave1_loop <= getarraysize($@CAVE1_MONSTERS_IDS)) goto L_Summon; + if ($@cave1_loop <= getarraysize($@CAVE1_MONSTERS_IDS)) + goto L_Summon; set $@cave1_loop, 0; end; @@ -37,15 +43,18 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave1 == 1) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave1 == 1) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave1 < $@CAVE1_WAVES) goto L_Summon; + if ($@wave_cave1 < $@CAVE1_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE1); end; OnMonsterDeath: set $@cave1_kills, $@cave1_kills + 1; - if ($@cave1_kills >= $@CAVE1_MONSTERS_QTY[1] + $@CAVE1_MONSTERS_QTY[2] + $@CAVE1_MONSTERS_QTY[3] + $@CAVE1_MONSTERS_QTY[4]) goto L_Done; + if ($@cave1_kills >= $@CAVE1_MONSTERS_QTY[1] + $@CAVE1_MONSTERS_QTY[2] + $@CAVE1_MONSTERS_QTY[3] + $@CAVE1_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -131,8 +140,9 @@ onInit: // --------------------- Cave 1 Checker ---------------------------- -025-4.gat,41,97,0 script #CheckCaveFight1 45,1,1,{ - if (cavefights & BATTLE_CAVE1 || $@battlecave1 == 1) goto L_Done; +025-4.gat,41,97,0|script|#CheckCaveFight1|45,1,1,{ + if (cavefights & BATTLE_CAVE1 || $@battlecave1 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -144,11 +154,15 @@ L_Done: // --------------------------------- Cave 2 --------------------------------------- -025-4.gat,115,77,0 script #StartCaveFight2 324,{ - if ($@battlecave2 == 2 && $@cave2fighter$ == strcharinfo(0)) end; - if ($@battlecave2 == 2 && $@cave2fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave2 == 1) goto L_Start; +025-4.gat,115,77,0|script|#StartCaveFight2|324,{ + if ($@battlecave2 == 2 && $@cave2fighter$ == strcharinfo(0)) + end; + if ($@battlecave2 == 2 && $@cave2fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave2 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -159,7 +173,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -168,7 +183,8 @@ L_Start: L_Summon: set $@cave2_loop, $@cave2_loop + 1; areamonster "025-4.gat",97, 62, 126, 96,"",$@CAVE2_MONSTERS_IDS[$@cave2_loop],$@CAVE2_MONSTERS_QTY[$@cave2_loop],"#StartCaveFight2::OnMonsterDeath"; - if ($@cave2_loop <= getarraysize($@CAVE2_MONSTERS_IDS)) goto L_Summon; + if ($@cave2_loop <= getarraysize($@CAVE2_MONSTERS_IDS)) + goto L_Summon; set $@cave2_loop, 0; end; @@ -180,15 +196,18 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave2 == 1) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave2 == 1) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave2 < $@CAVE2_WAVES) goto L_Summon; + if ($@wave_cave2 < $@CAVE2_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE2); end; OnMonsterDeath: set $@cave2_kills, $@cave2_kills + 1; - if ($@cave2_kills >= $@CAVE2_MONSTERS_QTY[1] + $@CAVE2_MONSTERS_QTY[2] + $@CAVE2_MONSTERS_QTY[3] + $@CAVE2_MONSTERS_QTY[4]) goto L_Done; + if ($@cave2_kills >= $@CAVE2_MONSTERS_QTY[1] + $@CAVE2_MONSTERS_QTY[2] + $@CAVE2_MONSTERS_QTY[3] + $@CAVE2_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -201,8 +220,9 @@ L_no_root: // --------------------- Cave 2 Checker ---------------------------- -025-4.gat,110,96,0 script #CheckCaveFight2 45,1,1,{ - if (cavefights & BATTLE_CAVE2 || $@battlecave2 == 1) goto L_Done; +025-4.gat,110,96,0|script|#CheckCaveFight2|45,1,1,{ + if (cavefights & BATTLE_CAVE2 || $@battlecave2 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -212,11 +232,15 @@ L_Done: } // ------------------------------------ Cave 3 -------------------------------------- -025-4.gat,164,103,0 script #StartCaveFight3 324,{ - if ($@battlecave3 == 2 && $@cave3fighter$ == strcharinfo(0)) end; - if ($@battlecave3 == 2 && $@cave3fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave3 == 1) goto L_Start; +025-4.gat,164,103,0|script|#StartCaveFight3|324,{ + if ($@battlecave3 == 2 && $@cave3fighter$ == strcharinfo(0)) + end; + if ($@battlecave3 == 2 && $@cave3fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave3 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -227,7 +251,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -236,7 +261,8 @@ L_Start: L_Summon: set $@cave3_loop, $@cave3_loop + 1; areamonster "025-4.gat",150, 84, 177, 117,"",$@CAVE3_MONSTERS_IDS[$@cave3_loop],$@CAVE3_MONSTERS_QTY[$@cave3_loop],"#StartCaveFight3::OnMonsterDeath"; - if ($@cave3_loop <= getarraysize($@CAVE3_MONSTERS_IDS)) goto L_Summon; + if ($@cave3_loop <= getarraysize($@CAVE3_MONSTERS_IDS)) + goto L_Summon; set $@cave3_loop, 0; end; @@ -248,15 +274,18 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave3 == 1) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave3 == 1) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave3 < $@CAVE3_WAVES) goto L_Summon; + if ($@wave_cave3 < $@CAVE3_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE3); end; OnMonsterDeath: set $@cave3_kills, $@cave3_kills + 1; - if ($@cave3_kills >= $@CAVE3_MONSTERS_QTY[1] + $@CAVE3_MONSTERS_QTY[2] + $@CAVE3_MONSTERS_QTY[3] + $@CAVE3_MONSTERS_QTY[4]) goto L_Done; + if ($@cave3_kills >= $@CAVE3_MONSTERS_QTY[1] + $@CAVE3_MONSTERS_QTY[2] + $@CAVE3_MONSTERS_QTY[3] + $@CAVE3_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -270,8 +299,9 @@ L_no_root: // --------------------- Cave 3 Checker ---------------------------- -025-4.gat,168,117,0 script #CheckCaveFight3 45,1,1,{ - if (cavefights & BATTLE_CAVE3 || $@battlecave3 == 1) goto L_Done; +025-4.gat,168,117,0|script|#CheckCaveFight3|45,1,1,{ + if (cavefights & BATTLE_CAVE3 || $@battlecave3 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -281,11 +311,15 @@ L_Done: } // --------------------------- Cave 4 -------------------------------- -025-4.gat,39,143,0 script #StartCaveFight4 324,{ - if ($@battlecave4 == 2 && $@cave4fighter$ == strcharinfo(0)) end; - if ($@battlecave4 == 2 && $@cave4fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave4 == 1) goto L_Start; +025-4.gat,39,143,0|script|#StartCaveFight4|324,{ + if ($@battlecave4 == 2 && $@cave4fighter$ == strcharinfo(0)) + end; + if ($@battlecave4 == 2 && $@cave4fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave4 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -296,7 +330,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -305,7 +340,8 @@ L_Start: L_Summon: set $@cave4_loop, $@cave4_loop + 1; areamonster "025-4.gat",28, 124, 57, 156,"",$@CAVE4_MONSTERS_IDS[$@cave4_loop],$@CAVE4_MONSTERS_QTY[$@cave4_loop],"#StartCaveFight4::OnMonsterDeath"; - if ($@cave4_loop <= getarraysize($@CAVE4_MONSTERS_IDS)) goto L_Summon; + if ($@cave4_loop <= getarraysize($@CAVE4_MONSTERS_IDS)) + goto L_Summon; set $@cave4_loop, 0; end; @@ -317,16 +353,20 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave4 == 1) message strcharinfo(0), "Oh no, more monsters?!"; - if ($@wave_cave4 == 2) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave4 == 1) + message strcharinfo(0), "Oh no, more monsters?!"; + if ($@wave_cave4 == 2) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave4 < $@CAVE4_WAVES) goto L_Summon; + if ($@wave_cave4 < $@CAVE4_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE4); end; OnMonsterDeath: set $@cave4_kills, $@cave4_kills + 1; - if ($@cave4_kills >= $@CAVE4_MONSTERS_QTY[1] + $@CAVE4_MONSTERS_QTY[2] + $@CAVE4_MONSTERS_QTY[3] + $@CAVE4_MONSTERS_QTY[4]) goto L_Done; + if ($@cave4_kills >= $@CAVE4_MONSTERS_QTY[1] + $@CAVE4_MONSTERS_QTY[2] + $@CAVE4_MONSTERS_QTY[3] + $@CAVE4_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -340,8 +380,9 @@ L_no_root: // --------------------- Cave 4 Checker ---------------------------- -025-4.gat,32,156,0 script #CheckCaveFight4 45,1,1,{ - if (cavefights & BATTLE_CAVE4 || $@battlecave4 == 1) goto L_Done; +025-4.gat,32,156,0|script|#CheckCaveFight4|45,1,1,{ + if (cavefights & BATTLE_CAVE4 || $@battlecave4 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -352,11 +393,15 @@ L_Done: // ---------------------------- Cave 5 ------------------------------ -025-4.gat,109,143,0 script #StartCaveFight5 324,{ - if ($@battlecave5 == 2 && $@cave5fighter$ == strcharinfo(0)) end; - if ($@battlecave5 == 2 && $@cave5fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave5 == 1) goto L_Start; +025-4.gat,109,143,0|script|#StartCaveFight5|324,{ + if ($@battlecave5 == 2 && $@cave5fighter$ == strcharinfo(0)) + end; + if ($@battlecave5 == 2 && $@cave5fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave5 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -367,7 +412,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -376,7 +422,8 @@ L_Start: L_Summon: set $@cave5_loop, $@cave5_loop + 1; areamonster "025-4.gat",91, 131, 124, 160,"",$@CAVE5_MONSTERS_IDS[$@cave5_loop],$@CAVE5_MONSTERS_QTY[$@cave5_loop],"#StartCaveFight5::OnMonsterDeath"; - if ($@cave5_loop <= getarraysize($@CAVE5_MONSTERS_IDS)) goto L_Summon; + if ($@cave5_loop <= getarraysize($@CAVE5_MONSTERS_IDS)) + goto L_Summon; set $@cave5_loop, 0; end; @@ -388,16 +435,20 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave5 == 1) message strcharinfo(0), "Oh no, more monsters?!"; - if ($@wave_cave5 == 2) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave5 == 1) + message strcharinfo(0), "Oh no, more monsters?!"; + if ($@wave_cave5 == 2) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave5 < $@CAVE5_WAVES) goto L_Summon; + if ($@wave_cave5 < $@CAVE5_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE5); end; OnMonsterDeath: set $@cave5_kills, $@cave5_kills + 1; - if ($@cave5_kills >= $@CAVE5_MONSTERS_QTY[1] + $@CAVE5_MONSTERS_QTY[2] + $@CAVE5_MONSTERS_QTY[3] + $@CAVE5_MONSTERS_QTY[4]) goto L_Done; + if ($@cave5_kills >= $@CAVE5_MONSTERS_QTY[1] + $@CAVE5_MONSTERS_QTY[2] + $@CAVE5_MONSTERS_QTY[3] + $@CAVE5_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -411,8 +462,9 @@ L_no_root: // --------------------- Cave 5 Checker ---------------------------- -025-4.gat,100,160,0 script #CheckCaveFight5 45,1,1,{ - if (cavefights & BATTLE_CAVE5 || $@battlecave5 == 1) goto L_Done; +025-4.gat,100,160,0|script|#CheckCaveFight5|45,1,1,{ + if (cavefights & BATTLE_CAVE5 || $@battlecave5 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -423,11 +475,15 @@ L_Done: // -------------------------------- Cave 6 ----------------------------------------- -025-4.gat,162,162,0 script #StartCaveFight6 324,{ - if ($@battlecave6 == 2 && $@cave6fighter$ == strcharinfo(0)) end; - if ($@battlecave6 == 2 && $@cave6fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave6 == 1) goto L_Start; +025-4.gat,162,162,0|script|#StartCaveFight6|324,{ + if ($@battlecave6 == 2 && $@cave6fighter$ == strcharinfo(0)) + end; + if ($@battlecave6 == 2 && $@cave6fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave6 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -438,7 +494,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -447,7 +504,8 @@ L_Start: L_Summon: set $@cave6_loop, $@cave6_loop + 1; areamonster "025-4.gat",153, 143, 178, 174,"",$@CAVE6_MONSTERS_IDS[$@cave6_loop],$@CAVE6_MONSTERS_QTY[$@cave6_loop],"#StartCaveFight6::OnMonsterDeath"; - if ($@cave6_loop <= getarraysize($@CAVE6_MONSTERS_IDS)) goto L_Summon; + if ($@cave6_loop <= getarraysize($@CAVE6_MONSTERS_IDS)) + goto L_Summon; set $@cave6_loop, 0; end; @@ -459,16 +517,20 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave6 == 1) message strcharinfo(0), "Oh no, more monsters?!"; - if ($@wave_cave6 == 2) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave6 == 1) + message strcharinfo(0), "Oh no, more monsters?!"; + if ($@wave_cave6 == 2) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave6 < $@CAVE6_WAVES) goto L_Summon; + if ($@wave_cave6 < $@CAVE6_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE6); end; OnMonsterDeath: set $@cave6_kills, $@cave6_kills + 1; - if ($@cave6_kills >= $@CAVE6_MONSTERS_QTY[1] + $@CAVE6_MONSTERS_QTY[2] + $@CAVE6_MONSTERS_QTY[3] + $@CAVE6_MONSTERS_QTY[4]) goto L_Done; + if ($@cave6_kills >= $@CAVE6_MONSTERS_QTY[1] + $@CAVE6_MONSTERS_QTY[2] + $@CAVE6_MONSTERS_QTY[3] + $@CAVE6_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -482,8 +544,9 @@ L_no_root: // --------------------- Cave 6 Checker ---------------------------- -025-4.gat,159,174,0 script #CheckCaveFight6 45,1,1,{ - if (cavefights & BATTLE_CAVE6 || $@battlecave6 == 1) goto L_Done; +025-4.gat,159,174,0|script|#CheckCaveFight6|45,1,1,{ + if (cavefights & BATTLE_CAVE6 || $@battlecave6 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -494,11 +557,15 @@ L_Done: // -------------------------------- Cave 7 ----------------------------------- -025-4.gat,44,202,0 script #StartCaveFight7 324,{ - if ($@battlecave7 == 2 && $@cave7fighter$ == strcharinfo(0)) end; - if ($@battlecave7 == 2 && $@cave7fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave7 == 1) goto L_Start; +025-4.gat,44,202,0|script|#StartCaveFight7|324,{ + if ($@battlecave7 == 2 && $@cave7fighter$ == strcharinfo(0)) + end; + if ($@battlecave7 == 2 && $@cave7fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave7 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -509,7 +576,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -518,7 +586,8 @@ L_Start: L_Summon: set $@cave7_loop, $@cave7_loop + 1; areamonster "025-4.gat",27, 185, 61, 219,"",$@CAVE7_MONSTERS_IDS[$@cave7_loop],$@CAVE7_MONSTERS_QTY[$@cave7_loop],"#StartCaveFight7::OnMonsterDeath"; - if ($@cave7_loop <= getarraysize($@CAVE7_MONSTERS_IDS)) goto L_Summon; + if ($@cave7_loop <= getarraysize($@CAVE7_MONSTERS_IDS)) + goto L_Summon; set $@cave7_loop, 0; end; @@ -530,17 +599,22 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave7 == 1) message strcharinfo(0), "Oh no, more monsters?!"; - if ($@wave_cave7 == 2) message strcharinfo(0), "I can't give up now!"; - if ($@wave_cave7 == 3) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave7 == 1) + message strcharinfo(0), "Oh no, more monsters?!"; + if ($@wave_cave7 == 2) + message strcharinfo(0), "I can't give up now!"; + if ($@wave_cave7 == 3) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave7 < $@CAVE7_WAVES) goto L_Summon; + if ($@wave_cave7 < $@CAVE7_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE7); end; OnMonsterDeath: set $@cave7_kills, $@cave7_kills + 1; - if ($@cave7_kills >= $@CAVE7_MONSTERS_QTY[1] + $@CAVE7_MONSTERS_QTY[2] + $@CAVE7_MONSTERS_QTY[3] + $@CAVE7_MONSTERS_QTY[4]) goto L_Done; + if ($@cave7_kills >= $@CAVE7_MONSTERS_QTY[1] + $@CAVE7_MONSTERS_QTY[2] + $@CAVE7_MONSTERS_QTY[3] + $@CAVE7_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -554,8 +628,9 @@ L_no_root: // --------------------- Cave 7 Checker ---------------------------- -025-4.gat,42,219,0 script #CheckCaveFight7 45,1,1,{ - if (cavefights & BATTLE_CAVE7 || $@battlecave7 == 1) goto L_Done; +025-4.gat,42,219,0|script|#CheckCaveFight7|45,1,1,{ + if (cavefights & BATTLE_CAVE7 || $@battlecave7 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -566,11 +641,15 @@ L_Done: // --------------------------- Cave 8 ------------------------------- -025-4.gat,105,210,0 script #StartCaveFight8 324,{ - if ($@battlecave8 == 2 && $@cave8fighter$ == strcharinfo(0)) end; - if ($@battlecave8 == 2 && $@cave8fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave8 == 1) goto L_Start; +025-4.gat,105,210,0|script|#StartCaveFight8|324,{ + if ($@battlecave8 == 2 && $@cave8fighter$ == strcharinfo(0)) + end; + if ($@battlecave8 == 2 && $@cave8fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave8 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -581,7 +660,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -590,7 +670,8 @@ L_Start: L_Summon: set $@cave8_loop, $@cave8_loop + 1; areamonster "025-4.gat",90, 193, 119, 216,"",$@CAVE8_MONSTERS_IDS[$@cave8_loop],$@CAVE8_MONSTERS_QTY[$@cave8_loop],"#StartCaveFight8::OnMonsterDeath"; - if ($@cave8_loop <= getarraysize($@CAVE8_MONSTERS_IDS)) goto L_Summon; + if ($@cave8_loop <= getarraysize($@CAVE8_MONSTERS_IDS)) + goto L_Summon; set $@cave8_loop, 0; end; @@ -602,17 +683,22 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave8 == 1) message strcharinfo(0), "Oh no, more monsters?!"; - if ($@wave_cave8 == 2) message strcharinfo(0), "I can't give up now!"; - if ($@wave_cave8 == 3) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave8 == 1) + message strcharinfo(0), "Oh no, more monsters?!"; + if ($@wave_cave8 == 2) + message strcharinfo(0), "I can't give up now!"; + if ($@wave_cave8 == 3) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave8 < $@CAVE8_WAVES) goto L_Summon; + if ($@wave_cave8 < $@CAVE8_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE8); end; OnMonsterDeath: set $@cave8_kills, $@cave8_kills + 1; - if ($@cave8_kills >= $@CAVE8_MONSTERS_QTY[1] + $@CAVE8_MONSTERS_QTY[2] + $@CAVE8_MONSTERS_QTY[3] + $@CAVE8_MONSTERS_QTY[4]) goto L_Done; + if ($@cave8_kills >= $@CAVE8_MONSTERS_QTY[1] + $@CAVE8_MONSTERS_QTY[2] + $@CAVE8_MONSTERS_QTY[3] + $@CAVE8_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -626,8 +712,9 @@ L_no_root: // --------------------- Cave 8 Checker ---------------------------- -025-4.gat,105,216,0 script #CheckCaveFight8 45,1,1,{ - if (cavefights & BATTLE_CAVE8 || $@battlecave8 == 1) goto L_Done; +025-4.gat,105,216,0|script|#CheckCaveFight8|45,1,1,{ + if (cavefights & BATTLE_CAVE8 || $@battlecave8 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -638,11 +725,15 @@ L_Done: // --------------------------- Cave 9 ------------------------------- -025-4.gat,157,220,0 script #StartCaveFight9 324,{ - if ($@battlecave9 == 2 && $@cave9fighter$ == strcharinfo(0)) end; - if ($@battlecave9 == 2 && $@cave9fighter$ != strcharinfo(0)) goto L_Cheat; - if (Rossy_Quest < 15) goto L_Cheat; - if ($@battlecave9 == 1) goto L_Start; +025-4.gat,157,220,0|script|#StartCaveFight9|324,{ + if ($@battlecave9 == 2 && $@cave9fighter$ == strcharinfo(0)) + end; + if ($@battlecave9 == 2 && $@cave9fighter$ != strcharinfo(0)) + goto L_Cheat; + if (Rossy_Quest < 15) + goto L_Cheat; + if ($@battlecave9 == 1) + goto L_Start; L_Cheat: message strcharinfo(0), "You shouldn't be here, you cheater."; @@ -653,7 +744,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -662,7 +754,8 @@ L_Start: L_Summon: set $@cave9_loop, $@cave9_loop + 1; areamonster "025-4.gat",144, 192, 173, 226,"",$@CAVE9_MONSTERS_IDS[$@cave9_loop],$@CAVE9_MONSTERS_QTY[$@cave9_loop],"#StartCaveFight9::OnMonsterDeath"; - if ($@cave9_loop <= getarraysize($@CAVE9_MONSTERS_IDS)) goto L_Summon; + if ($@cave9_loop <= getarraysize($@CAVE9_MONSTERS_IDS)) + goto L_Summon; set $@cave9_loop, 0; end; @@ -674,17 +767,22 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave9 == 1) message strcharinfo(0), "Oh no, more monsters?!"; - if ($@wave_cave9 == 2) message strcharinfo(0), "I can't give up now!"; - if ($@wave_cave9 == 3) message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; + if ($@wave_cave9 == 1) + message strcharinfo(0), "Oh no, more monsters?!"; + if ($@wave_cave9 == 2) + message strcharinfo(0), "I can't give up now!"; + if ($@wave_cave9 == 3) + message strcharinfo(0), "As soon as you kill the last monster, your vision blacks out and you feel a strange sensation... Maybe it is not healthy to stay in this cave."; - if ($@wave_cave9 < $@CAVE9_WAVES) goto L_Summon; + if ($@wave_cave9 < $@CAVE9_WAVES) + goto L_Summon; set cavefights, (cavefights | BATTLE_CAVE9); end; OnMonsterDeath: set $@cave9_kills, $@cave9_kills + 1; - if ($@cave9_kills >= $@CAVE9_MONSTERS_QTY[1] + $@CAVE9_MONSTERS_QTY[2] + $@CAVE9_MONSTERS_QTY[3] + $@CAVE9_MONSTERS_QTY[4]) goto L_Done; + if ($@cave9_kills >= $@CAVE9_MONSTERS_QTY[1] + $@CAVE9_MONSTERS_QTY[2] + $@CAVE9_MONSTERS_QTY[3] + $@CAVE9_MONSTERS_QTY[4]) + goto L_Done; end; L_Close: @@ -698,8 +796,9 @@ L_no_root: // --------------------- Cave 9 Checker ---------------------------- -025-4.gat,157,226,0 script #CheckCaveFight9 45,1,1,{ - if (cavefights & BATTLE_CAVE9 || $@battlecave9 == 1) goto L_Done; +025-4.gat,157,226,0|script|#CheckCaveFight9|45,1,1,{ + if (cavefights & BATTLE_CAVE9 || $@battlecave9 == 1) + goto L_Done; message strcharinfo(0), "You can't get out! Seems like a barrier was created when the energy transmuted itself into monsters."; end; @@ -710,10 +809,13 @@ L_Done: // --------------------- Boss Cave ---------------------------- -025-4.gat,157,30,0 script #StartBossCaveFight 325,{ - if ($@battlecave10 == 2 && $@cave10fighter$ == strcharinfo(0)) end; - if (Rossy_Quest >= 16) end; - if ($@battlecave10 == 1 && cavefights & BATTLE_CAVE1 && cavefights & BATTLE_CAVE2 && cavefights & BATTLE_CAVE3 && cavefights & BATTLE_CAVE4 && cavefights & BATTLE_CAVE5 && cavefights & BATTLE_CAVE6 && cavefights & BATTLE_CAVE7 && cavefights & BATTLE_CAVE8 && cavefights & BATTLE_CAVE9 && Rossy_Quest == 15) goto L_Start; +025-4.gat,157,30,0|script|#StartBossCaveFight|325,{ + if ($@battlecave10 == 2 && $@cave10fighter$ == strcharinfo(0)) + end; + if (Rossy_Quest >= 16) + end; + if ($@battlecave10 == 1 && cavefights & BATTLE_CAVE1 && cavefights & BATTLE_CAVE2 && cavefights & BATTLE_CAVE3 && cavefights & BATTLE_CAVE4 && cavefights & BATTLE_CAVE5 && cavefights & BATTLE_CAVE6 && cavefights & BATTLE_CAVE7 && cavefights & BATTLE_CAVE8 && cavefights & BATTLE_CAVE9 && Rossy_Quest == 15) + goto L_Start; message strcharinfo(0), "You shouldn't be here, you cheater."; percentheal -100, 0; end; @@ -722,7 +824,8 @@ L_Start: menu "Place a root at the center of the energy source.", -, "I am not prepared yet!", L_Close; - if ((countitem("Root")<1)) goto L_no_root; + if ((countitem("Root")<1)) + goto L_no_root; close2; delitem "Root", 1; message strcharinfo(0), "As you place the root on the energy source, earth monsters seem to emerge from the ground."; @@ -731,7 +834,8 @@ L_Start: L_Summon: set $@cave10_loop, $@cave10_loop + 1; areamonster "025-4.gat",142, 24, 172, 48,"",$@CAVE10_MONSTERS_IDS[$@cave10_loop],$@CAVE10_MONSTERS_QTY[$@cave10_loop],"#StartBossCaveFight::OnMonsterDeath"; - if ($@cave10_loop <= getarraysize($@CAVE10_MONSTERS_IDS)) goto L_Summon; + if ($@cave10_loop <= getarraysize($@CAVE10_MONSTERS_IDS)) + goto L_Summon; set $@cave10_loop, 0; end; @@ -750,12 +854,17 @@ L_Done: // Here you can define the messages to be shown for the players on the beginning of each wave. // Remember to adjust the number of conditionals according to the number of waves. - if ($@wave_cave10 == 1) message strcharinfo(0), "I can't give up now!"; - if ($@wave_cave10 == 2) message strcharinfo(0), "I feel I'm getting close to the end..."; - if ($@wave_cave10 == 3) message strcharinfo(0), "What? This is harder than I imagined!"; - if ($@wave_cave10 == 4) message strcharinfo(0), "Finally! It seems I have defeated all of them!"; - - if ($@wave_cave10 < $@CAVE10_WAVES) goto L_Summon; + if ($@wave_cave10 == 1) + message strcharinfo(0), "I can't give up now!"; + if ($@wave_cave10 == 2) + message strcharinfo(0), "I feel I'm getting close to the end..."; + if ($@wave_cave10 == 3) + message strcharinfo(0), "What? This is harder than I imagined!"; + if ($@wave_cave10 == 4) + message strcharinfo(0), "Finally! It seems I have defeated all of them!"; + + if ($@wave_cave10 < $@CAVE10_WAVES) + goto L_Summon; set $@wave_cave10, 5; set @boss, 0; startnpctimer; @@ -775,17 +884,21 @@ L_CleaningNorid: end; OnTimer4000: - if (isloggedin(getcharid(3,$@cave10fighter$))==0) goto L_CleaningNorid; + if (isloggedin(getcharid(3,$@cave10fighter$))==0) + goto L_CleaningNorid; attachrid(getcharid(3,$@cave10fighter$)); set @boss, @boss + 1; - if (@boss == 1) message strcharinfo(0), "You feel something strange... Looks like something terrible is about to show up in this cave."; - if (@boss == 2) goto L_SummonBoss; + if (@boss == 1) + message strcharinfo(0), "You feel something strange... Looks like something terrible is about to show up in this cave."; + if (@boss == 2) + goto L_SummonBoss; setnpctimer 0; end; OnMonsterDeath: set $@cave10_kills, $@cave10_kills + 1; - if ($@cave10_kills >= $@CAVE10_MONSTERS_QTY[1] + $@CAVE10_MONSTERS_QTY[2] + $@CAVE10_MONSTERS_QTY[3] + $@CAVE10_MONSTERS_QTY[4]) goto L_Done; + if ($@cave10_kills >= $@CAVE10_MONSTERS_QTY[1] + $@CAVE10_MONSTERS_QTY[2] + $@CAVE10_MONSTERS_QTY[3] + $@CAVE10_MONSTERS_QTY[4]) + goto L_Done; end; OnBossDeath: @@ -806,11 +919,15 @@ L_no_root: // --------------------- Boss Cave Checker ---------------------------- -025-4.gat,157,48,0 script #CheckCaveFightBoss 45,1,1,{ - if (Rossy_Quest >= 17) goto L_Done; - if (Rossy_Quest == 16) goto L_Julia; - if (Rossy_Quest < 16 && $@battlecave10 == 1) goto L_Out; - if (Rossy_Quest < 16 && $@battlecave10 == 2) goto L_Julia; +025-4.gat,157,48,0|script|#CheckCaveFightBoss|45,1,1,{ + if (Rossy_Quest >= 17) + goto L_Done; + if (Rossy_Quest == 16) + goto L_Julia; + if (Rossy_Quest < 16 && $@battlecave10 == 1) + goto L_Out; + if (Rossy_Quest < 16 && $@battlecave10 == 2) + goto L_Julia; end; L_Julia: @@ -828,8 +945,9 @@ L_Out: // --------------------- Julia Cave Checker Outside ---------------------------- -025-4.gat,157,24,0 script #CheckJuliaCaveOutside 45,1,1,{ - if (Rossy_Quest > 15) goto L_Done; +025-4.gat,157,24,0|script|#CheckJuliaCaveOutside|45,1,1,{ + if (Rossy_Quest > 15) + goto L_Done; message strcharinfo(0), "As you try to walk through, you bump into a strong magical barrier."; percentheal -10, 0; end; @@ -841,10 +959,13 @@ L_Done: // --------------------- Julia Cave Checker Inside ---------------------------- -025-4.gat,93,35,0 script #CheckJuliaCaveInside 45,1,1,{ - if (Rossy_Quest >= 17) goto L_Done; - if (Rossy_Quest == 16) goto L_Save; - if (Rossy_Quest <= 15) goto L_Cheat; +025-4.gat,93,35,0|script|#CheckJuliaCaveInside|45,1,1,{ + if (Rossy_Quest >= 17) + goto L_Done; + if (Rossy_Quest == 16) + goto L_Save; + if (Rossy_Quest <= 15) + goto L_Cheat; end; L_Cheat: -- cgit v1.2.3-70-g09d2