Corgi Engine  v8.8
MoreMountains.CorgiEngine.GUIManager Class Reference

Handles all GUI effects and changes More...

Inheritance diagram for MoreMountains.CorgiEngine.GUIManager:
MoreMountains.Tools.MMSingleton< GUIManager > MoreMountains.Tools.MMEventListener< LevelNameEvent > MoreMountains.Tools.MMEventListener< ControlsModeEvent > MoreMountains.CorgiEngine.MultiplayerGUIManager MoreMountains.CorgiEngine.RetroAdventureGUIManager

Public Member Functions

virtual void SetHUDActive (bool state)
 Sets the HUD active or inactive More...
 
virtual void SetAvatarActive (bool state)
 Sets the avatar active or inactive More...
 
virtual void SetMobileControlsActive (bool state, InputManager.MovementControls movementControl=InputManager.MovementControls.Joystick)
 Called by the input manager, this method turns controls visible or not depending on what's been chosen More...
 
virtual void SetPause (bool state)
 Sets the pause. More...
 
virtual void SetJetpackBar (bool state, string playerID)
 Sets the jetpackbar active or not. More...
 
virtual void SetAmmoDisplays (bool state, string playerID, int ammoDisplayID)
 Sets the ammo displays active or not More...
 
virtual void SetTimeSplash (bool state)
 Sets the time splash. More...
 
virtual void RefreshPoints ()
 Sets the text to the game manager's points. More...
 
virtual void UpdateHealthBar (float currentHealth, float minHealth, float maxHealth, string playerID)
 Updates the health bar. More...
 
virtual void UpdateJetpackBar (float currentFuel, float minFuel, float maxFuel, string playerID)
 Updates the jetpack bar. More...
 
virtual void UpdateAmmoDisplays (bool magazineBased, int totalAmmo, int maxAmmo, int ammoInMagazine, int magazineSize, string playerID, int ammoDisplayID, bool displayTotal)
 Updates the (optional) ammo displays. More...
 
virtual void SetLevelName (string name)
 Sets the level name in the HUD More...
 
virtual void OnMMEvent (LevelNameEvent levelNameEvent)
 When we catch a level name event, we change our level's name in the GUI More...
 
virtual void OnMMEvent (ControlsModeEvent controlsModeEvent)
 
- Public Member Functions inherited from MoreMountains.Tools.MMEventListener< LevelNameEvent >
void OnMMEvent (T eventType)
 
- Public Member Functions inherited from MoreMountains.Tools.MMEventListener< ControlsModeEvent >
void OnMMEvent (T eventType)
 

Public Attributes

GameObject HUD
 the game object that contains the heads up display (avatar, health, points...) More...
 
MMProgressBar[] HealthBars
 the jetpack bar More...
 
MMProgressBar[] JetPackBars
 the jetpack bar More...
 
AmmoDisplay[] AmmoDisplays
 the panels and bars used to display current weapon ammo More...
 
GameObject PauseScreen
 the pause screen game object More...
 
GameObject TimeSplash
 the time splash gameobject More...
 
CanvasGroup Buttons
 The mobile buttons. More...
 
CanvasGroup Arrows
 The mobile arrows. More...
 
CanvasGroup Joystick
 The mobile movement joystick. More...
 
Text PointsText
 the points counter More...
 
Text LevelText
 the level display More...
 
string PointsPattern = "000000"
 the pattern to apply when displaying the score More...
 

Protected Member Functions

override void Awake ()
 Initialization More...
 
virtual void Start ()
 Initialization More...
 
virtual void OnEnable ()
 On enable, we start listening to events More...
 
virtual void OnDisable ()
 On disable, we stop listening to events More...
 
- Protected Member Functions inherited from MoreMountains.Tools.MMSingleton< GUIManager >
virtual void InitializeSingleton ()
 Initializes the singleton. More...
 

Static Protected Member Functions

static void InitializeStatics ()
 Statics initialization to support enter play modes More...
 

