コード例 #1
0
 public void ReturnToCommandSelection()
 {
     soundPlayer.PlaySound(1, 1, true);
     selecting = SelectingMenu.selectingAction;
     selectedTileIndicator.gameObject.SetActive(false);
     battleUI.attackMenu.SetActive(false);
     battleUI.partyInfo.SetActive(true);
     battleUI.actionMenu.SetActive(true);
 }
コード例 #2
0
 public void ConfirmAttackSelection()
 {
     //This is all going to change once it's an array of course
     soundPlayer.PlaySound(0, 1, true);
     //selectedTargetVector[0] = Vector2.zero;
     //selectedTarget[i] = selectedTargetVector[i].x + selectedTargetVector[i].y;
     //selectedTargetsTransform[i].gameObject.SetActive(true);
     //selectedTargetsTransform[i].position = gameManager.tileScript.tileTransform[selectedTarget[i]].position;
     battleUI.attackMenu.SetActive(false);
     selecting = SelectingMenu.selectingTarget;
 }
コード例 #3
0
//Input
    public void ConfirmSelectedCommand()
    {
        soundPlayer.PlaySound(0, 1, true);
        if (battleUI.command == BattleUI.CommandSelection.Attack)
        {
            battleUI.InitiateAttackSelection();
        }
        else if (battleUI.command == BattleUI.CommandSelection.Defend)
        {
            //Go to Select defend
        }
        else if (battleUI.command == BattleUI.CommandSelection.Move)
        {
            //Go to move menu
            selecting = SelectingMenu.selectingMove;

            tileSelection = charControl[0].tile;     //0 is a placeholder for now Will be replaced with an Int indicating the active character when that's a thing
            selectedTile  = Mathf.FloorToInt(tileSelection.y + (tileSelection.x * tileVectorSize.y));
            selectedTileIndicator.gameObject.SetActive(true);
            selectedTileIndicator.position = tileScript.tileTransform[selectedTile].position;
            battleUI.actionMenu.SetActive(false);
            //gameManager.MoveFormation(0,5);
        }
        else if (battleUI.command == BattleUI.CommandSelection.Item)
        {
            //Go to Item Menu
        }
        else if (battleUI.command == BattleUI.CommandSelection.Run)
        {
            //Execute Running away
            RunFromBattle();
        }
        else
        {
            Debug.Log("Tried to confirm an Action command selection but nothing was selected");
        }
    }
コード例 #4
0
 //----------------------------Victory----------------------------
 public void Victory()
 {
     battleUI.victoryPanel.SetActive(true);
     selecting = SelectingMenu.victoryScreen;
 }