public TimedAreaDamageOverTimeEffect(ScriptableEffect effect, Enemy enemy) : base(effect, enemy)
    {
        var damageEffect = (ScriptableAreaDamageEffect)Effect;

        _mainEnemy    = enemy;
        _closeEnemies = new Collider[damageEffect.maxEnemies];
        _enemiesCount = Physics.OverlapSphereNonAlloc(_mainEnemy.transform.position, damageEffect.areaSize, _closeEnemies, LayerManager.Instance.enemyLayerMask);
    }
Example #2
0
 public TimedEffect(ScriptableEffect effect, Enemy enemy)
 {
     Effect    = effect;
     Enemy     = enemy;
     _interval = Interval;
 }
 public TimedAreaDamageEffect(ScriptableEffect effect, Enemy enemy) : base(effect, enemy)
 {
     _mainEnemy = enemy;
 }
 private static IEnumerator LoadEffectsResources <K, V>(Dictionary <K, V> effectCache) where V : ScriptableEffect
 {
     yield return(ScriptableEffect.LoadAll(effectCache.Values));
 }
 public TimedDamageOverTimeEffect(ScriptableEffect effect, Enemy enemy) : base(effect, enemy)
 {
     _enemy = enemy;
 }
Example #6
0
 public TimedSpeedEffect(ScriptableEffect effect, Enemy enemy) : base(effect, enemy)
 {
     _enemy = enemy;
 }