-
Notifications
You must be signed in to change notification settings - Fork 493
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rewrite Golemagg and fix 'Golemagg's Trust' #2835
Merged
Merged
Changes from 1 commit
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
DROP PROCEDURE IF EXISTS add_migration; | ||
DELIMITER ?? | ||
CREATE PROCEDURE `add_migration`() | ||
BEGIN | ||
DECLARE v INT DEFAULT 1; | ||
SET v = (SELECT COUNT(*) FROM `migrations` WHERE `id`='20241117202208'); | ||
IF v = 0 THEN | ||
INSERT INTO `migrations` VALUES ('20241117202208'); | ||
-- Add your query below. | ||
|
||
-- Moss Covered Feet - add SPELL_ATTR_EX_AURA_UNIQUE | ||
INSERT INTO `spell_mod` (`Id`, `procChance`, `procFlags`, `procCharges`, `DurationIndex`, `Category`, `CastingTimeIndex`, `StackAmount`, `SpellIconID`, `activeIconID`, `manaCost`, `Attributes`, `AttributesEx`, `AttributesEx2`, `AttributesEx3`, `AttributesEx4`, `Custom`, `InterruptFlags`, `AuraInterruptFlags`, `ChannelInterruptFlags`, `Dispel`, `Stances`, `StancesNot`, `SpellVisual`, `ManaCostPercentage`, `StartRecoveryCategory`, `StartRecoveryTime`, `MaxAffectedTargets`, `MaxTargetLevel`, `DmgClass`, `rangeIndex`, `RecoveryTime`, `CategoryRecoveryTime`, `SpellFamilyName`, `SpellFamilyFlags`, `Mechanic`, `EquippedItemClass`, `Comment`) VALUES | ||
(6870, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 67110928, -1, -1, -1, 1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, -1, -1, 'Moss Covered Feet - Add unique aura flag'); | ||
|
||
-- Golemagg - add missing auras | ||
-- 13879 Magma Splash - Golemagg splashes magma at his attackers, dealing Fire damage over time and reducing their armor. This ability can stack. | ||
-- 20556 Golemagg's Trust - Golemagg's Core Ragers will deal increased damage and have 50% increased attack speed if tanked too close to Golemagg. | ||
-- 18943 Double Attack - Proc chance: 50%, 3s cooldown | ||
UPDATE `creature_template` SET `auras` = "13879 20556 18943" WHERE `entry` = 11988; | ||
|
||
DELETE FROM `script_texts` WHERE `entry` = -1409002; -- %s refuses to die while its master is in trouble. (2) -> 7865 | ||
|
||
-- End of migration. | ||
END IF; | ||
END?? | ||
DELIMITER ; | ||
CALL add_migration(); | ||
DROP PROCEDURE IF EXISTS add_migration; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1558,7 +1558,7 @@ void Aura::TriggerSpell() | |
for (auto const& it : pList) | ||
{ | ||
Player* pPlayer = it.getSource(); | ||
if (pPlayer->GetGUID() == casterGUID) continue; | ||
if (pPlayer->GetGUID() == casterGUID.GetRawValue()) continue; | ||
if (!pPlayer) continue; | ||
if (pPlayer->IsDead()) continue; | ||
// 2d distance should be good enough | ||
|
@@ -1862,6 +1862,16 @@ void Aura::HandleAuraDummy(bool apply, bool Real) | |
target->HandleEmoteCommand(EMOTE_STATE_DANCE); | ||
break; | ||
} | ||
case 6870: // Moss Covered Feet | ||
{ | ||
if (target) | ||
{ | ||
m_positive = false; | ||
m_isPeriodic = true; | ||
m_modifier.periodictime = 1000; | ||
} | ||
return; | ||
} | ||
} | ||
break; | ||
} | ||
|
@@ -2062,8 +2072,18 @@ void Aura::HandleAuraDummy(bool apply, bool Real) | |
case 23183: // Mark of Frost | ||
{ | ||
if (m_removeMode == AURA_REMOVE_BY_DEATH) | ||
target->CastSpell(target, 23182, true, nullptr, this); | ||
return; | ||
{ | ||
if (Unit* caster = GetCaster()) | ||
{ | ||
// Azuregos | ||
// Only cast Mark of Frost on targets nearby when engaged | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this blizzlike? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I also have no poof for this - needs to be confirmed. |
||
if (caster->IsInCombat()) | ||
{ | ||
target->CastSpell(target, 23182, true, nullptr, this); | ||
} | ||
} | ||
} | ||
return; | ||
} | ||
case 28169: // Mutating Injection | ||
{ | ||
|
@@ -6795,6 +6815,41 @@ void Aura::PeriodicDummyTick() | |
|
||
return; | ||
} | ||
case 20556: // Golemagg's Trust | ||
{ | ||
if (Unit* pCaster = GetCaster()) | ||
{ | ||
if (pCaster->IsDead() && !pCaster->IsInCombat()) | ||
{ | ||
return; | ||
} | ||
// Golemagg's Core Ragers will deal increased damage | ||
// and have 50% increased attack speed if tanked too close to Golemagg. | ||
std::list<Creature*> addList; | ||
pCaster->GetCreatureListWithEntryInGrid(addList, 11672, 30.0f); | ||
if (!addList.empty()) | ||
{ | ||
for (const auto& itr : addList) | ||
{ | ||
// Golemagg's Trust Buff | ||
pCaster->CastSpell(itr, 20553, true, nullptr, this); | ||
} | ||
} | ||
} | ||
return; | ||
} | ||
case 6870: // Moss Covered Feet | ||
{ | ||
if (target->IsInCombat()) | ||
{ | ||
// 5% proc chance | ||
if (urand(0, 99) < 5) | ||
{ | ||
target->CastSpell(target, 6869, true, nullptr, this); // Fall Down | ||
} | ||
} | ||
return; | ||
} | ||
} | ||
break; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this necessary?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Without this modification, the spell can be applied multiple times to a player. I have no proof that this is correct - I just remember it not being applied more than once. I can remove this line if that’s preferable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#1223 (comment) - maybe this can be achieved differently, but currently I don't have any other idea except adding the unique flag.