mirror of
https://github.com/GreenComfyTea/MHR-Overlay.git
synced 2026-01-24 04:18:11 -08:00
Fix Health access attempts outside hooks
(large monster updated in previous commit)
This commit is contained in:
@@ -154,7 +154,8 @@ function this.update_large_monster(enemy)
|
||||
large_monster.update_stamina_timer(enemy, monster, nil);
|
||||
large_monster.update_rage_timer(enemy, monster, nil);
|
||||
|
||||
if quest_status.is_online and players.myself.id ~= 0 then
|
||||
if (quest_status.is_online and players.myself.id ~= 0)
|
||||
or not monster.is_health_initialized then
|
||||
local physical_param = large_monster.update_health(enemy, monster);
|
||||
pcall(large_monster.update_parts, enemy, monster, physical_param);
|
||||
pcall(large_monster.update_anomaly_parts, enemy, monster, nil);
|
||||
@@ -195,7 +196,8 @@ function this.update_small_monster(enemy)
|
||||
|
||||
small_monster.update(enemy, monster);
|
||||
|
||||
if quest_status.is_online and players.myself.id ~= 0 then
|
||||
if (quest_status.is_online and players.myself.id ~= 0)
|
||||
or not monster.is_health_initialized then
|
||||
small_monster.update_health(enemy, monster);
|
||||
end
|
||||
end
|
||||
|
||||
@@ -71,7 +71,6 @@ function this.new(enemy)
|
||||
this.init_UI(monster);
|
||||
|
||||
this.update_position(enemy, monster);
|
||||
this.update_health(enemy, monster);
|
||||
this.update(enemy, monster);
|
||||
|
||||
if this.list[enemy] == nil then
|
||||
|
||||
Reference in New Issue
Block a user