Beispiel #1
0
        private static void Curaga1(AbilityBuilder builder)
        {
            builder.Create(Feat.Curaga1, PerkType.Curaga)
            .Name("Curaga I")
            .HasRecastDelay(RecastGroup.Curaga1, 12f)
            .HasActivationDelay(4.0f)
            .RequirementMP(12)
            .UsesActivationType(AbilityActivationType.Casted)
            .DisplaysVisualEffectWhenActivating()
            .HasImpactAction((activator, target, level) =>
            {
                var bonus = GetAbilityModifier(AbilityType.Wisdom, activator);

                foreach (var member in Party.GetAllPartyMembersWithinRange(activator, 5.0f))
                {
                    var amount = Random.D6(2) + bonus;

                    ApplyEffectToObject(DurationType.Instant, GetRacialType(target) == RacialType.Undead
                            ? EffectDamage(amount)
                            : EffectHeal(amount), target);

                    ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Healing_S), member);

                    Enmity.ModifyEnmityOnAll(activator, amount);
                }

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.WhiteMagic, 3);
            });
        }
Beispiel #2
0
        private static void TransferStamina1(AbilityBuilder builder)
        {
            builder.Create(Feat.TransferStamina1, PerkType.TransferStamina)
            .Name("Transfer Stamina I")
            .HasRecastDelay(RecastGroup.Transfer, 60f)
            .RequirementMP(20)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasActivationDelay(4f)
            .HasCustomValidation((activator, target, level) =>
            {
                if (!GetIsPC(target) || GetIsDM(target))
                {
                    return("Only players may be targeted with this ability.");
                }

                return(string.Empty);
            })
            .HasImpactAction((activator, target, level) =>
            {
                const int BaseTransferAmount = 10;

                var playerId = GetObjectUUID(target);
                var dbPlayer = DB.Get <Player>(playerId);
                Stat.RestoreStamina(target, dbPlayer, BaseTransferAmount);
                DB.Set(playerId, dbPlayer);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 2);
                Enmity.ModifyEnmityOnAll(activator, 6);
            });
        }
Beispiel #3
0
        private static void Cover3(AbilityBuilder builder)
        {
            builder.Create(Feat.Cover3, PerkType.Cover)
            .Name("Cover III")
            .HasRecastDelay(RecastGroup.Cover, 120f)
            .RequirementStamina(12)
            .UsesActivationType(AbilityActivationType.Casted)
            .DisplaysVisualEffectWhenActivating(VisualEffect.None)
            .HasCustomValidation((activator, target, level) =>
            {
                if (activator == target)
                {
                    return("You cannot Cover yourself.");
                }

                return(string.Empty);
            })
            .HasImpactAction((activator, target, level) =>
            {
                var length = 60f + GetAbilityModifier(AbilityType.Constitution, activator) * 2f;
                StatusEffect.Apply(activator, target, StatusEffectType.Cover3, length);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Dur_Prot_Epic_Armor), target);

                Enmity.ModifyEnmityOnAll(activator, 10);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chivalry, 3);
            });
        }
