edit: it also works on mobile devices.
yeah so my game has a lobby system and theres a refresh room function that basically just shows you all the players inside of the room you joined and it used to work fine, but now for some reason it only works on the microsoft store version of roblox.
heres a video:
and here is the function:
module.refreshRoom = function()
local plrGui = plr.PlayerGui
for i,v in pairs(plrGui.Menu.Rooms.Storage.Room.Players:GetChildren()) do
if v:IsA("Frame") then
v:Destroy()
end
end
print("Success")
local rooms = game.ReplicatedStorage.Remotes.GetPublicRooms:InvokeServer()
for i,v in pairs(rooms) do
spawn(function()
print("Success2")
if v.owner == plrGui.Menu.Rooms.Storage.Room.Owner.Value then
local isOwner = false
if v.owner == plr.Name then
isOwner = true
plrGui.Menu.Rooms.Storage.Room.Start.Visible = true
plrGui.Menu.Rooms.Storage.Room.Password.Visible = true
else
plrGui.Menu.Rooms.Storage.Room.Start.Visible = false
plrGui.Menu.Rooms.Storage.Room.Password.Visible = false
end
for i,p in pairs(v.playerNames) do
spawn(function()
print("Success3")
local templateClone = plrGui.Menu.Rooms.Templates.PlayerTemplate:Clone()
templateClone.Parent = plrGui.Menu.Rooms.Storage.Room.Players
local plrPic = game.Players:GetUserThumbnailAsync(game.Players[p].UserId, Enum.ThumbnailType.HeadShot, Enum.ThumbnailSize.Size420x420)
templateClone.PlayerPic.Image = plrPic
templateClone.PlayerName.Text = p
if p ~= plr.Name and isOwner then
templateClone.Kick.Visible = true
end
templateClone.Visible = true
end)
end
end
end)
end
end
also im not getting any errors. heres the output:
Microsoft:
Regular:
any help appreciated, i am really confused and i have no idea what could be going on here.