Navigation Menu

Skip to content

Commit

Permalink
78
Browse files Browse the repository at this point in the history
+ movable castbar option
+ cursor tooltip option
+ auto fishing pole equip
+ right-click raid frame to tag a unit as a tank
+ rare/elite borders now displayed in original colour (silver/gold
respectively) over custom coloured unitframe border
+ class coloured battleground scoreboard names
+ druid mana bar
+ fixed druid energy ticker
+ fixed nameplate castbar offset
+ latest version of healcomm
+ save clock display preference between sessions
- occasional error message from non-player spell casts
- issue that sometimes caused disconnect when selling grey items
- conflict with RingMenu
  • Loading branch information
obble committed Jan 23, 2017
1 parent 673e5b2 commit 3f5f527
Show file tree
Hide file tree
Showing 34 changed files with 1,724 additions and 2,239 deletions.
27 changes: 20 additions & 7 deletions castbar/castbar.lua
Expand Up @@ -13,7 +13,8 @@
['Aimed Shot'] = [[Interface\Icons\inv_spear_07]]
}

orig.UseAction = UseAction
orig.UseAction = UseAction
orig.CastingBarFrame_OnEvent = CastingBarFrame_OnEvent

CastingBarFrame:SetStatusBarTexture(TEXTURE)

Expand Down Expand Up @@ -64,7 +65,7 @@

local ToggleIcon = function()
local t = CastingBarText:GetText()
if (not CastingBarFrame.hasIcon and not overrideIcons[t]) then
if not t or (not CastingBarFrame.hasIcon and not overrideIcons[t]) then
CastingBarFrame.Icon:Hide()
else
CastingBarFrame.Icon:Show()
Expand All @@ -75,18 +76,20 @@
end

local HideIcon = function()
if this.hasIcon then
this.hasIcon = false
if CastingBarFrame.hasIcon then
CastingBarFrame.hasIcon = false
end
end

UseAction = function(slot, target, button)
orig.UseAction(slot, target, button)
if CastingBarFrame:GetAlpha() < 1 or not CastingBarFrame:IsShown() then
local icon = GetActionTexture(slot)
CastingBarFrame.Icon.Texture:SetTexture(icon)
CastingBarFrame.hasIcon = true
CastingBarFrame:SetScript('OnHide', HideIcon)
if icon then
CastingBarFrame.hasIcon = true
CastingBarFrame.Icon.Texture:SetTexture(icon)
CastingBarFrame:SetScript('OnHide', HideIcon)
end
ToggleIcon()
end
end
Expand All @@ -95,6 +98,16 @@
PlayerCastingBarFrame()
end

CastingBarFrame_OnEvent = function()
orig.CastingBarFrame_OnEvent()
if event == 'SPELLCAST_STOP'
or event == 'SPELLCAST_CHANNEL_STOP'
or event == 'SPELLCAST_FAILED'
or event == 'SPELLCAST_INTERRUPTED' then
HideIcon()
end
end

CastingBarFrame:SetScript('OnShow', ToggleIcon)


Expand Down
4 changes: 4 additions & 0 deletions dark/dark.lua
Expand Up @@ -361,6 +361,10 @@
local _, a = SW_IconFrame_Button:GetRegions()
table.insert(MODUI_COLOURELEMENTS_FOR_UI, a)
end
if IsAddOnLoaded'DPSMate' then -- DPSMATE
local _, a = DPSMate_MiniMap:GetRegions()
table.insert(MODUI_COLOURELEMENTS_FOR_UI, a)
end
if arg1 == 'Blizzard_AuctionUI' then -- AUCTION
local _, a, b, c, d, e, f = AuctionFrame:GetRegions()
for _, v in pairs({a, b, c, d, e, f}) do
Expand Down
6 changes: 4 additions & 2 deletions globals/arrange.lua
Expand Up @@ -120,8 +120,10 @@
parent:SetPoint('BOTTOMRIGHT', MainMenuBarBackpackButton, 'TOPRIGHT', 3, 16)
end
end
while ContainerFrame1.bags[i] and tonumber(GetCVar'modOneBag') == 1 do
local f = _G[ContainerFrame1.bags[i]]
if tonumber(GetCVar'modShowTooltipCursor') == 1 then
GameTooltip:SetOwner(UIParent, 'ANCHOR_CURSOR')
end
while (ContainerFrame1.bags[i] and tonumber(GetCVar'modOneBag') == 1) do
GameTooltip:SetOwner(UIParent, 'ANCHOR_CURSOR')
i = i + 1
end
Expand Down
33 changes: 32 additions & 1 deletion globals/mount.lua
Expand Up @@ -16,12 +16,43 @@
end
end

