mirror of
https://github.com/EQEmu/Server.git
synced 2026-03-06 18:42:27 +00:00
[Tuning] FD and Sneak break when cast on adjustments. (#3861)
* [Tuning] FD and Sneak break when cast on adjustments.
Rules added:
RULE_REAL(Spells, BreakFeignDeathWhenCastOn, 50.0) // percentage that fd will break when you resist a spell
RULE_REAL(Spells, BreakSneakWhenCastOn, 2.0) // percentage that sneak will break when you resist a spell
* Fix default value to be peq default and spacing
This commit is contained in:
parent
7803170d6b
commit
0ada53aa96
@ -431,6 +431,8 @@ RULE_BOOL(Spells, AlwaysSendTargetsBuffs, false, "Ignore Leadership Alternate Ab
|
|||||||
RULE_BOOL(Spells, FlatItemExtraSpellAmt, false, "Allow SpellDmg stat to affect all spells, regardless of cast time/cooldown/etc")
|
RULE_BOOL(Spells, FlatItemExtraSpellAmt, false, "Allow SpellDmg stat to affect all spells, regardless of cast time/cooldown/etc")
|
||||||
RULE_BOOL(Spells, IgnoreSpellDmgLvlRestriction, false, "Ignore the 5 level spread on applying SpellDmg")
|
RULE_BOOL(Spells, IgnoreSpellDmgLvlRestriction, false, "Ignore the 5 level spread on applying SpellDmg")
|
||||||
RULE_BOOL(Spells, ItemExtraSpellAmtCalcAsPercent, false, "Apply the Item stats Spell Dmg and Heal Amount as Percentage-based modifiers instead of flat additions")
|
RULE_BOOL(Spells, ItemExtraSpellAmtCalcAsPercent, false, "Apply the Item stats Spell Dmg and Heal Amount as Percentage-based modifiers instead of flat additions")
|
||||||
|
RULE_REAL(Spells, BreakFeignDeathWhenCastOn, 2.0, "Percentage that fd will break when you resist a spell")
|
||||||
|
RULE_REAL(Spells, BreakSneakWhenCastOn, 2.0, "Percentage that sneak will break when you resist a spell")
|
||||||
RULE_BOOL(Spells, AllowItemTGB, false, "Target group buff (/tgb) doesn't work with items on live, custom servers want it though")
|
RULE_BOOL(Spells, AllowItemTGB, false, "Target group buff (/tgb) doesn't work with items on live, custom servers want it though")
|
||||||
RULE_BOOL(Spells, NPCInnateProcOverride, true, "NPC innate procs override the target type to single target")
|
RULE_BOOL(Spells, NPCInnateProcOverride, true, "NPC innate procs override the target type to single target")
|
||||||
RULE_BOOL(Spells, OldRainTargets, false, "Use old incorrectly implemented maximum targets for rains")
|
RULE_BOOL(Spells, OldRainTargets, false, "Use old incorrectly implemented maximum targets for rains")
|
||||||
|
|||||||
@ -9682,11 +9682,13 @@ void Client::BreakSneakWhenCastOn(Mob *caster, bool IsResisted)
|
|||||||
IsCastersTarget = true;
|
IsCastersTarget = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!IsCastersTarget) {
|
if (!IsCastersTarget) {
|
||||||
int chance = spellbonuses.NoBreakAESneak + itembonuses.NoBreakAESneak + aabonuses.NoBreakAESneak;
|
int chance = spellbonuses.NoBreakAESneak + itembonuses.NoBreakAESneak + aabonuses.NoBreakAESneak;
|
||||||
if (IsResisted) {
|
if (IsResisted) {
|
||||||
chance *= 2;
|
chance *= RuleR(Spells, BreakSneakWhenCastOn);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (chance && zone->random.Roll(chance)) {
|
if (chance && zone->random.Roll(chance)) {
|
||||||
return; // Do not drop Sneak/Hide
|
return; // Do not drop Sneak/Hide
|
||||||
}
|
}
|
||||||
@ -9697,12 +9699,12 @@ void Client::BreakSneakWhenCastOn(Mob *caster, bool IsResisted)
|
|||||||
|
|
||||||
void Client::BreakFeignDeathWhenCastOn(bool IsResisted)
|
void Client::BreakFeignDeathWhenCastOn(bool IsResisted)
|
||||||
{
|
{
|
||||||
if(GetFeigned()){
|
if (GetFeigned()) {
|
||||||
|
|
||||||
int chance = spellbonuses.FeignedCastOnChance + itembonuses.FeignedCastOnChance + aabonuses.FeignedCastOnChance;
|
int chance = spellbonuses.FeignedCastOnChance + itembonuses.FeignedCastOnChance + aabonuses.FeignedCastOnChance;
|
||||||
|
|
||||||
if (IsResisted)
|
if (IsResisted) {
|
||||||
chance *= 2;
|
chance *= RuleR(Spells, BreakFeignDeathWhenCastOn);
|
||||||
|
}
|
||||||
|
|
||||||
if(chance && (zone->random.Roll(chance))){
|
if(chance && (zone->random.Roll(chance))){
|
||||||
MessageString(Chat::SpellFailure,FD_CAST_ON_NO_BREAK);
|
MessageString(Chat::SpellFailure,FD_CAST_ON_NO_BREAK);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user