Ejemplo n.º 1
0
    private void SetTarget(LifeObjectCollider target)
    {
        LifeObjectCollider newLOC = target;

        if (target.GetPlayer() != MainScreenManager_GameScene.Instance.GetPlayer())
        {
            if (this.previousLOC != null)
            {
                previousLOC.EnableOutline(false);
            }
            if (this.previousSoldier != null)
            {
                previousSoldier.EnableOutline(false);
            }

            // Check if no soldiers before enabling outline?
            if (!target.GetPlayer().GetCardManager().GetDefenseManager().HasFrontDefense())
            {
                newLOC.EnableOutline(true);
            }
            else
            {
                newLOC.EnableOutline(false);
            }
            previousLOC     = newLOC;
            previousSoldier = null;
        }
    }
Ejemplo n.º 2
0
    public void SetAttackMode(bool val)
    {
        this.inAttackMode = val;
        if (!val)
        {
            if (previousLOC != null)
            {
                previousLOC.EnableOutline(false);
            }
            if (previousSoldier != null)
            {
                previousSoldier.EnableOutline(false);
            }

            previousLOC     = null;
            previousSoldier = null;
        }
    }