Exemple #1
0
        static void createMajorMagic()
        {
            var druid  = library.Get <BlueprintCharacterClass>("610d836f3a3a9ed42a4349b62f002e96");
            var spells = Helpers.wizardSpellList.SpellsByLevel[1].Spells;

            major_magic = Helpers.CreateFeatureSelection("MajorMagicRogueTalent",
                                                         "Major Magic",
                                                         "A rogue with this talent gains the ability to cast a 1st-level spell from the sorcerer/wizard spell list once per day as a spell-like ability for every 2 rogue levels she possesses. The rogue’s caster level for this ability is equal to her rogue level. The save DC for this spell is 11 + the rogue’s Intelligence modifier. A rogue must have the minor magic rogue talent and an Intelligence score of at least 11 to select this talent.",
                                                         "",
                                                         Helpers.GetIcon("4ac47ddb9fa1eaf43a1b6809980cfbd2"), //magic missile
                                                         FeatureGroup.RogueTalent,
                                                         Helpers.PrerequisiteStatValue(StatType.Intelligence, 11),
                                                         Helpers.PrerequisiteFeature(minor_magic)
                                                         );

            var classes = new BlueprintCharacterClass[] { library.Get <BlueprintCharacterClass>("299aa766dee3cbf4790da4efb8c72484"), //rogue
                                                          library.Get <BlueprintCharacterClass>("c75e0971973957d4dbad24bc7957e4fb"),
                                                          Investigator.investigator_class,
                                                          druid,                                                                       //for nature fang
                                                          Skald.skald_class,                                                           //for red tongue
                                                          library.Get <BlueprintCharacterClass>("772c83a25e2268e448e841dcd548235f"),   //bard for archaelogist
                                                          library.Get <BlueprintCharacterClass>("f1a70d9e1b0b41e49874e1fa9052a1ce") }; //inquisitor for sanctified slayer


            foreach (var s in spells)
            {
                var resource = Helpers.CreateAbilityResource("MajorMagic" + s.name + "Resource", "", "", Helpers.MergeIds("27fea41a99cd46609f8ab2283d1afce0", s.AssetGuid), null);
                resource.SetIncreasedByLevelStartPlusDivStep(0, 2, 1, 2, 1, 0, 0.0f, classes);
                BlueprintFeature feature = null;
                if (!s.HasVariants)
                {
                    var spell_like = Common.convertToSpellLike(s, "MajorMagic", classes, StatType.Intelligence, resource, no_scaling: true,
                                                               guid: Helpers.MergeIds("0e6a36ac029049c98a682f688e419f45", s.AssetGuid));
                    feature = Common.AbilityToFeatureMaybeReuseGuid(spell_like, false, Helpers.MergeIds("fb026930ab7943da96f6e17b7c778f2b", s.AssetGuid));
                    spell_like.AddComponent(Helpers.Create <NewMechanics.BindAbilitiesToClassFixedLevel>(b =>
                    {
                        b.Abilites          = new BlueprintAbility[] { spell_like };
                        b.CharacterClass    = classes[0];
                        b.AdditionalClasses = classes.Skip(1).ToArray();
                        b.Cantrip           = false;
                        b.Stat        = StatType.Intelligence;
                        b.fixed_level = 1;
                        b.Archetypes  = new BlueprintArchetype[] { Archetypes.SanctifiedSlayer.archetype, Archetypes.NatureFang.archetype };
                    }
                                                                                                         )
                                            );
                }
                else
                {
                    List <BlueprintAbility> spell_likes = new List <BlueprintAbility>();
                    foreach (var v in s.Variants)
                    {
                        spell_likes.Add(Common.convertToSpellLike(v, "MajorMagic", classes, StatType.Intelligence, resource, no_scaling: true,
                                                                  guid: Helpers.MergeIds("0e6a36ac029049c98a682f688e419f45", v.AssetGuid)));
                    }
                    var wrapper = Common.createVariantWrapper("MajorMagic" + s.name, guid: Helpers.MergeIds("0e6a36ac029049c98a682f688e419f45", s.AssetGuid), spell_likes.ToArray());
                    wrapper.SetNameDescriptionIcon(s.Name, s.Description, s.Icon);
                    feature = Common.AbilityToFeatureMaybeReuseGuid(wrapper, false, Helpers.MergeIds("3704cc05c1b64ea990ae6a2b97d35311", s.AssetGuid));
                    feature.AddComponent(Helpers.Create <NewMechanics.BindAbilitiesToClassFixedLevel>(b =>
                    {
                        b.Abilites          = spell_likes.ToArray();
                        b.CharacterClass    = classes[0];
                        b.AdditionalClasses = classes.Skip(1).ToArray();
                        b.Cantrip           = false;
                        b.Stat        = StatType.Intelligence;
                        b.fixed_level = 1;
                        b.Archetypes  = new BlueprintArchetype[] { Archetypes.SanctifiedSlayer.archetype, Archetypes.NatureFang.archetype };
                    }
                                                                                                      )
                                         );
                }
                feature.SetName("Major Magic: " + feature.Name);
                feature.Groups = new FeatureGroup[] { FeatureGroup.RogueTalent };
                feature.AddComponent(resource.CreateAddAbilityResource());
                major_magic.AllFeatures = major_magic.AllFeatures.AddToArray(feature);
            }
            addToTalentSelection(major_magic);
        }
