- Few improvements on damage -> frags display.

- Welcome window strings passed to curseforge localization tool.
This commit is contained in:
tercio
2014-08-09 13:48:44 -03:00
parent 688fb10a7b
commit 6fab96bf5c
6 changed files with 47 additions and 133 deletions
+3 -3
View File
File diff suppressed because one or more lines are too long
+1
View File
@@ -227,6 +227,7 @@
--> avoid using this values bellow, they aren't updated by the parser, only on demand by a user interaction.
voidzone_damage = 0,
frags_total = 0,
--> end
}
+34 -12
View File
@@ -459,8 +459,17 @@
tabela._custom = true
end
local total = instancia.showing.totals.frags_total
local porcentagem
if (instancia.row_info.percent_type == 1) then
porcentagem = _cstr ("%.1f", tabela [2] / total * 100)
elseif (instancia.row_info.percent_type == 2) then
porcentagem = _cstr ("%.1f", tabela [2] / instancia.top * 100)
end
esta_barra.texto_esquerdo:SetText (colocacao .. ". " .. tabela [1])
esta_barra.texto_direita:SetText (tabela [2])
esta_barra.texto_direita:SetText (tabela [2] .. " (" .. porcentagem .. "%)")
esta_barra.texto_esquerdo:SetSize (esta_barra:GetWidth() - esta_barra.texto_direita:GetStringWidth() - 20, 15)
@@ -478,8 +487,16 @@
esta_barra.textura:SetVertexColor (_unpack (_detalhes.class_colors [tabela [3]]))
if (tabela [3] == "UNKNOW" or tabela [3] == "UNGROUPPLAYER" or tabela [3] == "ENEMY") then
esta_barra.icone_classe:SetTexture ("Interface\\LFGFRAME\\LFGROLE_BW")
esta_barra.icone_classe:SetTexCoord (.25, .5, 0, 1)
--esta_barra.icone_classe:SetTexture ("Interface\\LFGFRAME\\LFGROLE_BW")
--esta_barra.icone_classe:SetTexCoord (.25, .5, 0, 1)
--esta_barra.icone_classe:SetVertexColor (1, 1, 1)
--esta_barra.icone_classe:SetTexture ([[Interface\MINIMAP\Minimap_skull_normal]])
--esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
--esta_barra.icone_classe:SetVertexColor (1, 1, 1)
esta_barra.icone_classe:SetTexture ([[Interface\AddOns\Details\images\classes_plus]])
esta_barra.icone_classe:SetTexCoord (0.50390625, 0.62890625, 0, 0.125)
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
else
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
@@ -611,6 +628,7 @@
esta_barra.colocacao = colocacao
local total = instancia.showing.totals.voidzone_damage
local combat_time = instancia.showing:GetCombatTime()
local dps = _math_floor (self.damage / combat_time)
@@ -731,6 +749,7 @@ function atributo_damage:RefreshWindow (instancia, tabela_do_combate, forcar, ex
if (keyName == "frags") then
local frags = instancia.showing.frags
local frags_total_kills = 0
local index = 0
for fragName, fragAmount in _pairs (frags) do
@@ -758,6 +777,8 @@ function atributo_damage:RefreshWindow (instancia, tabela_do_combate, forcar, ex
ntable [index] = {fragName, fragAmount, actor_classe}
end
frags_total_kills = frags_total_kills + fragAmount
end
local tsize = #ntable
@@ -767,10 +788,8 @@ function atributo_damage:RefreshWindow (instancia, tabela_do_combate, forcar, ex
end
end
instancia.top = 0
if (tsize > 0) then
--_table_sort (ntable, function (t1, t2)
-- return (t1 [2] > t2 [2])
--end)
_table_sort (ntable, _detalhes.Sort2)
instancia.top = ntable [1][2]
end
@@ -790,10 +809,10 @@ function atributo_damage:RefreshWindow (instancia, tabela_do_combate, forcar, ex
return _detalhes:EndRefresh (instancia, total, tabela_do_combate, showing) --> retorna a tabela que precisa ganhar o refresh
end
--estra mostrando ALL então posso seguir o padrão correto? primeiro, atualiza a scroll bar...
tabela_do_combate.totals.frags_total = frags_total_kills
instancia:AtualizarScrollBar (total)
--depois faz a atualização normal dele através dos iterators
local qual_barra = 1
local barras_container = instancia.barras
@@ -897,10 +916,8 @@ function atributo_damage:RefreshWindow (instancia, tabela_do_combate, forcar, ex
tabela_do_combate.totals.voidzone_damage = voidzone_damage_total
--esta mostrando ALL então posso seguir o padrão correto? primeiro, atualiza a scroll bar...
instancia:AtualizarScrollBar (total)
--depois faz a atualização normal dele através dos iterators
local qual_barra = 1
local barras_container = instancia.barras
@@ -1325,12 +1342,15 @@ function atributo_damage:AtualizaBarra (instancia, barras_container, qual_barra,
elseif (sub_atributo == 3) then --> mostrando damage taken
local dtps = self.damage_taken / combat_time
local formated_damage_taken = SelectedToKFunction (_, self.damage_taken)
local formated_dtps = SelectedToKFunction (_, dtps)
if (UsingCustomRightText) then
esta_barra.texto_direita:SetText (instancia.row_info.textR_custom_text:ReplaceData (formated_damage_taken, "", porcentagem, self))
esta_barra.texto_direita:SetText (instancia.row_info.textR_custom_text:ReplaceData (formated_damage_taken, formated_dtps, porcentagem, self))
else
esta_barra.texto_direita:SetText (formated_damage_taken .." (" .. porcentagem .. "%)") --seta o texto da direita --
esta_barra.texto_direita:SetText (formated_damage_taken .." (" .. formated_dtps .. ", " .. porcentagem .. "%)") --seta o texto da direita --
end
esta_porcentagem = _math_floor ((self.damage_taken/instancia.top) * 100) --> determina qual o tamanho da barra
@@ -2408,6 +2428,8 @@ function atributo_damage:MontaInfoDamageDone()
return true
end
gump:JI_AtualizaContainerAlvos (amt)
--_table_sort (meus_agressores, function (a, b) return a[2] > b[2] end)
_table_sort (meus_agressores, _detalhes.Sort2)
+3
View File
@@ -338,6 +338,9 @@ function _detalhes:ApplyProfile (profile_name, nosave, is_copy)
--> open the instance
if (instance:IsEnabled()) then
if (not instance.baseframe) then
instance:AtivarInstancia()
end
instance:LockInstance (instance.isLocked)
instance:RestoreMainWindowPosition()
instance:ReajustaGump()
-114
View File
@@ -189,121 +189,7 @@ function _detalhes:OpenWelcomeWindow ()
end
_detalhes.standard_skin = savedObject
end
do
local Loc = LibStub ("AceLocale-3.0"):NewLocale ("Details", "enUS", true)
if (Loc) then
Loc ["STRING_WELCOME_1"] = "|cFFFFFFFFWelcome to Details! Quick Setup Wizard\n\n|rThis guide will help you with some important configurations.\nYou can skip this at any time just clicking on 'skip' button."
Loc ["STRING_WELCOME_2"] = "if you change your mind, you can always modify again through options panel"
Loc ["STRING_WELCOME_3"] = "Choose your DPS and HPS prefered method:"
Loc ["STRING_WELCOME_4"] = "Activity Time"..": "
Loc ["STRING_WELCOME_5"] = "Effective Time"..": "
Loc ["STRING_WELCOME_6"] = "the timer of each raid member is put on hold if his activity is ceased and back again to count when is resumed."
Loc ["STRING_WELCOME_7"] = "used for rankings, this method uses the elapsed combat time for measure the Dps and Hps of all raid members."
Loc ["STRING_WELCOME_8"] = "if you change your mind, you can always modify again through options panel"
Loc ["STRING_WELCOME_9"] = "Details! reads and calculate combat numbers in a very fast way, but if some kind of data is irrelevant for you, you can disable/enable it 'on-the-fly'."
Loc ["STRING_WELCOME_10"] = "Mouse over each slider to see what they represent."
Loc ["STRING_WELCOME_11"] = "if you change your mind, you can always modify again through options panel"
Loc ["STRING_WELCOME_12"] = "In this page you can choose the update speed desired and also enable animations."
Loc ["STRING_WELCOME_13"] = ""
Loc ["STRING_WELCOME_14"] = "Update Speed"
Loc ["STRING_WELCOME_15"] = "This is the delay length between each update in the window,\nthe standard value is 1 second,\nbut you may decrease to 0.3 for more dynamic updates."
Loc ["STRING_WELCOME_16"] = "Enable Animations"
Loc ["STRING_WELCOME_17"] = "Enable or Disable bar animations."
Loc ["STRING_WELCOME_18"] = "if you change your mind, you can always modify again through options panel"
Loc ["STRING_WELCOME_19"] = "Memory Adjustments:"
Loc ["STRING_WELCOME_20"] = "The amount of memory used by addons doesn't affect framerate, but, saving memory in computers which doesn't have much of it, may help the whole system. Details! try to be as flexible as possible to keep the game smooth even in not high-end hardware."
Loc ["STRING_WELCOME_21"] = "max segments"
Loc ["STRING_WELCOME_22"] = "How many segments you want to maintain.\nFeel free to adjust this number to be comfortable for you."
Loc ["STRING_WELCOME_23"] = "memory threshold"
Loc ["STRING_WELCOME_24"] = "Details! try adjust it self with the amount of memory\navaliable on your system.\n\nAlso is recommeded keep the amount of\nsegments low if your system have 2gb ram or less."
Loc ["STRING_WELCOME_25"] = "segments saved on logout"
Loc ["STRING_WELCOME_26"] = "Using the Interface: Stretch"
Loc ["STRING_WELCOME_27"] = "- When you have the mouse over a Details! window, a |cFFFFFF00small hook|r will appear over the instance button. |cFFFFFF00Click, hold and pull|r up to |cFFFFFF00stretch|r the window, releasing the mouse click, the window |cFFFFFF00back to original|r size.\n\n- If you miss a |cFFFFBB00scroll bar|r, you can active it on the options panel."
Loc ["STRING_WELCOME_28"] = "Using the Interface: Instance Button"
Loc ["STRING_WELCOME_29"] = "Instance button basically do three things:\n\n- show |cFFFFFF00what instance|r is it through the |cFFFFFF00#number|r,\n- open a |cFFFFFF00new instance|r window when clicked.\n- show a menu with |cFFFFFF00closed instances|r which can be reopen at any one."
Loc ["STRING_WELCOME_30"] = "Using the Interface: Fast Switch Panel (shortcuts)"
Loc ["STRING_WELCOME_31"] = "- Right clicking |cFFFFFF00over a row|r or in the background opens the |cFFFFFF00shortcut menu|r.\n- You can choose which |cFFFFFF00attribute|r the shortcut will have by |cFFFFFF00right clicking|r his icon.\n- Left click |cFFFFFF00selects|r the shortcut attribute and |cFFFFFF00display|r it on the instance\n- Right click anywhere |cFFFFFF00closes|r the switch panel."
Loc ["STRING_WELCOME_32"] = "Using the Interface: Snap Instances"
Loc ["STRING_WELCOME_33"] = "You can |cFFFFFF00snap windows|r in vertical or horizontal. A window always snap with |cFFFFFF00previous instance number|r: like the image in the right, instance |cFFFFFF00#5|r snapped with |cFFFFFF00#4|r. When a snapped window is stretched, all other instances in the |cFFFFFF00cluster are also|r stretched."
Loc ["STRING_WELCOME_34"] = "Using the Interface: Micro Display"
Loc ["STRING_WELCOME_35"] = "All instances have three |cFFFFFF00mini widgets|r located at the bottom of window. |cFFFFFF00Right clicking|r pops up a menu and with |cFFFFFF00left click|r displays a options panel for that widget."
Loc ["STRING_WELCOME_36"] = "Using the Interface: Plugins"
Loc ["STRING_WELCOME_37"] = "|cFFFFFF00Threat, tank avoidance, and others|r are handled by |cFFFFFF00plugins|r. You can open a new instance, select '|cFFFFFF00Widgets|r' and choose what you want at |cFFFFFF00sword|r menu.\n\nTip: click over a bar on |cFFFFFF00Vanguard|r to show avoidance numbers."
Loc ["STRING_WELCOME_38"] = "Ready to Raid!"
Loc ["STRING_WELCOME_39"] = "Thank you for choosing Details!\n\nFeel free to always send feedbacks and bug reports to us (|cFFBBFFFFuse the fifth button a blue one|r), we appreciate."
Loc ["STRING_WELCOME_40"] = "Which parts of a fight is important to you?"
Loc ["STRING_WELCOME_41"] = "Some Cool Interface Tweaks:"
Loc ["STRING_WELCOME_42"] = "Quick Appearance Settings"
Loc ["STRING_WELCOME_43"] = "Choose your prefered skin:"
Loc ["STRING_WELCOME_44"] = "Wallpaper"
Loc ["STRING_WELCOME_45"] = "For more customization options, check the options panel."
end
end
do
local Loc = LibStub ("AceLocale-3.0"):NewLocale ("Details", "ptBR")
if (Loc) then
Loc ["STRING_WELCOME_1"] = "|cFFFFFFFFBem vindo ao Details! Setup Rapido\n\n|rEste guia ira ajuda-la a configurar rapidamente aspectos basicos desde addon.\nVoce pode pular este guia a qualquer momento clicando no botao de cancelar."
Loc ["STRING_WELCOME_2"] = "se voce mudar de ideia, voce pode mudar novamente no painel de opcoes"
Loc ["STRING_WELCOME_3"] = "Escolha o metodo de DPS e HPS preferido:"
Loc ["STRING_WELCOME_4"] = "Atividade"..": "
Loc ["STRING_WELCOME_5"] = "Efetividade"..": "
Loc ["STRING_WELCOME_6"] = "o tempo do jogador e posto em pausa quando sua atividade e interrompida voltando a contar seu tempo quando voltar a atividade, metodo mais comum."
Loc ["STRING_WELCOME_7"] = "usado em rankings, este metodo usa o tempo total da luta para medir o Dps e Hps de todos os membros da raide."
Loc ["STRING_WELCOME_8"] = "se voce mudar de ideia, voce pode mudar novamente no painel de opcoes"
Loc ["STRING_WELCOME_9"] = "Details! faz a leitura e calculos do combate de uma maneira rapida, mas se algo e irrelevante para voce, e possivel desativa-lo."
Loc ["STRING_WELCOME_10"] = "Passe o mouse para saber o que cada um representa"
Loc ["STRING_WELCOME_11"] = "se voce mudar de ideia, voce pode mudar novamente no painel de opcoes"
Loc ["STRING_WELCOME_12"] = "Aqui voce pode escolher o tempo de intervalo entre cada atualizacao da janela."
Loc ["STRING_WELCOME_13"] = ""
Loc ["STRING_WELCOME_14"] = "Update Speed"
Loc ["STRING_WELCOME_14"] = "Intervalo de Atualizacao"
Loc ["STRING_WELCOME_15"] = "tempo entre cada atualizacao,\nuso da cpu pode |cFFFF9900aumentar levemente|r com valores muito baixos\ne |cFF00FF00ter reducao|r com valores mais altos."
Loc ["STRING_WELCOME_16"] = "Animar Barras"
Loc ["STRING_WELCOME_17"] = "ativa ou desativa as animacoes das barras.\nuso da cpu pode |cFFFF9900aumentar levemente|r com esta opcao ligada."
Loc ["STRING_WELCOME_18"] = "se voce mudar de ideia, voce pode mudar novamente no painel de opcoes"
Loc ["STRING_WELCOME_19"] = "Ajustes da Memoria:"
Loc ["STRING_WELCOME_20"] = "A quantidade de memoria nos addons nao afeta a taxa de quadros por segundo, mas, diminuir seu uso em computadores com pouca memoria, pode ajudar o desempenho em todo o sistema."
Loc ["STRING_WELCOME_21"] = "total de segmentos"
Loc ["STRING_WELCOME_22"] = "Quantos segmentos voce deseja armazenar."
Loc ["STRING_WELCOME_23"] = "limites de memoria"
Loc ["STRING_WELCOME_24"] = "Details! tenta auto ajustar a memoria usada de acordo com a memoria disponivel no sistema.\n\nTambem e recomendado limitar a quantidade de segmentos com 2Gb ou menor de memoria ram."
Loc ["STRING_WELCOME_25"] = "segmentos salvos no logout"
Loc ["STRING_WELCOME_26"] = "Usando a Interface: Stretch"
Loc ["STRING_WELCOME_27"] = "- Quando o mouse esta sobre a janela, um |cFFFFFF00gancho|r aparecera no canto direito superior da janela. |cFFFFFF00Clique, segure e arraste|r para cima |cFFFFFF00para esticar|r a janela, soltando o clique o mouse |cFFFFFF00a janela volta ao tamanho original|r.\n\n- Se voce sente falta da |cFFFFBB00barra de rolagem|r, voce pode ativa-la no painel de opcoes."
Loc ["STRING_WELCOME_28"] = "Usando a Interface: Botao de Instancias (janelas)"
Loc ["STRING_WELCOME_29"] = "Botao de Instancias (janelas) e usado para:\n\n- mostrar |cFFFFFF00qual instancia|r ele eh, atraves do |cFFFFFF00#numero|r,\n- abrir uma |cFFFFFF00nova instancia do Details!|r quando clicado.\n- mostrado um menu das |cFFFFFF00janelas que estao fechadas|r para reabri-las."
Loc ["STRING_WELCOME_30"] = "Usando a Interface: Atalhos"
Loc ["STRING_WELCOME_31"] = "- Clicando com o Direito |cFFFFFF00em uma barra ou na janela|r abre |cFFFFFF00o menu de atalhos|r.\n- Voce pode escolher o |cFFFFFF00atributo|r que o atalho tera |cFFFFFF00clicando com o botao direito|r no seu icone.\n- Botao esquerdo |cFFFFFF00troca para aquele atributo|r \n- Botao direito fecha o painel de atalhos."
Loc ["STRING_WELCOME_32"] = "Usando a Interface: Juntar Instancias"
Loc ["STRING_WELCOME_33"] = "Voce pode |cFFFFFF00juntar as janelas|r na vertical ou horizontal. Uma janela grudara com a |cFFFFFF00janela anterior a ela|r: como na imagem a direita, a instancia |cFFFFFF00#5|r grudou na |cFFFFFF00#4|r. Quando grudadas, as janelas redimencionam, esticam e movem-se juntas."
Loc ["STRING_WELCOME_34"] = "Usando a Interface: Mini Displays"
Loc ["STRING_WELCOME_35"] = "Todas as janelas possuem 3 |cFFFFFF00mini displays|r localizados na parte inferior da janela. |cFFFFFF00Botao Direiro |r abrira um menu para escolher o que deseja mostrar |cFFFFFF00botao esquerdo|r abre as configuracoes."
Loc ["STRING_WELCOME_36"] = "Usando a Interface: Plugins"
Loc ["STRING_WELCOME_37"] = "|cFFFFFF00Ameaca, avoidance do tank, o muito mais|r podem ser vistos atraves de |cFFFFFF00plugins|r. Voce pode abrir uma nova janela e selecionar '|cFFFFFF00Widgets|r' e escolher o plugin no |cFFFFFF00menu da espada|r."
Loc ["STRING_WELCOME_38"] = "Pronto Para Jogar!"
Loc ["STRING_WELCOME_39"] = "Obrigado por escolher o Details!\n\nSinta-se a vontade para nos enviar feedbacks do que achou deste addon (|cFFBBFFFFno quinto botao, um azul|r)."
Loc ["STRING_WELCOME_40"] = "Quais dados sao importantes para voce?"
Loc ["STRING_WELCOME_41"] = "Alguns ajustes bacanas na interface:"
Loc ["STRING_WELCOME_42"] = "Ajustes na Aparencia"
Loc ["STRING_WELCOME_43"] = "Escolha sua Skin preferida:"
Loc ["STRING_WELCOME_44"] = "Papel de Parede"
Loc ["STRING_WELCOME_45"] = "Para mais ajustes na aparencia, veja o painel de opcoes."
end
end
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--> page 1
+6 -4
View File
@@ -278,15 +278,13 @@ function _G._detalhes:Start()
--> check is this is the first run
if (self.is_first_run) then
_detalhes:OpenWelcomeWindow()
if (#self.custom == 0) then
_detalhes:AddDefaultCustomDisplays()
end
_detalhes:FillUserCustomSpells()
end
--> start tutorial if this is first run
if (self.tutorial.logons < 2 and self.is_first_run) then
self:StartTutorial()
@@ -414,7 +412,7 @@ function _G._detalhes:Start()
--_detalhes:OpenOptionsWindow (_detalhes.tabela_instancias[1])
--print (_G ["DetailsClearSegmentsButton1"]:GetSize())
--_detalhes:OpenCustomDisplayWindow()
--_detalhes:OpenWelcomeWindow() --for debug
--_detalhes:OpenWelcomeWindow()
end
_detalhes:ScheduleTimer ("OpenOptionsWindowAtStart", 2)
--_detalhes:OpenCustomDisplayWindow()
@@ -427,5 +425,9 @@ function _G._detalhes:Start()
_detalhes:OpenProfiler()
if (self.is_first_run) then
_detalhes:OpenWelcomeWindow()
end
end