summaryrefslogtreecommitdiff
path: root/world/map/npc/annuals/halloween
diff options
context:
space:
mode:
authorwushin <pasekei@gmail.com>2014-12-01 09:23:20 -0600
committerwushin <pasekei@gmail.com>2014-12-01 09:23:20 -0600
commit126497666a2adb9962e1401b3d038a893266ae1e (patch)
tree5ab1298a5e46902e01afb68df09eac2f623c7906 /world/map/npc/annuals/halloween
parenta23d11f9299e27899486439a0dcfb0711c6fad24 (diff)
downloadserverdata-126497666a2adb9962e1401b3d038a893266ae1e.tar.gz
serverdata-126497666a2adb9962e1401b3d038a893266ae1e.tar.bz2
serverdata-126497666a2adb9962e1401b3d038a893266ae1e.tar.xz
serverdata-126497666a2adb9962e1401b3d038a893266ae1e.zip
Fix Timings for Annual Events
Diffstat (limited to 'world/map/npc/annuals/halloween')
-rw-r--r--world/map/npc/annuals/halloween/config.txt34
1 files changed, 10 insertions, 24 deletions
diff --git a/world/map/npc/annuals/halloween/config.txt b/world/map/npc/annuals/halloween/config.txt
index 0401fc3d..20fba752 100644
--- a/world/map/npc/annuals/halloween/config.txt
+++ b/world/map/npc/annuals/halloween/config.txt
@@ -337,32 +337,18 @@ L_Main:
if (gettime(6) == $@halloween_reward_start_month)
set $@halloween_min_age, ((gettime(5) + 38)*86400);
- if(gettime(6) <= $@halloween_end_month && gettime(5) > $@halloween_reward_end_day)
- goto L_NoEventTime;
- if((gettime(6) == $@halloween_reward_start_month && gettime(5) >= $@halloween_reward_start_day
- && (gettime(5) <= $@halloween_reward_end_day && $@halloween_reward_start_month == $@halloween_end_month
- || !($@halloween_reward_start_month == $@halloween_end_month)))
- || (gettime(6) == $@halloween_end_month && gettime(5) <= $@halloween_reward_end_day
- && (gettime(5) >= $@halloween_reward_start_day && $@halloween_reward_start_month == $@halloween_end_month
- || !($@halloween_reward_start_month == $@halloween_end_month)))
- || (gettime(6) < $@halloween_end_month && gettime(6) > $@halloween_reward_start_month))
- goto L_RewardTime;
- if((gettime(6) >= $@halloween_start_month) || (gettime(6) <= $@halloween_end_month && gettime(5) <= $@halloween_reward_start_day))
- goto L_EventTime;
- goto L_NoEventTime;
-
-L_NoEventTime:
- if($HALLOWEEN_TIME_KEY[5] < gettime(7))
- setarray $HALLOWEEN_TIME_KEY, $HALLOWEEN_TIME_KEY[0],$HALLOWEEN_TIME_KEY[1],$HALLOWEEN_TIME_KEY[2],$HALLOWEEN_TIME_KEY[3],$HALLOWEEN_TIME_KEY[4],gettime(7);
- set $@halloween_time, $@halloween_no_event_time;
- goto L_Return;
+ set $@start_month, $@halloween_start_month;
+ set $@end_month, $@halloween_end_month;
+ set $@start_day, 1;
+ set $@end_day, $@halloween_reward_end_day;
+ set $@reward_start_month, $@halloween_reward_start_month;
+ set $@reward_start_day, $@halloween_reward_start_day;
-L_EventTime:
- set $@halloween_time, $@halloween_event_time;
- goto L_Return;
+ callfunc "GetEventTime";
+ set $@halloween_time, $@event_time;
-L_RewardTime:
- set $@halloween_time, $@halloween_reward_time;
+ if($@halloween_time == 0 && $HALLOWEEN_TIME_KEY[5] < gettime(7))
+ setarray $HALLOWEEN_TIME_KEY, $HALLOWEEN_TIME_KEY[0],$HALLOWEEN_TIME_KEY[1],$HALLOWEEN_TIME_KEY[2],$HALLOWEEN_TIME_KEY[3],$HALLOWEEN_TIME_KEY[4],gettime(7);
goto L_Return;
L_Return: