mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-11 07:38:36 +00:00
[Experience] Add exp mod to npc types to let a server op change the exp modifier (#1252)
* Add exp mod to npc types to let a server op change the exp modifier a npc gives (useful for custom content) * Updated version.h
This commit is contained in:
+9
-1
@@ -215,7 +215,15 @@ uint32 Client::GetExperienceForKill(Mob *against)
|
||||
|
||||
if (against && against->IsNPC()) {
|
||||
uint32 level = (uint32)against->GetLevel();
|
||||
return EXP_FORMULA;
|
||||
uint32 ret = EXP_FORMULA;
|
||||
|
||||
auto mod = against->GetKillExpMod();
|
||||
if(mod >= 0) {
|
||||
ret *= mod;
|
||||
ret /= 100;
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user