As a Roblox developer, it is currently impossible to check whether the topbar has been disabled through starterGui:SetCore("TopbarEnabled", false)
and listen for this happening.
As a solution, I propose two new arguments that can be passed to StarterGui:GetCore
:
-
"TopbarEnabled"
, which returns a boolean that is true if the topbar is enabled and otherwise false. -
"TopbarEnabledEvent"
, which returns a BindableEvent that is fired whenever the topbar is enabled or disabled. A boolean that describes whether the topbar was enabled or disabled is passed to listeners.
This feature would assist developers who are creating code that is intended to be used in other developers’ games and has certain features that rely on the topbar being enabled. For example, the code may create a button in the topbar that, when clicked, opens some GUI. The button should not be placed there when the the topbar is disabled, so the developer could use the two new functionalities to detect the state of the topbar and account for it changing.