diff options
author | Jesusaves <cpntb1@ymail.com> | 2024-08-06 13:16:35 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2024-08-06 13:16:35 -0300 |
commit | 3eae0103f57809dc70ee38f9edfbd47c794d434f (patch) | |
tree | 0d8f78d743b56fec632e5f499d561628c94658e1 /npc | |
parent | 1f8b3ad8f1f6aee5cdb650c61a03b7a2138ed284 (diff) | |
download | serverdata-3eae0103f57809dc70ee38f9edfbd47c794d434f.tar.gz serverdata-3eae0103f57809dc70ee38f9edfbd47c794d434f.tar.bz2 serverdata-3eae0103f57809dc70ee38f9edfbd47c794d434f.tar.xz serverdata-3eae0103f57809dc70ee38f9edfbd47c794d434f.zip |
Add Gambling Day, on August 1st *AND* August 10th.
You can only claim the freebie once, though.
Diffstat (limited to 'npc')
-rw-r--r-- | npc/functions/daily.txt | 8 | ||||
-rw-r--r-- | npc/functions/event.txt | 22 | ||||
-rw-r--r-- | npc/functions/mobpoint.txt | 1 |
3 files changed, 31 insertions, 0 deletions
diff --git a/npc/functions/daily.txt b/npc/functions/daily.txt index 03b70ffa5..bdca3178b 100644 --- a/npc/functions/daily.txt +++ b/npc/functions/daily.txt @@ -189,6 +189,14 @@ function script daily_login_bonus_handler { dispbottom "##B##2"+l("It's International Chocolate Day!")+"##b "+l("All monsters may drop chocolate during this period. And here is one for you!")+"##0"; } } + if (gettime(6) == AUGUST) { + if (#TMW2_LOGINBONUS != gettime(GETTIME_YEAR) && ( + gettime(5) == 1 || gettime(5) == 10)) { + #TMW2_LOGINBONUS=gettime(GETTIME_YEAR); + getitem CasinoCoins, 1; + dispbottom "##B##2"+l("It's Moubootaur Legends' Gambling Day!")+"##b "+l("In permanent celebration of the 19.2 update, all monsters may drop casino coins during this period.")+"##0"; + } + } if (gettime(6) == SEPTEMBER) { if (#TMW2_LOGINBONUS != gettime(GETTIME_YEAR) && gettime(5) == 9) { #TMW2_LOGINBONUS=gettime(GETTIME_YEAR); diff --git a/npc/functions/event.txt b/npc/functions/event.txt index e46041780..75ff9d64b 100644 --- a/npc/functions/event.txt +++ b/npc/functions/event.txt @@ -425,6 +425,28 @@ function script CoffeeDay { return; } +// GamblingDay() +function script GamblingDay { + if (!playerattached()) + return; + + // Date check + if (gettime(6) != AUGUST) + return; + if (gettime(5) != 1 && gettime(5) != 10) + return; + + // Max. 24% chances, 0.1% per monster level + .@lv=min(200, getmonsterinfo(killedrid, MOB_LV)); + if (rand2(10000) < (.@lv*12)) { + getmapxy(.@m$, .@x, .@y, 0); + .@x+=rand2(-1,1); + .@y+=rand2(-1,1); + makeitem(CasinoCoins, 1, .@m$, .@x, .@y); + } + return; +} + // FSFDay() function script FSFDay { if (!playerattached()) diff --git a/npc/functions/mobpoint.txt b/npc/functions/mobpoint.txt index f7d6b7880..98ca54d3c 100644 --- a/npc/functions/mobpoint.txt +++ b/npc/functions/mobpoint.txt @@ -116,6 +116,7 @@ OnNPCKillEvent: callfunc "AuroraMobkill"; callfunc "ChocolateDay"; callfunc "CoffeeDay"; + callfunc "GamblingDay"; callfunc "FSFDay"; callfunc "CraftmasterDay"; callfunc "CadisQuestCheck"; |