Exemple #2
0
        static void createMinorMagic()
        {
            var druid  = library.Get <BlueprintCharacterClass>("610d836f3a3a9ed42a4349b62f002e96");
            var spells = Helpers.wizardSpellList.SpellsByLevel[0].Spells;

            minor_magic = Helpers.CreateFeatureSelection("MinorMagicRogueTalent",
                                                         "Minor Magic",
                                                         "A rogue with this talent gains the ability to cast a 0-level spell from the sorcerer/wizard spell list. This spell can be cast three times a day as a spell-like ability. The caster level for this ability is equal to the rogue’s level. The save DC for this spell is 10 + the rogue’s Intelligence modifier.",
                                                         "",
                                                         Helpers.GetIcon("16e23c7a8ae53cc42a93066d19766404"), //jolt
                                                         FeatureGroup.RogueTalent,
                                                         Helpers.PrerequisiteStatValue(StatType.Intelligence, 10)
                                                         );

            var classes = new BlueprintCharacterClass[] { library.Get <BlueprintCharacterClass>("299aa766dee3cbf4790da4efb8c72484"),   //rogue
                                                          library.Get <BlueprintCharacterClass>("c75e0971973957d4dbad24bc7957e4fb"),   //slayer
                                                          Investigator.investigator_class,
                                                          druid,                                                                       //for nature fang
                                                          Skald.skald_class,                                                           //skald for red tongue
                                                          library.Get <BlueprintCharacterClass>("772c83a25e2268e448e841dcd548235f"),   //bard for archaelogist
                                                          library.Get <BlueprintCharacterClass>("f1a70d9e1b0b41e49874e1fa9052a1ce") }; //inquisitor for sanctified slayer


            foreach (var s in spells)
            {
                BlueprintFeature feature = null;
                if (!s.HasVariants)
                {
                    var spell_like = Common.convertToSpellLike(s, "MinorMagic", classes, StatType.Intelligence, no_resource: true, no_scaling: true,
                                                               guid: Helpers.MergeIds("0e6a36ac029049c98a682f688e419f45", s.AssetGuid));
                    feature = Common.AbilityToFeatureMaybeReuseGuid(spell_like, false, Helpers.MergeIds("fb026930ab7943da96f6e17b7c778f2b", s.AssetGuid));
                    feature.AddComponent(Helpers.Create <BindAbilitiesToClass>(b =>
                    {
                        b.Abilites          = new BlueprintAbility[] { spell_like };
                        b.CharacterClass    = classes[0];
                        b.AdditionalClasses = classes.Skip(1).ToArray();
                        b.Cantrip           = true;
                        b.Stat       = StatType.Intelligence;
                        b.Archetypes = new BlueprintArchetype[] { Archetypes.SanctifiedSlayer.archetype, Archetypes.NatureFang.archetype };
                    }
                                                                               )
                                         );
                }
                else
                {
                    List <BlueprintAbility> spell_likes = new List <BlueprintAbility>();
                    foreach (var v in s.Variants)
                    {
                        spell_likes.Add(Common.convertToSpellLike(v, "MinorMagic", classes, StatType.Intelligence, no_resource: true, no_scaling: true,
                                                                  guid: Helpers.MergeIds("0e6a36ac029049c98a682f688e419f45", v.AssetGuid)));
                    }
                    var wrapper = Common.createVariantWrapper("MinorMagic" + s.name, Helpers.MergeIds("0e6a36ac029049c98a682f688e419f45", s.AssetGuid), spell_likes.ToArray());
                    wrapper.SetNameDescriptionIcon(s.Name, s.Description, s.Icon);
                    feature = Common.AbilityToFeatureMaybeReuseGuid(wrapper, false, Helpers.MergeIds("fb026930ab7943da96f6e17b7c778f2b", s.AssetGuid));
                    feature.AddComponent(Helpers.Create <BindAbilitiesToClass>(b =>
                    {
                        b.Abilites          = spell_likes.ToArray();
                        b.CharacterClass    = classes[0];
                        b.AdditionalClasses = classes.Skip(1).ToArray();
                        b.Cantrip           = true;
                        b.Stat       = StatType.Intelligence;
                        b.Archetypes = new BlueprintArchetype[] { Archetypes.SanctifiedSlayer.archetype, Archetypes.NatureFang.archetype };
                    }
                                                                               )
                                         );
                }
                feature.SetName("Minor Magic: " + feature.Name);
                feature.Groups          = new FeatureGroup[] { FeatureGroup.RogueTalent };
                minor_magic.AllFeatures = minor_magic.AllFeatures.AddToArray(feature);
            }
            addToTalentSelection(minor_magic);
        }