Protected Attributes

float _initialJoystickAlpha
 
float _initialArrowsAlpha
 
float _initialButtonsAlpha
 

Additional Inherited Members

- Static Public Member Functions inherited from MoreMountains.Tools.MMSingleton< GUIManager >
static T TryGetInstance ()
 
- Static Public Attributes inherited from MoreMountains.Tools.MMSingleton< GUIManager >
static bool HasInstance
 
static T Current
 
- Static Protected Attributes inherited from MoreMountains.Tools.MMSingleton< GUIManager >
static T _instance
 
- Properties inherited from MoreMountains.Tools.MMSingleton< GUIManager >
static T Instance [get]
 Singleton design pattern More...
 

Detailed Description

Handles all GUI effects and changes

Member Function Documentation

◆ Awake()

override void MoreMountains.CorgiEngine.GUIManager.Awake ( )
protectedvirtual

Initialization

Reimplemented from MoreMountains.Tools.MMSingleton< GUIManager >.

◆ InitializeStatics()

static void MoreMountains.CorgiEngine.GUIManager.InitializeStatics ( )
staticprotected

Statics initialization to support enter play modes

◆ OnDisable()

virtual void MoreMountains.CorgiEngine.GUIManager.OnDisable ( )
protectedvirtual

On disable, we stop listening to events

Reimplemented in MoreMountains.CorgiEngine.RetroAdventureGUIManager.

◆ OnEnable()

virtual void MoreMountains.CorgiEngine.GUIManager.OnEnable ( )
protectedvirtual

On enable, we start listening to events

Reimplemented in MoreMountains.CorgiEngine.RetroAdventureGUIManager.

◆ OnMMEvent() [1/2]

virtual void MoreMountains.CorgiEngine.GUIManager.OnMMEvent ( ControlsModeEvent  controlsModeEvent)
virtual

◆ OnMMEvent() [2/2]

virtual void MoreMountains.CorgiEngine.GUIManager.OnMMEvent ( LevelNameEvent  levelNameEvent)
virtual

When we catch a level name event, we change our level's name in the GUI

Parameters
levelNameEvent

◆ RefreshPoints()

virtual void MoreMountains.CorgiEngine.GUIManager.RefreshPoints ( )
virtual

Sets the text to the game manager's points.

◆ SetAmmoDisplays()

virtual void MoreMountains.CorgiEngine.GUIManager.SetAmmoDisplays ( bool  state,
string  playerID,
int  ammoDisplayID 
)
virtual

Sets the ammo displays active or not

Parameters
stateIf set to true state.
playerIDPlayer I.

◆ SetAvatarActive()

virtual void MoreMountains.CorgiEngine.GUIManager.SetAvatarActive ( bool  state)
virtual

Sets the avatar active or inactive

Parameters
stateIf set to true turns the HUD active, turns it off otherwise.

◆ SetHUDActive()

virtual void MoreMountains.CorgiEngine.GUIManager.SetHUDActive ( bool  state)
virtual

Sets the HUD active or inactive

Parameters
stateIf set to true turns the HUD active, turns it off otherwise.

◆ SetJetpackBar()

virtual void MoreMountains.CorgiEngine.GUIManager.SetJetpackBar ( bool  state,
string  playerID 
)
virtual

Sets the jetpackbar active or not.

Parameters
stateIf set to true, sets the pause.

◆ SetLevelName()

virtual void MoreMountains.CorgiEngine.GUIManager.SetLevelName ( string  name)
virtual

Sets the level name in the HUD

◆ SetMobileControlsActive()

virtual void MoreMountains.CorgiEngine.GUIManager.SetMobileControlsActive ( bool  state,
InputManager.MovementControls  movementControl = InputManager.MovementControls.Joystick 
)
virtual

Called by the input manager, this method turns controls visible or not depending on what's been chosen

Parameters
stateIf set to true state.
movementControlMovement control.

◆ SetPause()

