Esempio n. 1
0
        void Awake()
        {
            cooldown        = GetComponent <CoolDown>();
            cooldown.isOnCD = false;

            art = this;

            health    = actor.health;
            maxHealth = actor.health;
            strength  = actor.armor;
            speed     = actor.speed;
            evasion   = actor.evasion;
            armor     = actor.armor;
            zodiac    = actor.zodiac;

            spellsEquipped = GetComponent <SpellsEquipped>();
            abilities[0]   = spellsEquipped.ability[0];
            abilities[1]   = spellsEquipped.ability[1];
            abilities[2]   = spellsEquipped.ability[2];
            abilities[3]   = spellsEquipped.ability[3];

            animationHandler = GetComponent <AnimationHandler>();

            combatController = FindObjectOfType <CombatController>();
            mover            = GetComponent <Mover>();
            cooldown         = GetComponent <CoolDown>();
            channel          = GetComponent <Channel>();
            targetingManager = GetComponent <TargetingManager>();
            attackExecutor   = GetComponent <AttackExecutor>();
            playerStats      = GetComponent <PlayerStats>();
            //materialRenderer = GetComponent<Renderer>();


            savedAbility = null;
        }
Esempio n. 2
0
 void Start()
 {
     GetCurrentCell();
     currentCell.isOccupied = true;
     animationHandler       = GetComponent <AnimationHandler>();
     combatController       = FindObjectOfType <CombatController>();
 }
Esempio n. 3
0
        void Start()
        {
            abilities        = GetComponent <EnemySpells>().ability;
            safeAbility      = GetComponent <EnemySpells>().safeAbility;
            targets          = FindObjectsOfType <Fighter>();
            mover            = GetComponent <Mover>();
            onRailsMover     = GetComponent <OnRailsMover>();
            cooldown         = GetComponent <CoolDown>();
            channel          = GetComponent <Channel>();
            attackIndicator  = GetComponent <AttackIndicator>();
            attackReceiver   = GetComponent <AttackReceiver>();
            attackExecutor   = GetComponent <AttackExecutor>();
            enemyTarget      = GetComponent <EnemyTarget>();
            spline           = GetComponent <splineMove>();
            stateMachine     = GetComponent <StateMachine>();
            animationHandler = GetComponent <AnimationHandler>();

            allEnemies   = FindObjectsOfType <EnemyTarget>();
            allActors    = FindObjectsOfType <Fighter>();
            allPushables = FindObjectsOfType <Pushable>();

            combatController     = FindObjectOfType <CombatController>();
            cooldown.isOnCD      = true;
            channel.isChanneling = false;
            channel.channel      = 0f;

            //print("allPushables start count: " + allPushables.Length);

            //perform attack once will be used to check if the current attack is in progress
        }
Esempio n. 4
0
        void Start()
        {
            casterAnimation = GetComponent <AbilityFX>().caster.GetComponent <AnimationHandler>();

            foreach (AttackReceiver target in GetComponent <AbilityFX>().targets)
            {
                targetAnimations.Add(target.GetComponent <AnimationHandler>());
            }
        }
Esempio n. 5
0
        // Start is called before the first frame update
        void Start()
        {
            if (GetComponent <Fighter>() != null)
            {
                fighter = GetComponent <Fighter>();
                ResetStats(true);
            }

            if (GetComponent <EnemyTarget>() != null)
            {
                enemyTarget = GetComponent <EnemyTarget>();
                ResetStats(true);
            }

            animationHandler = GetComponent <AnimationHandler>();
        }
Esempio n. 6
0
 // Start is called before the first frame update
 void Start()
 {
     stats = GetComponent <PlayerStats>();
     statusEffectManager = GetComponent <StatusEffectManager>();
     animationHandler    = GetComponent <AnimationHandler>();
 }