From 513fa33ebd08607b13a64dfc1aa69b90b041c0a6 Mon Sep 17 00:00:00 2001 From: Flamanis Date: Fri, 22 Jan 2021 16:25:06 -0600 Subject: [PATCH] Always Show player: Ascending sort direction fix. --- classes/class_damage.lua | 10 ++++------ classes/class_heal.lua | 10 ++++------ classes/class_resources.lua | 10 ++++------ 3 files changed, 12 insertions(+), 18 deletions(-) diff --git a/classes/class_damage.lua b/classes/class_damage.lua index 2e66a3f8..4af7a9d6 100644 --- a/classes/class_damage.lua +++ b/classes/class_damage.lua @@ -2301,15 +2301,14 @@ function atributo_damage:RefreshWindow (instancia, tabela_do_combate, forcar, ex totalBarIsShown = true if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then + conteudo[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) + whichRowLine = whichRowLine+1 for i = iter_last-1, instancia.barraS[1], -1 do if (conteudo[i]) then conteudo[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) whichRowLine = whichRowLine+1 end end - - conteudo[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) - whichRowLine = whichRowLine+1 else for i = iter_last, instancia.barraS[1], -1 do if (conteudo[i]) then @@ -2320,15 +2319,14 @@ function atributo_damage:RefreshWindow (instancia, tabela_do_combate, forcar, ex end else if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then + conteudo[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) + whichRowLine = whichRowLine+1 for i = instancia.barraS[2]-1, instancia.barraS[1], -1 do if (conteudo[i]) then conteudo[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) whichRowLine = whichRowLine+1 end end - - conteudo[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) - whichRowLine = whichRowLine+1 else -- /run print (Details:GetInstance(1).barraS[2]) -- vai do 5 ao 1 -- qual barra come�a no 1 -- i = 5 at� 1 -- player 5 atualiza na barra 1 / player 1 atualiza na barra 5 for i = instancia.barraS[2], instancia.barraS[1], -1 do diff --git a/classes/class_heal.lua b/classes/class_heal.lua index 58b744a5..f84af34b 100644 --- a/classes/class_heal.lua +++ b/classes/class_heal.lua @@ -502,15 +502,14 @@ function atributo_heal:RefreshWindow (instancia, tabela_do_combate, forcar, expo gump:Fade (row1, "out") if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then + conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) + whichRowLine = whichRowLine+1 for i = iter_last-1, instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado if (conteudo[i]) then conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) whichRowLine = whichRowLine+1 end end - - conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) - whichRowLine = whichRowLine+1 else for i = iter_last, instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado if (conteudo[i]) then @@ -521,15 +520,14 @@ function atributo_heal:RefreshWindow (instancia, tabela_do_combate, forcar, expo end else if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then + conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) + whichRowLine = whichRowLine+1 for i = instancia.barraS[2]-1, instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado if (conteudo[i]) then conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) whichRowLine = whichRowLine+1 end end - - conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) - whichRowLine = whichRowLine+1 else for i = instancia.barraS[2], instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado if (conteudo[i]) then diff --git a/classes/class_resources.lua b/classes/class_resources.lua index 1a1a706a..85cbb307 100644 --- a/classes/class_resources.lua +++ b/classes/class_resources.lua @@ -602,13 +602,12 @@ function atributo_energy:RefreshWindow (instancia, tabela_do_combate, forcar, ex gump:Fade (row1, "out") if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then + conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra + whichRowLine = whichRowLine+1 for i = iter_last-1, instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra whichRowLine = whichRowLine+1 end - - conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra - whichRowLine = whichRowLine+1 else for i = iter_last, instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra @@ -617,13 +616,12 @@ function atributo_energy:RefreshWindow (instancia, tabela_do_combate, forcar, ex end else if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then + conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra + whichRowLine = whichRowLine+1 for i = instancia.barraS[2]-1, instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra whichRowLine = whichRowLine+1 end - - conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra - whichRowLine = whichRowLine+1 else for i = instancia.barraS[2], instancia.barraS[1], -1 do --> vai atualizar s� o range que esta sendo mostrado conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --> inst�ncia, index, total, valor da 1� barra