local fishing = function()
for bag = 0, NUM_BAG_SLOTS do
for slot = 1, GetContainerNumSlots(bag) do
local link = GetContainerItemLink(bag, slot)
if link then
local _, _, istring = string.find(link, '|H(.+)|h')
local n = GetItemInfo(istring)
if n and (string.find(n, 'Fishing Pole') or string.find(n, 'FC-5000')) then
UseContainerItem(bag, slot)
print'|cff4c8d00Your Fishing Pole has been equipped.|r'
break
end
end
end
end
end

local shapeshift = function()
for i = 1, GetNumShapeshiftForms() do
local _, name, active = GetShapeshiftFormInfo(i)
if active ~= nil then
CastShapeshiftForm(i)
break
end
end
end

local f = CreateFrame'Frame'
f:RegisterEvent'UI_ERROR_MESSAGE' f:RegisterEvent'GOSSIP_SHOW'
f:SetScript('OnEvent', function()
if event =='UI_ERROR_MESSAGE' then
if event =='UI_ERROR_MESSAGE' then
if string.find(arg1, 'mounted') or string.find(arg1, 'while silenced') then
dismount()
elseif string.find(arg1, 'Fishing Pole') then
fishing()
elseif string.find(arg1, 'shapeshift') then
shapeshift()
end
else
local _, g1 = GetGossipOptions()
Expand Down
3 changes: 2 additions & 1 deletion globals/shit.lua
Expand Up @@ -17,7 +17,7 @@

local update = function()
bu.last = bu.last + arg1
if bu.last > TOOLTIP_UPDATE_TIME then
if bu.last > .05 then
local i = table.getn(bu.junk)
if i > 0 then
UseContainerItem(bu.junk[i][1], bu.junk[i][2])
Expand All @@ -42,6 +42,7 @@
end
end
end
print'|cff4c8d00Selling poor quality or trash items.|r'
bu:SetScript('OnUpdate', update)
end)

Expand Down
17 changes: 10 additions & 7 deletions globals/table.lua
Expand Up @@ -33,29 +33,29 @@
['Clone'] = {[[Interface\Icons\spell_shadow_blackplague]], 2.5},
['Creeping Mold'] = {[[Interface\Icons\spell_shadow_creepingplague]], 3},
['Cripple'] = {[[Interface\Icons\spell_shadow_cripple]], 3},
['Crystal Flash'] = {[[Interface\Icons\spell_shadow_teleport]], 2, true},
['Crystal Gaze'] = {[[Interface\Icons\ability_golemthunderclap]], 2, true},
['Crystalline Slumber'] = {[[Interface\Icons\spell_nature_sleep]], 2, true},
['Crystal Flash'] = {[[Interface\Icons\spell_shadow_teleport]], 2},
['Crystal Gaze'] = {[[Interface\Icons\ability_golemthunderclap]], 2},
['Crystalline Slumber'] = {[[Interface\Icons\spell_nature_sleep]], 2},
['Cultivate Packet of Seeds'] = {[[Interface\Icons\inv_misc_food_45]], 10},
['Curse of Mending'] = {[[Interface\Icons\spell_shadow_antishadow]], 1},
['Curse of the Deadwood'] = {[[Interface\Icons\spell_shadow_gathershadows]], 2},
['Curse of the Fallen Magram'] = {[[Interface\Icons\spell_shadow_unholyfrenzy]], 2},
['Dark Sludge'] = {[[Interface\Icons\spell_shadow_creepingplague]], 5},
['Dire Growl'] = {[[Interface\Icons\ability_racial_cannibalize]], 1, true},
['Dire Growl'] = {[[Interface\Icons\ability_racial_cannibalize]], 1},
['Fevered Fatigue'] = {[[Interface\Icons\spell_nature_nullifydisease]], 3},
['Fire Shield II'] = {[[Interface\Icons\spell_fire_immolation]], 1},
['Flame Spike'] = {[[Interface\Icons\spell_fire_flamebolt]], 3},
['Flamespit'] = {[[Interface\Icons\spell_fire_selfdestruct]], 3},
['Freeze Solid'] = {[[Interface\Icons\spell_frost_glacier]], 2.5},
['Furbolg Form'] = {[[Interface\Icons\Inv_misc_monsterclaw_04]], 2, true},
['Diseased Slime'] = {[[Interface\Icons\spell_shadow_creepingplague]], 2, true},
['Furbolg Form'] = {[[Interface\Icons\Inv_misc_monsterclaw_04]], 2},
['Diseased Slime'] = {[[Interface\Icons\spell_shadow_creepingplague]], 2},
['Disenchant'] = {[[Interface\Icons\Inv_Enchant_Disenchant]], 3},
['Drink Minor Potion'] = {[[Interface\Icons\Spell_holy_heal]], 3},
['Dynamite'] = {[[Interface\Icons\spell_fire_selfdestruct]], 1},
['Earthgrab Totem'] = {[[Interface\Icons\spell_nature_naturetouchdecay]], .5},
['Exploding Shot'] = {[[Interface\Icons\spell_fire_fireball02]], 1},
['Icicle'] = {[[Interface\Icons\spell_frost_frostbolt02]], 1.5},
['Ink Spray'] = {[[Interface\Icons\spell_nature_sleep]], 1, true},
['Ink Spray'] = {[[Interface\Icons\spell_nature_sleep]], 1},
['Healing Ward'] = {[[Interface\Icons\spell_holy_layonhands]], 2},
['Holy Smite'] = {[[Interface\Icons\Spell_holy_holysmite]], 2.5},
['Lizard Bolt'] = {[[Interface\Icons\spell_nature_lightning]], 2},
Expand Down Expand Up @@ -351,6 +351,7 @@
['Wyvern Sting'] = true,
}

