Skip to content

Commit 89a4086

Browse files
authored
Merge pull request #31 from Puresyn/development
Development 1.0.2
2 parents fa7dc25 + d398ac6 commit 89a4086

18 files changed

+97
-16
lines changed
0 Bytes
Binary file not shown.

Core/Coms.lua

+15-8
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ end
3636
-- Serialize communication data:
3737
-- Can communitcate over whatever default channels are avaialable via hidden Addons subchannel.
3838
function MyAddon:Transmit(data)
39+
if not IsInGroup(LE_PARTY_CATEGORY_HOME) then return end -- Make sure you have a home party (local) group
3940
local serialized = LibSerialize:Serialize(data)
4041
local compressed = LibDeflate:CompressDeflate(serialized)
4142
local encoded = LibDeflate:EncodeForWoWAddonChannel(compressed)
@@ -49,6 +50,7 @@ end
4950

5051
-- sends request to party members to transmit their data
5152
function MyAddon:TransmitRequest(requestData)
53+
if not IsInGroup(LE_PARTY_CATEGORY_HOME) then return end -- Make sure you have a home party (local) group
5254
if requestData == nil or requestData.requestType == nil then
5355
KeyMaster:_DebugMsg("TransmitRequest", "Coms", "Received invalid data request type.")
5456
return
@@ -143,8 +145,10 @@ local function processOpenRaidData(payload, sender)
143145
senderData.mythicPlusRating = tonumber(dataAsTable[5])
144146
isDirty = true
145147

146-
KeyMaster:_DebugMsg("processOpenRaidData", "Coms", "Received initial data from OpenRaid for "..sender)
147-
UnitData:SetUnitData(senderData)
148+
if UnitData:GetUnitDataByGUID(senderData.GUID) == nil then
149+
KeyMaster:_DebugMsg("processOpenRaidData", "Coms", "Received initial data from OpenRaid for "..sender)
150+
UnitData:SetUnitData(senderData)
151+
end
148152
end
149153
end
150154
else
@@ -155,8 +159,10 @@ local function processOpenRaidData(payload, sender)
155159
senderData.mythicPlusRating = tonumber(dataAsTable[5])
156160
isDirty = true
157161

158-
KeyMaster:_DebugMsg("processOpenRaidData", "Coms", "Received updated data from OpenRaid for "..sender)
159-
UnitData:SetUnitData(senderData)
162+
if UnitData:GetUnitDataByGUID(senderData.GUID) == nil then
163+
KeyMaster:_DebugMsg("processOpenRaidData", "Coms", "Received updated data from OpenRaid for "..sender)
164+
UnitData:SetUnitData(senderData)
165+
end
160166
end
161167
end
162168

@@ -222,21 +228,22 @@ local function processKM2Data(payload, sender)
222228
KeyMaster:_DebugMsg("processKM2Data", "Coms", sender.." has incompatible ("..buildVersion..") data. Aborting mapping.")
223229
return
224230
end
231+
checkVersion(data)
232+
233+
-- if we're in an instance party we don't want to process other people's data or make ui changes
234+
if IsInGroup(LE_PARTY_CATEGORY_INSTANCE) then return end
225235

226236
KeyMaster:_DebugMsg("processKM2Data", "Coms", "Received data from "..sender.." using KM version v"..buildVersion)
227237
data.hasAddon = true
228238
UnitData:SetUnitData(data)
229-
239+
230240
-- Only update UI if party tab is open
231241
local partyTabContentFrame = _G["KeyMaster_PartyScreen"]
232242
if partyTabContentFrame ~= nil and partyTabContentFrame:IsShown() then
233243
PartyFrameMapping:UpdateSingleUnitData(data.GUID)
234244
PartyFrameMapping:UpdateKeystoneHighlights()
235245
PartyFrameMapping:CalculateTotalRatingGainPotential()
236246
end
237-
238-
239-
checkVersion(data)
240247
end
241248

242249
-- Deserialize communication data:

