コード例 #1
0
    public void Start()
    {
        IsExecuted = true;

        Combat.DiceModifications.ShowDiceModificationsUiEmpty();

        GenericSubPhase subphase = Phases.StartTemporarySubPhaseNew(
            SubphaseType.Name,
            SubphaseType,
            Combat.DiceModifications.Next
            );

        subphase.Start();
    }
コード例 #2
0
    public void Start()
    {
        IsExecuted = true;

        DiceCompareHelper.currentDiceCompareHelper.Close();
        Combat.DiceModifications.HideDiceModificationsUi();

        GenericSubPhase subphase = Phases.StartTemporarySubPhaseNew <CompareResultsSubPhase>(
            "Compare Results",
            Combat.DiceModifications.Next
            );

        Combat.CancelHitsByDefenceDice();
    }
コード例 #3
0
        public override void StartPhase()
        {
            Name = "Combat Phase";

            if (Phases.HasOnCombatPhaseStartEvents)
            {
                GenericSubPhase subphase = Phases.StartTemporarySubPhaseNew("Notification", typeof(NotificationSubPhase), StartCombatStartSubPhase);
                (subphase as NotificationSubPhase).TextToShow = "Start of Combat";
                subphase.Start();
            }
            else
            {
                StartCombatStartSubPhase();
            }
        }
コード例 #4
0
        public override void NextPhase()
        {
            Selection.DeselectAllShips();

            if (Phases.HasOnEndPhaseStartEvents)
            {
                GenericSubPhase subphase = Phases.StartTemporarySubPhaseNew("Notification", typeof(NotificationSubPhase), StartEndPhase);
                (subphase as NotificationSubPhase).TextToShow = "End";
                subphase.Start();
            }
            else
            {
                StartEndPhase();
            }
        }
コード例 #5
0
ファイル: Phases.cs プロジェクト: Conzar/FlyCasual
    // TEMPORARY SUBPHASES

    public static void StartTemporarySubPhase(string name, System.Type subPhaseType, Action callBack = null)
    {
        CurrentSubPhase.Pause();
        if (DebugManager.DebugPhases)
        {
            Debug.Log("Temporary phase " + subPhaseType + " is started directly");
        }
        GenericSubPhase previousSubPhase = CurrentSubPhase;

        CurrentSubPhase                    = (GenericSubPhase)System.Activator.CreateInstance(subPhaseType);
        CurrentSubPhase.Name               = name;
        CurrentSubPhase.CallBack           = callBack;
        CurrentSubPhase.PreviousSubPhase   = previousSubPhase;
        CurrentSubPhase.RequiredPlayer     = previousSubPhase.RequiredPlayer;
        CurrentSubPhase.RequiredPilotSkill = previousSubPhase.RequiredPilotSkill;
        CurrentSubPhase.Start();
    }
コード例 #6
0
        public override void NextPhase()
        {
            Selection.DeselectAllShips();

            bool anyShipHasSystemsAbility = Roster.AllShips.Values.Any(n => n.IsSystemsAbilityCanBeActivated);

            if (anyShipHasSystemsAbility)
            {
                GenericSubPhase subphase = Phases.StartTemporarySubPhaseNew("Notification", typeof(NotificationSubPhase), StartSystemsPhase);
                (subphase as NotificationSubPhase).TextToShow = "Systems";
                subphase.Start();
            }
            else
            {
                StartSystemsPhase();
            }
        }
コード例 #7
0
        public override void NextPhase()
        {
            Selection.DeselectAllShips();

            if (!DebugManager.NoCinematicCamera)
            {
                CameraScript.RestoreCamera();
            }

            if (Phases.Events.HasOnEndPhaseStartEvents)
            {
                GenericSubPhase subphase = Phases.StartTemporarySubPhaseNew("Notification", typeof(NotificationSubPhase), StartEndPhase);
                (subphase as NotificationSubPhase).TextToShow = "End";
                subphase.Start();
            }
            else
            {
                StartEndPhase();
            }
        }
コード例 #8
0
    // TEMPORARY SUBPHASES

    public static void StartTemporarySubPhaseOld(string name, System.Type subPhaseType, Action callBack = null)
    {
        GenericSubPhase subphase = StartTemporarySubPhaseNew(name, subPhaseType, callBack);

        subphase.Start();
    }
コード例 #9
0
 private static void Finish()
 {
     GameObject.Destroy(FakeShip);
     MovementTemplates.HideLastMovementRuler();
     GenericSubPhase.HideSubphaseDescription();
 }