diff options
author | jesusalva <cpntb1@ymail.com> | 2018-03-01 16:17:46 -0300 |
---|---|---|
committer | jesusalva <cpntb1@ymail.com> | 2018-03-01 16:17:46 -0300 |
commit | 952d3a7d34cdc777cdba4973041fbde7d4428906 (patch) | |
tree | a73e1a3de00994fca621a50bf640194aa04c24f8 /npc/commands/motd.txt | |
parent | fb0f0a7f9c1604e90b6fdc4b80a6fef1596e5bc2 (diff) | |
download | serverdata-952d3a7d34cdc777cdba4973041fbde7d4428906.tar.gz serverdata-952d3a7d34cdc777cdba4973041fbde7d4428906.tar.bz2 serverdata-952d3a7d34cdc777cdba4973041fbde7d4428906.tar.xz serverdata-952d3a7d34cdc777cdba4973041fbde7d4428906.zip |
Rework daily login to have streaks
Diffstat (limited to 'npc/commands/motd.txt')
-rw-r--r-- | npc/commands/motd.txt | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/npc/commands/motd.txt b/npc/commands/motd.txt index 6052656cc..5913347ec 100644 --- a/npc/commands/motd.txt +++ b/npc/commands/motd.txt @@ -186,8 +186,29 @@ OnPCLoginEvent: // Handle daily login bonus if (#LOGIN_DAY != .login_ref) { + // Are we on a streak, or have we broke it? (or is it a new month) + if (#LOGIN_DAY == .login_ref-1) + #LOGIN_STREAK=#LOGIN_STREAK+1; + else + #LOGIN_STREAK=1; + + // Update last day you've claimed a reward #LOGIN_DAY = .login_ref; - if (.login_ref % 3 == 0) { + + // Handle rewards: Streaks first, daily later. Streak reward overrides daily reward. + if (#LOGIN_STREAK == 30) { + getitem PinkieHat, 1; + dispbottom l("##2 30 Days login bonus: ##B1x @@##b", getitemlink(PinkieHat)); // TODO placeholder + } else if (#LOGIN_STREAK == 21) { + getitem StrangeCoin, 3; + dispbottom l("##2 21 Days login bonus: ##B3x @@##b", getitemlink(StrangeCoin)); + } else if (#LOGIN_STREAK == 14) { + getitem StrangeCoin, 2; + dispbottom l("##2 14 Days login bonus: ##B2x @@##b", getitemlink(StrangeCoin)); + } else if (#LOGIN_STREAK == 7) { + getexp 0, 20; + dispbottom l("##2 7 Days login bonus: ##B20 Job Exp.##b"); + } else if (.login_ref % 3 == 0) { getitem StrangeCoin, 1; dispbottom l("##2Daily login bonus: ##B1x @@##b", getitemlink(StrangeCoin)); } else if (.login_ref % 3 == 1) { |