public Attribute3(Perk perk) : base(perk) { uniquePerkSkillName = $"MechanicMaster.Attribute1: Sniper and CrossbowHunter fire rate increase"; handler += (turret, cash) => { if (turret.uniqueTurretName.Equals("Sniper") || turret.uniqueTurretName.Equals("CrossbowHunter")) { turret.AttackSpeed = turret.AttackSpeed + perk.currentLevel / 10 * deltaSpeed; } }; }
public Skill3(Perk perk) : base(perk) { uniquePerkSkillName = "Never Fly Away"; handler += (turret, cash) => { if (turret.uniqueTurretName.Equals("MachineGun") || turret.uniqueTurretName.Equals("PillBox")) { turret.targetFlyable = Turret.TargetFlyable.GroundAir; } }; }
public Attribute2(Perk perk) : base(perk) { uniquePerkSkillName = $"{nameof(MadBomber)}.{nameof(Attribute2)}"; handler += (turret, cash) => { if (turret is SharpnelThrower || turret is PatriotMissile || turret is RocketLauncher) { turret.MaxRange = (int)(turret.MaxRange * (1 + factor * perk.currentLevel)); } }; }
public Skill7(Perk perk) : base(perk) { uniquePerkSkillName = "Ranged Strike"; handler += (turret, cash) => { if (turret is SharpnelThrower || turret is PatriotMissile || turret is RocketLauncher) { turret.MaxRange = (int)((1 + factor) * turret.MaxRange); } }; }
public Skill4(Perk perk) : base(perk) { uniquePerkSkillName = "Ramrod and Reload"; handler += (turret, cash) => { if (turret.uniqueTurretName.Equals("CrossbowHunter") || turret.uniqueTurretName.Equals("SniPer")) { turret.AttackSpeed = turret.AttackSpeed + deltaSpeed; } }; }
public Attribute2(Perk perk) : base(perk) { uniquePerkSkillName = $"MechanicMaster.Attribute1: Sniper and CrossbowHunter basic damage increase"; handler += (turret, cash) => { if (turret.uniqueTurretName.Equals("Sniper") || turret.uniqueTurretName.Equals("CrossbowHunter")) { turret.DamageFactor += perk.currentLevel * factor; } }; }
public Skill8(Perk perk) : base(perk) { uniquePerkSkillName = "Millionare"; handler += (enemy) => { enemy.EnemyKilledEvent += (e) => { e.rewardcash = (int)(e.rewardcash * (1 + factor)); }; }; }
public Attribute1(Perk perk) : base(perk) { uniquePerkSkillName = $"{nameof(MadBomber)}.Attribute1"; handler += (turret, cash) => { if (turret is SharpnelThrower || turret is PatriotMissile || turret is RocketLauncher) { turret.DamageFactor += perk.currentLevel * factor; } }; }
public void InitPerks() { mm = GameObject.Find("Player/MechanicMaster").AddComponent <MechanicMaster>(); mb = GameObject.Find("Player/MadBomber").AddComponent <MadBomber>(); switch (currentPerkName) { case "MechanicMaster": currentPerk = mm; break; case "MadBomber": currentPerk = mb; break; } }
public Skill3(Perk perk) : base(perk) { uniquePerkSkillName = "High explosion round"; handler += (turret, cash) => { if (turret is SharpnelThrower || turret is PatriotMissile || turret is RocketLauncher) { turret.DamageFactor += factor; } }; }
public Attribute4(Perk perk) : base(perk) { uniquePerkSkillName = "MechanicMaster.Attribute4: Initialized cash bonus"; handler += (wave, cash) => { if (gameManager.gameMode.currentWave == 1) { gameManager.gameMode.currentCash += (int)(cash * factor); } }; }
public Attribute1(Perk perk) : base(perk) { uniquePerkSkillName = $"MechanicMaster.Attribute1"; handler += (turret, cash) => { if (turret.uniqueTurretName.Equals("MachineGun") || turret.uniqueTurretName.Equals("PillBox")) { turret.DamageFactor += perk.currentLevel * factor; } }; }
public Skill1(Perk perk) : base(perk) { uniquePerkSkillName = $"Speed Loader"; handler += (turret, cash) => { if (turret is SharpnelThrower || turret is PatriotMissile || turret is RocketLauncher) { turret.AttackSpeed = (int)((1 + deltaSpeedFactor) * turret.AttackSpeed); } ; }; }
public Skill1(Perk perk) : base(perk) { uniquePerkSkillName = "Armour Piercing Bullet"; handler += (turret, cash) => { var utn = turret.uniqueTurretName; if (utn.Equals("MachineGun") || utn.Equals("CrossbowHunter") || utn.Equals("PillBox") || utn.Equals("SniPer")) { turret.DamageFactor += factor; } }; }
public Skill2(Perk perk) : base(perk) { uniquePerkSkillName = "Aggregation"; handler += (turret, cash) => { if (turret is PatriotMissile || turret is RocketLauncher) { var buff = turret.ContainsBuff("ExplosiveEffect") as ExplosiveEffect; turret.DamageFactor += damageFactor; turret.MaxRange = (int)(turret.MaxRange * (1 - rangeFactor)); } }; }
public Skill4(Perk perk) : base(perk) { uniquePerkSkillName = "Back Off"; handler += (turret, cash) => { if (turret is PatriotMissile || turret is RocketLauncher) { var stunBuff = new StunEffect { duration = stunDuration, possibility = 1 }; stunBuff.uniqueBuffName = stunBuff.buffName + $":MadBomber.{uniquePerkSkillName}"; turret.AppendBuff(new StunEffect { duration = stunDuration, possibility = 1 }); } }; }
public Skill8(Perk perk) : base(perk) { uniquePerkSkillName = "Bully"; uniqueBuffName = "ExplosiveEffect:Bully"; handler += (turret, cash) => { if (turret is SharpnelThrower || turret is PatriotMissile || turret is RocketLauncher) { turret.AppendBuff(new ExplosiveEffectBully { radius = radius, uniqueBuffName = uniqueBuffName, damage = turret.Damage, damageType = Turret.DamageType.Explosive }); } }; }
public Skill5(Perk perk) : base(perk) { uniquePerkSkillName = "A New Type"; uniqueBuffName = $"ExplosiveEffect:MadBomber.{uniquePerkSkillName}"; handler += (turret, cash) => { if (turret.uniqueTurretName == "MachineGun" || turret.uniqueTurretName == "PillBox") { var ee = new ExplosiveEffect { damage = turret.Damage, radius = range, damageType = Turret.DamageType.Explosive, uniqueBuffName = uniqueBuffName }; ee.damageFactor = 0; turret.AppendBuff(ee); var temp = turret.DamageFactor; turret.DamageFactor = ee.damage; ee.damageFactor = temp; } }; }
public Skill6(Perk perk) : base(perk) { uniquePerkSkillName = "Explosion Type"; uniqueBuffName = "ExplosiveEffect:ExplosionType"; handler += (turret, cash) => { if (turret.uniqueTurretName == "MachineGun" || turret.uniqueTurretName == "PillBox") { turret.HasDirectHitDamage = false; turret.AppendBuff(new ExplosiveEffect { damage = turret.Damage, damageType = Turret.DamageType.Explosive, radius = radius, uniqueBuffName = uniqueBuffName }); } }; }
public void ChangePerk(string nextPerkName) { if (currentPerkName.Equals(nextPerkName)) { return; } else { switch (nextPerkName) { case "MechanicMaster": currentPerk = mm; break; case "MadBomber": currentPerk = mb; break; } currentPerkName = nextPerkName; } }
public Skill10(Perk perk) : base(perk) { uniquePerkSkillName = "Dud Versus Head"; handler += (turret, cash) => { if (turret is RocketLauncher) { if (turret.ContainsBuff("ExplosiveEffect") is ExplosiveEffect ee) { ee.bEnable = false; } switch (turret.currentLevel) { case 1: turret.DamageFactor += factor1; break; case 2: turret.DamageFactor += factor2; break; case 3: turret.DamageFactor += factor3; break; } } }; }
public PerkSkill(Perk perk) { this.perk = perk; }
public Skill7(Perk perk) : base(perk) { uniquePerkSkillName = "Crazy Boy"; }
public Skill6(Perk perk) : base(perk) { }
public Skill9(Perk perk) : base(perk) { uniquePerkSkillName = "Final Core"; }