public WeaponStats GetCopy() { if (Gift != null) { return new WeaponStats(Damage, Speed, Splash, Debuff.GetInstance(Gift.Target, Gift.Amount, Gift.Duration)); } else { return new WeaponStats(Damage, Speed, Splash); } }
public Projectile(WeaponStats stats, Creep targetCreep, Vector2 startPoint, TowerTypes parentTowerType) { Stats = stats.GetCopy(); TargetCreep = targetCreep; CenterPosition = startPoint; this.type = SelectTypeBasedOnTowerType(parentTowerType); this.TextureID = TowerFactory.GetProjectileMediaID(type); this.numFrames = ProjectileDefinitions.ProjectileStats[type].NumFrames; }