Beispiel #4
0
        private static void Raise(AbilityBuilder builder)
        {
            builder.Create(Feat.Raise, PerkType.Raise)
            .Name("Raise I")
            .HasRecastDelay(RecastGroup.Raise, 60f)
            .HasActivationDelay(15f)
            .RequirementMP(25)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasCustomValidation((activator, target, level) =>
            {
                if (GetCurrentHitPoints(target) > -11 ||
                    !GetIsDead(target))
                {
                    return("Your target is still alive.");
                }

                return(string.Empty);
            })
            .HasImpactAction((activator, target, level) =>
            {
                ApplyEffectToObject(DurationType.Instant, EffectResurrection(), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.WhiteMagic, 5);
                Enmity.ModifyEnmityOnAll(activator, 60);
            });
        }
        private static void RecoveryStab3(AbilityBuilder builder)
        {
            builder.Create(Feat.RecoveryStab3, PerkType.RecoveryStab)
            .Name("Recovery Stab III")
            .HasRecastDelay(RecastGroup.RecoveryStab, 60f)
            .RequirementStamina(16)
            .UsesActivationType(AbilityActivationType.Weapon)
            .HasImpactAction((activator, target, level) =>
            {
                var bonus = GetAbilityModifier(AbilityType.Wisdom, activator);
                foreach (var member in Party.GetAllPartyMembersWithinRange(activator, 5.0f))
                {
                    var amount   = Random.D8(3) + bonus;
                    var duration = 24f;

                    if (StatusEffect.HasStatusEffect(activator, StatusEffectType.DeliberateStab))
                    {
                        duration *= 2f;
                    }

                    ApplyEffectToObject(DurationType.Instant, EffectHeal(amount), member);
                    ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Healing_S), member);
                    ApplyEffectToObject(DurationType.Temporary, EffectRegenerate(1, 6f), member, duration);


                    Enmity.ModifyEnmityOnAll(activator, amount + 6);
                }

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 3);
                Enmity.ModifyEnmityOnAll(activator, 10);
            });
        }
        private static void Convert(AbilityBuilder builder)
        {
            builder.Create(Feat.Convert, PerkType.Convert)
            .Name("Convert")
            .HasRecastDelay(RecastGroup.Convert, 600f)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasCustomValidation((activator, target, level) =>
            {
                if (!GetIsPC(activator) || GetIsDM(activator))
                {
                    return("Only players may use this ability.");
                }

                var playerId = GetObjectUUID(activator);
                var dbPlayer = DB.Get <Player>(playerId);

                if (dbPlayer.MP <= 0)
                {
                    return("Your MP is too low to convert.");
                }

                return(string.Empty);
            })
            .HasImpactAction((activator, target, level) =>
            {
                var playerId = GetObjectUUID(activator);
                var dbPlayer = DB.Get <Player>(playerId);

                var currentHP = GetCurrentHitPoints(activator);
                var currentMP = dbPlayer.MP;

                // Set MP to 0 then do a restore by the player's HP.
                dbPlayer.MP = 0;
                Stat.RestoreMP(activator, dbPlayer, currentHP);
                DB.Set(playerId, dbPlayer);

                // Current HP is higher than MP. Deal damage.
                if (currentHP > currentMP)
                {
                    var damageAmount = currentHP - currentMP;
                    ApplyEffectToObject(DurationType.Instant, EffectDamage(damageAmount), activator);
                }
                // Current HP is lower than MP. Heal damage.
                else if (currentHP < currentMP)
                {
                    var recoverAmount = currentMP - currentHP;
                    ApplyEffectToObject(DurationType.Instant, EffectHeal(recoverAmount), activator);
                }

                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Good_Help), activator);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 5);
                Enmity.ModifyEnmityOnAll(activator, 10);
            });
        }
 private static void Invincible(AbilityBuilder builder)
 {
     builder.Create(Feat.Invincible, PerkType.Invincible)
     .Name("Invincible")
     .HasRecastDelay(RecastGroup.OneHourAbility, 3600f)
     .UsesActivationType(AbilityActivationType.Casted)
     .RequirementStamina(50)
     .HasImpactAction((activator, target, level) =>
     {
         StatusEffect.Apply(activator, target, StatusEffectType.Invincible, 30.0f);
         CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chivalry, 5);
         Enmity.ModifyEnmityOnAll(activator, 500);
         ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Fnf_Sound_Burst), target);
     });
 }
        private static void Refresh(AbilityBuilder builder)
        {
            builder.Create(Feat.Refresh, PerkType.Refresh)
            .Name("Refresh")
            .HasRecastDelay(RecastGroup.Refresh, 18f)
            .RequirementMP(12)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasImpactAction((activator, target, level) =>
            {
                StatusEffect.Apply(activator, target, StatusEffectType.Refresh, 180f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Head_Mind), target);

                Enmity.ModifyEnmityOnAll(activator, 6);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 3);
            });
        }
        private static void PerfectDodge(AbilityBuilder builder)
        {
            builder.Create(Feat.PerfectDodge, PerkType.PerfectDodge)
            .Name("Perfect Dodge")
            .HasRecastDelay(RecastGroup.OneHourAbility, 3600f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementStamina(50)
            .HasImpactAction((activator, target, level) =>
            {
                ApplyEffectToObject(DurationType.Temporary, EffectACIncrease(20), target, 30f);
                ApplyEffectToObject(DurationType.Temporary, EffectVisualEffect(VisualEffect.Vfx_Dur_Pixiedust), target, 30f);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Thievery, 5);
                Enmity.ModifyEnmityOnAll(activator, 150);
            });
        }
        private static void Manafont(AbilityBuilder builder)
        {
            builder.Create(Feat.Manafont, PerkType.Manafont)
            .Name("Manafont")
            .HasRecastDelay(RecastGroup.OneHourAbility, 3600f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementMP(50)
            .HasImpactAction((activator, target, level) =>
            {
                StatusEffect.Apply(activator, target, StatusEffectType.Manafont, 30f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Fnf_Sound_Burst), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 5);
                Enmity.ModifyEnmityOnAll(activator, 100);
            });
        }
Beispiel #11
0
        private static void Ironclad1(AbilityBuilder builder)
        {
            builder.Create(Feat.Ironclad1, PerkType.Ironclad)
            .Name("Ironclad I")
            .HasRecastDelay(RecastGroup.Ironclad, 300f)
            .RequirementStamina(10)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasImpactAction((activator, target, level) =>
            {
                StatusEffect.Apply(activator, target, StatusEffectType.Ironclad1, 60f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Death_Ward), target);

                Enmity.ModifyEnmityOnAll(activator, 8);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chivalry, 3);
            });
        }
Beispiel #12
0
        private static void SubtleBlow2(AbilityBuilder builder)
        {
            builder.Create(Feat.SubtleBlow2, PerkType.SubtleBlow)
            .Name("Subtle Blow II")
            .HasRecastDelay(RecastGroup.SubtleBlow, 300f)
            .RequirementStamina(7)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasImpactAction((activator, target, level) =>
            {
                StatusEffect.Apply(activator, target, StatusEffectType.SubtleBlow2, 30f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Ac_Bonus), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chi, 3);
                Enmity.ModifyEnmityOnAll(activator, 8);
            });
        }
        private static void ElementalSeal(AbilityBuilder builder)
        {
            builder.Create(Feat.ElementalSeal, PerkType.ElementalSeal)
            .Name("Elemental Seal")
            .DisplaysVisualEffectWhenActivating()
            .HasRecastDelay(RecastGroup.OneHourAbility, 3600f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementMP(50)
            .HasImpactAction((activator, target, level) =>
            {
                StatusEffect.Apply(activator, target, StatusEffectType.ElementalSeal, 30f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Fnf_Howl_Mind), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.BlackMagic, 5);
                Enmity.ModifyEnmityOnAll(activator, 300);
            });
        }
        private static void DeliberateStab(AbilityBuilder builder)
        {
            builder.Create(Feat.DeliberateStab, PerkType.DeliberateStab)
            .Name("Deliberate Stab")
            .HasRecastDelay(RecastGroup.DeliberateStab, 300f)
            .RequirementStamina(20)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasActivationDelay(2f)
            .HasImpactAction((activator, target, level) =>
            {
                StatusEffect.Apply(activator, target, StatusEffectType.DeliberateStab, 30f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Divine_Strike_Holy), activator);

                Enmity.ModifyEnmityOnAll(activator, 3);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 3);
            });
        }
        private static void Regen2(AbilityBuilder builder)
        {
            builder.Create(Feat.Regen1, PerkType.Regen)
            .Name("Regen II")
            .HasRecastDelay(RecastGroup.Regen, 12f)
            .HasActivationDelay(4f)
            .RequirementMP(12)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasImpactAction((activator, target, level) =>
            {
                ApplyEffectToObject(DurationType.Temporary, EffectRegenerate(2, 6f), target, 60f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Holy_Aid), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.WhiteMagic, 3);
                Enmity.ModifyEnmityOnAll(activator, 6);
            });
        }
        private static void Flee2(AbilityBuilder builder)
        {
            builder.Create(Feat.Flee2, PerkType.Flee)
            .Name("Flee II")
            .HasRecastDelay(RecastGroup.Flee, 300f)
            .RequirementStamina(25)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasActivationDelay(2.0f)
            .HasImpactAction((activator, target, level) =>
            {
                var duration = 30f + (GetAbilityModifier(AbilityType.Dexterity, activator) * 2);
                ApplyEffectToObject(DurationType.Temporary, EffectMovementSpeedIncrease(80), target, duration);

                Enmity.ModifyEnmityOnAll(activator, 8);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Thievery, 3);
            });
        }
Beispiel #17
0
        private static void ShockSpikes2(AbilityBuilder builder)
        {
            builder.Create(Feat.ShockSpikes2, PerkType.ShockSpikes)
            .Name("Shock Spikes II")
            .HasRecastDelay(RecastGroup.ShockSpikes, 10f)
            .HasActivationDelay(3f)
            .RequirementMP(12)
            .UsesActivationType(AbilityActivationType.Casted)
            .DisplaysVisualEffectWhenActivating()
            .HasImpactAction((activator, target, level) =>
            {
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Com_Blood_Crt_Yellow), target);
                ApplyShockSpikes(target, 1, DamageBonus.DAMAGEBONUS_2d4);

                Enmity.ModifyEnmityOnAll(activator, 8);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 3);
            });
        }
Beispiel #18
0
        private static void Protect(AbilityBuilder builder)
        {
            builder.Create(Feat.Protect, PerkType.Protect)
            .Name("Protect")
            .HasRecastDelay(RecastGroup.Protect, 4f)
            .HasActivationDelay(2.0f)
            .RequirementMP(4)
            .UsesActivationType(AbilityActivationType.Casted)
            .DisplaysVisualEffectWhenActivating()
            .HasImpactAction((activator, target, level) =>
            {
                ApplyEffectToObject(DurationType.Temporary, EffectDamageReduction(4, DamagePower.Normal), target, 1800f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Ac_Bonus), target);

                Enmity.ModifyEnmityOnAll(activator, 4);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 2);
            });
        }
        private static void InnerHealing4(AbilityBuilder builder)
        {
            builder.Create(Feat.InnerHealing4, PerkType.InnerHealing)
            .Name("Inner Healing IV")
            .HasRecastDelay(RecastGroup.InnerHealing, 180f)
            .HasActivationDelay(2f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementStamina(25)
            .HasImpactAction((activator, target, level) =>
            {
                var hpRecover = (int)(GetMaxHitPoints(target) * 0.4f);
                ApplyEffectToObject(DurationType.Instant, EffectHeal(hpRecover), target);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Restoration), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chi, 8);
                Enmity.ModifyEnmityOnAll(activator, 25 + hpRecover);
            });
        }
        private static void Chakra1(AbilityBuilder builder)
        {
            builder.Create(Feat.Chakra1, PerkType.Chakra)
            .Name("Chakra I")
            .HasRecastDelay(RecastGroup.Chakra, 30f)
            .HasActivationDelay(2f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementStamina(10)
            .HasImpactAction((activator, target, level) =>
            {
                var hpRecover = Random.D6(2);
                ApplyEffectToObject(DurationType.Instant, EffectHeal(hpRecover), target);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Healing_S), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chi, 2);
                Enmity.ModifyEnmityOnAll(activator, 6 + hpRecover);
            });
        }
