コード例 #1
0
            public Oracle.Spirit createOracleSpirit(HexEngine associated_hex_engine, string asset_prefix, bool test = false)
            {
                test_mode      = test;
                hex_engine     = associated_hex_engine;
                prefix         = asset_prefix;
                primary_stat   = hex_engine.hex_stat;
                secondary_stat = hex_engine.hex_stat;
                createHexes();

                createSpiritAbility();
                createGreaterSpiritAbility();

                spells = new BlueprintAbility[9]
                {
                    library.Get <BlueprintAbility>("91da41b9793a4624797921f221db653c"),                                                                    //color sparay
                    NewSpells.hypnotic_pattern,
                    SpellDuplicates.addDuplicateSpell(library.Get <BlueprintAbility>("ce7dad2b25acf85429b6c9550787b2d9"), "ShamanHeavensGlitterdust", ""), //glitterdust
                    library.Get <BlueprintAbility>("4b8265132f9c8174f87ce7fa6d0fe47b"),                                                                    //rainbow pattern
                    NewSpells.overland_flight,
                    library.Get <BlueprintAbility>("645558d63604747428d55f0dd3a4cb58"),                                                                    //chain lightning
                    library.Get <BlueprintAbility>("b22fd434bdb60fb4ba1068206402c4cf"),                                                                    //prismatic spray
                    library.Get <BlueprintAbility>("e96424f70ff884947b06f41a765b7658"),                                                                    //sunburst
                    NewSpells.meteor_swarm
                };

                return(new Oracle.Spirit("Heavens",
                                         "Heavens",
                                         "A shaman who selects the heavens spirit has eyes that sparkle like starlight, exuding an aura of otherworldliness to those she is around. When she calls upon one of this spirit’s abilities, her eyes turn pitch black and the colors around her drain for a brief moment.",
                                         library.Get <BlueprintAbility>("ce7dad2b25acf85429b6c9550787b2d9").Icon,//glitterdust
                                         "",
                                         spirit_ability,
                                         greater_spirit_ability,
                                         spells,
                                         hexes));
            }
コード例 #2
0
            public Oracle.Spirit createOracleSpirit(HexEngine associated_hex_engine, string asset_prefix, bool test = false)
            {
                test_mode      = test;
                hex_engine     = associated_hex_engine;
                prefix         = asset_prefix;
                primary_stat   = hex_engine.hex_stat;
                secondary_stat = hex_engine.hex_stat;

                createHexes();

                createSpiritAbility();
                createGreaterSpiritAbility();

                spells = new BlueprintAbility[9]
                {
                    library.Get <BlueprintAbility>("4783c3709a74a794dbe7c8e7e0b1b038"),                                         //burning hands
                    library.Get <BlueprintAbility>("21ffef7791ce73f468b6fca4d9371e8b"),                                         //resist energy
                    library.Get <BlueprintAbility>("2d81362af43aeac4387a3d4fced489c3"),                                         //fireball
                    NewSpells.wall_of_fire,
                    library.Get <BlueprintAbility>("b3a203742191449458d2544b3f442194"),                                         //summon elemental large fire
                    NewSpells.fire_seeds,
                    SpellDuplicates.addDuplicateSpell("e3d0dfe1c8527934294f241e0ae96a8d", "FireStormShamanFlameSpiritAbility"), //firestorm
                    NewSpells.incendiary_cloud,
                    library.Get <BlueprintAbility>("08ccad78cac525040919d51963f9ac39"),                                         //fiery body
                };
                return(new Oracle.Spirit("Flame",
                                         "Flame",
                                         "A shaman who selects the flame spirit has a radiant light behind her eyes and the faint smell of smoke about her. When she calls upon one of this spirit’s abilities, a hungry spectral flame dances around her body.",
                                         library.Get <BlueprintAbility>("19309b5551a28d74288f4b6f7d8d838d").Icon, //wall of fire
                                         "",
                                         spirit_ability,
                                         greater_spirit_ability,
                                         spells,
                                         hexes));
            }
