Remove the realm "-legionx5" from player names on dueler

This commit is contained in:
2025-01-05 17:35:20 +01:00
parent 35c51143bc
commit c00ddd410a

View File

@@ -100,7 +100,9 @@ function shared.DeathReporter.Init()
systemMessageFrame:RegisterEvent("CHAT_MSG_SYSTEM")
systemMessageFrame:SetScript("OnEvent", function(self, event, msg)
if not Heimdall_Data.config.deathReporter.enabled then return end
local source, destination = string.match(msg, "(.+) has defeated (.+) in a duel")
local source, destination = string.match(msg, "([^ ]+) has defeated ([^ ]+) in a duel")
source = string.match(source, "([^-]+)")
destination = string.match(destination, "([^-]+)")
if source and destination then
print(string.format("Detected duel between %s and %s", source, destination))
local now = GetTime()