summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
Diffstat (limited to 'npc')
-rw-r--r--npc/003-1/hasan.txt21
-rw-r--r--npc/functions/scoreboards.txt5
-rw-r--r--npc/functions/seasons.txt3
3 files changed, 19 insertions, 10 deletions
diff --git a/npc/003-1/hasan.txt b/npc/003-1/hasan.txt
index f100b0c32..2472ddc9f 100644
--- a/npc/003-1/hasan.txt
+++ b/npc/003-1/hasan.txt
@@ -85,7 +85,7 @@ L_Complete:
mesn;
mesq l("I am collecting money for the Yearly Autumn Scorpion Hunter quest.");
mesq l("You're, of course, invited. Thus far, the total prize money I've collected is @@ GP.", $HASAN_GP);
- if (season() == AUTUMN || $@GM_OVERRIDE) {
+ if (season() == AUTUMN || $@GM_OVERRIDE || is_staff()) {
mesq l("You've killed @@ scorpions, and a total of @@ were killed this season.", getq2(SQuest_Autumn), $HASAN_ST);
mesq l("If the event ended now, you would get @@ GP.", getq2(SQuest_Autumn)*$HASAN_GP/$HASAN_ST);
mes "";
@@ -118,19 +118,22 @@ L_Complete:
mesn l("Summary");
mes l("Scorpions killed: @@/@@ scorpions", getq2(SQuest_Autumn), $HASAN_ST);
mes l("Total money collected: @@ GP", $HASAN_LT);
- mes l("##2Your prize: @@ GP", .@p);
+ mesc l("Your prize: %s GP", fnum(.@p)), 2;
if (getq2(SQuest_Autumn) > 20)
getexp (getq2(SQuest_Autumn)/20), 0;
if (.@p >= 1)
- Zeny=Zeny+.@p;
-
- // Top 3 reward
- .@nb = query_sql("SELECT c.name FROM `quest` AS i, `char` AS c WHERE i.quest_id="+SQuest_Autumn+" AND i.char_id=c.char_id ORDER BY i.count2 DESC LIMIT 5", .@name$);
- if (strcharinfo(0) == .@name$[0])
+ Zeny+=.@p;
+
+ // Top 5 reward
+ if (strcharinfo(0) == $@hasn_name$[0])
+ getitem SupremeGift, 1;
+ if (strcharinfo(0) == $@hasn_name$[1])
+ getitem PrismGift, 1;
+ if (strcharinfo(0) == $@hasn_name$[2])
getitem GoldenGift, 1;
- if (strcharinfo(0) == .@name$[1])
+ if (strcharinfo(0) == $@hasn_name$[3])
getitem SilverGift, 1;
- if (strcharinfo(0) == .@name$[2])
+ if (strcharinfo(0) == $@hasn_name$[4])
getitem BronzeGift, 1;
// Quest is closed
diff --git a/npc/functions/scoreboards.txt b/npc/functions/scoreboards.txt
index 66389fdf3..ebc1b151c 100644
--- a/npc/functions/scoreboards.txt
+++ b/npc/functions/scoreboards.txt
@@ -23,7 +23,10 @@ function script ScoreboardsReload {
if (season() == SUMMER || season() == AUTUMN) {
.@nb = query_sql("SELECT c.name, i.count2 FROM `quest` AS i, `char` AS c WHERE i.quest_id=305 AND i.char_id=c.char_id AND i.count1="+(gettime(GETTIME_YEAR)-2000)+" ORDER BY i.count2 DESC LIMIT 10", $@ched_name$, $@ched_value);
}
- if (season() == WINTER || season() == AUTUMN) {
+ if (season() == AUTUMN || season() == WINTER) {
+ .@nb = query_sql("SELECT c.name, i.count2 FROM `quest` AS i, `char` AS c WHERE i.quest_id="+SQuest_Autumn+" AND i.char_id=c.char_id ORDER BY i.count2 DESC LIMIT 5", $@hasn_name$, $@hasn_value);
+ }
+ if (season() == WINTER || season() == SPRING) {
.@nb = query_sql("SELECT c.name, i.count2 FROM `quest` AS i, `char` AS c WHERE i.quest_id="+SQuest_Christmas+" AND i.char_id=c.char_id ORDER BY i.count2 DESC LIMIT 5", $@xmas_box_name$, $@xmas_box_value);
.@nb = query_sql("SELECT c.name, i.count3 FROM `quest` AS i, `char` AS c WHERE i.quest_id="+SQuest_Christmas+" AND i.char_id=c.char_id ORDER BY i.count3 DESC LIMIT 5", $@xmas_gp_name$, $@xmas_gp_value);
}
diff --git a/npc/functions/seasons.txt b/npc/functions/seasons.txt
index d2ed85264..fa3b5c5bd 100644
--- a/npc/functions/seasons.txt
+++ b/npc/functions/seasons.txt
@@ -384,6 +384,9 @@ OnWinterStart:
end;
OnWinterEnd:
+ // Hasan's rewards can't be claimed anymore. Delete that from all players.
+ DelQuestFromEveryPlayer(SQuest_Autumn);
+
delmonsterdrop(WaterFairy, GingerBreadMan);
delmonsterdrop(RedMushroom, GingerBreadMan);
delmonsterdrop(Duck, GingerBreadMan);