summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-12-07 22:44:55 -0300
committerJesusaves <cpntb1@ymail.com>2021-12-07 22:44:55 -0300
commitc1ca96a81d1ede3896f39c5cfbd5643a00e63a20 (patch)
tree762235b7be5f5bee90d7d2906a46b14eb952f11a
parenteec4652b973075e42ed87396d7e801fe38b0b6f5 (diff)
downloadserverdata-c1ca96a81d1ede3896f39c5cfbd5643a00e63a20.tar.gz
serverdata-c1ca96a81d1ede3896f39c5cfbd5643a00e63a20.tar.bz2
serverdata-c1ca96a81d1ede3896f39c5cfbd5643a00e63a20.tar.xz
serverdata-c1ca96a81d1ede3896f39c5cfbd5643a00e63a20.zip
Fix a few of the major errors and bugs
-rw-r--r--npc/081-2/logic.txt23
-rw-r--r--npc/annuals/xmas/2021.txt27
2 files changed, 29 insertions, 21 deletions
diff --git a/npc/081-2/logic.txt b/npc/081-2/logic.txt
index ba9b6abd..604fd9eb 100644
--- a/npc/081-2/logic.txt
+++ b/npc/081-2/logic.txt
@@ -160,7 +160,8 @@ OnInit:
end;
}
-081-2,105,213,0 script #X21Barrier1 NPC_HIDDEN,2,0,{
+081-2,100,213,0 script #X21Barrier1 NPC_HIDDEN,7,0,{
+ @inst = instance_id();
if (!'XMAS21CANDLE)
npctalkonce l("The strong shall yield the powder to enlighten the way, according to the established sequence.");
end;
@@ -185,6 +186,26 @@ OnInit:
if (!'XMAS21TREE)
npctalkonce l("The leaves in a room, the objects from the other; When they merge together, the festivities shall proceed.");
end;
+OnPlant:
+ getmapxy(.@m$, .@x, .@y, 0);
+ // Should never happen, so nuke everything
+ if (instance_id() < 0) end;
+ // Already planted this spot
+ if ('XMAS21TREE_X[.@x] && 'XMAS21TREE_Y[.@y]) return;
+ // Record the success planting it
+ 'XMAS21TREE_X[.@x] = true;
+ 'XMAS21TREE_Y[.@y] = true;
+ // Sprout a Christmas Tree IF position was not already filled
+ monster(.@m$, .@x, .@y, strmobinfo(1, ChristmasTree), ChristmasTree, 1, "#XMAS21Core::OnX1164");
+ // Unlock the gate once the puzzle is complete
+ if (X21SEED_CHECK()) {
+ delcells("X21L2@"+X21ID());
+ specialeffect(FX_MAGIC_WICKED_SPAWN, AREA, getcharid(3));
+ getexp X21_EXP_PUZZLE, 0;
+ getitem AquaTicket, X21_TICKET_PUZZLE;
+ X21INIT();
+ }
+ end;
OnInit:
.distance=2;
end;
diff --git a/npc/annuals/xmas/2021.txt b/npc/annuals/xmas/2021.txt
index ca24ebcc..dee9db7c 100644
--- a/npc/annuals/xmas/2021.txt
+++ b/npc/annuals/xmas/2021.txt
@@ -88,7 +88,7 @@ function script X21INIT {
if (X21TYPE() == IOT_PARTY)
"#XMAS21Core"::spawn2(Koyntety, 70, 250, 99, 265, 1, .@mapa$, true);
else
- "#XMAS21Core"::spawn2(ManaGuardian, 70, 250, 99, 265, 1, .@mapa$, true);
+ "#XMAS21Core"::spawn2(ManaGuard, 70, 250, 99, 265, 1, .@mapa$, true);
/* Northern Lights Dungeon */
"#XMAS21Core"::spawn(WhiteSlime, 37, .@mapa$);
@@ -253,23 +253,7 @@ function script X21_SEEDS {
return;
if (.@y < 159 || .@y > 177)
return;
- // Should never happen, so nuke everything
- //if (instance_id() < 0) end;
- // Already planted this spot
- if ('XMAS21TREE_X[.@x] && 'XMAS21TREE_Y[.@y]) return;
- // Record the success planting it
- 'XMAS21TREE_X[.@x] = true;
- 'XMAS21TREE_Y[.@y] = true;
- // Sprout a Christmas Tree IF position was not already filled
- monster(.@m$, .@x, .@y, strmobinfo(1, ChristmasTree), ChristmasTree, 1, "#XMAS21Core::OnX1164");
- // Unlock the gate once the puzzle is complete
- if (X21SEED_CHECK()) {
- delcells("X21L2@"+X21ID());
- specialeffect(FX_MAGIC_WICKED_SPAWN, AREA, getcharid(3));
- getexp X21_EXP_PUZZLE, 0;
- getitem AquaTicket, X21_TICKET_PUZZLE;
- X21INIT();
- }
+ addtimer 10, instance_npcname("#X21SeedFlag", @inst)+"::OnPlant";
return;
}
@@ -338,6 +322,8 @@ public function spawn2 {
setunitdata(.@mg, UDT_HP, .@hp);
setunitdata(.@mg, UDT_ATKMIN, .@ak);
setunitdata(.@mg, UDT_ATKMAX, .@ax);
+ } else if (.@noob) {
+ debugmes "WARN: Faulty %dx %d at map %s", getarg(5,1), getarg(0), .@m$;
}
}
return;
@@ -376,7 +362,7 @@ OnX1147:
OnX1140:
OnX1143:
OnX1138:
- spawn2(any(Tengu, ManaSlayer, ManaGuardian, ManaGuardian), 70, 250, 99, 265, 1, getmap(), true);
+ spawn2(any(Tengu, ManaSlayer, ManaGuard, ManaGuard), 70, 250, 99, 265, 1, getmap(), true);
/* Give player enough fuel potions */
getmapxy(.@m$, .@x, .@y, 0);
.@x1=.@x-1;
@@ -407,6 +393,7 @@ OnX1165:
.@y2=.@y+2;
.@x=cap_value(rand2(.@x1, .@x2), 47, 65);
.@y=cap_value(rand2(.@y1, .@y2), 191, 212);
+ debugmes "GIFT BOX %d %d", .@x, .@y;
makeitem(AquaTicket, 1, .@m$, .@x, .@y);
end;
@@ -499,7 +486,7 @@ On1140:
spawn(Tengu);
end;
On1138:
- spawn(ManaGuardian);
+ spawn(ManaGuard);
end;
On1143:
spawn(ManaSlayer);