Exemplo n.º 1
0
 public AttackBonus(AttackBonus from)
 {
     BonusChance      = from.BonusChance;
     BAMModel         = from.BAMModel;
     POWModel         = from.POWModel;
     KABAMModel       = from.KABAMModel;
     BonusPoints      = from.BonusPoints;
     BAMBonusChance   = from.BAMBonusChance;
     POWBonusChance   = from.POWBonusChance;
     _combatPadScript = from._combatPadScript;
 }
Exemplo n.º 2
0
        private bool SetupAttackInfo()
        {
            GameObject combatPanel = GameObject.FindWithTag("CombatPanel") as GameObject;

            if (null != combatPanel)
            {
                _combatPadScript = combatPanel.GetComponent <CombatPad>();
            }

            if (null == _combatPadScript)
            {
                Debug.LogError("Attack.SetupAttack: CombatPadScript is null.");
            }

            if (null == _combatPadScript)
            {
                return(false);
            }

            BAMBonusChance = 33;
            POWBonusChance = 66;
            _isSetup       = true;
            return(true);
        }
Exemplo n.º 3
0
        private bool SetupAttack()
        {
            if (null != Attacker)
            {
                _entityControllerScript = Attacker.GetComponent <EntityController>();
            }
            if (null != Attacker)
            {
                _fx = Attacker.AddComponent <FX>();
            }
            if (null != _fx)
            {
                FXInfo.CopyTo(_fx);
                _fx.InitFX();
            }
            _healthPanel = GameObject.FindWithTag("HealthGameObject") as GameObject;
            _combatPanel = GameObject.FindWithTag("CombatPanel") as GameObject;
            if (null != _combatPanel)
            {
                _combatPadScript = _combatPanel.GetComponent <CombatPad>();
            }
            _superBar = GameObject.FindWithTag("SuperBar") as GameObject;
            GameObject movementPad = GameObject.FindWithTag("MovementPad") as GameObject;

            if (null != movementPad)
            {
                _keyboardScript = movementPad.GetComponent <Keyboard>();
            }

            if (null == Attacker)
            {
                Debug.LogError("Attack.SetupAttack: Attacker is null.");
            }
            if (null == _entityControllerScript)
            {
                Debug.LogError("Attack.SetupAttack: _entityControllerScript is null.");
            }
            if (null == _healthPanel)
            {
                Debug.LogError("Attack.SetupAttack: _healthPanel is null.");
            }
            if (null == _combatPanel)
            {
                Debug.LogError("Attack.SetupAttack: _combatPanel is null.");
            }
            if (null == _superBar)
            {
                Debug.LogError("Attack.SetupAttack: _superBar is null.");
            }
            if (null == _combatPadScript)
            {
                Debug.LogError("Attack.SetupAttack: _combatPadScript is null.");
            }
            if (null == _keyboardScript)
            {
                Debug.LogError("Attack.SetupAttack: _keyboardScript is null.");
            }

            if (null == Attacker)
            {
                return(false);
            }
            if (null == _healthPanel)
            {
                return(false);
            }
            if (null == _combatPanel)
            {
                return(false);
            }
            if (null == _superBar)
            {
                return(false);
            }
            if (null == _combatPadScript)
            {
                return(false);
            }
            if (null == _keyboardScript)
            {
                return(false);
            }

            _isSetup = true;
            return(true);
        }