What do you want to achieve? Hello, I have a problem with a BillBoardGui with text labels inside, the problem appears only on mobile. Please watch the video to understand what happens in certain camera positions. I don’t understand where this problem comes from, I tried a lot of things in the BillBoardGUI and text labels settings, nothing seems to work. Thanks
What is the issue?
local Players = game:GetService("Players")
Players.PlayerAdded:Connect(function(plr)
plr.CharacterAdded:Connect(function(char)
wait(2)
local rep = game:GetService("ServerStorage")
local nametag = rep:WaitForChild("NameTag"):Clone()
local head = char.Head
nametag.Parent = head
nametag.Adornee = head
local uppertext = nametag.UpperText
local secondtext = nametag.SecondText
local Simpsons = Instance.new("IntValue")
Simpsons.Value = #plr:WaitForChild("Creatures"):GetChildren()
plr:WaitForChild("leaderstats"):FindFirstChild("Simpsons").Value = #plr:WaitForChild("Creatures"):GetChildren()
uppertext.Text = Simpsons.Value
if uppertext.Text == "134" then
uppertext.TextColor3 = Color3.fromRGB(76, 157, 255)
secondtext.TextColor3 = Color3.fromRGB(76, 157, 255)
end
end)
end)
game.ReplicatedStorage:WaitForChild("Nametag").OnServerEvent:Connect(function(plr, data)
if not plr:WaitForChild("Creatures"):FindFirstChild(data) then
local newval = Instance.new("BoolValue")
newval.Name = data
newval.Parent = plr:WaitForChild("Creatures")
plr:WaitForChild("leaderstats"):FindFirstChild("Simpsons").Value = #plr:WaitForChild("Creatures"):GetChildren()
plr.Character.Head.NameTag.UpperText.Text = plr:WaitForChild("leaderstats"):FindFirstChild("Simpsons").Value
if plr.Character.Head.NameTag.UpperText.Text == "134" then
plr.Character.Head.NameTag.UpperText.TextColor3 = Color3.fromRGB(76, 157, 255)
plr.Character.Head.NameTag.SecondText.TextColor3 = Color3.fromRGB(76, 157, 255)
end
end
end)
I think it’s related to something that is on the map, because in the previous update this bug doesn’t appear but now it appears while none of the scripts have been modified … I don’t know it’s pretty weird and it prevents me from updating my game
I just tried it and it doesn’t change the problem. This is not related to a lag problem, my game is well optimized and has little latency. It seems to be related to I don’t know what, maybe textures or GUI surfaces or the sky, or maybe some meshs I don’t really know I tried so many things. I never had this problem before updating my game, it’s not related to the script because even if I delete all the scripts in my game the problem persists
But I tried everything with, literally, it seems to be a roblox bug, not optimized for mobile players, because this bug does not appear on computer. Somethings on the map seem to provoke that
I geuss you can do it with one text label, if you wanted to.
game.ReplicatedStorage:WaitForChild(“Nametag”).OnServerEvent:Connect(function(plr, data)
if not plr:WaitForChild(“Creatures”):FindFirstChild(data) then
local newval = Instance.new(“BoolValue”)
newval.Name = data
newval.Parent = plr:WaitForChild(“Creatures”)
plr:WaitForChild(“leaderstats”):FindFirstChild(“Simpsons”).Value = #plr:WaitForChild(“Creatures”):GetChildren()
local creatureCount = plr:WaitForChild("leaderstats"):FindFirstChild("Simpsons").Value
local displayText = string.format("<font color='%s'>%d</font>/134", creatureCount == 134 and "rgb(76, 157, 255)" or "rgb(255, 255, 255)", creatureCount)
plr.Character.Head.NameTag.TextLabel.Text = displayText
if creatureCount == 134 then
plr.Character.Head.NameTag.TextLabel.TextColor3 = Color3.fromRGB(76, 157, 255)
else
plr.Character.Head.NameTag.TextLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
end
end
end)
game.Players.PlayerAdded:Connect(function(plr)
local billboardgui = script:WaitForChild(‘NameTag’):Clone() --relocate this to anywhere
repeat wait() until plr.Character
billboardgui.Parent=plr.Character:WaitForChild(‘Head’)
local leaderstats = Instance.new(‘Configuration’, plr)
leaderstats.Name = ‘leaderstats’
local simpsons = Instance.new(‘IntValue’, leaderstats)
simpsons.Value = 0 --or the datastore thing, you can change this
simpsons.Name = ‘Simpsons’
local creatures = Instance.new(‘Folder’, plr)
creatures.Name = ‘Creatures’
end)
Used your script -the local Simpsons. Made the NameTag and Texts by the script names… Added the numbers in manually, then dropped it in Server Storage… Worked fine. Flicker isn’t coming from this, I would guess. I left everthing default but, checked Always on top and set StudsOffset 0,3,0.
Apparently it has something to do with the way Roblox manages a phone/tablet’s memory. If Roblox needs to cut down on memory, it will lower the quality of some aspects of your game, the TextLabel text rendering might be one of them. So i remplaced every text labels in my map with decals. This post was 2 years ago lol