-- TODO: DR/decay
MODUI_BUFFS_TO_TRACK = {
-- MISC
['Invulnerability'] = {[[Interface\Icons\Spell_holy_divineintervention]], 6},
Expand Down Expand Up @@ -388,6 +389,7 @@
['Power Word: Shield'] = {[[Interface\Icons\Spell_holy_powerwordshield]], 30},
-- ROGUE
['Vanish'] = {[[Interface\Icons\Ability_vanish]], 10},
['Gouge'] = {[[Interface\Icons\Ability_gouge]], 5}
-- WARLOCK
-- ['Shadow Trance'] = {'Interface\\Icons\\Spell_shadow_twilight', 10},
}
Expand Down Expand Up @@ -427,6 +429,7 @@
['Cheap Shot'] = {[[Interface\Icons\Ability_cheapshot]], 5, 'None'},
['Gouge'] = {[[Interface\Icons\Ability_gouge]], 4, 'None'},
['Kidney Shot'] = {[[Interface\Icons\Ability_rogue_kidneyshot]], 6, 'None'},
['Sap'] = {[[Interface\Icons\Ability_sap]], 11},
-- WARLOCK
['Curse of Exhaustion'] = {[[Interface\Icons\Spell_shadow_grimward]], 12, 'Curse'},
['Curse of Tongues'] = {[[Interface\Icons\Spell_shadow_curseoftounges]], 30, 'Curse'},
Expand Down
15 changes: 7 additions & 8 deletions libs/healcomm/Healcomm.lua → libs/healcomm/HealComm.lua
Expand Up @@ -44,32 +44,31 @@ local function onEvent(unitname)
if UnitName("target") == unitname then
onHeal("target")
end
local unitobj = roster:GetUnitObjectFromName(unitname)
local unit = unitobj.unitid
if not unit then
local unitobj = roster:GetUnitObjectFromName(name)
if not unitobj or not unitobj.unitid then
return
end
if UnitIsUnit("player", unit) then
if UnitIsUnit("player", unitobj.unitid) then
onHeal("player")
else
for i=1, 4 do
if UnitIsUnit("party"..i, unit) then
if UnitIsUnit("party"..i, unitobj.unitid) then
onHeal("party"..i)
end
end
end
if UnitInRaid("player") then
local header = GROUP.." "..unitobj.subgroup
local classheader = UnitClass(unit)
local classheader = UnitClass(unitobj.unitid)
local frame, unitframe
for i=1, NUM_RAID_PULLOUT_FRAMES do
frame = getglobal("RaidPullout"..i.."Name")
if frame:GetText() == header or frame:GetText() == classheader then
frame = getglobal("RaidPullout"..i)
for z=1, frame.numPulloutButtons do
unitframe = getglobal(frame:GetName().."Button"..z)
if unitframe.unit == unit then
onHeal(unit, getglobal(unitframe:GetName().."HealthBar"))
if unitframe.unit == unitobj.unitid then
onHeal(unitobj.unitid, getglobal(unitframe:GetName().."HealthBar"))
end
end
end
Expand Down

0 comments on commit 3f5f527

Please sign in to comment.