mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 05:21:29 +00:00
[Spells] Added a pet check to Cazic Touch (#1365)
* Added a pet check to Cazic Touch * Added a pet check to Cazic Touch * Added rule option to Cazic pet Check * Removed Magic Numbers * Bracket fix * Revert "Bracket fix" This reverts commit 3deb3e0cade7bbb48946f394b96b6c98911b3ae8. * Bracket fix * Update spells.cpp * Fixed constants * Revert "Fixed constants" This reverts commit 68502effd38cd5b84961a4c96f93504040dcffd5. * Update eq_constants.h * Update eq_constants.h Co-authored-by: ProducerZekServer <go@away.com> Co-authored-by: Chris Miles <akkadius1@gmail.com>
This commit is contained in:
parent
b87c5484b1
commit
6e61f6d0ba
@ -440,7 +440,6 @@ static const uint32 MAX_SPELL_DB_ID_VAL = 65535;
|
||||
|
||||
static const uint32 DB_SPELL_CAZIC_TOUCH = 982;
|
||||
static const uint32 DB_SPELL_TOUCH_OF_VINITRAS = 2859;
|
||||
|
||||
static const uint32 DB_FACTION_GEM_CHOPPERS = 255;
|
||||
static const uint32 DB_FACTION_HERETICS = 265;
|
||||
static const uint32 DB_FACTION_KING_AKANON = 333;
|
||||
|
||||
@ -372,6 +372,7 @@ RULE_BOOL(Spells, OldRainTargets, false, "Use old incorrectly implemented maximu
|
||||
RULE_BOOL(Spells, NPCSpellPush, false, "Enable spell push on NPCs")
|
||||
RULE_BOOL(Spells, July242002PetResists, true, "Enable Pets using PCs resist change from July 24 2002")
|
||||
RULE_INT(Spells, AOEMaxTargets, 0, "Max number of targets a Targeted AOE spell can cast on. Set to 0 for no limit.")
|
||||
RULE_BOOL(Spells, CazicTouchTargetsPetOwner, true, "If True, causes Cazic Touch to swap targets from pet to pet owner if a pet is tanking.")
|
||||
RULE_BOOL(Spells, PreventFactionWarOnCharmBreak, false, "Enable spell interupts and dot removal on charm break to prevent faction wars.")
|
||||
RULE_BOOL(Spells, AllowDoubleInvis, false, "Allows you to cast invisibility spells on a player that is already invisible")
|
||||
RULE_BOOL(Spells, AllowSpellMemorizeFromItem, false, "Allows players to memorize spells by right-clicking spell scrolls")
|
||||
|
||||
@ -2046,6 +2046,15 @@ bool Mob::SpellFinished(uint16 spell_id, Mob *spell_target, CastingSlot slot, ui
|
||||
if(!IsValidSpell(spell_id))
|
||||
return false;
|
||||
|
||||
//Death Touch targets the pet owner instead of the pet when said pet is tanking.
|
||||
if ((RuleB(Spells, CazicTouchTargetsPetOwner) && spell_target->HasOwner()) && spell_id == DB_SPELL_CAZIC_TOUCH || spell_id == DB_SPELL_TOUCH_OF_VINITRAS) {
|
||||
Mob* owner = spell_target->GetOwner();
|
||||
|
||||
if (owner) {
|
||||
spell_target = owner;
|
||||
}
|
||||
}
|
||||
|
||||
//Guard Assist Code
|
||||
if (RuleB(Character, PVPEnableGuardFactionAssist) && IsDetrimentalSpell(spell_id) && spell_target != this) {
|
||||
if (IsClient() || (HasOwner() && GetOwner()->IsClient())) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user