GuiManager
GuiManager is a singleton class that manages the mounting and unmounting of GuiObjects to the PlayerGui. It is intended to be used as a singleton and should be accessed via FusionOnRails.GuiManager. This is not meant to be a replacement for dedicated UI frameworks, but rather a way to easily manage UIs that are not complex enough to warrant a dedicated framework.
[API][CLASS PROPS] .ScreenGui: ScreenGui
[OBJECT SIGNALS]
:GetSignal("Mounted") -> Signal<GuiObject, string>
[OBJECT METHODS]
:Mount(gui: GuiObject, name: string?)
:Unmount(name: string)
:GetMounted(name: string) -> GuiObject?
Functions
Init
GuiManager:
Init
(
) →
(
)
Parents the ScreenGui to the PlayerGui.
Mount
GuiManager:
Mount
(
name:
string?
--
The name of the GuiObject to mount
) →
(
)
Mounts the GuiObject with the given name if there is not one already mounted. If one is already mounted to the given name, it will be unmounted in favor of the new one.
Unmount
GuiManager:
Unmount
(
name:
string
,
--
The name of the GuiObject to unmount
destroy:
boolean?
--
Whether or not to actually destroy the instance
) →
(
)
Unmounts the GuiObject with the given name if there is one mounted.
GetMounted
Fetches the GuiObject with the given name if there is one mounted. If no name is provided, returns all the mounted Guis.