Battleground Commander

Battleground Commander

79.7k Downloads

Ready check initiated by someone from the same realm can't find the user

linaori opened this issue ยท 0 comments

commented

The event doesn't pass the realm of the user, should add a fallback to "first name" when no realm is present.

Reference:

local Memory = {
lastKnownGroupType = GetGroupType(),
AllPlayerData = {
--[GUID] = {
-- guid = GUID,
-- name = playerName,
-- firstName = playerName without realm,
-- realmName = normalized realm name,
-- units = {primary => first unit, first unit = true, second unit = true},

Location to update:

function Namespace.PlayerData.GetPlayerDataByName(name)
for _, data in pairs(Memory.AllPlayerData) do
Private.RefreshMissingData(data)
if data.name == name then
return data
end
end
return nil
end