diff options
Diffstat (limited to 'npc/functions')
-rw-r--r-- | npc/functions/clientversion.txt | 21 | ||||
-rw-r--r-- | npc/functions/mobpoint.txt | 1 | ||||
-rw-r--r-- | npc/functions/vault.txt | 28 |
3 files changed, 29 insertions, 21 deletions
diff --git a/npc/functions/clientversion.txt b/npc/functions/clientversion.txt index 55ccc3fbd..443e5b10b 100644 --- a/npc/functions/clientversion.txt +++ b/npc/functions/clientversion.txt @@ -1145,27 +1145,6 @@ function script clientupdater { } } - // Permanent Level Boost - // #ADD_LVL means the user have to right to get some levels. This is a sketch. The code might be deleted. - if (#ADD_LVL) { - //logmes "[Merger] EXP +"+#ADD_LVL, LOGMES_ATCOMMAND; - if ((readparam(BaseExp)+#ADD_LVL > readparam(NextBaseExp))) { - do { - if (BaseLevel >= TOP3AVERAGELVL()) break; // Boundaries - .@v=readparam(NextBaseExp)-readparam(BaseExp); - getexp .@v, 0; - #ADD_LVL-=.@v; - } while (readparam(BaseExp)+#ADD_LVL > readparam(NextBaseExp)); - } - // Only give remaining EXP if you did not hit the boundary - if (BaseLevel < TOP3AVERAGELVL()) { - getexp #ADD_LVL, 0; - #ADD_LVL=0; - } - //rodex_sendmail(getcharid(0), "TMW2 Team", "Welcome to Moubootaur Legends", "Hey, thanks for believing on us! We hope to have a great time together. Any problem, ask for help in #world - the Discord bridge! Enjoy our game!", 20); - // TODO: Maybe give an item which lets you open the storage anywhere? - } - if (.@dg) { next; closeclientdialog; diff --git a/npc/functions/mobpoint.txt b/npc/functions/mobpoint.txt index 36f647e01..138d578c6 100644 --- a/npc/functions/mobpoint.txt +++ b/npc/functions/mobpoint.txt @@ -92,6 +92,7 @@ OnNPCKillEvent: callfunc "CadisQuestCheck"; callfunc "GeminiKill"; callfunc "SK_drops"; + callfunc "BonusEXP"; // Other updates $@MK_TRIGGERED=true; diff --git a/npc/functions/vault.txt b/npc/functions/vault.txt index 78eb5e7db..b66d46ff0 100644 --- a/npc/functions/vault.txt +++ b/npc/functions/vault.txt @@ -39,3 +39,31 @@ function script MirrorLakeSendTo { end; } + +// BonusEXP({mobId}) +function script BonusEXP { + // Only applies if you are not in TOP 3 + if (BaseLevel >= TOP3AVERAGELVL()) + return; + + // Permanent Level Boost + if (#ADD_LVL) { + .@mobId=getarg(0, killedrid); + .@exp = min(#ADD_LVL, getmonsterinfo(.@mobId, MOB_BASEEXP) * 2); + getexp .@exp, 0; + #ADD_LVL-=.@exp; + + /* + if ((readparam(BaseExp)+.@exp > readparam(NextBaseExp))) { + do { + if (BaseLevel >= TOP3AVERAGELVL()) break; // Boundaries + .@v=readparam(NextBaseExp)-readparam(BaseExp); + getexp .@v, 0; + #ADD_LVL-=.@v; + } while (readparam(BaseExp)+.@exp > readparam(NextBaseExp)); + } + */ + } + return; +} + |