Loading Panel

Loading

All actions with showing loading screens and switching scenes are controlled by this class.

To get started:

Add prefab “Loading” to the first scene.

  • Methods
Loading.ShowOpaquePanel();
Loading.ShowTransparentPanel();
Loading.HideAllPanels();

Loading.BlockTouch();

Loading.SwitchToNextScene();
Loading.SwitchToPreviousScene();

ShowOpaquePanel – show a loading screen with an opaque background, for example used between scene switches.

ShowTransparentPanel – show a loading screen with a transparent background, for example, used between calls to server functions.

HideAllPanels – hide all active loading screens.
*they are automatically hidden after a certain time, configured in the “Loading” prefab.

BlockTouch – blocks the user’s touch by turning on an invisible layer. For example, it blocks touches when the spin is spinning.

SwitchToNextScene – switches to the next scene by index.

SwitchToPreviousScene – switches to the previous scene by index.

Powered by BetterDocs

Go to Top