Does it fail on the live game and Test Server too? Or just Play Solo?
Do not try to do sorts of “active” and “unactive”.
I’ve fixed your code now. There is the code:
local function SetNameTag(active)
local Character = Player.Character
if not Character then return end
print('Disabling')
Character.Head.NameTag.Enabled = true
end
print(1)
SetNameTag(false)
No there’s a reason why I use active. Because I use this functions again to re-enable the tag…
This seems very much like a bug. I can’t reproduce it in a blank baseplate with the exact same properties on the BillboardGui. Try it in a live game. Try it in Test Server. If it continues with those, then something very very strange is going on.
If this Gui exists on the server, try having it disabled on the server and enabled on each client to see if it’s any different. Either way this is a bug. Enabled should have executive control over whether the Gui renders or not.
I’m not able to re-pro this issue, setting enabled to false works for me. Is it printing ‘Disabling’? If not, that means Player.Character is nil so you can try waiting for character.
Considering setting none of the properties is working for you, I have a strong feeling that your script is referencing the incorrect BillboardGui. It is unlikely this is a bug and more likely an implementation issue. I cannot reproduce this.
Except for the fact that my SS clearly shows the gui. There’s only 1 billboard gui inside my players head (as is seen in the SS) and if I delete that billboard gui while in game, it gets removed. So it’s not my implementation
I am not the wises one when it comes to optimal code but try this one.
local function SetNameTag(active)
local Timeout = tick() + 5
local Character = Player.Character
repeat wait(0.25) until (Character and Character.Parent) or tick() >= Timeout
if not Character then print("Character undefined") return end
print('Disabling')
Character.Head.NameTag.Enabled = true
end
print(1)
SetNameTag(false)
(Edit: just mistyped Character)
No it very much is your implementation. I can’t repro this issue with BillboardGuis myself. Do you get this same issue with other BillboardGuis either in your game (existing ones or ones that you create) or in separate places? If you don’t, it is almost certainly your implementation.
If it’s my implentation then explain how this SS is possible? Do you see a second BillboardGui inside my characters head? No. There’s only 1, so it’s only referencing the one. You can also clearly see ‘Enabled’ is false.
Please read my post again. I’ve been asking if you are able to repro this issue with other BillboardGuis whether they are existing ones in the same game, new ones that you create or ones that are in a completely separate place file to this one.
From all the pictures you’ve provided, the changes are shown as enabled set to false. It that the same for the server?
No I haven’t bothered to create a repro, because I don’t need to. It’s clearly visible for me right there, that’s enough to prove that’s something ain’t right
No it’s really not enough. I need to be able to understand if you’re having this problem with other BillboardGuis or not because that’ll help determine if the issue is specific to your implementation or not. A single screenshot doesn’t suffice because it’s specific to this circumstance, so it doesn’t tell me if you’re having the same issue elsewhere and if it’s an engine bug or if it’s just your own code.
I don’t see how it can be a problem with my implementation. Screenshot clearly shows 1 BillboardGui, it clearly shows that the BillboardGui is not enabled, and my function
local function SetNameTag(active)
print(active)
local Character = Player.Character
if not Character then return end
print('Character found')
Character.Head.NameTag.Enabled = active
print(Character.Head.NameTag.Enabled)
end
print(1)
SetNameTag(false)
returns this
Shows it still disabled too
It very well could be though and that denial to review your code or attempt a repro is crippling for information. I genuinely cannot help you here if you aren’t willing to work with me and at least try to produce a repro because that in itself can reveal whether you’re experiencing a bug or implementation error.
Refactoring and editing your code hasn’t worked so far and neither has setting other properties, so the only other best thing I can think of you doing is to attempt this with other BillboardGuis and see if you are experiencing the same issue or not.
I’ll be signing off here for this post unless information about a repro is provided and if you’re also experiencing this elsewhere. Best of luck fixing this.
Posted an official bug report on this, as I am 100% certain this is a bug. To add further proof that this is 100% on Roblox’s end and not mine. Video shows me manually inserting a BillboardGui and then an object into that Gui, then attempting to disable it with no affect. This has nothing to do with own implentation/code. As far as I’m concerned, BillboardGui’s should be able to make edits from the client (obviously not replicate to server) but since it’s a UI element it should be editable.
Also, I tried putting it in PlayerGui and then adorning it to the player head and it works normally, so yes I could do that, however then you’d only be able to see your own name tag
Unfortunately you only seem to have that problem on that one place. I am unable to re-create this issue from what is shown. I’ve tried to create it on the client, and server. They appear to work fine for me, so I am not sure what could be causing that issue.
Here is my attempt to replicate.
Ye i’ve tried numerous times creating repos, can’t do it. I don’t know why it’s only happening inside the 1 game. I’ve tried uploading to different places, still no fix