コード例 #3
0
            internal static Spirit create()
            {
                createCinderDanceHex();

                createSpiritAbility();
                createGreaterSpiritAbility();
                createTrueSpiritAbility();
                createManifestation();

                spells = new BlueprintAbility[9]
                {
                    library.Get <BlueprintAbility>("4783c3709a74a794dbe7c8e7e0b1b038"), //burning hands
                    library.Get <BlueprintAbility>("21ffef7791ce73f468b6fca4d9371e8b"), //resist energy
                    library.Get <BlueprintAbility>("2d81362af43aeac4387a3d4fced489c3"), //fireball
                    library.Get <BlueprintAbility>("f72f8f03bf0136c4180cd1d70eb773a5"), //controlled fireball
                    library.Get <BlueprintAbility>("b3a203742191449458d2544b3f442194"), //summon elemental large fire
                    NewSpells.fire_seeds,
                    SpellDuplicates.addDuplicateSpell("e3d0dfe1c8527934294f241e0ae96a8d", "FireStormShamanFlameSpiritAbility"),
                    library.Get <BlueprintAbility>("e4926aa766a1cc048835237b3a97597d"), //summon elemental elder fire
                    library.Get <BlueprintAbility>("08ccad78cac525040919d51963f9ac39"), //fiery body
                };

                fire_nimbus = hex_engine.createFireNimbus("ShamanFireNimbus",
                                                          "Fire Nimbus",
                                                          "The shaman causes a creature within 30 feet to gain a nimbus of fire. Though this doesn’t harm the creature, it does cause the creature to emit light like a torch, preventing it from gaining any benefit from concealment or invisibility. The target also takes a –2 penalty on saving throws against spells or effects that deal fire damage. The fire nimbus lasts for a number of rounds equal to the shaman’s level. A successful Will saving throw negates this effect. Whether or not the save is successful, the creature cannot be the target of this hex again for 24 hours."
                                                          );

                flame_curse = hex_engine.createFlameCurse("ShamanFlameCurse",
                                                          "Flame Curse",
                                                          "The shaman causes a creature within 30 feet to become vulnerable to fire until the end of the shaman’s next turn. If the creature is already vulnerable to fire, this hex has no effect. Fire immunity and resistances apply as normal, and any saving throw allowed by the effect that caused the damage reduces it as normal. At 8th and 16th levels, the duration of this hex is extended by 1 round. A creature affected by this hex cannot be affected by it again for 24 hours."
                                                          );

                ward_of_flames = hex_engine.createFlameWardHex("ShamanFlameWard",
                                                               "Flame Ward",
                                                               "The shaman touches a willing creature (including herself ) and grants a ward of flames. The next time the warded creature is struck with a melee attack, the creature making the attack takes 1d6 points of fire damage + 1 point of fire damage for every 2 shaman levels she possesses. This ward lasts for 1 minute, after which it fades away if not already expended. At 8th and 16th levels, the ward lasts for one additional attack. A creature affected by this hex cannot be affected by it again for 24 hours."
                                                               );
                hexes = new BlueprintFeature[]
                {
                    cinder_dance,
                    fire_nimbus,
                    flame_curse,
                    ward_of_flames,
                };


                return(new Spirit("Flame",
                                  "Flame",
                                  "A shaman who selects the flame spirit has a radiant light behind her eyes and the faint smell of smoke about her. When she calls upon one of this spirit’s abilities, a hungry spectral flame dances around her body.",
                                  library.Get <BlueprintAbility>("19309b5551a28d74288f4b6f7d8d838d").Icon, //wall of fire
                                  "",
                                  spirit_ability,
                                  greater_spirit_ability,
                                  true_spirit_ability,
                                  manifestation,
                                  hexes,
                                  spells));
            }
コード例 #4
0
            public void OnEventAboutToTrigger(RuleCalculateAbilityParams evt)
            {
                var spell = (this.Fact as Feature)?.Param.Blueprint as BlueprintAbility;

                if (SpellDuplicates.isDuplicate(spell, evt.Spell) || SpellDuplicates.isDuplicate(spell, evt.Spell?.Parent))
                {
                    evt.AddBonusCasterLevel(bonus);
                }
            }
コード例 #5
0
ファイル: Life.cs プロジェクト: zedr0n/KingmakerRebalance
            internal static Spirit create()
            {
                createSpiritAbility();
                createGreaterSpiritAbility();
                createTrueSpiritAbility();
                createManifestation();

                spells = new BlueprintAbility[9]
                {
                    library.Get <BlueprintAbility>("f6f95242abdfac346befd6f4f6222140"),                                            //remove sickness
                    library.Get <BlueprintAbility>("e84fc922ccf952943b5240293669b171"),                                            //lesser restoration
                    SpellDuplicates.addDuplicateSpell("e7240516af4241b42b2cd819929ea9da", "ShamanLifeSpiritNeutralizePoison", ""), //neutralzie poison
                    library.Get <BlueprintAbility>("f2115ac1148256b4ba20788f7e966830"),                                            //restoration
                    library.Get <BlueprintAbility>("d5847cad0b0e54c4d82d6c59a3cda6b0"),                                            //breath of life
                    SpellDuplicates.addDuplicateSpell("5da172c4c89f9eb4cbb614f3a67357d3", "ShamanLifeSpiritHeal", ""),             //heal
                    library.Get <BlueprintAbility>("fafd77c6bfa85c04ba31fdc1c962c914"),                                            //greater restoration
                    SpellDuplicates.addDuplicateSpell("867524328b54f25488d371214eea0d90", "shamanLifeSpiritMassHeal", ""),         //mass heal
                    SpellDuplicates.addDuplicateSpell("80a1a388ee938aa4e90d427ce9a7a3e9", "shamanLifeSpiritResurrection", ""),     //resurrection
                };

                curse_of_suffereing = BattleSpirit.curse_of_suffering_hex;
                enhanced_cures      = hex_engine.createEnchancedCures("ShamanEnhancedCures",
                                                                      "Enhanced Cures",
                                                                      "When the shaman casts a cure spell, the maximum number of hit points healed is based on her shaman level, not the limit imposed by the spell. For example an 11th-level shaman with this hex can cast cure light wounds to heal 1d8+11 hit points instead of the normal 1d8+5 maximum."
                                                                      );

                life_link = hex_engine.createLifeLink("ShamanLifeLink",
                                                      "Life Link",
                                                      "The shaman creates a bond between herself and another creature within 30 feet. Each round at the start of the shaman’s turn, if the bonded creature is wounded for 5 or more hit points below its maximum hit points it heals 5 hit points and the shaman takes 5 points of damage. The shaman can have one bond active per shaman level. The bond continues until the bonded creature dies, the shaman dies, the distance between her and the bonded creature exceeds 40 feet, or the shaman ends it as an immediate action. If the shaman has multiple bonds active, she can end as many as she wants with the same immediate action."
                                                      );

                life_sight = hex_engine.createLifeSight("ShamanLifeSight",
                                                        "Life Sight",
                                                        "Shaman is able to sense all nearby living creatures; this functions similar to blindsight, but only for living creatures within 30 feet of her. The shaman can use this ability a number of rounds per day equal to her shaman level, but these rounds do not need to consecutive."
                                                        );

                hexes = new BlueprintFeature[]
                {
                    curse_of_suffereing,
                    enhanced_cures,
                    life_sight,
                    life_link,
                };

                return(new Spirit("Life",
                                  "Life",
                                  "A shaman who selects the life spirit appears more vibrant than most mortals. Her skin seems to glow, and her teeth are a pearly white. When she calls upon one of this spirit’s abilities, her eyes and hair shimmer in the light.",
                                  manifestation.Icon,
                                  "",
                                  spirit_ability,
                                  greater_spirit_ability,
                                  true_spirit_ability,
                                  manifestation,
                                  hexes,
                                  spells));
            }
