protected override IList <SpellEffect> GetHitEffects(Page page, Character caster, Character target) { float targetHealthPercentage = ((float)target.Stats.GetStatCount(Stats.Get.MOD, StatType.HEALTH)) / target.Stats.GetStatCount(Stats.Get.MAX, StatType.HEALTH); int tentaclesToSummon = 0; // TODO fix this terrible code, use a dictionary please if (targetHealthPercentage > .66) { tentaclesToSummon = 2; } else if (targetHealthPercentage > .33) { tentaclesToSummon = 3; } else { tentaclesToSummon = 4; } Func <Character> summonTentacleFunc = () => { Character tentacle = OceanNPCs.Tentacle(); Interceptor interceptor = new Interceptor(); interceptor.Caster = new BuffParams(target.Stats, target.Id); tentacle.Buffs.AddBuff(interceptor); return(tentacle); }; return(new SpellEffect[] { new SummonEffect(page.GetSide(target), page, summonTentacleFunc, tentaclesToSummon) }); }
private static Area SeaWorld(Flags flags, Party party, Page camp, Page quests) { return(new Area( AreaType.SEA_WORLD, new Stage[] { new BattleStage( "Welcome to the ocean", () => new Encounter[] { new Encounter(OceanNPCs.SharkPirate()) }), new BattleStage( "Sinister singers", () => new Encounter[] { new Encounter(OceanNPCs.Siren()), new Encounter(OceanNPCs.Siren(), OceanNPCs.SharkPirate()) }), new BattleStage( "Insaniquarium", () => new Encounter[] { new Encounter(OceanNPCs.Shark(), OceanNPCs.Siren()), new Encounter(OceanNPCs.Shark(), OceanNPCs.Siren(), OceanNPCs.Shark(), OceanNPCs.Siren()) }), new BattleStage( "GitKraken", () => new Encounter [] { new Encounter(Music.BOSS, OceanNPCs.Kraken()) }), new BattleStage( "Heart of the Swarm", () => new Encounter[] { new Encounter(OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Swarm()), new Encounter(OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Swarm()), new Encounter(OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Swarm()), }), new BattleStage( "Nearing the end", () => new Encounter[] { new Encounter(OceanNPCs.DreadSinger()), new Encounter(OceanNPCs.Elemental()), }), new BattleStage( "Final Trench", () => new Encounter[] { new Encounter(OceanNPCs.DreadSinger(), OceanNPCs.DreadSinger()), new Encounter(OceanNPCs.Elemental(), OceanNPCs.Elemental(), OceanNPCs.DreadSinger()), new Encounter(OceanNPCs.Elemental(), OceanNPCs.Siren(), OceanNPCs.SharkPirate(), OceanNPCs.DreadSinger()), new Encounter(OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Swarm(), OceanNPCs.Elemental(), OceanNPCs.Siren(), OceanNPCs.SharkPirate(), OceanNPCs.DreadSinger()) }), new BattleStage( "Finale", () => new Encounter[] { new Encounter(OceanNPCs.Elemental()) }) }, new PageGroup[] { OceanNPCs.OceanShop(camp, flags, party) } )); }