virtual void MoreMountains.CorgiEngine.GUIManager.SetPause ( bool  state)
virtual

Sets the pause.

Parameters
stateIf set to true, sets the pause.

◆ SetTimeSplash()

virtual void MoreMountains.CorgiEngine.GUIManager.SetTimeSplash ( bool  state)
virtual

Sets the time splash.

Parameters
stateIf set to true, turns the timesplash on.

◆ Start()

virtual void MoreMountains.CorgiEngine.GUIManager.Start ( )
protectedvirtual

Initialization

◆ UpdateAmmoDisplays()

virtual void MoreMountains.CorgiEngine.GUIManager.UpdateAmmoDisplays ( bool  magazineBased,
int  totalAmmo,
int  maxAmmo,
int  ammoInMagazine,
int  magazineSize,
string  playerID,
int  ammoDisplayID,
bool  displayTotal 
)
virtual

Updates the (optional) ammo displays.

Parameters
magazineBasedIf set to true magazine based.
totalAmmoTotal ammo.
maxAmmoMax ammo.
ammoInMagazineAmmo in magazine.
magazineSizeMagazine size.
playerIDPlayer I.
displayTotalIf set to true display total.

◆ UpdateHealthBar()

virtual void MoreMountains.CorgiEngine.GUIManager.UpdateHealthBar ( float  currentHealth,
float  minHealth,
float  maxHealth,
string  playerID 
)
virtual

Updates the health bar.

Parameters
currentHealthCurrent health.
minHealthMinimum health.
maxHealthMax health.
playerIDPlayer I.

◆ UpdateJetpackBar()

virtual void MoreMountains.CorgiEngine.GUIManager.UpdateJetpackBar ( float  currentFuel,
float  minFuel,
float  maxFuel,
string  playerID 
)
virtual

Updates the jetpack bar.

Parameters
currentFuelCurrent fuel.
minFuelMinimum fuel.
maxFuelMax fuel.
playerIDPlayer I.

Member Data Documentation

◆ _initialArrowsAlpha

float MoreMountains.CorgiEngine.GUIManager._initialArrowsAlpha
protected

◆ _initialButtonsAlpha

float MoreMountains.CorgiEngine.GUIManager._initialButtonsAlpha
protected

◆ _initialJoystickAlpha

float MoreMountains.CorgiEngine.GUIManager._initialJoystickAlpha
protected

◆ AmmoDisplays

AmmoDisplay [] MoreMountains.CorgiEngine.GUIManager.AmmoDisplays

the panels and bars used to display current weapon ammo

◆ Arrows

CanvasGroup MoreMountains.CorgiEngine.GUIManager.Arrows

The mobile arrows.

◆ Buttons

CanvasGroup MoreMountains.CorgiEngine.GUIManager.Buttons

The mobile buttons.

◆ HealthBars

MMProgressBar [] MoreMountains.CorgiEngine.GUIManager.HealthBars

the jetpack bar

◆ HUD

GameObject MoreMountains.CorgiEngine.GUIManager.HUD

the game object that contains the heads up display (avatar, health, points...)

◆ JetPackBars

MMProgressBar [] MoreMountains.CorgiEngine.GUIManager.JetPackBars

the jetpack bar

◆ Joystick

CanvasGroup MoreMountains.CorgiEngine.GUIManager.Joystick

The mobile movement joystick.

◆ LevelText

Text MoreMountains.CorgiEngine.GUIManager.LevelText

the level display

◆ PauseScreen

GameObject MoreMountains.CorgiEngine.GUIManager.PauseScreen

the pause screen game object

◆ PointsPattern

string MoreMountains.CorgiEngine.GUIManager.PointsPattern = "000000"

the pattern to apply when displaying the score

◆ PointsText

Text MoreMountains.CorgiEngine.GUIManager.PointsText

the points counter

◆ TimeSplash

GameObject MoreMountains.CorgiEngine.GUIManager.TimeSplash

the time splash gameobject


The documentation for this class was generated from the following file: