示例#1
0
 public static void addToBackToTheGrave(ChannelEntry entry)
 {
     if (entry.channel_type.isOf(ChannelType.BackToTheGrave))
     {
         if (back_to_the_grave_base == null)
         {
             back_to_the_grave_base = entry.base_ability;
         }
         else
         {
             back_to_the_grave_base.addToAbilityVariants(entry.ability);
         }
     }
 }
示例#2
0
        static void createExtraChannelPaladin()
        {
            var paladin_extra_channel_resource = Helpers.CreateAbilityResource("PaladinExtraChannelResource", "", "", "", null);

            paladin_extra_channel_resource.SetFixedResource(0);

            var paladin_channel_energy = library.Get <BlueprintFeature>("cb6d55dda5ab906459d18a435994a760");
            var paladin_heal           = library.Get <BlueprintAbility>("6670f0f21a1d7f04db2b8b115e8e6abf");
            var paladin_harm           = library.Get <BlueprintAbility>("4937473d1cfd7774a979b625fb833b47");

            BlueprintAbility paladin_harm_base = paladin_channel_energy.GetComponent <AddFacts>().Facts[0] as BlueprintAbility;
            BlueprintAbility paladin_heal_base = paladin_channel_energy.GetComponent <AddFacts>().Facts[1] as BlueprintAbility;

            var heal_living_extra = ChannelEnergyEngine.createChannelEnergy(ChannelEnergyEngine.ChannelType.PositiveHeal,
                                                                            "PaladinChannelEnergyHealLivingExtra",
                                                                            paladin_heal.Name + " (Extra)",
                                                                            paladin_heal.Description,
                                                                            "",
                                                                            paladin_heal.GetComponent <ContextRankConfig>(),
                                                                            paladin_heal.GetComponent <NewMechanics.ContextCalculateAbilityParamsBasedOnClasses>(),
                                                                            Helpers.CreateResourceLogic(paladin_extra_channel_resource, true, 1));

            var harm_undead_extra = ChannelEnergyEngine.createChannelEnergy(ChannelEnergyEngine.ChannelType.PositiveHarm,
                                                                            "PaladinChannelEnergyHarmUndeadExtra",
                                                                            paladin_harm.Name + " (Extra)",
                                                                            paladin_harm.Description,
                                                                            "",
                                                                            paladin_harm.GetComponent <ContextRankConfig>(),
                                                                            paladin_harm.GetComponent <NewMechanics.ContextCalculateAbilityParamsBasedOnClasses>(),
                                                                            Helpers.CreateResourceLogic(paladin_extra_channel_resource, true, 1));

            paladin_heal_base.addToAbilityVariants(heal_living_extra);
            paladin_harm_base.addToAbilityVariants(harm_undead_extra);
            ChannelEnergyEngine.storeChannel(heal_living_extra, paladin_channel_energy, ChannelEnergyEngine.ChannelType.PositiveHeal);
            ChannelEnergyEngine.storeChannel(harm_undead_extra, paladin_channel_energy, ChannelEnergyEngine.ChannelType.PositiveHarm);

            paladin_channel_energy.AddComponent(Helpers.CreateAddFacts(heal_living_extra, harm_undead_extra));
            paladin_channel_energy.AddComponent(Helpers.CreateAddAbilityResource(paladin_extra_channel_resource));
            paladin_channel_extra = ChannelEnergyEngine.createExtraChannelFeat(heal_living_extra, paladin_channel_energy, "ExtraChannelPaladin", "Extra Channel (Paladin)", "");
        }