Skip to content

Commit

Permalink
Update for 9.0.5, 2.5.1, 1.13.7
Browse files Browse the repository at this point in the history
  • Loading branch information
Ketho committed May 25, 2021
1 parent 5ae29c4 commit 50d51ef
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 33 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Release AddOn

on:
push:
tags:
- '**'

env:
CF_API_KEY: ${{ secrets.CF_API_KEY }}
WOWI_API_TOKEN: ${{ secrets.WOWI_API_TOKEN }}
GITHUB_OAUTH: ${{ secrets.GITHUB_TOKEN }}

jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1

- uses: BigWigsMods/packager@master
with:
args: -g classic

- uses: BigWigsMods/packager@master
with:
args: -g bcc

- uses: BigWigsMods/packager@master
3 changes: 0 additions & 3 deletions .gitignore

This file was deleted.

16 changes: 4 additions & 12 deletions .pkgmeta
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
package-as: NameplateColors

externals:
Libs/LibStub:
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/LibStub
tag: latest
Libs/CallbackHandler-1.0:
url: svn://svn.wowace.com/wow/callbackhandler/mainline/trunk/CallbackHandler-1.0
tag: latest
Libs/AceConfig-3.0:
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceConfig-3.0
tag: latest
Libs/AceGUI-3.0:
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceGUI-3.0
tag: latest
Libs/LibStub: https://repos.wowace.com/wow/libstub/trunk
Libs/CallbackHandler-1.0: https://repos.wowace.com/wow/callbackhandler/trunk/CallbackHandler-1.0
Libs/AceConfig-3.0: https://repos.curseforge.com/wow/ace3/trunk/AceConfig-3.0
Libs/AceGUI-3.0: https://repos.curseforge.com/wow/ace3/trunk/AceGUI-3.0
14 changes: 7 additions & 7 deletions NameplateColors.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ local NAME, S = ...
local ACR = LibStub("AceConfigRegistry-3.0")
local ACD = LibStub("AceConfigDialog-3.0")
local db
local isClassic = (WOW_PROJECT_ID == WOW_PROJECT_CLASSIC)
local isRetail = (WOW_PROJECT_ID == WOW_PROJECT_MAINLINE)

local defaults = {
db_version = 1.3,
Expand Down Expand Up @@ -189,7 +189,7 @@ local options = {
},
spacing2 = {type = "description", order = 4, name = ""},
nameplatesize = {
type = "range", order = 5, hidden = isClassic,
type = "range", order = 5, hidden = not isRetail,
width = "double", desc = OPTION_TOOLTIP_UNIT_NAMEPLATES_MAKE_LARGER,
name = UNIT_NAMEPLATES_MAKE_LARGER,
get = function(i) return tonumber(GetCVar("NamePlateHorizontalScale")) end,
Expand Down Expand Up @@ -227,7 +227,7 @@ local options = {
func = function()
NameplateColorsDB = CopyTable(defaults)
db = NameplateColorsDB
if not isClassic then
if isRetail then
SetNameplateSize(defaults.nameplatesize)
end
SetFontSize(defaults.namesize)
Expand Down Expand Up @@ -285,7 +285,7 @@ function f:SetupNameplates()

if ShouldShowName(frame) then
-- not sure anymore what colorNameBySelection is for in retail and why its disabled in classic
if isClassic or frame.optionTable.colorNameBySelection then
if not isRetail or frame.optionTable.colorNameBySelection then
if UnitIsPlayer(frame.unit) then
local name = GetUnitName(frame.unit)
local faction = UnitFactionGroup(frame.unit)
Expand Down Expand Up @@ -315,20 +315,20 @@ function f:SetupNameplates()
local _, class = UnitClass(frame.unit)
local reaction = flag.."nameplate"
local color = db[reaction] == 1 and CLASS_COLORS[class] or db[reaction.."color"]
local r, g, b = color.r, color.g, color.b
local r, g, b = color.r, color.g, color.b
frame.healthBar:SetStatusBarColor(r, g, b)
end

-- can use nameplateShowOnlyNames but it controls both enemy and friendly
local alpha = db[flag.."nameplate"] == 3 and 0 or 1
frame.healthBar:SetAlpha(alpha) -- name-only option
if not isClassic then
if isRetail then
frame.ClassificationFrame:SetAlpha(alpha) -- also hide that elite dragon icon
end
end)

-- override when set through the Blizzard options
if not isClassic then
if isRetail then
hooksecurefunc(InterfaceOptionsNamesPanelUnitNameplatesMakeLarger, "setFunc", function(value)
SetNameplateSize(value == "1" and (db.nameplatesize>1 and db.nameplatesize or 1.4) or 1)
end)
Expand Down
18 changes: 7 additions & 11 deletions NameplateColors.toc
Original file line number Diff line number Diff line change
@@ -1,24 +1,20 @@
#@retail@
## Interface: 80205
#@end-retail@
#@non-retail@
# ## Interface: 11302
#@end-non-retail@
## Interface-Retail: 90005
## Interface-Classic: 11307
## Interface-BCC: 20501
## Version: @project-version@
## Title: NameplateColors
## Notes: Colors friendly and enemy nameplates
## Author: Ketho @ EU-Boulderfist
## SavedVariables: NameplateColorsDB
## OptionalDeps: Ace3
## X-Embeds: Ace3
## X-Curse-Project-ID: 101116
## X-WoWI-ID: 24050

#@no-lib-strip@
Libs\LibStub\LibStub.lua
Libs\CallbackHandler-1.0\CallbackHandler-1.0.xml
Libs\AceGUI-3.0\AceGUI-3.0.xml
Libs\AceConfig-3.0\AceConfig-3.0.xml
#Libs\LibStub\LibStub.lua
#Libs\CallbackHandler-1.0\CallbackHandler-1.0.xml
#Libs\AceGUI-3.0\AceGUI-3.0.xml
#Libs\AceConfig-3.0\AceConfig-3.0.xml
#@end-no-lib-strip@

NameplateColors.lua

0 comments on commit 50d51ef

Please sign in to comment.