summaryrefslogtreecommitdiff
path: root/npc/functions/quests.txt
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-04-17 16:15:39 -0300
committerJesusaves <cpntb1@ymail.com>2021-04-17 16:15:39 -0300
commitf0e1bab3417e559b5b62f3ae4e74ea922a2c945f (patch)
tree8e2dd3fbe727083b54f583817a1825eb95c29b94 /npc/functions/quests.txt
parent14f7af0b7b3839f0e1b35c31bf3bd17e70cf366f (diff)
downloadserverdata-f0e1bab3417e559b5b62f3ae4e74ea922a2c945f.tar.gz
serverdata-f0e1bab3417e559b5b62f3ae4e74ea922a2c945f.tar.bz2
serverdata-f0e1bab3417e559b5b62f3ae4e74ea922a2c945f.tar.xz
serverdata-f0e1bab3417e559b5b62f3ae4e74ea922a2c945f.zip
Update Valon's scripts
Diffstat (limited to 'npc/functions/quests.txt')
-rw-r--r--npc/functions/quests.txt30
1 files changed, 30 insertions, 0 deletions
diff --git a/npc/functions/quests.txt b/npc/functions/quests.txt
index 3f0c40ef..fcdc13eb 100644
--- a/npc/functions/quests.txt
+++ b/npc/functions/quests.txt
@@ -35,3 +35,33 @@ function script elanore_decrease_exp {
return;
}
+function script ValonCount {
+ @valon_mob = 0;
+ if (QL_VALON >= 2)
+ @valon_mob = (QL_VALON - 2);
+ @valon_count = ((STARTAREA & NIBBLE_2_MASK) >> NIBBLE_2_SHIFT);
+ return;
+}
+
+function script ResetValonCntMask {
+ STARTAREA = (STARTAREA & ~(NIBBLE_2_MASK) | (0 << NIBBLE_2_SHIFT));
+ return;
+}
+
+function script ValonProgress {
+ ValonCount();
+ if ((QL_VALON > 1) && (QL_VALON < 6))
+ message strcharinfo(0), $@ValonMobName$[@valon_mob] + ": " + @valon_count + "/" + $@ValonMobCnt[@valon_mob];
+ return;
+}
+
+function script AddValonCntMask {
+ @valon_tmp = (@valon_count + 1);
+ if (@valon_tmp > $@ValonMobCnt[@valon_mob])
+ @valon_tmp = $@ValonMobCnt[@valon_mob];
+ STARTAREA = (STARTAREA & ~(NIBBLE_2_MASK) | (@valon_tmp << NIBBLE_2_SHIFT));
+ @valon_tmp = 0;
+ ValonProgress();
+ return;
+}
+