- Added Rallying Cry on warrior cooldown list.

- Healthstone now is considered both healing and cooldown attributes.
- Fixed the sort method for custom displays, now the bars wuth same value is correctly sort by alphabetical.
- Fixed non-combat switch by role where changing role wasn't changing the attribute.
- Fixed the icons hiding and showing with Alpha Modify Types.
- NickTag now don't check if a received name is invalid.
This commit is contained in:
tercio
2014-06-27 22:10:13 -03:00
parent 4fca65b5f3
commit eb87774f40
12 changed files with 152 additions and 67 deletions
+33 -4
View File
@@ -1179,21 +1179,35 @@ function _detalhes:SwitchTo (switch_table, nosave)
end
--backtable indexes: [1]: mode [2]: attribute [3]: sub attribute [4]: segment [5]: raidmode index [6]: solomode index
function _detalhes:CheckSwitchOnCombatEnd (nowipe)
function _detalhes:CheckSwitchOnCombatEnd (nowipe, warning)
self:SwitchBack()
local role = _UnitGroupRolesAssigned ("player")
local got_switch = false
if (role == "DAMAGER" and self.switch_damager) then
self:SwitchTo (self.switch_damager)
got_switch = true
elseif (role == "HEALER" and self.switch_healer) then
self:SwitchTo (self.switch_healer)
got_switch = true
elseif (role == "TANK" and self.switch_tank) then
self:SwitchTo (self.switch_tank, true)
got_switch = true
elseif (role == "NONE" and _detalhes.last_assigned_role ~= "NONE") then
self:SwitchBack()
got_switch = true
end
if (warning and got_switch) then
local attribute_name = self:GetInstanceAttributeText()
self:InstanceAlert (string.format (Loc ["STRING_SWITCH_WARNING"], attribute_name), {[[Interface\AddOns\Details\images\sword]], 18, 18, false}, 4)
end
if (self.switch_all_roles_after_wipe and not nowipe) then
@@ -1205,36 +1219,51 @@ function _detalhes:CheckSwitchOnCombatEnd (nowipe)
end
function _detalhes:CheckSwitchOnLogon()
function _detalhes:CheckSwitchOnLogon (warning)
for index, instancia in ipairs (_detalhes.tabela_instancias) do
if (instancia.ativa) then
instancia:CheckSwitchOnCombatEnd (true)
instancia:CheckSwitchOnCombatEnd (true, warning)
end
end
end
function _detalhes:CheckSwitchOnCombatStart()
function _detalhes:CheckSegmentForSwitchOnCombatStart()
end
function _detalhes:CheckSwitchOnCombatStart (check_segment)
self:SwitchBack()
local all_roles = self.switch_all_roles_in_combat
local role = _UnitGroupRolesAssigned ("player")
local got_switch = false
if (role == "DAMAGER" and self.switch_damager_in_combat) then
self:SwitchTo (self.switch_damager_in_combat)
got_switch = true
elseif (role == "HEALER" and self.switch_healer_in_combat) then
self:SwitchTo (self.switch_healer_in_combat)
got_switch = true
elseif (role == "TANK" and self.switch_tank_in_combat) then
self:SwitchTo (self.switch_tank_in_combat)
got_switch = true
elseif (self.switch_all_roles_in_combat) then
self:SwitchTo (self.switch_all_roles_in_combat)
got_switch = true
end
if (check_segment and got_switch) then
if (self:GetSegment() ~= 0) then
self:TrocaTabela (0)
end
end
end
function _detalhes:ExportSkin()