mirror of
https://github.com/GreenComfyTea/MHR-Overlay.git
synced 2026-01-25 04:48:22 -08:00
Added DPS, missing offsets and additional options.
This commit is contained in:
@@ -4,6 +4,7 @@ local table_helpers;
|
||||
local singletons;
|
||||
local customization_menu;
|
||||
local damage_UI_entity;
|
||||
local time;
|
||||
|
||||
player.list = {};
|
||||
player.myself = nil;
|
||||
@@ -17,6 +18,10 @@ function player.new(player_id, player_name, player_hunter_rank)
|
||||
new_player.name = player_name;
|
||||
new_player.hunter_rank = player_hunter_rank;
|
||||
|
||||
new_player.join_time = time.total_elapsed_seconds;
|
||||
new_player.first_hit_time = -1;
|
||||
new_player.dps = 0;
|
||||
|
||||
new_player.small_monsters = {};
|
||||
|
||||
new_player.small_monsters.total_damage = 0;
|
||||
@@ -115,6 +120,10 @@ function player.update_damage(_player, damage_source_type, is_large_monster, dam
|
||||
return;
|
||||
end
|
||||
|
||||
if _player.first_hit_time == -1 then
|
||||
_player.first_hit_time = time.total_elapsed_seconds;
|
||||
end
|
||||
|
||||
local player_monster_type = _player.small_monsters;
|
||||
if is_large_monster then
|
||||
player_monster_type = _player.large_monsters;
|
||||
@@ -262,14 +271,15 @@ function player.init_UI(_player)
|
||||
config.current_config.damage_meter_UI.damage_bar,
|
||||
config.current_config.damage_meter_UI.highlighted_damage_bar,
|
||||
config.current_config.damage_meter_UI.player_name_label,
|
||||
config.current_config.damage_meter_UI.dps_label,
|
||||
config.current_config.damage_meter_UI.hunter_rank_label,
|
||||
config.current_config.damage_meter_UI.damage_value_label,
|
||||
config.current_config.damage_meter_UI.damage_percentage_label
|
||||
);
|
||||
end
|
||||
|
||||
function player.draw(_player, position_on_screen, opacity_scale, top_damage)
|
||||
damage_UI_entity.draw(_player, position_on_screen, opacity_scale, top_damage);
|
||||
function player.draw(_player, position_on_screen, opacity_scale, top_damage, top_dps)
|
||||
damage_UI_entity.draw(_player, position_on_screen, opacity_scale, top_damage, top_dps);
|
||||
end
|
||||
|
||||
function player.init_module()
|
||||
@@ -278,6 +288,7 @@ function player.init_module()
|
||||
singletons = require("MHR_Overlay.Game_Handler.singletons");
|
||||
customization_menu = require("MHR_Overlay.UI.customization_menu");
|
||||
damage_UI_entity = require("MHR_Overlay.UI.UI_Entities.damage_UI_entity");
|
||||
time = require("MHR_Overlay.Game_Handler.time");
|
||||
|
||||
player.init_total();
|
||||
end
|
||||
|
||||
@@ -27,7 +27,7 @@ function singletons.init_message_manager()
|
||||
|
||||
singletons.message_manager = sdk.get_managed_singleton("snow.gui.MessageManager");
|
||||
if singletons.message_manager == nil then
|
||||
log.error("[MHR Overlay] No message manager");
|
||||
--log.error("[MHR Overlay] No message manager");
|
||||
end
|
||||
|
||||
return singletons.message_manager;
|
||||
@@ -40,7 +40,7 @@ function singletons.init_enemy_manager()
|
||||
|
||||
singletons.enemy_manager = sdk.get_managed_singleton("snow.enemy.EnemyManager");
|
||||
if singletons.enemy_manager == nil then
|
||||
log.error("[MHR Overlay] No enemy manager");
|
||||
--log.error("[MHR Overlay] No enemy manager");
|
||||
end
|
||||
|
||||
return singletons.enemy_manager;
|
||||
@@ -53,7 +53,7 @@ function singletons.init_lobby_manager()
|
||||
|
||||
singletons.lobby_manager = sdk.get_managed_singleton("snow.LobbyManager");
|
||||
if singletons.lobby_manager == nil then
|
||||
log.error("[MHR Overlay] No lobby manager");
|
||||
--log.error("[MHR Overlay] No lobby manager");
|
||||
return false;
|
||||
end
|
||||
|
||||
@@ -67,7 +67,7 @@ function singletons.init_progress_manager()
|
||||
|
||||
singletons.progress_manager = sdk.get_managed_singleton("snow.progress.ProgressManager");
|
||||
if singletons.progress_manager == nil then
|
||||
log.error("[MHR Overlay] No progress manager");
|
||||
--log.error("[MHR Overlay] No progress manager");
|
||||
return false;
|
||||
end
|
||||
|
||||
@@ -81,7 +81,7 @@ function singletons.init_quest_manager()
|
||||
|
||||
singletons.quest_manager = sdk.get_managed_singleton("snow.QuestManager");
|
||||
if singletons.quest_manager == nil then
|
||||
log.error("[MHR Overlay] No quest manager");
|
||||
--log.error("[MHR Overlay] No quest manager");
|
||||
end
|
||||
|
||||
return singletons.quest_manager;
|
||||
@@ -94,7 +94,7 @@ function singletons.init_player_manager()
|
||||
|
||||
singletons.player_manager = sdk.get_managed_singleton("snow.player.PlayerManager");
|
||||
if singletons.player_manager == nil then
|
||||
log.error("[MHR Overlay] No player manager");
|
||||
--log.error("[MHR Overlay] No player manager");
|
||||
end
|
||||
|
||||
return singletons.player_manager;
|
||||
@@ -107,7 +107,7 @@ function singletons.init_village_area_manager()
|
||||
|
||||
singletons.village_area_manager = sdk.get_managed_singleton("snow.VillageAreaManager");
|
||||
if singletons.village_area_manager == nil then
|
||||
log.error("[MHR Overlay] No village manager");
|
||||
--log.error("[MHR Overlay] No village area manager");
|
||||
end
|
||||
|
||||
return singletons.village_area_manager;
|
||||
@@ -120,7 +120,7 @@ function singletons.init_gui_manager()
|
||||
|
||||
singletons.gui_manager = sdk.get_managed_singleton("snow.gui.GuiManager");
|
||||
if singletons.gui_manager == nil then
|
||||
log.error("[MHR Overlay] No gui manager");
|
||||
--log.error("[MHR Overlay] No gui manager");
|
||||
end
|
||||
|
||||
return singletons.gui_manager;
|
||||
|
||||
78
reframework/autorun/MHR_Overlay/Game_Handler/time.lua
Normal file
78
reframework/autorun/MHR_Overlay/Game_Handler/time.lua
Normal file
@@ -0,0 +1,78 @@
|
||||
local time = {};
|
||||
local singletons;
|
||||
local customization_menu;
|
||||
local player;
|
||||
local config;
|
||||
|
||||
local quest_manager_type_def = sdk.find_type_definition("snow.QuestManager");
|
||||
local get_quest_elapsed_time_min_method = quest_manager_type_def:get_method("getQuestElapsedTimeMin");
|
||||
local get_quest_elapsed_time_sec_method = quest_manager_type_def:get_method("getQuestElapsedTimeSec");
|
||||
|
||||
time.total_elapsed_seconds = 0;
|
||||
time.elapsed_minutes = 0;
|
||||
time.elapsed_seconds = 0;
|
||||
|
||||
time.last_whole_seconds = 0;
|
||||
|
||||
function time.tick()
|
||||
if singletons.quest_manager == nil then
|
||||
return;
|
||||
end
|
||||
|
||||
local quest_time_elapsed_minutes = get_quest_elapsed_time_min_method:call(singletons.quest_manager);
|
||||
if quest_time_elapsed_minutes == nil then
|
||||
customization_menu.status = "No quest time elapsed minutes";
|
||||
return;
|
||||
end
|
||||
|
||||
time.elapsed_minutes = quest_time_elapsed_minutes;
|
||||
|
||||
local quest_time_total_elapsed_seconds = get_quest_elapsed_time_sec_method:call(singletons.quest_manager);
|
||||
if quest_time_total_elapsed_seconds == nil then
|
||||
customization_menu.status = "No quest time total elapsed seconds";
|
||||
return;
|
||||
end
|
||||
|
||||
time.total_elapsed_seconds = quest_time_total_elapsed_seconds;
|
||||
time.elapsed_seconds = quest_time_total_elapsed_seconds - quest_time_elapsed_minutes * 60;
|
||||
|
||||
if time.total_elapsed_seconds - time.last_whole_seconds > 1 then
|
||||
time.last_whole_seconds = time.total_elapsed_seconds;
|
||||
time.update_players_dps();
|
||||
end
|
||||
end
|
||||
|
||||
function time.update_players_dps()
|
||||
|
||||
local new_total_dps = 0;
|
||||
for _, _player in pairs(player.list) do
|
||||
if config.current_config.damage_meter_UI.settings.dps_mode == "Quest Time" then
|
||||
if time.total_elapsed_seconds > 0 then
|
||||
_player.dps = _player.display.total_damage / time.total_elapsed_seconds;
|
||||
end
|
||||
elseif config.current_config.damage_meter_UI.settings.dps_mode == "Join Time" then
|
||||
if time.total_elapsed_seconds - _player.join_time > 0 then
|
||||
_player.dps = _player.display.total_damage / (time.total_elapsed_seconds - _player.join_time);
|
||||
end
|
||||
elseif config.current_config.damage_meter_UI.settings.dps_mode == "First Hit" then
|
||||
if time.total_elapsed_seconds - _player.first_hit_time > 0 then
|
||||
_player.dps = _player.display.total_damage / (time.total_elapsed_seconds - _player.first_hit_time);
|
||||
end
|
||||
else
|
||||
end
|
||||
|
||||
new_total_dps = new_total_dps + _player.dps;
|
||||
end
|
||||
|
||||
player.total.dps = new_total_dps;
|
||||
end
|
||||
|
||||
function time.init_module()
|
||||
player = require("MHR_Overlay.Damage_Meter.player");
|
||||
singletons = require("MHR_Overlay.Game_Handler.singletons");
|
||||
customization_menu = require("MHR_Overlay.UI.customization_menu");
|
||||
time = require("MHR_Overlay.Game_Handler.time");
|
||||
config = require("MHR_Overlay.Misc.config");
|
||||
end
|
||||
|
||||
return time;
|
||||
@@ -119,13 +119,18 @@ function config.init()
|
||||
|
||||
health = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = false,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = -25,
|
||||
y = 12
|
||||
x = -22,
|
||||
y = -5
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
|
||||
@@ -144,7 +149,7 @@ function config.init()
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 50,
|
||||
y = 25
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
|
||||
@@ -163,7 +168,7 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 55,
|
||||
x = -5,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
@@ -182,7 +187,7 @@ function config.init()
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
y = 0
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -200,13 +205,18 @@ function config.init()
|
||||
|
||||
stamina = {
|
||||
visibility = false,
|
||||
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 30
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = true,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 37
|
||||
x = 5,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFA3F5F0,
|
||||
|
||||
@@ -224,8 +234,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 54
|
||||
x = 25,
|
||||
y = 16
|
||||
},
|
||||
color = 0xFFA3F5F0,
|
||||
|
||||
@@ -244,8 +254,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 64
|
||||
x = 45,
|
||||
y = 29
|
||||
},
|
||||
color = 0xFFA3F5F0,
|
||||
|
||||
@@ -262,8 +272,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 54
|
||||
x = 0,
|
||||
y = 17
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -285,6 +295,8 @@ function config.init()
|
||||
|
||||
settings = {
|
||||
hide_dead_or_captured = true,
|
||||
render_highlighted_monster = true,
|
||||
render_not_highlighted_monsters = true,
|
||||
max_distance = 300,
|
||||
opacity_falloff = true
|
||||
},
|
||||
@@ -329,13 +341,18 @@ function config.init()
|
||||
|
||||
health = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = false,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = -25,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
|
||||
@@ -354,7 +371,7 @@ function config.init()
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 5,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -374,7 +391,7 @@ function config.init()
|
||||
|
||||
offset = {
|
||||
x = 150,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -392,7 +409,7 @@ function config.init()
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
y = 0
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -429,13 +446,18 @@ function config.init()
|
||||
|
||||
stamina = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 37
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = true,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 37
|
||||
x = 15-10,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFA3F5F0,
|
||||
|
||||
@@ -453,8 +475,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 54
|
||||
x = 55-10,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -473,8 +495,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 54
|
||||
x = 145-10,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -491,8 +513,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 54
|
||||
x = 10-10,
|
||||
y = 17
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -509,13 +531,18 @@ function config.init()
|
||||
|
||||
rage = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 61
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = true,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 61
|
||||
x = 5,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFFF9393,
|
||||
|
||||
@@ -533,8 +560,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 78
|
||||
x = 45,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -553,8 +580,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 78
|
||||
x = 135,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -570,11 +597,11 @@ function config.init()
|
||||
|
||||
timer_label = {
|
||||
visibility = true,
|
||||
text = "%.0f:%02.0f",
|
||||
text = "%2.0f:%02.0f",
|
||||
|
||||
offset = {
|
||||
x = 157,
|
||||
y = 78
|
||||
x = 140,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -591,8 +618,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 78
|
||||
x = 0,
|
||||
y = 17
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -611,8 +638,8 @@ function config.init()
|
||||
visibility = false,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 50
|
||||
x = 10,
|
||||
y = 111
|
||||
},
|
||||
|
||||
spacing = {
|
||||
@@ -639,8 +666,8 @@ function config.init()
|
||||
},
|
||||
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 61
|
||||
x = 5,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFf9d9ff,
|
||||
|
||||
@@ -658,8 +685,8 @@ function config.init()
|
||||
visibility = false,
|
||||
text = language.current_language.UI.HP,
|
||||
offset = {
|
||||
x = -15,
|
||||
y = 69
|
||||
x = -25,
|
||||
y = 8
|
||||
},
|
||||
color = 0xF1F4A3CC,
|
||||
|
||||
@@ -677,8 +704,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 74
|
||||
x = 45,
|
||||
y = 13
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -697,8 +724,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 74
|
||||
x = 135,
|
||||
y = 13
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -715,8 +742,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 75
|
||||
x = 0,
|
||||
y = 14
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -742,6 +769,9 @@ function config.init()
|
||||
|
||||
settings = {
|
||||
hide_dead_or_captured = true,
|
||||
render_highlighted_monster = true,
|
||||
render_not_highlighted_monsters = true,
|
||||
highlighted_monster_location = "Normal",
|
||||
orientation = "Horizontal"
|
||||
},
|
||||
|
||||
@@ -785,13 +815,18 @@ function config.init()
|
||||
|
||||
health = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = false,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = -25,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
|
||||
@@ -810,7 +845,7 @@ function config.init()
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 5,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -830,7 +865,7 @@ function config.init()
|
||||
|
||||
offset = {
|
||||
x = 150,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -848,7 +883,7 @@ function config.init()
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
y = 0
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -885,13 +920,18 @@ function config.init()
|
||||
|
||||
stamina = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 37
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = false,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 37
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFA3F5F0,
|
||||
|
||||
@@ -910,7 +950,7 @@ function config.init()
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 54
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -930,7 +970,7 @@ function config.init()
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 54
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -948,7 +988,7 @@ function config.init()
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 37
|
||||
y = 0
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -965,13 +1005,18 @@ function config.init()
|
||||
|
||||
rage = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 42
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = false,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 61
|
||||
y = 19
|
||||
},
|
||||
color = 0xFFFF9393,
|
||||
|
||||
@@ -990,7 +1035,7 @@ function config.init()
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 78
|
||||
y = 36
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1010,7 +1055,7 @@ function config.init()
|
||||
|
||||
offset = {
|
||||
x = 150,
|
||||
y = 33
|
||||
y = -9
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1026,11 +1071,11 @@ function config.init()
|
||||
|
||||
timer_label = {
|
||||
visibility = true,
|
||||
text = "%.0f:%02.0f",
|
||||
text = "%2.0f:%02.0f",
|
||||
|
||||
offset = {
|
||||
x = 150,
|
||||
y = 33
|
||||
x = 157,
|
||||
y = -9
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1048,7 +1093,7 @@ function config.init()
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 42
|
||||
y = 0
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -1067,7 +1112,7 @@ function config.init()
|
||||
visibility = false,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
x = 10,
|
||||
y = 50
|
||||
},
|
||||
|
||||
@@ -1095,8 +1140,8 @@ function config.init()
|
||||
},
|
||||
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 61
|
||||
x = 5,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFf9d9ff,
|
||||
|
||||
@@ -1114,8 +1159,8 @@ function config.init()
|
||||
visibility = false,
|
||||
text = language.current_language.UI.HP,
|
||||
offset = {
|
||||
x = -15,
|
||||
y = 69
|
||||
x = -25,
|
||||
y = 8
|
||||
},
|
||||
color = 0xF1F4A3CC,
|
||||
|
||||
@@ -1133,8 +1178,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 74
|
||||
x = 45,
|
||||
y = 13
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1153,8 +1198,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 74
|
||||
x = 135,
|
||||
y = 13
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1171,8 +1216,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 75
|
||||
x = 0,
|
||||
y = 14
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -1230,13 +1275,18 @@ function config.init()
|
||||
|
||||
health = {
|
||||
visibility = true,
|
||||
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = false,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = -25,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
|
||||
@@ -1255,7 +1305,7 @@ function config.init()
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 5,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1275,7 +1325,7 @@ function config.init()
|
||||
|
||||
offset = {
|
||||
x = 150,
|
||||
y = 19
|
||||
y = 2
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1293,7 +1343,7 @@ function config.init()
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 17
|
||||
y = 0
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -1325,18 +1375,23 @@ function config.init()
|
||||
|
||||
color = 0xB9000000
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
stamina = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 37
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = true,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 37
|
||||
x = 15-10,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFA3F5F0,
|
||||
|
||||
@@ -1354,8 +1409,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 54
|
||||
x = 55-10,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1374,8 +1429,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 54
|
||||
x = 145-10,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1392,8 +1447,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 54
|
||||
x = 10-10,
|
||||
y = 17
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -1410,13 +1465,18 @@ function config.init()
|
||||
|
||||
rage = {
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 61
|
||||
},
|
||||
|
||||
text_label = {
|
||||
visibility = true,
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 61
|
||||
x = 5,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFFF9393,
|
||||
|
||||
@@ -1434,8 +1494,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 78
|
||||
x = 45,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1454,8 +1514,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 78
|
||||
x = 135,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1471,11 +1531,11 @@ function config.init()
|
||||
|
||||
timer_label = {
|
||||
visibility = true,
|
||||
text = "%.0f:%02.0f",
|
||||
text = "%2.0f:%02.0f",
|
||||
|
||||
offset = {
|
||||
x = 157,
|
||||
y = 78
|
||||
x = 140,
|
||||
y = 17
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1492,8 +1552,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 78
|
||||
x = 0,
|
||||
y = 17
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -1512,8 +1572,8 @@ function config.init()
|
||||
visibility = true,
|
||||
|
||||
offset = {
|
||||
x = 0,
|
||||
y = 50
|
||||
x = 10,
|
||||
y = 111
|
||||
},
|
||||
|
||||
spacing = {
|
||||
@@ -1540,8 +1600,8 @@ function config.init()
|
||||
},
|
||||
|
||||
offset = {
|
||||
x = 15,
|
||||
y = 61
|
||||
x = 5,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFf9d9ff,
|
||||
|
||||
@@ -1559,8 +1619,8 @@ function config.init()
|
||||
visibility = false,
|
||||
text = language.current_language.UI.HP,
|
||||
offset = {
|
||||
x = -15,
|
||||
y = 69
|
||||
x = -25,
|
||||
y = 8
|
||||
},
|
||||
color = 0xF1F4A3CC,
|
||||
|
||||
@@ -1578,8 +1638,8 @@ function config.init()
|
||||
visibility = true,
|
||||
text = "%.0f/%.0f", -- current_health/max_health
|
||||
offset = {
|
||||
x = 55,
|
||||
y = 74
|
||||
x = 45,
|
||||
y = 13
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1598,8 +1658,8 @@ function config.init()
|
||||
text = "%5.1f%%",
|
||||
|
||||
offset = {
|
||||
x = 145,
|
||||
y = 74
|
||||
x = 135,
|
||||
y = 13
|
||||
},
|
||||
color = 0xFFFFFFFF,
|
||||
|
||||
@@ -1616,8 +1676,8 @@ function config.init()
|
||||
bar = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 10,
|
||||
y = 75
|
||||
x = 0,
|
||||
y = 14
|
||||
},
|
||||
|
||||
size = {
|
||||
@@ -1681,7 +1741,7 @@ function config.init()
|
||||
},
|
||||
|
||||
spacing = {
|
||||
x = 270,
|
||||
x = 300,
|
||||
y = 24
|
||||
},
|
||||
|
||||
@@ -1695,11 +1755,12 @@ function config.init()
|
||||
|
||||
highlighted_bar = "Me",
|
||||
damage_bar_relative_to = "Top Damage", -- "total damage" or "top damage"
|
||||
my_damage_bar_location = "First" -- "normal" or "first" or "last"
|
||||
my_damage_bar_location = "First", -- "normal" or "first" or "last"
|
||||
dps_mode = "First Hit"
|
||||
},
|
||||
|
||||
sorting = {
|
||||
type = "Damage", -- "normal" or "damage"
|
||||
type = "Damage", -- "normal" or "damage" or "dps"
|
||||
reversed_order = false
|
||||
},
|
||||
|
||||
@@ -1729,7 +1790,7 @@ function config.init()
|
||||
|
||||
text = "%s",
|
||||
offset = {
|
||||
x = 5,
|
||||
x = 45,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
@@ -1806,6 +1867,26 @@ function config.init()
|
||||
color = 0xFF000000
|
||||
}
|
||||
},
|
||||
|
||||
dps_label = {
|
||||
visibility = true,
|
||||
text = "%.1f",
|
||||
|
||||
offset = {
|
||||
x = 265,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFCCF4E1,
|
||||
|
||||
shadow = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 1,
|
||||
y = 1
|
||||
},
|
||||
color = 0xFF000000
|
||||
}
|
||||
},
|
||||
|
||||
total_damage_label = {
|
||||
visibility = true,
|
||||
@@ -1844,6 +1925,26 @@ function config.init()
|
||||
color = 0xFF000000
|
||||
}
|
||||
},
|
||||
|
||||
total_dps_label = {
|
||||
visibility = true,
|
||||
text = "%.1f",
|
||||
|
||||
offset = {
|
||||
x = 265,
|
||||
y = 0
|
||||
},
|
||||
color = 0xFFFF7373,
|
||||
|
||||
shadow = {
|
||||
visibility = true,
|
||||
offset = {
|
||||
x = 1,
|
||||
y = 1
|
||||
},
|
||||
color = 0xFF000000
|
||||
}
|
||||
},
|
||||
|
||||
damage_bar = {
|
||||
visibility = true,
|
||||
|
||||
@@ -114,7 +114,9 @@ language.default_language = {
|
||||
|
||||
static_orientation = "Static Orientation",
|
||||
|
||||
hide_dead_or_captured = "Hide dead or captured",
|
||||
hide_dead_or_captured = "Hide Dead or Captured",
|
||||
render_highlighted_monster = "Render Highlighted Monster",
|
||||
render_not_highlighted_monsters = "Render Not Highlighted Monsters",
|
||||
|
||||
opacity_falloff = "Opacity Falloff",
|
||||
max_distance = "Max Distance",
|
||||
@@ -189,7 +191,9 @@ language.default_language = {
|
||||
player_name_label = "Player Name Label",
|
||||
hunter_rank_label = "Hunter Rank Label",
|
||||
damage_value_label = "Damage Value Label",
|
||||
damage_percentage_label = "Damage Percetange Label",
|
||||
damage_percentage_label = "Damage Percentage Label",
|
||||
dps_label = "DPS Label",
|
||||
total_dps_label = "Total DPS Label",
|
||||
total_damage_label = "Total Damage Label",
|
||||
total_damage_value_label = "Total Damage Value Label",
|
||||
damage_bar = "Damage Bar",
|
||||
@@ -232,6 +236,16 @@ language.default_language = {
|
||||
word_player = "Word \"Player\"";
|
||||
player_id = "Player ID",
|
||||
player_name = "Player Name",
|
||||
|
||||
dps_mode = "DPS Mode",
|
||||
dps = "DPS",
|
||||
top_dps = "Top DPS",
|
||||
total_dps = "Total DPS",
|
||||
first_hit = "First Hit",
|
||||
quest_time = "Quest Time",
|
||||
join_time = "Join Time",
|
||||
fight_time = "Fight Time"
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -207,7 +207,7 @@ function large_monster.init_dynamic_UI(monster)
|
||||
config.current_config.large_monster_UI.dynamic.rage.text_label,
|
||||
config.current_config.large_monster_UI.dynamic.rage.value_label,
|
||||
config.current_config.large_monster_UI.dynamic.rage.percentage_label,
|
||||
config.current_config.large_monster_UI.static.rage.timer_label
|
||||
config.current_config.large_monster_UI.dynamic.rage.timer_label
|
||||
);
|
||||
|
||||
for REpart, part in pairs(monster.parts) do
|
||||
@@ -561,11 +561,31 @@ function large_monster.draw_dynamic(monster, position_on_screen, opacity_scale)
|
||||
|
||||
drawing.draw_label(monster.dynamic_name_label, position_on_screen, opacity_scale, monster_name_text);
|
||||
|
||||
health_UI_entity.draw(monster, monster.health_dynamic_UI, position_on_screen, opacity_scale);
|
||||
drawing.draw_capture_line(monster.health_dynamic_UI.bar, position_on_screen, opacity_scale, monster.capture_percentage);
|
||||
local health_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.dynamic.health.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.dynamic.health.offset.y
|
||||
};
|
||||
|
||||
stamina_UI_entity.draw(monster, monster.stamina_dynamic_UI, position_on_screen, opacity_scale);
|
||||
rage_UI_entity.draw(monster, monster.rage_dynamic_UI, position_on_screen, opacity_scale);
|
||||
local stamina_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.dynamic.stamina.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.dynamic.stamina.offset.y
|
||||
};
|
||||
|
||||
local rage_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.dynamic.rage.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.dynamic.rage.offset.y
|
||||
};
|
||||
|
||||
local parts_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.dynamic.parts.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.dynamic.parts.offset.y
|
||||
};
|
||||
|
||||
health_UI_entity.draw(monster, monster.health_dynamic_UI, health_position_on_screen, opacity_scale);
|
||||
drawing.draw_capture_line(monster.health_dynamic_UI.bar, health_position_on_screen, opacity_scale, monster.capture_percentage);
|
||||
|
||||
stamina_UI_entity.draw(monster, monster.stamina_dynamic_UI, stamina_position_on_screen, opacity_scale);
|
||||
rage_UI_entity.draw(monster, monster.rage_dynamic_UI, rage_position_on_screen, opacity_scale);
|
||||
|
||||
--sort parts here
|
||||
local displayed_parts = {};
|
||||
@@ -612,8 +632,8 @@ function large_monster.draw_dynamic(monster, position_on_screen, opacity_scale)
|
||||
|
||||
for j, part in ipairs(displayed_parts) do
|
||||
local part_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.dynamic.parts.offset.x + config.current_config.large_monster_UI.dynamic.parts.spacing.x * (j - 1),
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.dynamic.parts.offset.y + config.current_config.large_monster_UI.dynamic.parts.spacing.y * (j - 1);
|
||||
x = parts_position_on_screen.x + config.current_config.large_monster_UI.dynamic.parts.spacing.x * (j - 1),
|
||||
y = parts_position_on_screen.y + config.current_config.large_monster_UI.dynamic.parts.spacing.y * (j - 1);
|
||||
}
|
||||
|
||||
body_part.draw_dynamic(part, part_position_on_screen, opacity_scale);
|
||||
@@ -646,12 +666,31 @@ function large_monster.draw_static(monster, position_on_screen, opacity_scale)
|
||||
|
||||
drawing.draw_label(monster.static_name_label, position_on_screen, opacity_scale, monster_name_text);
|
||||
|
||||
local health_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.static.health.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.static.health.offset.y
|
||||
};
|
||||
|
||||
health_UI_entity.draw(monster, monster.health_static_UI, position_on_screen, opacity_scale);
|
||||
drawing.draw_capture_line(monster.health_static_UI.bar, position_on_screen, opacity_scale, monster.capture_percentage);
|
||||
local stamina_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.static.stamina.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.static.stamina.offset.y
|
||||
};
|
||||
|
||||
stamina_UI_entity.draw(monster, monster.stamina_static_UI, position_on_screen, opacity_scale);
|
||||
rage_UI_entity.draw(monster, monster.rage_static_UI, position_on_screen, opacity_scale);
|
||||
local rage_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.static.rage.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.static.rage.offset.y
|
||||
};
|
||||
|
||||
local parts_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.static.parts.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.static.parts.offset.y
|
||||
};
|
||||
|
||||
health_UI_entity.draw(monster, monster.health_static_UI, health_position_on_screen, opacity_scale);
|
||||
drawing.draw_capture_line(monster.health_static_UI.bar, health_position_on_screen, opacity_scale, monster.capture_percentage);
|
||||
|
||||
stamina_UI_entity.draw(monster, monster.stamina_static_UI, stamina_position_on_screen, opacity_scale);
|
||||
rage_UI_entity.draw(monster, monster.rage_static_UI, rage_position_on_screen, opacity_scale);
|
||||
|
||||
--sort parts here
|
||||
local displayed_parts = {};
|
||||
@@ -698,8 +737,8 @@ function large_monster.draw_static(monster, position_on_screen, opacity_scale)
|
||||
|
||||
for j, part in ipairs(displayed_parts) do
|
||||
local part_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.static.parts.offset.x + config.current_config.large_monster_UI.static.parts.spacing.x * (j - 1),
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.static.parts.offset.y + config.current_config.large_monster_UI.static.parts.spacing.y * (j - 1);
|
||||
x = parts_position_on_screen.x + config.current_config.large_monster_UI.static.parts.spacing.x * (j - 1),
|
||||
y = parts_position_on_screen.y + config.current_config.large_monster_UI.static.parts.spacing.y * (j - 1);
|
||||
}
|
||||
|
||||
body_part.draw_static(part, part_position_on_screen, opacity_scale);
|
||||
@@ -732,12 +771,31 @@ function large_monster.draw_highlighted(monster, position_on_screen, opacity_sca
|
||||
|
||||
drawing.draw_label(monster.highlighted_name_label, position_on_screen, opacity_scale, monster_name_text);
|
||||
|
||||
local health_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.highlighted.health.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.highlighted.health.offset.y
|
||||
};
|
||||
|
||||
health_UI_entity.draw(monster, monster.health_highlighted_UI, position_on_screen, opacity_scale);
|
||||
drawing.draw_capture_line(monster.health_highlighted_UI.bar, position_on_screen, opacity_scale, monster.capture_percentage);
|
||||
local stamina_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.highlighted.stamina.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.highlighted.stamina.offset.y
|
||||
};
|
||||
|
||||
stamina_UI_entity.draw(monster, monster.stamina_highlighted_UI, position_on_screen, opacity_scale);
|
||||
rage_UI_entity.draw(monster, monster.rage_highlighted_UI, position_on_screen, opacity_scale);
|
||||
local rage_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.highlighted.rage.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.highlighted.rage.offset.y
|
||||
};
|
||||
|
||||
local parts_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.highlighted.parts.offset.x,
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.highlighted.parts.offset.y
|
||||
};
|
||||
|
||||
health_UI_entity.draw(monster, monster.health_highlighted_UI, health_position_on_screen, opacity_scale);
|
||||
drawing.draw_capture_line(monster.health_highlighted_UI.bar, health_position_on_screen, opacity_scale, monster.capture_percentage);
|
||||
|
||||
stamina_UI_entity.draw(monster, monster.stamina_highlighted_UI, stamina_position_on_screen, opacity_scale);
|
||||
rage_UI_entity.draw(monster, monster.rage_highlighted_UI, rage_position_on_screen, opacity_scale);
|
||||
|
||||
--sort parts here
|
||||
local displayed_parts = {};
|
||||
@@ -784,8 +842,8 @@ function large_monster.draw_highlighted(monster, position_on_screen, opacity_sca
|
||||
|
||||
for j, part in ipairs(displayed_parts) do
|
||||
local part_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.large_monster_UI.highlighted.parts.offset.x + config.current_config.large_monster_UI.highlighted.parts.spacing.x * (j - 1),
|
||||
y = position_on_screen.y + config.current_config.large_monster_UI.highlighted.parts.offset.y + config.current_config.large_monster_UI.highlighted.parts.spacing.y * (j - 1);
|
||||
x = parts_position_on_screen.x + config.current_config.large_monster_UI.highlighted.parts.spacing.x * (j - 1),
|
||||
y = parts_position_on_screen.y + config.current_config.large_monster_UI.highlighted.parts.spacing.y * (j - 1);
|
||||
}
|
||||
|
||||
body_part.draw_highlighted(part, part_position_on_screen, opacity_scale);
|
||||
|
||||
@@ -234,9 +234,18 @@ end
|
||||
function small_monster.draw(monster, position_on_screen, opacity_scale)
|
||||
drawing.draw_label(monster.name_label, position_on_screen, opacity_scale, monster.name);
|
||||
|
||||
local health_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.small_monster_UI.health.offset.x,
|
||||
y = position_on_screen.y + config.current_config.small_monster_UI.health.offset.y
|
||||
};
|
||||
|
||||
local stamina_position_on_screen = {
|
||||
x = position_on_screen.x + config.current_config.small_monster_UI.stamina.offset.x,
|
||||
y = position_on_screen.y + config.current_config.small_monster_UI.stamina.offset.y
|
||||
};
|
||||
|
||||
health_UI_entity.draw(monster, monster.health_UI, position_on_screen, opacity_scale);
|
||||
stamina_UI_entity.draw(monster, monster.stamina_UI, position_on_screen, opacity_scale);
|
||||
health_UI_entity.draw(monster, monster.health_UI, health_position_on_screen, opacity_scale);
|
||||
stamina_UI_entity.draw(monster, monster.stamina_UI, stamina_position_on_screen, opacity_scale);
|
||||
end
|
||||
|
||||
function small_monster.init_list()
|
||||
|
||||
@@ -149,7 +149,17 @@ function damage_meter_UI.draw()
|
||||
table.insert(reversed_quest_players, quest_players[i]);
|
||||
end
|
||||
quest_players = reversed_quest_players;
|
||||
elseif config.current_config.damage_meter_UI.sorting.type == "Damage" then
|
||||
elseif config.current_config.damage_meter_UI.sorting.type == "DPS" then
|
||||
if config.current_config.damage_meter_UI.sorting.reversed_order then
|
||||
table.sort(quest_players, function(left, right)
|
||||
return left.dps < right.dps;
|
||||
end);
|
||||
else
|
||||
table.sort(quest_players, function(left, right)
|
||||
return left.dps > right.dps;
|
||||
end);
|
||||
end
|
||||
else
|
||||
if config.current_config.damage_meter_UI.sorting.reversed_order then
|
||||
table.sort(quest_players, function(left, right)
|
||||
return left.display.total_damage < right.display.total_damage;
|
||||
@@ -173,10 +183,15 @@ function damage_meter_UI.draw()
|
||||
end
|
||||
|
||||
local top_damage = 0;
|
||||
local top_dps = 0;
|
||||
for _, _player in ipairs(quest_players) do
|
||||
if _player.display.total_damage > top_damage then
|
||||
top_damage = _player.display.total_damage;
|
||||
end
|
||||
|
||||
if _player.dps > top_dps then
|
||||
top_dps = _player.dps;
|
||||
end
|
||||
end
|
||||
|
||||
-- draw
|
||||
@@ -187,7 +202,7 @@ function damage_meter_UI.draw()
|
||||
goto continue1
|
||||
end
|
||||
|
||||
player.draw(_player, position_on_screen, 1, top_damage);
|
||||
player.draw(_player, position_on_screen, 1, top_damage, top_dps);
|
||||
|
||||
if config.current_config.damage_meter_UI.settings.orientation == "Horizontal" then
|
||||
position_on_screen.x = position_on_screen.x + config.current_config.damage_meter_UI.spacing.x;
|
||||
@@ -210,7 +225,7 @@ function damage_meter_UI.draw()
|
||||
|
||||
drawing.draw_label(config.current_config.damage_meter_UI.total_damage_label, position_on_screen, 1, language.current_language.UI.total_damage);
|
||||
drawing.draw_label(config.current_config.damage_meter_UI.total_damage_value_label, position_on_screen, 1, player.total.display.total_damage);
|
||||
|
||||
drawing.draw_label(config.current_config.damage_meter_UI.total_dps_label, position_on_screen, 1, player.total.dps);
|
||||
end
|
||||
|
||||
function damage_meter_UI.init_module()
|
||||
|
||||
@@ -70,7 +70,7 @@ function large_monster_UI.draw(dynamic_enabled, static_enabled, highlighted_enab
|
||||
end
|
||||
|
||||
if dynamic_enabled then
|
||||
large_monster_UI.draw_dynamic(displayed_monsters);
|
||||
large_monster_UI.draw_dynamic(displayed_monsters, highlighted_monster);
|
||||
end
|
||||
|
||||
if highlighted_enabled then
|
||||
@@ -78,12 +78,12 @@ function large_monster_UI.draw(dynamic_enabled, static_enabled, highlighted_enab
|
||||
end
|
||||
|
||||
if static_enabled then
|
||||
large_monster_UI.draw_static(displayed_monsters);
|
||||
large_monster_UI.draw_static(displayed_monsters, highlighted_monster);
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function large_monster_UI.draw_dynamic(displayed_monsters)
|
||||
function large_monster_UI.draw_dynamic(displayed_monsters, highlighted_monster)
|
||||
local i = 0;
|
||||
for _, monster in ipairs(displayed_monsters) do
|
||||
if config.current_config.large_monster_UI.dynamic.settings.max_distance == 0 then
|
||||
@@ -94,6 +94,16 @@ function large_monster_UI.draw_dynamic(displayed_monsters)
|
||||
goto continue;
|
||||
end
|
||||
|
||||
if monster == highlighted_monster then
|
||||
if not config.current_config.large_monster_UI.dynamic.settings.render_highlighted_monster then
|
||||
goto continue;
|
||||
end
|
||||
else
|
||||
if not config.current_config.large_monster_UI.dynamic.settings.render_not_highlighted_monsters then
|
||||
goto continue;
|
||||
end
|
||||
end
|
||||
|
||||
local position_on_screen = {};
|
||||
|
||||
local world_offset = Vector3f.new(config.current_config.large_monster_UI.dynamic.world_offset.x, config.current_config.large_monster_UI.dynamic.world_offset.y, config.current_config.large_monster_UI.dynamic.world_offset.z);
|
||||
@@ -123,7 +133,7 @@ function large_monster_UI.draw_dynamic(displayed_monsters)
|
||||
end
|
||||
end
|
||||
|
||||
function large_monster_UI.draw_static(displayed_monsters)
|
||||
function large_monster_UI.draw_static(displayed_monsters, highlighted_monster)
|
||||
-- sort here
|
||||
if config.current_config.large_monster_UI.static.sorting.type == "Normal" and config.current_config.large_monster_UI.static.sorting.reversed_order then
|
||||
local reversed_monsters = {};
|
||||
@@ -173,6 +183,16 @@ function large_monster_UI.draw_static(displayed_monsters)
|
||||
goto continue;
|
||||
end
|
||||
|
||||
if monster == highlighted_monster then
|
||||
if not config.current_config.large_monster_UI.static.settings.render_highlighted_monster then
|
||||
goto continue;
|
||||
end
|
||||
else
|
||||
if not config.current_config.large_monster_UI.static.settings.render_not_highlighted_monsters then
|
||||
goto continue;
|
||||
end
|
||||
end
|
||||
|
||||
local monster_position_on_screen = {
|
||||
x = position_on_screen.x,
|
||||
y = position_on_screen.y
|
||||
|
||||
@@ -1,45 +1,24 @@
|
||||
local time_UI = {};
|
||||
local singletons;
|
||||
local customization_menu;
|
||||
local time;
|
||||
local screen;
|
||||
local config;
|
||||
local drawing;
|
||||
|
||||
local quest_manager_type_def = sdk.find_type_definition("snow.QuestManager");
|
||||
local get_quest_elapsed_time_min_method = quest_manager_type_def:get_method("getQuestElapsedTimeMin");
|
||||
local get_quest_elapseD_time_sec_method = quest_manager_type_def:get_method("getQuestElapsedTimeSec");
|
||||
|
||||
function time_UI.draw()
|
||||
if singletons.quest_manager == nil then
|
||||
return;
|
||||
end
|
||||
local elapsed_minutes = time.elapsed_minutes;
|
||||
local elapsed_seconds = time.elapsed_seconds;
|
||||
|
||||
local quest_time_elapsed_minutes = get_quest_elapsed_time_min_method:call( singletons.quest_manager);
|
||||
if quest_time_elapsed_minutes == nil then
|
||||
customization_menu.status = "No quest time elapsed minutes";
|
||||
if elapsed_seconds == 0 and elapsed_minutes == 0 then
|
||||
return;
|
||||
end
|
||||
|
||||
local quest_time_total_elapsed_seconds = get_quest_elapseD_time_sec_method:call(singletons.quest_manager);
|
||||
if quest_time_total_elapsed_seconds == nil then
|
||||
customization_menu.status = "No quest time total elapsed seconds";
|
||||
return;
|
||||
end
|
||||
|
||||
if quest_time_total_elapsed_seconds == 0 then
|
||||
return;
|
||||
end
|
||||
|
||||
local quest_time_elapsed_seconds = quest_time_total_elapsed_seconds - quest_time_elapsed_minutes * 60;
|
||||
|
||||
local position_on_screen = screen.calculate_absolute_coordinates(config.current_config.time_UI.position);
|
||||
|
||||
drawing.draw_label(config.current_config.time_UI.time_label, position_on_screen, 1, quest_time_elapsed_minutes, quest_time_elapsed_seconds);
|
||||
drawing.draw_label(config.current_config.time_UI.time_label, position_on_screen, 1, elapsed_minutes, elapsed_seconds);
|
||||
end
|
||||
|
||||
function time_UI.init_module()
|
||||
singletons = require("MHR_Overlay.Game_Handler.singletons");
|
||||
customization_menu = require("MHR_Overlay.UI.customization_menu");
|
||||
time = require("MHR_Overlay.Game_Handler.time");
|
||||
screen = require("MHR_Overlay.Game_Handler.screen");
|
||||
config = require("MHR_Overlay.Misc.config");
|
||||
drawing = require("MHR_Overlay.UI.drawing");
|
||||
|
||||
@@ -5,13 +5,14 @@ local config;
|
||||
local player;
|
||||
local language;
|
||||
|
||||
function damage_UI_entity.new(bar, highlighted_bar, player_name_label, hunter_rank_label, value_label, percentage_label)
|
||||
function damage_UI_entity.new(bar, highlighted_bar, player_name_label, dps_label, hunter_rank_label, value_label, percentage_label)
|
||||
local entity = {};
|
||||
|
||||
--entity.visibility = visibility;
|
||||
entity.bar = table_helpers.deep_copy(bar);
|
||||
entity.highlighted_bar = table_helpers.deep_copy(highlighted_bar);
|
||||
entity.player_name_label = table_helpers.deep_copy(player_name_label);
|
||||
entity.dps_label = table_helpers.deep_copy(dps_label);
|
||||
entity.hunter_rank_label = table_helpers.deep_copy(hunter_rank_label);
|
||||
entity.value_label = table_helpers.deep_copy(value_label);
|
||||
entity.percentage_label = table_helpers.deep_copy(percentage_label);
|
||||
@@ -19,7 +20,7 @@ function damage_UI_entity.new(bar, highlighted_bar, player_name_label, hunter_ra
|
||||
return entity;
|
||||
end
|
||||
|
||||
function damage_UI_entity.draw(_player, position_on_screen, opacity_scale, top_damage)
|
||||
function damage_UI_entity.draw(_player, position_on_screen, opacity_scale, top_damage, top_dps)
|
||||
|
||||
local player_include = config.current_config.damage_meter_UI.player_name_label.include.others;
|
||||
if _player.id == _player.myself_id then
|
||||
@@ -56,10 +57,14 @@ function damage_UI_entity.draw(_player, position_on_screen, opacity_scale, top_d
|
||||
end
|
||||
end
|
||||
|
||||
x = string.format("%s / %s", tostring(_player.dps), tostring(top_dps));
|
||||
|
||||
if _player.id == player.myself_id and config.current_config.damage_meter_UI.settings.highlighted_bar == "Me" then
|
||||
drawing.draw_bar(_player.damage_UI.highlighted_bar, position_on_screen, opacity_scale, player_damage_bar_percentage);
|
||||
elseif config.current_config.damage_meter_UI.settings.highlighted_bar == "Top Damage" and _player.display.total_damage == top_damage then
|
||||
drawing.draw_bar(_player.damage_UI.highlighted_bar, position_on_screen, opacity_scale, player_damage_bar_percentage);
|
||||
elseif config.current_config.damage_meter_UI.settings.highlighted_bar == "Top DPS" and _player.dps == top_dps then
|
||||
drawing.draw_bar(_player.damage_UI.highlighted_bar, position_on_screen, opacity_scale, player_damage_bar_percentage);
|
||||
else
|
||||
drawing.draw_bar(_player.damage_UI.bar, position_on_screen, opacity_scale, player_damage_bar_percentage);
|
||||
end
|
||||
@@ -75,6 +80,7 @@ function damage_UI_entity.draw(_player, position_on_screen, opacity_scale, top_d
|
||||
drawing.draw_label(_player.damage_UI.player_name_label, position_on_screen, opacity_scale, player_name_text);
|
||||
drawing.draw_label(_player.damage_UI.value_label, position_on_screen, opacity_scale, _player.display.total_damage);
|
||||
drawing.draw_label(_player.damage_UI.percentage_label, position_on_screen, opacity_scale, 100 * player_damage_percentage);
|
||||
drawing.draw_label(_player.damage_UI.dps_label, position_on_screen, opacity_scale, _player.dps);
|
||||
end
|
||||
|
||||
function damage_UI_entity.init_module()
|
||||
|
||||
@@ -45,6 +45,7 @@ customization_menu.damage_meter_UI_highlighted_bar_types = {};
|
||||
customization_menu.damage_meter_UI_damage_bar_relative_types = {};
|
||||
customization_menu.damage_meter_UI_my_damage_bar_location_types = {};
|
||||
customization_menu.damage_meter_UI_sorting_types = {};
|
||||
customization_menu.damage_meter_UI_dps_modes = {};
|
||||
|
||||
customization_menu.fonts = {"Arial", "Arial Black", "Bahnschrift", "Calibri", "Cambria", "Cambria Math", "Candara",
|
||||
"Comic Sans MS", "Consolas", "Constantia", "Corbel", "Courier New", "Ebrima",
|
||||
@@ -63,15 +64,18 @@ customization_menu.small_monster_UI_sorting_type_index = 1;
|
||||
|
||||
customization_menu.large_monster_UI_orientation_index = 1;
|
||||
customization_menu.large_monster_UI_sorting_type_index = 1;
|
||||
customization_menu.large_monster_UI_highlighted_monster_location_index = 1;
|
||||
|
||||
customization_menu.large_monster_dynamic_UI_parts_sorting_type_index = 1;
|
||||
customization_menu.large_monster_static_UI_parts_sorting_type_index = 1;
|
||||
customization_menu.large_monster_highlighted_UI_parts_sorting_type_index = 1;
|
||||
|
||||
customization_menu.damage_meter_UI_orientation_index = 1;
|
||||
customization_menu.damage_meter_UI_sorting_type_index = 1;
|
||||
customization_menu.damage_meter_UI_highlighted_bar_index = 1;
|
||||
customization_menu.damage_meter_UI_damage_bar_relative_index = 1;
|
||||
customization_menu.damage_meter_UI_my_damage_bar_location_index = 1;
|
||||
customization_menu.damage_meter_UI_dps_mode_index = 1;
|
||||
|
||||
customization_menu.small_monster_UI_anchor_index = 1;
|
||||
customization_menu.large_monster_UI_anchor_index = 1;
|
||||
@@ -106,11 +110,11 @@ function customization_menu.init()
|
||||
customization_menu.displayed_monster_UI_sorting_types = {language.current_language.customization_menu.normal, language.current_language.customization_menu.health, language.current_language.customization_menu.health_percentage, language.current_language.customization_menu.distance};
|
||||
customization_menu.displayed_large_monster_UI_parts_sorting_types = {language.current_language.customization_menu.normal, language.current_language.customization_menu.health, language.current_language.customization_menu.health_percentage};
|
||||
|
||||
customization_menu.displayed_damage_meter_UI_highlighted_bar_types = {language.current_language.customization_menu.me, language.current_language.customization_menu.top_damage, language.current_language.customization_menu.none};
|
||||
customization_menu.displayed_damage_meter_UI_highlighted_bar_types = {language.current_language.customization_menu.me, language.current_language.customization_menu.top_damage, language.current_language.customization_menu.top_dps, language.current_language.customization_menu.none};
|
||||
customization_menu.displayed_damage_meter_UI_damage_bar_relative_types = {language.current_language.customization_menu.total_damage, language.current_language.customization_menu.top_damage};
|
||||
customization_menu.displayed_damage_meter_UI_my_damage_bar_location_types = {language.current_language.customization_menu.normal, language.current_language.customization_menu.first, language.current_language.customization_menu.last};
|
||||
customization_menu.displayed_damage_meter_UI_sorting_types = {language.current_language.customization_menu.normal, language.current_language.customization_menu.damage};
|
||||
|
||||
customization_menu.displayed_damage_meter_UI_sorting_types = {language.current_language.customization_menu.normal, language.current_language.customization_menu.damage, language.current_language.customization_menu.dps};
|
||||
customization_menu.displayed_damage_meter_UI_dps_modes = {language.current_language.customization_menu.first_hit, language.current_language.customization_menu.quest_time, language.current_language.customization_menu.join_time};
|
||||
|
||||
|
||||
|
||||
@@ -121,12 +125,11 @@ function customization_menu.init()
|
||||
customization_menu.monster_UI_sorting_types = {language.default_language.customization_menu.normal, language.default_language.customization_menu.health, language.default_language.customization_menu.health_percentage, language.default_language.customization_menu.distance};
|
||||
customization_menu.large_monster_UI_parts_sorting_types = {language.default_language.customization_menu.normal, language.default_language.customization_menu.health, language.default_language.customization_menu.health_percentage};
|
||||
|
||||
customization_menu.damage_meter_UI_highlighted_bar_types = {language.default_language.customization_menu.me, language.default_language.customization_menu.top_damage, language.default_language.customization_menu.none};
|
||||
customization_menu.damage_meter_UI_highlighted_bar_types = {language.default_language.customization_menu.me, language.default_language.customization_menu.top_damage, language.default_language.customization_menu.top_dps, language.default_language.customization_menu.none};
|
||||
customization_menu.damage_meter_UI_damage_bar_relative_types = {language.default_language.customization_menu.total_damage, language.default_language.customization_menu.top_damage};
|
||||
customization_menu.damage_meter_UI_my_damage_bar_location_types = {language.default_language.customization_menu.normal, language.default_language.customization_menu.first, language.default_language.customization_menu.last};
|
||||
customization_menu.damage_meter_UI_sorting_types = {language.default_language.customization_menu.normal, language.default_language.customization_menu.damage};
|
||||
|
||||
|
||||
customization_menu.damage_meter_UI_sorting_types = {language.default_language.customization_menu.normal, language.default_language.customization_menu.damage, language.default_language.customization_menu.dps};
|
||||
customization_menu.damage_meter_UI_dps_modes = {language.default_language.customization_menu.first_hit, language.default_language.customization_menu.quest_time, language.default_language.customization_menu.join_time};
|
||||
|
||||
|
||||
|
||||
@@ -146,6 +149,9 @@ function customization_menu.init()
|
||||
customization_menu.large_monster_UI_sorting_type_index = table_helpers.find_index(
|
||||
customization_menu.monster_UI_sorting_types, config.current_config.large_monster_UI.static.sorting.type, false);
|
||||
|
||||
customization_menu.large_monster_UI_highlighted_monster_location_index = table_helpers.find_index(
|
||||
customization_menu.damage_meter_UI_my_damage_bar_location_types, config.current_config.large_monster_UI.static.settings.highlighted_monster_location, false);
|
||||
|
||||
customization_menu.large_monster_dynamic_UI_parts_sorting_type_index = table_helpers.find_index(
|
||||
customization_menu.large_monster_UI_parts_sorting_types,
|
||||
config.current_config.large_monster_UI.dynamic.parts.sorting.type, false);
|
||||
@@ -154,6 +160,10 @@ function customization_menu.init()
|
||||
customization_menu.large_monster_UI_parts_sorting_types,
|
||||
config.current_config.large_monster_UI.static.parts.sorting.type, false);
|
||||
|
||||
customization_menu.large_monster_highlighted_UI_parts_sorting_type_index = table_helpers.find_index(
|
||||
customization_menu.large_monster_UI_parts_sorting_types,
|
||||
config.current_config.large_monster_UI.highlighted.parts.sorting.type, false);
|
||||
|
||||
customization_menu.damage_meter_UI_orientation_index = table_helpers.find_index(customization_menu.orientation_types,
|
||||
config.current_config.damage_meter_UI.settings.orientation, false);
|
||||
|
||||
@@ -172,6 +182,11 @@ function customization_menu.init()
|
||||
customization_menu.damage_meter_UI_sorting_type_index = table_helpers.find_index(
|
||||
customization_menu.damage_meter_UI_sorting_types, config.current_config.damage_meter_UI.sorting.type, false);
|
||||
|
||||
customization_menu.damage_meter_UI_dps_mode_index = table_helpers.find_index(
|
||||
customization_menu.damage_meter_UI_dps_modes, config.current_config.damage_meter_UI.settings.dps_mode, false);
|
||||
|
||||
|
||||
|
||||
customization_menu.selected_font_index = table_helpers.find_index(customization_menu.fonts,
|
||||
config.current_config.global_settings.UI_font.family, false);
|
||||
|
||||
@@ -220,6 +235,10 @@ function customization_menu.draw()
|
||||
imgui.checkbox(language.current_language.customization_menu.large_monster_static_UI, config.current_config.large_monster_UI.static.enabled);
|
||||
config_changed = config_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.highlighted.enabled =
|
||||
imgui.checkbox(language.current_language.customization_menu.large_monster_highlighted_UI, config.current_config.large_monster_UI.highlighted.enabled);
|
||||
config_changed = config_changed or changed;
|
||||
|
||||
changed, config.current_config.time_UI.enabled = imgui.checkbox(language.current_language.customization_menu.time_UI, config.current_config.time_UI.enabled);
|
||||
config_changed = config_changed or changed;
|
||||
imgui.same_line();
|
||||
@@ -1168,6 +1187,14 @@ function customization_menu.draw()
|
||||
large_monster_UI.dynamic.settings.hide_dead_or_captured);
|
||||
config_changed = config_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.dynamic.settings.render_highlighted_monster = imgui.checkbox(language.current_language.customization_menu.render_highlighted_monster, config.current_config.
|
||||
large_monster_UI.dynamic.settings.render_highlighted_monster);
|
||||
config_changed = config_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.dynamic.settings.render_not_highlighted_monsters = imgui.checkbox(language.current_language.customization_menu.render_not_highlighted_monsters, config.current_config.
|
||||
large_monster_UI.dynamic.settings.render_not_highlighted_monsters);
|
||||
config_changed = config_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.dynamic.settings.opacity_falloff =
|
||||
imgui.checkbox(language.current_language.customization_menu.opacity_falloff, config.current_config.large_monster_UI.dynamic.settings.opacity_falloff);
|
||||
config_changed = config_changed or changed;
|
||||
@@ -1312,6 +1339,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.dynamic.health.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.dynamic.health.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.dynamic.health.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.dynamic.health.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.dynamic.health.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.dynamic.health.text_label.visibility);
|
||||
@@ -1647,6 +1690,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.dynamic.stamina.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.dynamic.stamina.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.dynamic.stamina.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.dynamic.stamina.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.dynamic.stamina.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.dynamic.stamina.text_label.visibility);
|
||||
@@ -1918,6 +1977,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.dynamic.rage.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.dynamic.rage.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.dynamic.rage.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.dynamic.rage.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_dynamic_UI_changed = large_monster_dynamic_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.dynamic.rage.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.dynamic.rage.text_label.visibility);
|
||||
@@ -2677,6 +2752,27 @@ function customization_menu.draw()
|
||||
changed, config.current_config.large_monster_UI.static.settings.hide_dead_or_captured = imgui.checkbox(language.current_language.customization_menu.hide_dead_or_captured, config.current_config.
|
||||
large_monster_UI.static.settings.hide_dead_or_captured);
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.static.settings.render_highlighted_monster = imgui.checkbox(language.current_language.customization_menu.render_highlighted_monster, config.current_config.
|
||||
large_monster_UI.static.settings.render_highlighted_monster);
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.static.settings.render_not_highlighted_monsters = imgui.checkbox(language.current_language.customization_menu.render_not_highlighted_monsters, config.current_config.
|
||||
large_monster_UI.static.settings.render_not_highlighted_monsters);
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
changed, customization_menu.large_monster_UI_highlighted_monster_location_index =
|
||||
imgui.combo(language.current_language.customization_menu.highlighted_monster_location, customization_menu.large_monster_UI_highlighted_monster_location_index,
|
||||
customization_menu.displayed_damage_meter_UI_my_damage_bar_location_types);
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
if changed then
|
||||
config.current_config.large_monster_UI.static.settings.highlighted_monster_location =
|
||||
customization_menu.damage_meter_UI_my_damage_bar_location_types[customization_menu.large_monster_UI_highlighted_monster_location_index];
|
||||
end
|
||||
|
||||
changed, customization_menu.large_monster_UI_orientation_index = imgui.combo(language.current_language.customization_menu.orientation,
|
||||
customization_menu.large_monster_UI_orientation_index, customization_menu.displayed_orientation_types);
|
||||
@@ -2843,6 +2939,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.static.health.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.static.health.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.static.health.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.static.health.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.static.health.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.static.health.text_label.visibility);
|
||||
@@ -3178,6 +3290,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.static.stamina.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.static.stamina.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.static.stamina.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.static.stamina.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.static.stamina.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.static.stamina.text_label.visibility);
|
||||
@@ -3448,6 +3576,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.static.rage.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.static.rage.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.static.rage.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.static.rage.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_static_UI_changed = large_monster_static_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.static.rage.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.static.rage.text_label.visibility);
|
||||
@@ -4327,6 +4471,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.highlighted.health.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.highlighted.health.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.highlighted.health.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.highlighted.health.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.highlighted.health.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.highlighted.health.text_label.visibility);
|
||||
@@ -4662,6 +4822,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.highlighted.stamina.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.highlighted.stamina.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.highlighted.stamina.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.highlighted.stamina.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.highlighted.stamina.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.highlighted.stamina.text_label.visibility);
|
||||
@@ -4932,6 +5108,22 @@ function customization_menu.draw()
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.large_monster_UI.highlighted.rage.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.large_monster_UI.highlighted.rage.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.large_monster_UI.highlighted.rage.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.large_monster_UI.highlighted.rage.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
large_monster_highlighted_UI_changed = large_monster_highlighted_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.text_label) then
|
||||
changed, config.current_config.large_monster_UI.highlighted.rage.text_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.large_monster_UI.highlighted.rage.text_label.visibility);
|
||||
@@ -5833,6 +6025,16 @@ function customization_menu.draw()
|
||||
customization_menu.damage_meter_UI_my_damage_bar_location_types[customization_menu.damage_meter_UI_my_damage_bar_location_index];
|
||||
end
|
||||
|
||||
changed, customization_menu.damage_meter_UI_dps_mode_index =
|
||||
imgui.combo(language.current_language.customization_menu.dps_mode, customization_menu.damage_meter_UI_dps_mode_index,
|
||||
customization_menu.displayed_damage_meter_UI_dps_modes);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
if changed then
|
||||
config.current_config.damage_meter_UI.settings.dps_mode =
|
||||
customization_menu.damage_meter_UI_dps_modes[customization_menu.damage_meter_UI_dps_mode_index];
|
||||
end
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
@@ -6277,6 +6479,72 @@ function customization_menu.draw()
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.dps_label) then
|
||||
changed, config.current_config.damage_meter_UI.dps_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.damage_meter_UI.dps_label.visibility);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
-- add text format
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.damage_meter_UI.dps_label.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.damage_meter_UI.dps_label.offset.x, 0.1, -screen.width, screen.width, "%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.damage_meter_UI.dps_label.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.damage_meter_UI.dps_label.offset.y, 0.1, -screen.height, screen.height, "%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.color) then
|
||||
changed, config.current_config.damage_meter_UI.dps_label.color = imgui.color_picker_argb("", config.current_config.damage_meter_UI.dps_label.color, customization_menu.color_picker_flags);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.shadow) then
|
||||
changed, config.current_config.damage_meter_UI.dps_label.shadow.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.damage_meter_UI.dps_label.shadow.visibility);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.damage_meter_UI.dps_label.shadow.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.damage_meter_UI.dps_label.shadow.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.damage_meter_UI.dps_label.shadow.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.damage_meter_UI.dps_label.shadow.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.color) then
|
||||
changed, config.current_config.damage_meter_UI.dps_label.shadow.color = imgui.color_picker_argb("", config.current_config.damage_meter_UI.dps_label.shadow.color, customization_menu.color_picker_flags);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.total_damage_label) then
|
||||
changed, config.current_config.damage_meter_UI.total_damage_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.damage_meter_UI.total_damage_label.visibility);
|
||||
@@ -6408,6 +6676,72 @@ function customization_menu.draw()
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.total_dps_label) then
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.damage_meter_UI.total_dps_label.visibility);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
-- add text format
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.damage_meter_UI.total_dps_label.offset.x, 0.1, -screen.width, screen.width, "%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.damage_meter_UI.total_dps_label.offset.y, 0.1, -screen.height, screen.height, "%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.color) then
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.color = imgui.color_picker_argb("", config.current_config.damage_meter_UI.total_dps_label.color, customization_menu.color_picker_flags);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.shadow) then
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.shadow.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.damage_meter_UI.total_dps_label.shadow.visibility);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.offset) then
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.shadow.offset.x = imgui.drag_float(language.current_language.customization_menu.x,
|
||||
config.current_config.damage_meter_UI.total_dps_label.shadow.offset.x, 0.1, -screen.width, screen.width,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.shadow.offset.y = imgui.drag_float(language.current_language.customization_menu.y,
|
||||
config.current_config.damage_meter_UI.total_dps_label.shadow.offset.y, 0.1, -screen.height, screen.height,
|
||||
"%.1f");
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.color) then
|
||||
changed, config.current_config.damage_meter_UI.total_dps_label.shadow.color = imgui.color_picker_argb("", config.current_config.damage_meter_UI.total_dps_label.shadow.color, customization_menu.color_picker_flags);
|
||||
config_changed = config_changed or changed;
|
||||
damage_meter_UI_changed = damage_meter_UI_changed or changed;
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
imgui.tree_pop();
|
||||
end
|
||||
|
||||
if imgui.tree_node(language.current_language.customization_menu.damage_bar) then
|
||||
changed, config.current_config.damage_meter_UI.damage_bar.visibility = imgui.checkbox(language.current_language.customization_menu.visible,
|
||||
config.current_config.damage_meter_UI.damage_bar.visibility);
|
||||
|
||||
Reference in New Issue
Block a user