コード例 #6
0
            public void OnEventAboutToTrigger(RuleCalculateAbilityParams evt)
            {
                var spell = (this.Fact as Feature)?.Param.Blueprint as BlueprintAbility;

                if (SpellDuplicates.isDuplicate(spell, evt.Spell) || SpellDuplicates.isDuplicate(spell, evt.Spell?.Parent))
                {
                    evt.AddBonusDC(dc_bonus.Calculate(this.Fact.MaybeContext));
                    evt.AddBonusConcentration(concentration_bonus.Calculate(this.Fact.MaybeContext));
                }
            }
コード例 #7
0
        static bool Prefix(SpellSpecializationParametrized __instance, RuleCalculateAbilityParams evt)
        {
            var spell = (__instance.Fact as Feature)?.Param.Blueprint as BlueprintAbility;

            if (SpellDuplicates.isDuplicate(spell, evt.Spell) || SpellDuplicates.isDuplicate(spell, evt.Spell?.Parent))
            {
                evt.AddBonusCasterLevel(2);
            }

            return(false);
        }
コード例 #8
0
            public override void OnEventAboutToTrigger(RuleCalculateAbilityParams evt)
            {
                int bonus = this.Value.Calculate(this.Context);

                foreach (var s in Spells)
                {
                    if (SpellDuplicates.isDuplicate(s, evt.Spell))
                    {
                        evt.AddBonusDC(bonus);
                        return;
                    }
                }
            }
コード例 #9
0
            public override void OnEventAboutToTrigger(RuleSpellResistanceCheck evt)
            {
                int bonus = this.Value.Calculate(this.Context);

                foreach (var s in Spells)
                {
                    if (SpellDuplicates.isDuplicate(s, evt.Ability))
                    {
                        evt.AdditionalSpellPenetration += bonus;
                        return;
                    }
                }
            }
コード例 #10
0
            public override void OnEventAboutToTrigger(RuleSavingThrow evt)
            {
                BlueprintAbility sourceAbility = evt.Reason.Context?.SourceAbility;

                int bonus = this.Value.Calculate(this.Context);

                foreach (var s in Spells)
                {
                    if (SpellDuplicates.isDuplicate(s, evt.Reason.Context?.SourceAbility))
                    {
                        evt.AddTemporaryModifier(evt.Initiator.Stats.SaveWill.AddModifier(bonus, (GameLogicComponent)this, this.ModifierDescriptor));
                        evt.AddTemporaryModifier(evt.Initiator.Stats.SaveReflex.AddModifier(bonus, (GameLogicComponent)this, this.ModifierDescriptor));
                        evt.AddTemporaryModifier(evt.Initiator.Stats.SaveFortitude.AddModifier(bonus, (GameLogicComponent)this, this.ModifierDescriptor));
                        return;
                    }
                }
            }