Beispiel #21
0
        private static void ElectricFist1(AbilityBuilder builder)
        {
            builder.Create(Feat.ElectricFist1, PerkType.ElectricFist)
            .Name("Electric Fist I")
            .HasRecastDelay(RecastGroup.ElectricFist, 60f)
            .UsesActivationType(AbilityActivationType.Weapon)
            .RequirementStamina(3)
            .HasImpactAction((activator, target, level) =>
            {
                var modifier = GetAbilityModifier(AbilityType.Wisdom, activator);
                modifier     = modifier > 0 ? modifier : 0;
                var damage   = Random.D4(2) + modifier;
                ApplyEffectToObject(DurationType.Instant, EffectDamage(damage, DamageType.Electrical), target);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Com_Hit_Electrical), target);

                CombatPoint.AddCombatPoint(activator, target, SkillType.Chi, 3);
                Enmity.ModifyEnmityOnAll(activator, 6 + damage);
            });
        }
        private static void HundredFists(AbilityBuilder builder)
        {
            builder.Create(Feat.HundredFists, PerkType.HundredFists)
            .Name("Hundred Fists")
            .HasRecastDelay(RecastGroup.OneHourAbility, 3600f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementStamina(50)
            .HasImpactAction((activator, target, level) =>
            {
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chi, 5);
                Enmity.ModifyEnmityOnAll(activator, 250);

                var effect = EffectLinkEffects(EffectHaste(), EffectModifyAttacks(5));
                effect     = TagEffect(effect, "HUNDRED_FISTS");

                ApplyEffectToObject(DurationType.Temporary, effect, target, 30.0f);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Knock), target);
            });
        }
        public Dictionary <Feat, AbilityDetail> BuildAbilities()
        {
            var builder = new AbilityBuilder()
                          .Create(Feat.ElementalSpread, PerkType.ElementalSpread)
                          .Name("Elemental Spread")
                          .HasRecastDelay(RecastGroup.ElementalSpread, 600f)
                          .HasActivationDelay(1f)
                          .RequirementMP(10)
                          .UsesActivationType(AbilityActivationType.Casted)
                          .DisplaysVisualEffectWhenActivating()
                          .HasImpactAction((activator, target, level) =>
            {
                StatusEffect.Apply(activator, target, StatusEffectType.ElementalSpread, 60f);

                Enmity.ModifyEnmityOnAll(activator, 10);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.BlackMagic, 3);
            });

            return(builder.Build());
        }
Beispiel #24
0
        private static void Cure3(AbilityBuilder builder)
        {
            builder.Create(Feat.Cure3, PerkType.Cure)
            .Name("Cure III")
            .HasRecastDelay(RecastGroup.Cure3, 5f)
            .HasActivationDelay(2.0f)
            .RequirementMP(15)
            .UsesActivationType(AbilityActivationType.Casted)
            .DisplaysVisualEffectWhenActivating()
            .HasImpactAction((activator, target, level) =>
            {
                var amount = Random.D8(3) + GetAbilityModifier(AbilityType.Wisdom, activator);

                ApplyEffectToObject(DurationType.Instant, EffectHeal(amount), target);
                ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Healing_M), target);

                Enmity.ModifyEnmityOnAll(activator, amount);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.WhiteMagic, 3);
            });
        }
Beispiel #25
0
        public Dictionary <Feat, AbilityDetail> BuildAbilities()
        {
            var builder = new AbilityBuilder()
                          .Create(Feat.SpikedDefense, PerkType.SpikedDefense)
                          .HasRecastDelay(RecastGroup.SpikedDefense, 120f)
                          .RequirementStamina(10)
                          .UsesActivationType(AbilityActivationType.Casted)
                          .HasImpactAction((activator, target, level) =>
            {
                const float Duration = 60f;

                ApplyEffectToObject(DurationType.Temporary, EffectVisualEffect(VisualEffect.Vfx_Dur_Aura_Pulse_Red_Orange), target, Duration);
                ApplyEffectToObject(DurationType.Temporary, EffectDamageShield(2, DamageBonus.DAMAGEBONUS_1d4, DamageType.Piercing), target);

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chivalry, 3);
                Enmity.ModifyEnmityOnAll(activator, 10);
            });

            return(builder.Build());
        }
Beispiel #26
0
        private static void Defender3(AbilityBuilder builder)
        {
            builder.Create(Feat.Defender3, PerkType.Defender)
            .Name("Defender III")
            .HasRecastDelay(RecastGroup.Defender, 300f)
            .RequirementStamina(25)
            .UsesActivationType(AbilityActivationType.Casted)
            .HasImpactAction((activator, target, level) =>
            {
                foreach (var member in Party.GetAllPartyMembersWithinRange(target, 5.0f))
                {
                    StatusEffect.Apply(activator, member, StatusEffectType.Defender3, 60f);
                    ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Death_Ward), member);

                    Enmity.ModifyEnmityOnAll(activator, 4);
                }

                Enmity.ModifyEnmityOnAll(activator, 6);
                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chivalry, 3);
            });
        }
