diff options
author | Jesusaves <cpntb1@ymail.com> | 2021-12-07 11:01:18 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2021-12-07 11:32:52 -0300 |
commit | 08ea4636d79ffe5055f203d9017b29a1fa2832c6 (patch) | |
tree | 5f2218872fa4e4e8d31ef0851c98f45b191847e8 /npc/annuals/xmas | |
parent | 7c5fbe2f3a627bceb6132dbd50d06e4c92257b8a (diff) | |
download | serverdata-08ea4636d79ffe5055f203d9017b29a1fa2832c6.tar.gz serverdata-08ea4636d79ffe5055f203d9017b29a1fa2832c6.tar.bz2 serverdata-08ea4636d79ffe5055f203d9017b29a1fa2832c6.tar.xz serverdata-08ea4636d79ffe5055f203d9017b29a1fa2832c6.zip |
Some minor fixes, but some stuff is still broken
Diffstat (limited to 'npc/annuals/xmas')
-rw-r--r-- | npc/annuals/xmas/2021.txt | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/npc/annuals/xmas/2021.txt b/npc/annuals/xmas/2021.txt index 70b2b7da..f32901a6 100644 --- a/npc/annuals/xmas/2021.txt +++ b/npc/annuals/xmas/2021.txt @@ -254,7 +254,7 @@ function script X21_SEEDS { if (.@y < 159 || .@y > 177) return; // Should never happen, so nuke everything - if (instance_id() < 0) end; + //if (instance_id() < 0) end; // Already planted this spot if ('XMAS21TREE_X[.@x] && 'XMAS21TREE_Y[.@y]) return; // Record the success planting it @@ -328,16 +328,16 @@ public function spawn2 { .@y2=min(getarg(2)+getarg(3), getmapinfo(MAPINFO_SIZE_Y, .@m$)-20); */ if (mobcount(.@m$, .@n$) < 200) { - .@m=areamonster(.@m$, .@x1, .@y1, .@x2, .@y2, strmobinfo(1, getarg(0)), getarg(0), getarg(5, 1), .@n$); - if (.@noob) { - .@hp = getunitdata(.@m, UDT_MAXHP) * 3 / 5; // Reduce to 60% HP - .@ak = getunitdata(.@m, UDT_ATKMIN) * 4 / 5; // Reduce to 80% ATK - .@ax = getunitdata(.@m, UDT_ATKMAX) * 4 / 5; // Reduce to 80% ATK - - setunitdata(.@m, UDT_MAXHP, .@hp); - setunitdata(.@m, UDT_HP, .@hp); - setunitdata(.@m, UDT_ATKMIN, .@ak); - setunitdata(.@m, UDT_ATKMAX, .@ax); + .@mg=areamonster(.@m$, .@x1, .@y1, .@x2, .@y2, strmobinfo(1, getarg(0)), getarg(0), getarg(5, 1), .@n$); + if (.@noob && .@mg) { + .@hp = getunitdata(.@mg, UDT_MAXHP) * 3 / 5; // Reduce to 60% HP + .@ak = getunitdata(.@mg, UDT_ATKMIN) * 4 / 5; // Reduce to 80% ATK + .@ax = getunitdata(.@mg, UDT_ATKMAX) * 4 / 5; // Reduce to 80% ATK + + setunitdata(.@mg, UDT_MAXHP, .@hp); + setunitdata(.@mg, UDT_HP, .@hp); + setunitdata(.@mg, UDT_ATKMIN, .@ak); + setunitdata(.@mg, UDT_ATKMAX, .@ax); } } return; @@ -556,8 +556,9 @@ OnInit: "#XMAS21Core"::spawn(Wisp, 7, "081-1"); "#XMAS21Core"::spawn(Spectre, 7, "081-1"); "#XMAS21Core"::spawn(WhiteSlime, 12, "081-1"); - "#XMAS21Core"::spawn(SantaSlime, 3, "081-1"); - "#XMAS21Core"::spawn(Moggun, 18, "081-1"); + "#XMAS21Core"::spawn(SantaSlime, 4, "081-1"); + "#XMAS21Core"::spawn(Moggun, 10, "081-1"); + "#XMAS21Core"::spawn(Moonshroom, 7, "081-1"); end; } |