Core/Localization/Localization.deDE.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Spieler offline", text = "Spieler offl
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Gruppensteigerungspotenzial", text = "Geschätzte Gruppenwertungssteigerung"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Steigerungspotenzial", text = "Geschätzte persönlicher Wertungssteigerung für verfügbare Schlüssel bei +1 Abschluss."}
112112
L.PARTYFRAME["NoKey"] = { name = "Kein Schlüsselstein", text = "Kein Schlüsselstein"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Informationen über Gruppenmitglieder sind in Matchmaking-Gruppen nicht verfügbar. (Dungeonbrowser, Schlachtzugsbrowser, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Schlüsselsteinstufe", text = "Zu berechnendes Schlüsselsteinniveau."}

Core/Localization/Localization.enUS.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Player Offline", text = "Player is off
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Party Gain Potential", text = "Estimated Party Rating Gain"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Gain Potential", text = "Estimated personal point gain for available key(s) at +1 completion."}
112112
L.PARTYFRAME["NoKey"] = { name = "No Key", text = "No Key"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Party member information unavailable in matchmaking groups. (Dungeon Finder, Raid Finder, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Key Level", text = "Key level to be calculated."}

Core/Localization/Localization.ptBR.lua

+2-1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Jogador Offline", text = "Jogador offl
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Potencial de ganho do grupo", text = "Ganho estimado do grupo"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Potencial de ganho", text = "Estimativa pessoal de ganho de pontos para as chaves disponíveis na conclusão +1."}
112112
L.PARTYFRAME["NoKey"] = { name = "Nenhuma chave", text = "Nenhuma chave"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Informação dos jogadores da equipe indisponível em formador de grupo. (Localizador de Masmorras, Localizador de Raides, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Nível da chave", text = "Nível da chave à ser calculado."}
@@ -143,7 +144,7 @@ L.ABOUTFRAME["AboutGeneral"] = { name = "Informações Key Master", text = "Info
143144
L.ABOUTFRAME["AboutAuthors"] = { name = "Autores", text = "Autores"}
144145
L.ABOUTFRAME["AboutSpecialThanks"] = { name = "Agradecimentos Especiais", text = "Agradecimentos Especiais"}
145146
L.ABOUTFRAME["AboutContributors"] = { name = "Contribuidores", text = "Contribuidores"}
146-
L.ABOUTFRAME["Translators"] = { text = "Translators" }
147+
L.ABOUTFRAME["Translators"] = { text = "Tradutores" }
147148

148149
L.SYSTEMMESSAGE = {}
149150
L.SYSTEMMESSAGE["NOTICE"] = { text = "Importante: Os cálculos para a 4a temporada de Dragonflight ainda estão sendo verificados."}

Core/Localization/Localization.ruRU.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Игрок оффлайн", text = "И
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Потенциальный групповой прирост", text = "Потенциальный прирост группового рейтинга"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Вероятность прироста", text = "Предполагаемый прирост личных очков за доступные ключи при завершении их на +1"}
112112
L.PARTYFRAME["NoKey"] = { name = "Нет ключа", text = "Нет ключа"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Информация о членах группы недоступна в группах подбора игроков. (Поиск подземелий, Поиск рейдов и т.д.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Уровень ключа", text = "Уровень ключа, подлежащий расчету"}

Core/Localization/Localization.zhTW.lua

+2-1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "玩家離線", text = "玩家已離線
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "隊伍收益預估", text = "預估隊伍評分收益"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "收益預估", text = "預估個人分數收益,當完成 +1 的可用鑰石時。"}
112112
L.PARTYFRAME["NoKey"] = { name = "無鑰石", text = "無鑰石"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "隊伍成員資訊在配對隊伍中不可用。 (地城搜尋器, 團隊搜尋器, 等等。)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "鑰石層級", text = "要計算的鑰石層級。"}
@@ -143,7 +144,7 @@ L.ABOUTFRAME["AboutGeneral"] = { name = "Key Master 資訊", text = "Key Master
143144
L.ABOUTFRAME["AboutAuthors"] = { name = "作者", text = "作者"}
144145
L.ABOUTFRAME["AboutSpecialThanks"] = { name = "特別感謝", text = "特別感謝"}
145146
L.ABOUTFRAME["AboutContributors"] = { name = "貢獻者", text = "貢獻者"}
146-
L.ABOUTFRAME["Translators"] = { text = "Translators" }
147+
L.ABOUTFRAME["Translators"] = { text = "翻譯者" }
147148

148149
L.SYSTEMMESSAGE = {}
149150
L.SYSTEMMESSAGE["NOTICE"] = { text = "注意: 巨龍崛起第4賽季評分計算仍待驗證。"}

Core/PendingLocalizations/Localization.esES.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Jugador sin conexión", text = "El jug
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Potencial de ganancia grupal", text = "Ganancia estimada de calificación grupal"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Ganar potencial", text = "Ganancia de puntos personales estimada para las claves disponibles al completar +1."}
112112
L.PARTYFRAME["NoKey"] = { name = "No hay llave", text = "No hay llave"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Party member information unavailable in matchmaking groups. (Dungeon Finder, Raid Finder, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Nivel clave", text = "Nivel clave a calcular."}

Core/PendingLocalizations/Localization.esMX.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Jugador sin conexión", text = "El jug
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Potencial de ganancia grupal", text = "Ganancia estimada de calificación grupal"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Ganar potencial", text = "Ganancia de puntos personales estimada para las claves disponibles al completar +1."}
112112
L.PARTYFRAME["NoKey"] = { name = "No hay llave", text = "No hay llave"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Party member information unavailable in matchmaking groups. (Dungeon Finder, Raid Finder, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Nivel clave", text = "Nivel clave a calcular."}

Core/PendingLocalizations/Localization.frFR.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Joueur hors ligne", text = "Le joueur
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Potentiel de gain de groupe", text = "Gain estimé de note de groupe"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Gagner du potentiel", text = "Gain de points personnels estimé pour les clés disponibles à l'achèvement de +1."}
112112
L.PARTYFRAME["NoKey"] = { name = "Pas de clé", text = "Pas de clé"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Party member information unavailable in matchmaking groups. (Dungeon Finder, Raid Finder, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Niveau clé", text = "Niveau clé à calculer."}

Core/PendingLocalizations/Localization.itIT.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Giocatore non in linea", text = "Il gi
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Potenziale di guadagno del partito", text = "Guadagno stimato del rating del partito"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Guadagna potenziale", text = "Guadagno di punti personali stimato per le chiavi disponibili al completamento +1."}
112112
L.PARTYFRAME["NoKey"] = { name = "Nessuna chiave", text = "Nessuna chiave"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Party member information unavailable in matchmaking groups. (Dungeon Finder, Raid Finder, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Livello chiave", text = "Livello chiave da calcolare."}

Core/PendingLocalizations/Localization.zhCN.lua

+1
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ L.PARTYFRAME["PlayerOffline"] = { name = "Player Offline", text = "Player is off
110110
L.PARTYFRAME["TeamRatingGain"] = { name = "Party Gain Potential", text = "Estimated Party Rating Gain"}
111111
L.PARTYFRAME["MemberPointsGain"] = { name = "Gain Potential", text = "Estimated personal point gain for available key(s) at +1 completion."}
112112
L.PARTYFRAME["NoKey"] = { name = "No Key", text = "No Key"}
113+
L.PARTYFRAME["NoPartyInfo"] = { text = "Party member information unavailable in matchmaking groups. (Dungeon Finder, Raid Finder, etc.)" }
113114

114115
L.PLAYERFRAME = {}
115116
L.PLAYERFRAME["KeyLevel"] = { name = "Key Level", text = "Key level to be calculated."}

Core/UI/PartyFrame.lua

+34-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
--------------------------------
2+
-- PartyFrame.lua
3+
-- Handles Party tab interface
4+
-- and interactions.
5+
--------------------------------
6+
17
local _, KeyMaster = ...
28
local MainInterface = KeyMaster.MainInterface
39
local DungeonTools = KeyMaster.DungeonTools
@@ -44,6 +50,32 @@ local function portalButton_mouseoout(self, event, ...)
4450
cdFrame:SetCooldown(0 ,0)
4551
end
4652

53+
-- Party frame notification when party info isn't displayed
54+
function PartyFrame:noPartyInfoNotification(parent)
55+
local noPartyInfo = CreateFrame("Frame", "KM_NoPartyInfo", parent)
56+
noPartyInfo:SetSize(parent:GetWidth()-4, parent:GetHeight()-4)
57+
noPartyInfo:SetPoint("CENTER", parent, "CENTER")
58+
noPartyInfo:SetFrameLevel(parent:GetFrameLevel()+1)
59+
noPartyInfo.text = noPartyInfo:CreateFontString(nil, "OVERLAY", "KeyMasterFontBig")
60+
noPartyInfo.text:SetText(KeyMasterLocals.PARTYFRAME["NoPartyInfo"].text)
61+
noPartyInfo.text:SetPoint("CENTER", noPartyInfo, "CENTER", 60, -90)
62+
noPartyInfo.text:SetWidth(parent:GetWidth()*0.55)
63+
noPartyInfo.text:SetJustifyV("CENTER")
64+
noPartyInfo.text:SetJustifyH("LEFT")
65+
local msgColor = {}
66+
msgColor.r, msgColor.g, msgColor.b, _ = Theme:GetThemeColor("color_POOR")
67+
noPartyInfo.text:SetTextColor(msgColor.r, msgColor.g, msgColor.b, 1)
68+
noPartyInfo.icon = noPartyInfo:CreateTexture()
69+
noPartyInfo.icon:SetTexture("Interface\\Addons\\KeyMaster\\Assets\\Images\\KeyMaster-Interface-Clean")
70+
noPartyInfo.icon:SetTexCoord(916/1024, 1, 216/1024, 322/1024)
71+
noPartyInfo.icon:SetPoint("RIGHT", noPartyInfo.text, "LEFT", -8, 0)
72+
noPartyInfo.icon:SetSize(80, 80)
73+
noPartyInfo.icon:SetAlpha(0.1)
74+
noPartyInfo:Hide()
75+
76+
return noPartyInfo
77+
end
78+
4779
local function createPartyDungeonHeader(anchorFrame, mapId)
4880
if not anchorFrame and mapId then
4981
KeyMaster:_ErrorMsg("createPartyDungeonHeader", "PartyFrame", "No valid parameters passed.")
@@ -138,11 +170,11 @@ local function createPartyDungeonHeader(anchorFrame, mapId)
138170
local pButton = CreateFrame("Button","portal_button"..mapId,temp_frame,"SecureActionButtonTemplate")
139171
pButton:SetAttribute("type", "spell")
140172
pButton:SetAttribute("spell", portalSpellName)
141-
pButton:RegisterForClicks("LeftButtonDown")
173+
pButton:RegisterForClicks("AnyDown")
142174
pButton:SetWidth(pButton:GetParent():GetWidth())
143175
pButton:SetHeight(pButton:GetParent():GetWidth())
144176
pButton:SetPoint("TOPLEFT", temp_frame, "TOPLEFT", 0, 0)
145-
pButton:SetScript("OnMouseUp", portalButton_buttonevent)
177+
pButton:SetScript("OnMouseDown", portalButton_buttonevent)
146178
pButton:SetScript("OnEnter", portalButton_mouseover)
147179
pButton:SetScript("OnLeave", portalButton_mouseoout)
148180

Core/UI/PartyFrameMapping.lua

+11-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ local partyFrameLookup = {
1515
}
1616

1717
function PartyFrameMapping:ShowPartyRow(unitId)
18-
_G[partyFrameLookup[unitId]]:Show()
18+
_G[partyFrameLookup[unitId]]:Show()
1919
end
2020

2121
function PartyFrameMapping:HidePartyRow(unitId)
@@ -369,6 +369,15 @@ function PartyFrameMapping:UpdateSingleUnitData(unitGUID)
369369
end
370370

371371
function PartyFrameMapping:UpdatePartyFrameData()
372+
if IsInGroup(LE_PARTY_CATEGORY_INSTANCE) then
373+
PartyFrameMapping:HideAllPartyFrame()
374+
PartyFrameMapping:ResetTallyFramePositioning()
375+
if _G["KM_NoPartyInfo"] then _G["KM_NoPartyInfo"]:Show() end
376+
-- Show explination frame
377+
return
378+
end
379+
380+
if _G["KM_NoPartyInfo"] then _G["KM_NoPartyInfo"]:Hide() end
372381
local partyMembers = {"player", "party1", "party2", "party3", "party4"}
373382
for _,unitId in pairs(partyMembers) do
374383
local unitGuid = UnitGUID(unitId)
@@ -380,5 +389,5 @@ function PartyFrameMapping:UpdatePartyFrameData()
380389
end
381390
PartyFrameMapping:UpdateKeystoneHighlights()
382391
PartyFrameMapping:CalculateTotalRatingGainPotential()
383-
PartyFrameMapping:ResetTallyFramePositioning()
392+
PartyFrameMapping:ResetTallyFramePositioning()
384393
end

Core/UI/UIinit.lua

+1
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ function MainInterface:Initialize()
5151

5252
-- Party Tab Content
5353
local partyTabContent = PartyFrame:Initialize(contentRegion)
54+
local partyNotification = _G["KM_NoPartyInfo"] or PartyFrame:noPartyInfoNotification(partyTabContent)
5455

5556
-- Config Tab
5657
local configContent = _G["KM_Configuration_Frame"] or ConfigFrame:CreateConfigFrame(contentRegion)

KeyMaster.lua

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ local PartyFrame = KeyMaster.PartyFrame
1616

1717
-- Global Variables
1818
KM_ADDON_NAME = KeyMasterLocals.ADDONNAME
19-
KM_AUTOVERSION = '1.0.1'
19+
KM_AUTOVERSION = '1.0.2'
2020
KM_VERSION_STATUS = KeyMasterLocals.BUILDRELEASE -- BUILDALPHA BUILDBETA BUILDRELEASE - for display and update notification purposes
2121

2222
--------------------------------

KeyMaster.toc

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
## X-Max-Interface: 100206
33
## X-Min-Interface: 100205
44

5-
## Version: 1.0.1
5+
## Version: 1.0.2
66
## Title: |cffb09c60Key Master|r
77
## Title-ptBR: |cffb09c60Key Master|r
88
## Title-ruRU: |cffb09c60Key Master|r [|cffe6b080Мастер ключей|r]

PatchNotes.txt

+22
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,28 @@ Key Master AddOn for World of Warcraft
22
(c) 2024 – Released under the GNU General Public License
33

44
PATCH NOTES:
5+
--------------------------------------------------
6+
Key Master v1.0.2
7+
--------------------------------------------------
8+
Updates:
9+
- When you are a party member of the matchmaking group system: Looking for Raid (LFR),
10+
Looking for Group (LFG), Battle Ground, Arena, or Follower dungeon, party member information
11+
is no longer displayed in the party tab for that party. This does not apply to custom
12+
(user created) groups or normal party members outside of your instance group.
13+
- Added notification when party information is not displayed.
14+
15+
Fixes:
16+
- Fixed GitHub issue #30 - When joining an LFR, LFG, or follower dungeon you would see many
17+
"You are not in a party" messages in chat.
18+
- Fixed rare case were party member data would vanish after briefly being displayed.
19+
20+
Open Items:
21+
- Known: [ADDON_ACTION_BLOCKED] AddOn 'KeyMaster' tried to call a protected function 'KM_PlayerRow1:Show()'.
22+
- Reported: Dungeon portals buttons not casting the portal spell when the spell is available (known/off CD) and clicked.
23+
24+
If you experience any of these open item unicorns, please report them with as much detail as possible in the
25+
Key Master Issues GitHub. https://github.com/Puresyn/KeyMaster/issues
26+
527
--------------------------------------------------
628
Key Master v1.0.1
729
--------------------------------------------------

0 commit comments

Comments
 (0)