Beispiel #27
0
        private static void Valor2(AbilityBuilder builder)
        {
            builder.Create(Feat.Valor2, PerkType.Valor)
            .Name("Valor II")
            .HasRecastDelay(RecastGroup.Valor, 600f)
            .HasActivationDelay(4f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementStamina(40)
            .HasImpactAction((activator, target, level) =>
            {
                foreach (var member in Party.GetAllPartyMembersWithinRange(activator, 5.0f))
                {
                    var hpRecover = (int)(GetMaxHitPoints(member) * 0.4f);
                    ApplyEffectToObject(DurationType.Instant, EffectHeal(hpRecover), member);
                    ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Restoration), member);
                }

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.Chi, 5);
                Enmity.ModifyEnmityOnAll(activator, 70);
            });
        }
Beispiel #28
0
        private static void Protectra(AbilityBuilder builder)
        {
            builder.Create(Feat.Protectra, PerkType.Protectra)
            .Name("Protectra")
            .HasRecastDelay(RecastGroup.Protectra, 10f)
            .HasActivationDelay(3.0f)
            .RequirementMP(10)
            .UsesActivationType(AbilityActivationType.Casted)
            .DisplaysVisualEffectWhenActivating()
            .HasImpactAction((activator, target, level) =>
            {
                foreach (var member in Party.GetAllPartyMembersWithinRange(activator, 5.0f))
                {
                    ApplyEffectToObject(DurationType.Temporary, EffectDamageReduction(4, DamagePower.Normal), member, 1800f);
                    ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Ac_Bonus), member);

                    Enmity.ModifyEnmityOnAll(activator, 2);
                }

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.WhiteMagic, 4);
            });
        }
        private static void Benediction(AbilityBuilder builder)
        {
            builder.Create(Feat.Benediction, PerkType.Benediction)
            .Name("Benediction")
            .DisplaysVisualEffectWhenActivating()
            .HasRecastDelay(RecastGroup.OneHourAbility, 3600f)
            .UsesActivationType(AbilityActivationType.Casted)
            .RequirementMP(50)
            .HasImpactAction((activator, target, level) =>
            {
                var members = Party.GetAllPartyMembersWithinRange(activator, 15.0f);

                foreach (var member in members)
                {
                    var maxHP = GetMaxHitPoints(member);
                    ApplyEffectToObject(DurationType.Instant, EffectHeal(maxHP), member);
                    ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Healing_X), member);
                }

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.WhiteMagic, 5);
                Enmity.ModifyEnmityOnAll(activator, 300 + members.Count * 50);
            });
        }
        private static void RecoveryStab1(AbilityBuilder builder)
        {
            builder.Create(Feat.RecoveryStab1, PerkType.RecoveryStab)
            .Name("Recovery Stab I")
            .HasRecastDelay(RecastGroup.RecoveryStab, 60f)
            .RequirementStamina(8)
            .UsesActivationType(AbilityActivationType.Weapon)
            .HasImpactAction((activator, target, level) =>
            {
                var bonus = GetAbilityModifier(AbilityType.Wisdom, activator);
                foreach (var member in Party.GetAllPartyMembersWithinRange(activator, 5.0f))
                {
                    var amount = Random.D6(2) + bonus;

                    ApplyEffectToObject(DurationType.Instant, EffectHeal(amount), member);
                    ApplyEffectToObject(DurationType.Instant, EffectVisualEffect(VisualEffect.Vfx_Imp_Healing_S), member);

                    Enmity.ModifyEnmityOnAll(activator, amount + 2);
                }

                CombatPoint.AddCombatPointToAllTagged(activator, SkillType.RedMagic, 3);
                Enmity.ModifyEnmityOnAll(activator, 6);
            });
        }