summaryrefslogtreecommitdiff
path: root/npc/functions
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-11-21 14:06:12 -0300
committerJesusaves <cpntb1@ymail.com>2021-11-21 14:06:12 -0300
commit2ebc5a5825bfb0d453e8e9855bfbdaccf4796215 (patch)
treeafe8c44ad727e3ccec113a1342b727d784a64780 /npc/functions
parent697ecd8708a654a675d492f161b3f8c9b72a3c15 (diff)
downloadserverdata-2ebc5a5825bfb0d453e8e9855bfbdaccf4796215.tar.gz
serverdata-2ebc5a5825bfb0d453e8e9855bfbdaccf4796215.tar.bz2
serverdata-2ebc5a5825bfb0d453e8e9855bfbdaccf4796215.tar.xz
serverdata-2ebc5a5825bfb0d453e8e9855bfbdaccf4796215.zip
Initial, draft version of the first boss chamber
Diffstat (limited to 'npc/functions')
-rw-r--r--npc/functions/clear_vars.txt11
1 files changed, 8 insertions, 3 deletions
diff --git a/npc/functions/clear_vars.txt b/npc/functions/clear_vars.txt
index b5222e43..ee4a2151 100644
--- a/npc/functions/clear_vars.txt
+++ b/npc/functions/clear_vars.txt
@@ -1,4 +1,10 @@
// Update variables on server init, login and logout
+
+function script isChristmas21 {
+ // FIXME: 12/12 = 346; 26/12 = 360; 09/01 = 9 (OBVIOUSLY)
+ return (gettime(8) >= 346 || gettime(8) <= 9);
+}
+
function script ClearVariables {
// Some temporary bugfix
GM = getgroupid();
@@ -138,8 +144,7 @@ function script ClearVariables {
}
// Christmas 2021 Event
- // FIXME: 12/12 = 346; 26/12 = 360; 09/01 = 9 (OBVIOUSLY)
- if (gettime(8) >= 346 || gettime(8) <= 9) {
+ if (isChristmas21()) {
#OLD_EXP=BaseExp;
#OLD_LV=BaseLevel;
}
@@ -153,7 +158,7 @@ function script FlushVariables {
##01_TMWEXP = 0;
// Christmas 2021 Event
- if (gettime(8) >= 346 || gettime(8) <= 9) {
+ if (isChristmas21()) {
#NEW_LV+=(BaseLevel-#OLD_LV);
if (BaseLevel != #OLD_LV) {
#NEW_EXP=BaseExp;