Fix a bug when autotarget was trying to target dead monster causing all large monster UI to not work

This commit is contained in:
GreenComfyTea
2023-02-06 15:55:57 +02:00
parent fcf35d817f
commit 9958817989
3 changed files with 6 additions and 7 deletions

View File

@@ -291,8 +291,8 @@ if debug.enabled then
end
if xy ~= "" then
d2d.text(drawing.font, "xy:\n" .. tostring(xy), 6, 11, 0xFF000000);
d2d.text(drawing.font, "xy:\n" .. tostring(xy), 5, 10, 0xFFFFFFFF);
d2d.text(drawing.font, "xy:\n" .. tostring(xy), 6, 31, 0xFF000000);
d2d.text(drawing.font, "xy:\n" .. tostring(xy), 5, 30, 0xFFFFFFFF);
end
end);
end
@@ -303,8 +303,8 @@ if debug.enabled then
end
if xy ~= "" then
draw.text("xy:\n" .. tostring(xy), 6, 11, 0xFF000000);
draw.text("xy:\n" .. tostring(xy), 5, 10, 0xFFFFFFFF);
draw.text("xy:\n" .. tostring(xy), 6, 31, 0xFF000000);
draw.text("xy:\n" .. tostring(xy), 5, 30, 0xFFFFFFFF);
end
end);
end

View File

@@ -3041,7 +3041,7 @@ function config.init_default()
highlighted = {
enabled = true,
position = {
x = 615,
y = 25, -- y = 44,

View File

@@ -127,7 +127,6 @@ function large_monster_UI.draw(dynamic_enabled, static_enabled, highlighted_enab
if highlighted_enabled then
large_monster_UI.draw_highlighted(highlighted_monster, cached_config);
end
if static_enabled then
large_monster_UI.draw_static(displayed_monsters, highlighted_monster, cached_config);
end
@@ -281,7 +280,7 @@ function large_monster_UI.draw_highlighted(monster, cached_config)
local position_on_screen = screen.calculate_absolute_coordinates(cached_config.position);
if monster.dead_or_captured and cached_config.settings.hide_dead_or_captured then
if monster.dead_or_captured then
return;
end