SurfaceGuis breaks when you reset

,
  • Describe the bug. Describe what is happening when the bug occurs. Describe what you would normally expect to occur.

If you have a SurfaceGui copied over from StarterGui, it will not react to user input events after you respawn.
It only seems to grab hover events when I join before I reset/die in-game. The bug is only affecting SurfaceGuis copied from StarterGui, and not SurfaceGuis placed in Workspace under the adornee part.

  • How often does the bug happen (Everytime/sometimes/rarely)? What are the steps that reproduce the bug? Please list them in very high detail. Provide simple example places that exhibit the bug and provide description of what you believe should be the behavior.

After a couple of tries in two different places, the issue seems to occur everytime.

  1. Make a SurfaceGui inside of StarterGui
  2. Place a TextButton inside of the SurfaceGui
  3. Make a part in Workspace and set the Adornee of the SurfaceGui to that part
  4. Play the game in studio and hover your mouse over the textbutton - notice how the color changes.
  5. Open the menu and reset your character (ESC, then R for hotkeys)
  6. Try hover over the textbutton, and notice how the textbutton does not react to your mouse being hovered over it.
  • Where does the bug happen (www, gametest, etc) Is it level-specific? Is it game specific? Please post a link to the place that exhibits the issue.
    Happens for the WWW-site. It is not level-specific or game-specific.
    https://www.roblox.com/games/626302497/Place

  • Would a screenshot or video help describe it to someone? If so, post one.

3 Likes

This bug is still happening. Very easy reproduction. The surfacegui object itself breaks, as not even the default mouseover darken behavior happens. For some reason it doesn’t affect surfaceguis parented under a Part in workspace (but the wiki says bugs happen when they are parented there)

With ResetPlayerGuiOnSpawn false, it doesn’t have the bug of course. But this is still an issue in probably many games.

2 Likes

I made a quick repro place for this bug as I just encountered it today as well. Upon spawning, both buttons on both bricks should work. After the character respawns (by resetting in this case), the red brick’s button no longer responds at all. Bug occurs in Play Solo with and without FE enabled.repro.rbxl (14.9 KB)

2 Likes

We will check this out. Will try and post an update when we have more info.

2 Likes

@AllYourBlox has been working on this, will probably have an update soon

I hate to revive this thread but I have the same issue when I respawn - has this been worked on at all anymore?

1 Like

@AllYourBlox

2 Likes

It’s OK to revive this, but it’s likely to be a new bug or some form of regression. The original bug was something I fixed in April, and the repro.rbxl Kinnis97 linked to above still functions correctly for me in both solo play and server-client deployment, so I suspect there is something else going on. Do you have a file or unlocked place that easily reproduces what you’re seeing?

2 Likes

Ill send you the place privately when Im at the computer.

This is my SurfaceGui, it only responds if it begins in PlayerGui. If I die it stops responding, but it responds all the time with render on top. I tried putting the SurfaceGui in the player Gui on spawn from replicated storage and it never responds on the first spawn.

I tried moving the brick closer to the camera and it still doesn’t work. Am I missing something or does this sound like a new bug that I again will send privately when I can.

I have adornee set already but I make it adornee again from the script in case the adornee is detached when moving it to a new game where it was fine but suffers the same issue as respawn breaking it.

1 Like

Unfortunately, this still seems to be happening as long as I have the SurfaceGui in StarterGui.
I’ve only experienced button clicks breaking, though I haven’t been tried mouse entered/removed events.

I’m not sure if this is the same bug, though it seems similar and matches what has been described so far and I would rather not open another duplicate thread.

1 Like

I’m still having this bug. Is this something that I’m doing wrong?

1 Like

Just so this is recorded here, a common solution to this issue is to ensure that your SurfaceGui is the descendant of a ScreenGui with ResetOnSpawn disabled.

1 Like

Found a better solution. Simply adorn it

1 Like

The bug still remain unfix. Can ROBLOX look into it?

1 Like

Yep i did that, but certain player are able to click, some are unable to.

1 Like

I ran into this issue myself and it took hours to fix because SurfaceGUIs seem to be very, very delicate to work with. If you run into this issue, chances are:

  • You have the GUI inside another object within StarterGui (for some reason Folders broke the GUIs separately, which was not fun. This might require ROBLOX Engineers to further investigate and return with a definitive answer to as I’ve found it is inconsistent with Studio (Beta Branch & Public Branch)

  • You have a LocalScript that controls all or part of the functions in the same GUI, meaning anything such as refreshing breaks. You may need to set the LocalScript within StarterPlayerScripts and tweak it in order to fetch the UI through the LocalPlayer.PlayerGui.

  • You might have the UI in a service that doesn’t support interactive UIs (workspace, ReplicatedStorage or wherever you’ve put it that isn’t StarterGui. Make sure it is in StarterGUI, Labelled clearly for your sanity.

  • [15/01/2021]: You can’t have any events the script requires in the SurfaceGUI or StarterGUI - Instead have them in ReplicatedStorage or as a child of the script.

  • As Mentioned earlier, you might have an invisible brick in front of the UI. This one is by far the easiest mistakes to make.

2 Likes