fix modify max power and health from duplicating on a mob when the base mob values are extremely low

This commit is contained in:
Emagi 2024-04-13 13:15:55 -04:00
parent f9ddc49fcd
commit d1af2ec649

View file

@ -2094,7 +2094,6 @@ int EQ2Emu_lua_ModifyMaxPower(lua_State* state) {
sint32 value = lua_interface->GetSInt32Value(state, 2);
lua_interface->ResetFunctionStack(state);
if (spawn && value != 0) {
spawn->SetPower(spawn->GetPower() + value);
if (value > spawn->GetTotalHPBase())
spawn->SetTotalPower(spawn->GetTotalPower() + value);
}
@ -2107,7 +2106,6 @@ int EQ2Emu_lua_ModifyMaxHP(lua_State* state) {
sint32 value = lua_interface->GetSInt32Value(state, 2);
lua_interface->ResetFunctionStack(state);
if (spawn && value != 0) {
spawn->SetHP(spawn->GetHP() + value);
if (value > spawn->GetTotalHPBase())
spawn->SetTotalHP(spawn->GetTotalHP() + value);
}