vrtc / chorus (public) (License: CC0) (since 2023-08-12) (hash sha1)
World of Warcraft add-on stub. The overall goal is to create a specialized raid frame.
List of commits:
Subject Hash Author Date (UTC)
feat: Add threat percentage for hostiles 590bc95167dfc0f22a135fe173182104b6f5b923 Vladyslav Bondarenko 2023-08-22 13:17:57
feat: Add threat for hostiles 22562481a0c9dfb297ebbe47da4aa19046cf6eeb Vladyslav Bondarenko 2023-08-21 22:28:50
fix(build): Add more luacheck definitions aac4bb444d894b5d565af3abe417cbafd4f966f5 Vladyslav Bondarenko 2023-08-21 18:09:50
fix: Ensure TargetFrame is hidden 98bd355e604bf1c51791d5f5874ef33ab640123c Vladyslav Bondarenko 2023-08-21 14:04:40
fix: Show only meaningful numbers for health 37217b1dc78c0a2b4711dc45ada0c4873e904a1f Vladyslav Bondarenko 2023-08-21 13:32:19
fix: Remove testing range frame 4fcfd5c7bf4626137a1251cbcbe54157055ac875 Vladyslav Bondarenko 2023-08-21 13:10:16
fix: Place solo frames range frame correctly f926b1fb857a48b14a706926f14b5da730d210f1 Vladyslav Bondarenko 2023-08-21 13:08:42
feat!: Re-add player solo frames bf5346aa96a3daeadafeb3a723f7821012f1d5e5 Vladyslav Bondarenko 2023-08-21 12:22:48
fix: Render raid target icon on correct layer 890bb5340a3876b611f67ac1277cc009e5e4df5b Vladyslav Bondarenko 2023-08-20 18:12:31
feat: Display health deficit 0620038bf95d2c8e77eb088f2345764f428563d4 Vladyslav Bondarenko 2023-08-20 17:55:49
fix(build): Update rockspec dcffb9897deb97fa4039cd4513a51e397ebc4ab7 Vladyslav Bondarenko 2023-08-20 17:16:25
feat!: Update raid frame layout ad51f7e37e8babd30ee45c5b87d931a09c1fc0f3 Vladyslav Bondarenko 2023-08-20 14:45:38
fix: Do not show range to oneself c055a76806c5646e4027698c6a105f06199be4ae Vladyslav Bondarenko 2023-08-20 04:29:32
feat!: Add raid targeting icons 53121d5d75fb55d745734337ab70283496e46e7c Vladyslav Bondarenko 2023-08-19 23:22:01
feat!: Add general threat situation widget a002db1c9c810f21fe1e1c042a435875bbe5f317 Vladyslav Bondarenko 2023-08-19 22:20:58
fix!: Highlight offline players 7c28b6efa34f6e5450d2999acfd5a54880aa6df0 Vladyslav Bondarenko 2023-08-19 21:06:38
fix!: Change aura sorting ba249c7309ccbcb14fea727b347c3dd532af73ee Vladyslav Bondarenko 2023-08-19 20:40:31
feat: Show player in party 198e8c86b9b93dd9c3edf7045d5bbcb9142d76d6 Vladyslav Bondarenko 2023-08-19 20:38:40
feat(doc)!: Add project description 4b406a549e83dda3845104e8a6a233eae481a3c8 Vladyslav Bondarenko 2023-08-19 05:58:50
fix: Typo in ChorusRaidFrame 61fb4f93c227e3b94a52df26eeffece12fe86e55 Vladyslav Bondarenko 2023-08-18 21:00:34
Commit 590bc95167dfc0f22a135fe173182104b6f5b923 - feat: Add threat percentage for hostiles
Show detailed threat percentage for enemy creatures in addition to the
overall threat situation color coded indicator.

