Exemplo n.º 1
0
 public void Generate(ImmediateCube source)
 {
     this.damage       = source.damage;
     this.attackType   = source.attackType;
     this.targetType   = source.targetType;
     this.bulletPrefab = source.bulletPrefab;
     this.isTracing    = source.isTracing;
     this.hitEffect    = source.hitEffect;
 }
Exemplo n.º 2
0
 public void Generate(FiringCube source)
 {
     damage          = source.damage;
     attackType      = source.attackType;
     targetType      = source.targetType;
     bulletPrefab    = source.bulletPrefab;
     isTracing       = source.isTracing;
     duration        = source.duration;
     damagePerSecond = source.damagePerSecond;
 }
Exemplo n.º 3
0
 public void Generate(SlowCube source)
 {
     damage           = source.damage;
     attackType       = source.attackType;
     targetType       = source.targetType;
     bulletPrefab     = source.bulletPrefab;
     isTracing        = source.isTracing;
     hitEffect        = source.hitEffect;
     slowDuration     = source.slowDuration;
     slowSpeedPercent = source.slowSpeedPercent;
 }
Exemplo n.º 4
0
 public void Generate(ExplosionCube source)
 {
     damage               = source.damage;
     attackType           = source.attackType;
     targetType           = source.targetType;
     bulletPrefab         = source.bulletPrefab;
     isTracing            = source.isTracing;
     explosionRadius      = source.explosionRadius;
     explosionAttenuation = source.explosionAttenuation;
     hitEffect            = source.hitEffect;
 }
Exemplo n.º 5
0
 public void Generate(StunCube source)
 {
     damage       = source.damage;
     attackType   = source.attackType;
     targetType   = source.targetType;
     bulletPrefab = source.bulletPrefab;
     isTracing    = source.isTracing;
     hitEffect    = source.hitEffect;
     stunDuration = source.stunDuration;
     possibility  = source.possibility;
 }
Exemplo n.º 6
0
    public void TakeDamage(float damage, TowerDescription.AttackType type)
    {
        switch (type)
        {
        case TowerDescription.AttackType.bullet: TakeDamage(damage * bulletResis); break;

        case TowerDescription.AttackType.explosive: TakeDamage(damage * explosiveResis); break;

        case TowerDescription.AttackType.flame: TakeDamage(damage * flameResis); break;

        case TowerDescription.AttackType.tesla: TakeDamage(damage * teslaResis); break;

        case TowerDescription.AttackType.nuclear: TakeDamage(damage * nuclearResis); break;

        case TowerDescription.AttackType.unknown: Debug.Log("Unknown damage taken."); TakeDamage(damage); break;
        }
    }
Exemplo n.º 7
0
    internal float GetResis(TowerDescription.AttackType type)
    {
        switch (type)
        {
        case TowerDescription.AttackType.bullet: return(bulletResis);

        case TowerDescription.AttackType.explosive: return(explosiveResis);

        case TowerDescription.AttackType.flame: return(flameResis);

        case TowerDescription.AttackType.tesla: return(teslaResis);

        case TowerDescription.AttackType.nuclear: return(nuclearResis);

        default: return(1);
        }
    }
Exemplo n.º 8
0
    public void Generate(ExplosionFiringCube source)
    {
        damage                  = source.damage;
        attackType              = source.attackType;
        targetType              = source.targetType;
        bulletPrefab            = source.bulletPrefab;
        isTracing               = source.isTracing;
        target                  = source.target;
        explosionRadius         = source.explosionRadius;
        explosionAttenuation    = source.explosionAttenuation;
        hitEffect               = source.hitEffect;
        explosionParticleEffect = source.explosionParticleEffect;

        firingRadius         = source.firingRadius;
        duration             = source.duration;
        damagePerSecond      = source.damagePerSecond;
        firingParticleEffect = source.firingParticleEffect;
    }