Ejemplo n.º 1
0
        private void OnHudStateChanged(HudModel.EHudState hudState)
        {
            Type targetType = null;

            switch (hudState)
            {
            case HudModel.EHudState.Hidden:
                targetType = typeof(HudStateHidden);
                break;

            case HudModel.EHudState.GamePlay:
                targetType = typeof(HudStateGamePlay);
                break;
            }

            if (targetType != null &&
                (CurrentStateBehaviour == null ||
                 targetType != CurrentStateBehaviour.GetType()))
            {
                GoToState(targetType);
            }
        }
Ejemplo n.º 2
0
 private void OnHudStateChanged(HudModel.EHudState hudState)
 {
     GoToState((int)hudState);
 }