Additionally fix minor threat situation update issues. For example
update threat situation correctly for target frame when player switches
targets.
Author: Vladyslav Bondarenko
Author date (UTC): 2023-08-22 13:17
Committer name: Vladyslav Bondarenko
Committer date (UTC): 2023-08-22 13:17
Parent(s): 22562481a0c9dfb297ebbe47da4aa19046cf6eeb
Signer:
Signing key: EFF9624877D25D02
Signing status: E
Tree: 5bd1d2ac17458dfd08e2fb60f109af243442b2e9
File Lines added Lines deleted
etc/luacheckrc.lua 3 2
src/ChorusThreatFrameTemplate.lua 24 3
src/ChorusThreatFrameTemplate.xml 14 2
File etc/luacheckrc.lua changed (mode: 100644) (index ca5be7a..1a5738c)
3 3 --[[ Functions defined in World of Warcraft client Lua environment. It is --[[ Functions defined in World of Warcraft client Lua environment. It is
4 4 distinct from default Lua 5.1 environment. For example, `os` package is distinct from default Lua 5.1 environment. For example, `os` package is
5 5 excluded. Only globals used by this project are included, therefore the list is excluded. Only globals used by this project are included, therefore the list is
6 only a subset and not extensive. ]]--
6 only a subset and not exhaustive. ]]--
7 7
8 8 stds.wowapi = { stds.wowapi = {
9 9 read_globals = { read_globals = {
 
... ... stds.wowapi = {
18 18 'IsSpellInRange', 'IsSpellInRange',
19 19 'UnitAura', 'UnitAura',
20 20 'UnitClass', 'UnitClass',
21 'UnitDetailedThreatSituation',
21 22 'UnitExists', 'UnitExists',
22 23 'UnitGUID', 'UnitGUID',
23 24 'UnitHealth', 'UnitHealth',
 
... ... stds.framexml = {
107 108 }, },
108 109 } }
109 110
110 --[[ Functions and globals defined by authors of this add-on. This list is not extensive. ]]--
111 --[[ Functions and globals defined by authors of this add-on. This list is not exhaustive. ]]--
111 112
112 113 stds.chorus = { stds.chorus = {
113 114 read_globals = { read_globals = {
File src/ChorusThreatFrameTemplate.lua changed (mode: 100644) (index ca8a4f0..75edb4b)
... ... local function threatFrameEventProcessor(self)
23 23 return return
24 24 end end
25 25
26 local threatStatus
26 local threatStatus, threatPercentage
27 27
28 28 local owner = 'player' local owner = 'player'
29 29 if UnitIsFriend(owner, u) then if UnitIsFriend(owner, u) then
30 30 threatStatus = UnitThreatSituation(u) threatStatus = UnitThreatSituation(u)
31 31 else else
32 _, threatStatus = UnitDetailedThreatSituation(owner, u)
32 local _, threatStatus0, threatPercentage0 = UnitDetailedThreatSituation(owner, u)
33 threatStatus = threatStatus0
34 threatPercentage = threatPercentage0
33 35 end end
34 36
35 37 local r = 0 local r = 0
 
... ... local function threatFrameEventProcessor(self)
45 47 local artwork = self.artwork local artwork = self.artwork
46 48 assert (artwork ~= nil) assert (artwork ~= nil)
47 49 artwork:SetVertexColor(r, g, b, a) artwork:SetVertexColor(r, g, b, a)
50
51 local label = self.label or _G[self:GetName() .. 'Text']
52 if label and threatPercentage then
53 assert('number' == type(threatPercentage))
54
55 threatPercentage = math.min(math.max(0, math.abs(math.floor(threatPercentage)), 100))
56
57 assert(threatPercentage >= 0)
58 assert(threatPercentage <= 100)
59
60 label:SetText(string.format('%d%%', threatPercentage))
61 elseif label then
62 label:SetText(nil)
63 end
48 64 end end
49 65
50 66 local function threatFrameMain(self) local function threatFrameMain(self)
 
... ... local function threatFrameMain(self)
54 70 assert(artwork ~= nil) assert(artwork ~= nil)
55 71 self.artwork = artwork self.artwork = artwork
56 72
57 self:RegisterEvent('UNIT_THREAT_SITUATION_UPDATE')
73 self:RegisterEvent('PARTY_MEMBERS_CHANGED')
74 self:RegisterEvent('PLAYER_ALIVE')
58 75 self:RegisterEvent('PLAYER_ENTERING_WORLD') self:RegisterEvent('PLAYER_ENTERING_WORLD')
76 self:RegisterEvent('PLAYER_FOCUS_CHANGED')
77 self:RegisterEvent('PLAYER_TARGET_CHANGED')
78 self:RegisterEvent('RAID_ROSTER_UPDATE')
79 self:RegisterEvent('UNIT_THREAT_SITUATION_UPDATE')
59 80 self:SetScript('OnEvent', threatFrameEventProcessor) self:SetScript('OnEvent', threatFrameEventProcessor)
60 81 end end
61 82
File src/ChorusThreatFrameTemplate.xml changed (mode: 100644) (index d55b8c4..f518ae7)
3 3 <Script file="ChorusThreatFrameTemplate.lua"/> <Script file="ChorusThreatFrameTemplate.lua"/>
4 4 <Frame name="ChorusThreatFrameTemplate" virtual="true"> <Frame name="ChorusThreatFrameTemplate" virtual="true">
5 5 <Size> <Size>
6 <AbsDimension x="16" y="16" />
6 <AbsDimension x="48" y="16" />
7 7 </Size> </Size>
8 8 <Layers> <Layers>
9 9 <Layer level="ARTWORK"> <Layer level="ARTWORK">
10 <Texture name="$parentArtwork" file="Interface\RaidFrame\UI-RaidFrame-Threat" setAllPoints="true"/>
10 <Texture name="$parentArtwork" file="Interface\RaidFrame\UI-RaidFrame-Threat">
11 <Size>
12 <AbsDimension x="16" y="16" />
13 </Size>
14 <Anchors>
15 <Anchor point="BOTTOMLEFT">
16 <Offset x="0" y="0"/>
17 </Anchor>
18 </Anchors>
19 </Texture>
20 </Layer>
21 <Layer level="OVERLAY">
22 <FontString name="$parentText" inherits="ChorusFont12Mono" setAllPoints="true" justifyH="RIGHT" justifyV="MIDDLE"/>
11 23 </Layer> </Layer>
12 24 </Layers> </Layers>
13 25 <Scripts> <Scripts>
Hints:
Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://rocketgit.com/user/vrtc/chorus

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@ssh.rocketgit.com/user/vrtc/chorus

Clone this repository using git:
git clone git://git.rocketgit.com/user/vrtc/chorus

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a merge request:
... clone the repository ...
... make some changes and some commits ...
git push origin main