コード例 #11
0
            public Shaman.Spirit createShamanSpirit(HexEngine associated_hex_engine, string asset_prefix, string extra_channel_asset_prefix, string extra_channel_asset_name, bool test = false)
            {
                test_mode            = test;
                hex_engine           = associated_hex_engine;
                prefix               = asset_prefix;
                extra_channel_prefix = extra_channel_asset_prefix;
                extra_channel_name   = extra_channel_asset_name;
                primary_stat         = hex_engine.hex_stat;
                secondary_stat       = hex_engine.hex_secondary_stat;

                createSpiritAbility();
                createGreaterSpiritAbility();
                createTrueSpiritAbility();
                createManifestation();

                createHexes();

                spells = new BlueprintAbility[9]
                {
                    library.Get <BlueprintAbility>("f6f95242abdfac346befd6f4f6222140"),                                            //remove sickness
                    library.Get <BlueprintAbility>("e84fc922ccf952943b5240293669b171"),                                            //lesser restoration
                    SpellDuplicates.addDuplicateSpell("e7240516af4241b42b2cd819929ea9da", "ShamanLifeSpiritNeutralizePoison", ""), //neutralzie poison
                    library.Get <BlueprintAbility>("f2115ac1148256b4ba20788f7e966830"),                                            //restoration
                    library.Get <BlueprintAbility>("d5847cad0b0e54c4d82d6c59a3cda6b0"),                                            //breath of life
                    SpellDuplicates.addDuplicateSpell("5da172c4c89f9eb4cbb614f3a67357d3", "ShamanLifeSpiritHeal", ""),             //heal
                    library.Get <BlueprintAbility>("fafd77c6bfa85c04ba31fdc1c962c914"),                                            //greater restoration
                    SpellDuplicates.addDuplicateSpell("867524328b54f25488d371214eea0d90", "shamanLifeSpiritMassHeal", ""),         //mass heal
                    SpellDuplicates.addDuplicateSpell("80a1a388ee938aa4e90d427ce9a7a3e9", "shamanLifeSpiritResurrection", ""),     //resurrection
                };

                return(new Shaman.Spirit("Life",
                                         "Life",
                                         "A shaman who selects the life spirit appears more vibrant than most mortals. Her skin seems to glow, and her teeth are a pearly white. When she calls upon one of this spirit’s abilities, her eyes and hair shimmer in the light.",
                                         manifestation.Icon,
                                         "",
                                         spirit_ability,
                                         greater_spirit_ability,
                                         true_spirit_ability,
                                         manifestation,
                                         hexes,
                                         spells));
            }
コード例 #12
0
        static void createFear()
        {
            var shaken               = library.Get <BlueprintBuff>("25ec6cb6ab1845c48a95f9c20b034220");
            var frightened           = library.Get <BlueprintBuff>("f08a7239aa961f34c8301518e71d4cdf");
            var frightened_aura_buff = library.CopyAndAdd <BlueprintBuff>("f08a7239aa961f34c8301518e71d4cdf", "FrightenedFearPhantomAuraBuff", "f4c61d62e328424697f291b76bc3b9cc");
            var apply_shakened       = Common.createContextActionApplyBuff(shaken, Helpers.CreateContextDuration(diceCount: 1, diceType: DiceType.D4), dispellable: false);
            var apply_frighted       = Common.createContextActionApplyBuff(frightened, Helpers.CreateContextDuration(diceCount: 1, diceType: DiceType.D4), dispellable: false);


            var frightful_attack_buff = Helpers.CreateBuff("FearPhantomFrightfulAttackBuff",
                                                           "Frightful Attack",
                                                           "When the spiritualist reaches 12th level, if the phantom hits with a slam attack, it can frighten those it hits instead of causing them to be shaken (the phantom chooses when it makes the attack). This is a mind-affecting fear effect.",
                                                           "",
                                                           frightened.Icon,
                                                           null
                                                           );
            var frightful_attack_toggle = Helpers.CreateActivatableAbility("FearPhantomFrightfulAttackToggleAbility",
                                                                           frightful_attack_buff.Name,
                                                                           frightful_attack_buff.Description,
                                                                           "",
                                                                           frightful_attack_buff.Icon,
                                                                           frightful_attack_buff,
                                                                           AbilityActivationType.Immediately,
                                                                           UnitCommand.CommandType.Free,
                                                                           null);

            var frightful_attack = Common.ActivatableAbilityToFeature(frightful_attack_toggle, false);
            var apply_effect     = Helpers.CreateConditional(Common.createContextConditionCasterHasFact(frightful_attack_buff),
                                                             Helpers.CreateActionSavingThrow(SavingThrowType.Will, Helpers.CreateConditionalSaved(null, apply_frighted)),
                                                             Helpers.CreateActionSavingThrow(SavingThrowType.Will, Helpers.CreateConditionalSaved(null, apply_shakened)));

            var horryfying_strike = Helpers.CreateFeature("FearPhantomHorrifyingStrikeFeature",
                                                          "Horrifying Strike",
                                                          "If the phantom hits a creature with a slam attack, that creature must succeed at a Will saving throw (DC = 10 + 1/2 the phantom’s Hit Dice + the phantom’s Charisma modifier) or be shaken for 1d4 rounds. Multiple attacks against the same creature do not cause the creature to become frightened. This is a mind-affecting fear effect.",
                                                          "",
                                                          shaken.Icon,
                                                          FeatureGroup.None,
                                                          Common.createAddInitiatorAttackWithWeaponTriggerWithCategory(Helpers.CreateActionList(apply_effect),
                                                                                                                       wait_for_attack_to_resolve: true,
                                                                                                                       weapon_category: WeaponCategory.OtherNaturalWeapons
                                                                                                                       ),
                                                          Common.createContextCalculateAbilityParamsBasedOnClasses(getPhantomSpiritualistArray(), StatType.Charisma),
                                                          Helpers.CreateSpellDescriptor(SpellDescriptor.MindAffecting | SpellDescriptor.Fear | SpellDescriptor.Shaken)
                                                          );

            var horryfying_strike_exciter = Helpers.CreateFeature("FearPhantomHorrifyingStrikeExciterFeature",
                                                                  "Horrifying Strike",
                                                                  "If the phantom hits a creature with a slam attack, that creature must succeed at a Will saving throw (DC = 10 + 1/2 the phantom’s Hit Dice + the phantom’s Charisma modifier) or be shaken for 1d4 rounds. Multiple attacks against the same creature do not cause the creature to become frightened. This is a mind-affecting fear effect.",
                                                                  "",
                                                                  shaken.Icon,
                                                                  FeatureGroup.None,
                                                                  Common.createAddInitiatorAttackWithWeaponTrigger(Helpers.CreateActionList(apply_effect),
                                                                                                                   wait_for_attack_to_resolve: true,
                                                                                                                   check_weapon_range_type: true,
                                                                                                                   range_type: AttackTypeAttackBonus.WeaponRangeType.Melee
                                                                                                                   ),
                                                                  Common.createContextCalculateAbilityParamsBasedOnClasses(getPhantomSpiritualistArray(), StatType.Charisma),
                                                                  Helpers.CreateSpellDescriptor(SpellDescriptor.MindAffecting | SpellDescriptor.Fear | SpellDescriptor.Shaken)
                                                                  );



            var immunity_to_fear_buff = library.CopyAndAdd <BlueprintBuff>("c5c86809a1c834e42a2eb33133e90a28", "FearPhantomShelterAlliesBuff", "");

            immunity_to_fear_buff.ComponentsArray = new BlueprintComponent[]
            {
                Common.createAddConditionImmunity(Kingmaker.UnitLogic.UnitCondition.Shaken),
                Common.createAddConditionImmunity(Kingmaker.UnitLogic.UnitCondition.Frightened),
                Common.createBuffDescriptorImmunity(SpellDescriptor.Shaken | SpellDescriptor.Frightened),
                Common.createSpellImmunityToSpellDescriptor(SpellDescriptor.Shaken | SpellDescriptor.Frightened)
            };

            immunity_to_fear_buff.SetNameDescription("Shelter Allies",
                                                     "When the spiritualist reaches 17th level, the phantom protects its allies from terror. Allies within the phantom’s increase fear aura are immune to fear as long as they are within the aura."
                                                     );

            var shelter_allies = Helpers.CreateFeature("FearPhantomShelterAlliesFeature",
                                                       immunity_to_fear_buff.Name,
                                                       immunity_to_fear_buff.Description,
                                                       "",
                                                       immunity_to_fear_buff.Icon,
                                                       FeatureGroup.None);

            var save_suceeded_buff = Helpers.CreateBuff("FearPhantomIncreasedFearImmuneBuff",
                                                        "",
                                                        "",
                                                        "f915d82077db4e3b8c00d954a98d2c3a",
                                                        null,
                                                        null
                                                        );

            save_suceeded_buff.SetBuffFlags(BuffFlags.RemoveOnRest | BuffFlags.HiddenInUi);

            var aura_effect_enemy_save = Helpers.CreateActionSavingThrow(SavingThrowType.Will,
                                                                         Helpers.CreateConditionalSaved(Common.createContextActionApplyBuff(save_suceeded_buff, Helpers.CreateContextDuration(), dispellable: false, is_permanent: true),
                                                                                                        Common.createContextActionApplyBuff(frightened_aura_buff, Helpers.CreateContextDuration(), dispellable: false, is_permanent: true)
                                                                                                        )
                                                                         );
            var aura_effect_enemy = Helpers.CreateConditional(new Condition[] { Common.createContextConditionHasBuffFromCaster(save_suceeded_buff, not: true),
                                                                                Common.createContextConditionHasBuffFromCaster(frightened_aura_buff, not: true) },
                                                              aura_effect_enemy_save);
            var aura_effect_ally = Common.createContextActionApplyBuff(immunity_to_fear_buff, Helpers.CreateContextDuration(), dispellable: false, is_permanent: true);

            var aura_effect = Helpers.CreateConditional(Helpers.Create <ContextConditionIsEnemy>(),
                                                        Helpers.CreateConditional(Helpers.Create <NewMechanics.ContextConditionHasCondition>(c => c.condition = Kingmaker.UnitLogic.UnitCondition.Shaken),
                                                                                  aura_effect_enemy,
                                                                                  Common.createContextActionRemoveBuffFromCaster(frightened_aura_buff)
                                                                                  ),
                                                        Helpers.CreateConditional(Common.createContextConditionCasterHasFact(shelter_allies),
                                                                                  aura_effect_ally)
                                                        );

            var remove_effect = Helpers.CreateConditional(new Condition[] { Helpers.Create <ContextConditionIsEnemy>() },
                                                          new GameAction[] { Common.createContextActionRemoveBuffFromCaster(save_suceeded_buff),
                                                                             Common.createContextActionRemoveBuffFromCaster(frightened_aura_buff), },
                                                          new GameAction[] { Common.createContextActionRemoveBuffFromCaster(immunity_to_fear_buff) }
                                                          );
            var aura_component = Helpers.CreateAreaEffectRunAction(unitEnter: aura_effect,
                                                                   unitExit: remove_effect,
                                                                   round: aura_effect
                                                                   );


            var toggle = Common.createToggleAreaEffect("FearPhantomIncreaseFear",
                                                       "Increase Fear",
                                                       "When the spiritualist reaches 7th level, as a swift action, the phantom can emit a 20-foot radius aura that amplifies the fear conditions of enemies within it if they fail their Will saving throws (DC = 10 + 1/2 the phantom’s Hit Dice + the phantom’s Charisma modifier). A shaken enemy in the aura becomes frightened, a frightened creature becomes panicked, and a panicked creature cowers. This effect lasts either as long as the enemy stays within the aura and is under the condition of the initial fear effect, or for a number of rounds after it leaves the aura equal to 1/2 the phantom’s Hit Dice, or until the end of the original fear effect’s duration, whichever comes first. A creature that succeeds at the saving throw is immune to this effect from the same phantom for 24 hours. This is a mind-affecting fear effect.",
                                                       Helpers.GetIcon("08cb5f4c3b2695e44971bf5c45205df0"), //scare
                                                       20.Feet(),
                                                       AbilityActivationType.WithUnitCommand,
                                                       UnitCommand.CommandType.Swift,
                                                       Common.createPrefabLink("8a80d991f3d68e84293e098a6faa7620"), //unholy
                                                       null,
                                                       new BlueprintComponent[]
            {
                aura_component,
                Common.createContextCalculateAbilityParamsBasedOnClasses(getPhantomSpiritualistArray(), StatType.Charisma),
                frightened.GetComponent <SpellDescriptorComponent>()
            }
                                                       );

            toggle.DeactivateIfOwnerDisabled = true;
            var increase_fear = Common.ActivatableAbilityToFeature(toggle, false);

            var stealthy = library.Get <BlueprintFeature>("c7e1d5ef809325943af97f093e149c4f");

            var stealthy_phantom = Common.featureToFeature(stealthy, false);

            stealthy_phantom.SetDescription("The phantom gains Stealthy as a bonus feat.");

            var fear_archetype = createPhantomArchetype("FearPhantomArchetype",
                                                        "Fear",
                                                        false,
                                                        true,
                                                        true,
                                                        new StatType[] { StatType.SkillPersuasion, StatType.SkillStealth },
                                                        new LevelEntry[] { Helpers.LevelEntry(1, stealthy_phantom) },
                                                        new LevelEntry[] { Helpers.LevelEntry(1) }
                                                        );

            //bane, scare, fear, phantasmal killer, phantasmal web, frightful aspect
            createPhantom("Fear",
                          "Fear",
                          "A phantom with this emotional focus suffered from overwhelming fear in life. As a phantom, it is able to channel that fear into a terrifying weapon. Fear phantoms are often horrifying to behold. Sometimes they appear as ghostly figures in tattered funeral garb or wrapped in chains or other bindings. Their features may be distorted into gaunt and haunting forms, making them seem more like ghosts or spectres. A miasma of livid gray swirling motes often surrounds their forms as they stalk their surroundings, seeking to bestow their terror on others.\n"
                          + "Skills: The phantom gains a number of ranks in Persuasion and Stealth equal to its number of Hit Dice. While confined in the spiritualist’s consciousness, such a phantom grants the spiritualist Skill Focus in each of these skills.\n"
                          + "Good Saves: Reflex and Will.\n"
                          + "Stealthy: The phantom gains Stealthy as a bonus feat.",
                          frightened.Icon,
                          fear_archetype,
                          horryfying_strike, increase_fear, frightful_attack, shelter_allies,
                          new StatType[] { StatType.SkillPersuasion, StatType.SkillStealth },
                          12, 14,
                          new BlueprintAbility[]
            {
                library.Get <BlueprintAbility>("8bc64d869456b004b9db255cdd1ea734"),             //bane
                NewSpells.savage_maw,
                library.Get <BlueprintAbility>("8a28a811ca5d20d49a863e832c31cce1"),             //vampyric touch
                library.Get <BlueprintAbility>("6717dbaef00c0eb4897a1c908a75dfe5")              //phantasmal killer
            },
                          horryfying_strike_exciter,
                          increase_fear,
                          emotion_conduit_spells: new BlueprintAbility[]
            {
                library.Get <BlueprintAbility>("8bc64d869456b004b9db255cdd1ea734"),              //bane
                library.Get <BlueprintAbility>("08cb5f4c3b2695e44971bf5c45205df0"),              //scare
                SpellDuplicates.addDuplicateSpell(library.Get <BlueprintAbility>("d2aeac47450c76347aebbc02e4f463e0"), "EmotionConduitFearSpell", ""),
                library.Get <BlueprintAbility>("6717dbaef00c0eb4897a1c908a75dfe5"),              //phantasmal killer
                library.Get <BlueprintAbility>("12fb4a4c22549c74d949e2916a2f0b6a"),              //phantasmal web
                library.Get <BlueprintAbility>("e788b02f8d21014488067bdd3ba7b325"),              //frightful aspect
            }
                          );
        }
コード例 #13
0
ファイル: Anger.cs プロジェクト: veidral/KingmakerRebalance
        static void createAnger()
        {
            var powerful_strikes = Helpers.CreateFeature("AngerPhantomPowerfulStrikesFeature",
                                                         "Powerful Strikes",
                                                         "A phantom with this focus deals more damage with its slam attacks. It deals slam damage as a creature one size category larger than its current size.\n"
                                                         + "The phantom also gains Power Attack as a bonus feat.",
                                                         "",
                                                         Helpers.GetIcon("7812ad3672a4b9a4fb894ea402095167"), //improved unarmed strike
                                                         FeatureGroup.None
                                                                                                              //Common.createWeaponTypeSizeChange(1, new BlueprintWeaponType[] { library.Get<BlueprintWeaponType>("f18cbcb39a1b35643a8d129b1ec4e716") })
                                                                                                              //power attack and damage will be added in archetype
                                                         );

            var powerful_strikes_spiritualist = Helpers.CreateFeature("AngerPhantomPowerfulStrikesExciterFeature",
                                                                      powerful_strikes.Name,
                                                                      powerful_strikes.Description,
                                                                      "",
                                                                      powerful_strikes.Icon,
                                                                      FeatureGroup.None,
                                                                      Helpers.Create <MeleeWeaponSizeChange>(m => m.SizeCategoryChange = 1),
                                                                      Helpers.CreateAddFact(library.Get <BlueprintFeature>("9972f33f977fc724c838e59641b2fca5"))
                                                                      );

            var aura_of_fury_effect_buff = Helpers.CreateBuff("AngerPhantomAuraOfFuryEffectBuff",
                                                              "Aura of Fury",
                                                              "When the spiritualist reaches 7th level, as a swift action, the phantom can emit a 20-foot-radius aura of fury. Creatures within the aura gain a +2 bonus on melee attack rolls but take a –2 penalty to AC. Ending the aura is a free action.",
                                                              "",
                                                              Helpers.GetIcon("97b991256e43bb140b263c326f690ce2"), //rage
                                                              null,
                                                              Helpers.CreateAddStatBonus(Kingmaker.EntitySystem.Stats.StatType.AC, -2, Kingmaker.Enums.ModifierDescriptor.UntypedStackable),
                                                              Common.createAttackTypeAttackBonus(2, AttackTypeAttackBonus.WeaponRangeType.Melee, ModifierDescriptor.UntypedStackable)
                                                              );

            var toggle = Common.createToggleAreaEffect(aura_of_fury_effect_buff, 20.Feet(), Helpers.CreateConditionsCheckerAnd(),
                                                       AbilityActivationType.WithUnitCommand,
                                                       UnitCommand.CommandType.Swift,
                                                       Common.createPrefabLink("b3acbaa70e97c3649992e8f1e4bfe8dd"), //anarchic
                                                       null
                                                       );

            toggle.DeactivateIfOwnerDisabled = true;
            var aura_of_fury = Common.ActivatableAbilityToFeature(toggle, false);

            var ferocious_mien_buff = library.CopyAndAdd <BlueprintBuff>("4f139d125bb602f48bfaec3d3e1937cb", "AngerPhantomFerociousMienBuff", "");

            ferocious_mien_buff.AddComponents(library.Get <BlueprintBuff>("a1ffec0ce7c167a40aaea13dc49b757b").ComponentsArray);
            ferocious_mien_buff.FxOnStart = library.Get <BlueprintBuff>("a1ffec0ce7c167a40aaea13dc49b757b").FxOnStart;

            var ferocious_mien_resource = Helpers.CreateAbilityResource("AngeerPhantomFerociousMienResource", "", "", "", null);

            ferocious_mien_resource.SetFixedResource(3);
            var ferocious_mien_ability = Helpers.CreateAbility("AngerPhantomFerociousMienAbility",
                                                               "Ferocious Mien",
                                                               "When the spiritualist reaches 12th level, three times per day as a swift action, a phantom in ectoplasmic form can grow more ferocious and frightening. It becomes one size category larger than its current size, as affected by an enlarge person spell, and grows fiercer in combat, as if affected by a rage spell. This effect lasts for 1 round per class level of the spiritualist.",
                                                               "",
                                                               ferocious_mien_buff.Icon,
                                                               AbilityType.Supernatural,
                                                               UnitCommand.CommandType.Swift,
                                                               AbilityRange.Personal,
                                                               Helpers.roundsPerLevelDuration,
                                                               "",
                                                               Helpers.CreateRunActions(Common.createContextActionApplyBuff(ferocious_mien_buff, Helpers.CreateContextDuration(Helpers.CreateContextValue(AbilityRankType.Default)), dispellable: false)),
                                                               library.Get <BlueprintAbility>("c60969e7f264e6d4b84a1499fdcf9039").GetComponent <AbilitySpawnFx>(),
                                                               ferocious_mien_resource.CreateResourceLogic()
                                                               );

            ferocious_mien_ability.setMiscAbilityParametersSelfOnly();
            var ferocious_mien = Common.AbilityToFeature(ferocious_mien_ability, false);

            ferocious_mien.AddComponent(ferocious_mien_resource.CreateAddAbilityResource());

            var wail_of_banshee       = library.Get <BlueprintAbility>("b24583190f36a8442b212e45226c54fc");
            var furious_wail_resource = Helpers.CreateAbilityResource("AngerPhantomFuriousWailResource", "", "", "", null);

            furious_wail_resource.SetFixedResource(1);
            var furious_wail_ability = Common.convertToSuperNatural(wail_of_banshee, "AngerPhantom", getPhantomArray(), StatType.Charisma, furious_wail_resource);
            var furious_wail         = Common.AbilityToFeature(furious_wail_ability);

            furious_wail.AddComponent(furious_wail_resource.CreateAddAbilityResource());


            var powerful_strikes_phantom = Helpers.CreateFeature("AngerPhantomBaseFeature",
                                                                 "Strength Focus",
                                                                 "The phantom gains a +2 bonus to Strength and a –2 penalty to Dexterity. Instead of the phantom gaining a bonus to Dexterity as the spiritualist gains levels, an anger-focused phantom gains a bonus to Strength instead.",
                                                                 "",
                                                                 null,
                                                                 FeatureGroup.None,
                                                                 Helpers.CreateAddFact(library.Get <BlueprintFeature>("9972f33f977fc724c838e59641b2fca5"))
                                                                 );


            var anger_archetype = createPhantomArchetype("AngerPhantomArchetype",
                                                         "Anger",
                                                         true,
                                                         false,
                                                         true,
                                                         new StatType[] { StatType.SkillPersuasion, StatType.SkillLoreNature },
                                                         new LevelEntry[] { Helpers.LevelEntry(1, slam_damage_large, powerful_strikes_phantom),
                                                                            Helpers.LevelEntry(2, str_cha_bonus),
                                                                            Helpers.LevelEntry(4, str_cha_bonus),
                                                                            Helpers.LevelEntry(6, str_cha_bonus),
                                                                            Helpers.LevelEntry(8, str_cha_bonus),
                                                                            Helpers.LevelEntry(9, str_cha_bonus),
                                                                            Helpers.LevelEntry(12, str_cha_bonus),
                                                                            Helpers.LevelEntry(13, str_cha_bonus),
                                                                            Helpers.LevelEntry(15, str_cha_bonus), },
                                                         new LevelEntry[] { Helpers.LevelEntry(1, slam_damage),
                                                                            Helpers.LevelEntry(2, dex_cha_bonus),
                                                                            Helpers.LevelEntry(4, dex_cha_bonus),
                                                                            Helpers.LevelEntry(6, dex_cha_bonus),
                                                                            Helpers.LevelEntry(8, dex_cha_bonus),
                                                                            Helpers.LevelEntry(9, dex_cha_bonus),
                                                                            Helpers.LevelEntry(12, dex_cha_bonus),
                                                                            Helpers.LevelEntry(13, dex_cha_bonus),
                                                                            Helpers.LevelEntry(15, dex_cha_bonus), }
                                                         );

            //burst of adrenaline, rage, howling agony, shout, song of discord, transformation
            createPhantom("Anger",
                          "Anger",
                          "Phantoms with this emotional focus are filled with seething anger from events in their past lives. Phantoms with this focus often take the form of hulking brutes with furrowed brows or of frenzied creatures that always seem ready to strike down those who come too near. Many times, these phantoms exude a bright red aura, especially when they are engaged in combat, or they seem to breathe a red mist in shallow pants from behind clenched, phantasmal teeth.\n"
                          + "Skills: The phantom gains a number of ranks in Persuasion and Lore (Nature) equal to its number of Hit Dice. While confined in the spiritualist’s consciousness, the phantom grants the spiritualist Skill Focus in each of these skills.\n"
                          + "Good Saves: Fortitude and Will.\n"
                          + "Strength Focus: The phantom gains a +2 bonus to Strength and a –2 penalty to Dexterity. Instead of the phantom gaining a bonus to Dexterity as the spiritualist gains levels, an anger-focused phantom gains a bonus to Strength instead.",
                          aura_of_fury.Icon,
                          anger_archetype,
                          powerful_strikes, aura_of_fury, ferocious_mien, furious_wail,
                          new StatType[] { StatType.SkillPersuasion, StatType.SkillLoreNature },
                          14, 12,
                          new BlueprintAbility[]
            {
                library.Get <BlueprintAbility>("c60969e7f264e6d4b84a1499fdcf9039"),             //enlarge person
                library.Get <BlueprintAbility>("97b991256e43bb140b263c326f690ce2"),             //rage
                library.Get <BlueprintAbility>("e80a4d6c0efa5774cbd515e3e37095b0"),             //longstrider greater
                library.Get <BlueprintAbility>("f09453607e683784c8fca646eec49162")              //shout
            },
                          powerful_strikes_spiritualist,
                          aura_of_fury,
                          emotion_conduit_spells: new BlueprintAbility[]
            {
                NewSpells.burst_of_adrenaline,
                SpellDuplicates.addDuplicateSpell(library.Get <BlueprintAbility>("97b991256e43bb140b263c326f690ce2"), "EmotionConduitRageSpell"), //rage
                NewSpells.howling_agony,
                library.Get <BlueprintAbility>("f09453607e683784c8fca646eec49162"),                                                               //shout
                library.Get <BlueprintAbility>("d38aaf487e29c3d43a3bffa4a4a55f8f"),                                                               //song of discord
                library.Get <BlueprintAbility>("27203d62eb3d4184c9aced94f22e1806"),                                                               //transformation
            }
                          );
        }