diff options
Diffstat (limited to 'world/map/npc/annuals/halloween')
-rw-r--r-- | world/map/npc/annuals/halloween/config.txt | 39 | ||||
-rw-r--r-- | world/map/npc/annuals/halloween/debug.txt | 39 |
2 files changed, 12 insertions, 66 deletions
diff --git a/world/map/npc/annuals/halloween/config.txt b/world/map/npc/annuals/halloween/config.txt index 226d8bbb..8e9169e8 100644 --- a/world/map/npc/annuals/halloween/config.txt +++ b/world/map/npc/annuals/halloween/config.txt @@ -244,7 +244,7 @@ L_Main: set $@n, $@n + 1; - set $@halloween_npc_tathin, $@n; + set $@halloween_npc_yanis, $@n; set $@halloween_npc_names$[$@n], "[Tathin]"; set $@halloween_greetings$[$@n], "\"I am employed by the Tonori Government, make sure you abide the regulations we wrote down for Trick-or-Treaters this year...\""; set $@halloween_trick_notscary$[$@n], "Of course I will... not!"; @@ -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: @@ -372,6 +358,5 @@ L_Return: L_HalloweenError: debugmes "Halloween is Dead Jim."; - gmcommand "@mapexit"; - end; + mapexit; } diff --git a/world/map/npc/annuals/halloween/debug.txt b/world/map/npc/annuals/halloween/debug.txt index 64da1d38..38bed87f 100644 --- a/world/map/npc/annuals/halloween/debug.txt +++ b/world/map/npc/annuals/halloween/debug.txt @@ -139,42 +139,3 @@ L_Close: set @halloween_npc_id, 0; close; } -009-1.gat,51,38,0|script|HalloweenDebug#1|409 -{ - callfunc "HalloweenDebug"; - goto L_End; - -OnInit: - if(!debug) - disablenpc "HalloweenDebug#1"; - goto L_End; - -L_End: - end; -} -001-1.gat,38,26,0|script|HalloweenDebug#2|409 -{ - callfunc "HalloweenDebug"; - goto L_End; - -OnInit: - if(!debug) - disablenpc "HalloweenDebug#2"; - goto L_End; - -L_End: - end; -} -026-1.gat,23,37,0|script|HalloweenDebug#3|409 -{ - callfunc "HalloweenDebug"; - goto L_End; - -OnInit: - if(!debug) - disablenpc "HalloweenDebug#3"; - goto L_End; - -L_End: - end; -} |