Merge branch 'master' into Playerbot

This commit is contained in:
Yunfan Li
2025-05-16 19:42:56 +08:00
19 changed files with 310 additions and 44 deletions

85
apps/extractor/extractor.sh Executable file
View File

@@ -0,0 +1,85 @@
#!/bin/bash
function Base {
echo "Extract Base"
rm -rf dbc maps Cameras
./map_extractor
Menu
}
function VMaps {
echo "Extract VMaps"
mkdir -p Buildings vmaps
rm -rf Buildings/* vmaps/*
./vmap4_extractor
./vmap4_assembler Buildings vmaps
rmdir -rf Buildings
Menu
}
function MMaps {
echo "This may take a few hours to complete. Please be patient."
mkdir -p mmaps
rm -rf mmaps/*
./mmaps_generator
Menu
}
function All {
echo "This may take a few hours to complete. Please be patient."
rm -rf dbc maps Cameras
mkdir -p Buildings vmaps mmaps
rm -rf Buildings/* vmaps/* mmaps/*
./map_extractor
./vmap4_extractor
./vmap4_assembler Buildings vmaps
rmdir -rf Buildings
./mmaps_generator
Menu
}
function Menu {
echo ""
echo "..............................................."
echo "AzerothCore dbc, maps, vmaps, mmaps extractor"
echo "..............................................."
echo "PRESS 1, 2, 3 OR 4 to select your task, or 5 to EXIT."
echo "..............................................."
echo ""
echo "WARNING! when extracting the vmaps extractor will"
echo "output the text below, it's intended and not an error:"
echo ".........................................."
echo "Extracting World\Wmo\Band\Final_Stage.wmo"
echo "No such file."
echo "Couldn't open RootWmo!!!"
echo "Done!"
echo " .........................................."
echo ""
echo "Press 1, 2, 3 or 4 to start extracting or 5 to exit."
echo "1 - Extract base files (NEEDED) and cameras."
echo "2 - Extract vmaps (needs maps to be extracted before you run this) (OPTIONAL, highly recommended)"
echo "3 - Extract mmaps (needs vmaps to be extracted before you run this, may take hours) (OPTIONAL, highly recommended)"
echo "4 - Extract all (may take hours)"
echo "5 - EXIT"
echo ""
read -rp "Type 1, 2, 3, 4 or 5 then press ENTER: " choice
case $choice in
1) Base ;;
2) VMaps ;;
3) MMaps ;;
4) All ;;
5) exit 0;;
*) echo "Invalid choice."; read -rp "Type 1, 2, 3, 4 or 5 then press ENTER: " choice ;;
esac
}
if [ -d "./Data" ] && [ -f "map_extractor" ] && [ -f "vmap4_extractor" ] && [ -f "vmap4_assembler" ] && [ -f "mmaps_generator" ]; then
echo "The required files and folder exist in the current directory."
chmod +x map_extractor vmap4_extractor vmap4_assembler mmaps_generator
Menu
else
echo "One or more of the required files or folder is missing from the current directory."
echo "Place map_extractor vmap4_extractor vmap4_assembler mmaps_generator"
echo "In your WoW folder with WoW.exe"
fi

85
apps/extractor/extractor_es.sh Executable file
View File

@@ -0,0 +1,85 @@
#!/bin/bash
function Base {
echo "Extrayendo archivos base"
rm -rf dbc maps Cameras
./map_extractor
Menu
}
function VMaps {
echo "Extrayendo VMaps"
mkdir -p Buildings vmaps
rm -rf Buildings/* vmaps/*
./vmap4_extractor
./vmap4_assembler Buildings vmaps
rmdir -rf Buildings
Menu
}
function MMaps {
echo "Esto puede tardar unas horas en completarse. Por favor, tenga paciencia."
mkdir -p mmaps
rm -rf mmaps/*
./mmaps_generator
Menu
}
function All {
echo "Esto puede tardar varias horas en completarse. Por favor, tenga paciencia."
rm -rf dbc maps Cameras
mkdir -p Buildings vmaps mmaps
rm -rf Buildings/* vmaps/* mmaps/*
./map_extractor
./vmap4_extractor
./vmap4_assembler Buildings vmaps
rmdir -rf Buildings
./mmaps_generator
Menu
}
function Menu {
echo ""
echo "..............................................."
echo "Extractor de dbc, maps, vmaps, mmaps de AzerothCore"
echo "..............................................."
echo "PRESIONE 1, 2, 3 O 4 para seleccionar su tarea, o 5 para SALIR."
echo "..............................................."
echo ""
echo "ADVERTENCIA: al extraer los vmaps del extractor"
echo "la salida del texto de abajo, es intencional y no un error:"
echo ".........................................."
echo "Extracting World\Wmo\Band\Final_Stage.wmo"
echo "No such file."
echo "Couldn't open RootWmo!!!"
echo "Done!"
echo ".........................................."
echo ""
echo "Presione 1, 2, 3 o 4 para iniciar la extracción o 5 para salir."
echo "1 - Extraer los archivos base (NECESARIOS) y las cámaras."
echo "2 - Extraer vmaps (necesita que los mapas se extraigan antes de ejecutar esto) (OPCIONAL, muy recomendable)"
echo "3 - Extraer mmaps (necesita que los vmaps se extraigan antes de ejecutar esto, puede llevar horas) (OPCIONAL, muy recomendable)"
echo "4 - Extraer todo (puede llevar varias horas)"
echo "5 - SALIR"
echo ""
read -rp "Escriba 1, 2, 3, 4 o 5 y pulse ENTER: " choice
case $choice in
1) Base ;;
2) VMaps ;;
3) MMaps ;;
4) All ;;
5) exit 0;;
*) echo "Opción inválida."; read -rp "Escriba 1, 2, 3, 4 o 5 y presione ENTER: " choice ;;
esac
}
if [ -d "./Data" ] && [ -f "map_extractor" ] && [ -f "vmap4_extractor" ] && [ -f "vmap4_assembler" ] && [ -f "mmaps_generator" ]; then
echo "Los archivos y carpetas requeridos existen en el directorio actual."
chmod +x map_extractor vmap4_extractor vmap4_assembler mmaps_generator
Menu
else
echo "Uno o más archivos o carpetas requeridos no se encuentran en el directorio actual."
echo "Coloque map_extractor vmap4_extractor vmap4_assembler mmaps_generator"
echo "en su directorio de WoW junto con WoW.exe"
fi

View File

@@ -0,0 +1,3 @@
-- DB update 2025_05_09_01 -> 2025_05_10_00
-- Deletes `Lorgalis Manuscript` (5359) from `Aku'mai Fisher` (4824), `Blackfathom Myrmidon` (4807), `Blackfathom Sea Witch` (4805) and `Snapping Crustacean` (4822)
DELETE FROM `creature_loot_template` WHERE `Item` = 5359;

View File

@@ -0,0 +1,6 @@
-- DB update 2025_05_10_00 -> 2025_05_10_01
--
DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 19) AND (`SourceGroup` = 0) AND (`SourceEntry` = 12821) AND (`ConditionValue1` IN (12820,12832));
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(19, 0, 12821, 0, 0, 8, 0, 12820, 0, 0, 0, 0, 0, '', 'Allow picking quest \'Opening the Backdoor\' only if \'A Delicate Touch\' has been completed.'),
(19, 0, 12821, 0, 0, 8, 0, 12832, 0, 0, 0, 0, 0, '', 'Allow picking quest \'Opening the Backdoor\' only if \'Bitter Departure\' has been completed.');

View File

@@ -0,0 +1,4 @@
-- DB update 2025_05_10_01 -> 2025_05_10_02
DELETE FROM `spell_script_names` WHERE `spell_id` = -1022;
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
(-1022, 'spell_pal_hand_of_protection');

View File

@@ -0,0 +1,3 @@
-- DB update 2025_05_10_02 -> 2025_05_10_03
--
UPDATE `spell_proc_event` SET `procFlags` = 0 WHERE `entry` IN (20186, 20185);

View File

@@ -0,0 +1,3 @@
-- DB update 2025_05_10_03 -> 2025_05_10_04
UPDATE `command` SET `help` = 'Syntax: .reload config\r\n\r\nReload config settings (by default stored in worldserver.conf). Not all settings can be change at reload: some new setting values will be ignored until restart, some values will applied with delay or only to new objects/maps, some values will explicitly rejected to change at reload.' WHERE `name` = 'reload config';
UPDATE `command` SET `help` = 'Syntax: .server exit\r\n\r\nTerminate AzerothCore NOW. Exit code 0.' WHERE `name` = 'server exit';

View File

@@ -0,0 +1,4 @@
-- DB update 2025_05_10_04 -> 2025_05_12_00
-- Add No_Taunt flag
UPDATE `creature_template` SET `flags_extra` = `flags_extra` |256 WHERE (`entry` = 25315);

View File

@@ -0,0 +1,10 @@
-- DB update 2025_05_12_00 -> 2025_05_12_01
-- Update comments and edit row 2.
UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 28529;
DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 28529);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(28529, 0, 0, 0, 0, 0, 100, 0, 0, 0, 2000, 3000, 0, 0, 11, 6660, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Scarlet Crusader - In Combat - Cast \'Shoot\''),
(28529, 0, 1, 0, 4, 0, 50, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Scarlet Crusader - On Aggro - Say Line 0'),
(28529, 0, 2, 0, 25, 0, 100, 0, 0, 0, 0, 0, 0, 0, 205, 23, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Scarlet Crusader - On Reset - Set combat distance to 23');

View File

@@ -0,0 +1,2 @@
-- DB update 2025_05_12_01 -> 2025_05_13_00
UPDATE `creature_model_info` SET `BoundingRadius` = 6, `CombatReach` = 15 WHERE `DisplayID` = 23200;

View File

@@ -0,0 +1,11 @@
-- DB update 2025_05_13_00 -> 2025_05_15_00
--
DELETE FROM `spell_script_names` WHERE `spell_id` = 46102;
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
(46102, 'spell_spell_fury_aura');
-- Remove 'Deal periodic damage'
SET @procFlags = (0x4000 | 0x10000);
DELETE FROM `spell_proc_event` WHERE `entry` = 46102;
INSERT INTO `spell_proc_event` (`entry`, `procFlags`) VALUES
(46102, @procFlags);

View File

@@ -7826,7 +7826,7 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
// Judgement of Light
case 20185:
{
if (!victim || !victim->IsAlive() || victim->HasSpellCooldown(20267))
if (!victim || !victim->IsAlive())
return false;
auto* caster = triggeredByAura->GetBase()->GetCaster();
@@ -7836,13 +7836,12 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
// 2% of base health
basepoints0 = int32(victim->CountPctFromMaxHealth(2));
victim->CastCustomSpell(victim, 20267, &basepoints0, 0, 0, true, 0, triggeredByAura);
victim->AddSpellCooldown(20267, 0, 4 * IN_MILLISECONDS);
return true;
}
// Judgement of Wisdom
case 20186:
{
if (!victim || !victim->IsAlive() || !victim->HasActivePowerType(POWER_MANA) || victim->HasSpellCooldown(20268))
if (!victim || !victim->IsAlive() || !victim->HasActivePowerType(POWER_MANA))
return false;
auto* caster = triggeredByAura->GetBase()->GetCaster();
@@ -7852,7 +7851,6 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
// 2% of base mana
basepoints0 = int32(CalculatePct(victim->GetCreateMana(), 2));
victim->CastCustomSpell(victim, 20268, &basepoints0, nullptr, nullptr, true, 0, triggeredByAura);
victim->AddSpellCooldown(20268, 0, 4 * IN_MILLISECONDS);
return true;
}
// Holy Power (Redemption Armor set)
@@ -16251,10 +16249,6 @@ void Unit::ProcDamageAndSpellFor(bool isVictim, Unit* target, uint32 procFlag, u
continue;
}
// Triggered spells not triggering additional spells
//bool triggered = !spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_FROM_PROCS) ?
// (procExtra & PROC_EX_INTERNAL_TRIGGERED && !(procFlag & PROC_FLAG_DONE_TRAP_ACTIVATION)) : false;
bool hasTriggeredProc = false;
for (uint8 i = 0; i < MAX_SPELL_EFFECTS; ++i)
{
@@ -17499,11 +17493,11 @@ bool Unit::IsTriggeredAtSpellProcEvent(Unit* victim, Aura* aura, WeaponAttackTyp
return false;
// Additional checks for triggered spells (ignore trap casts)
//if (procExtra & PROC_EX_INTERNAL_TRIGGERED && !(procFlag & PROC_FLAG_DONE_TRAP_ACTIVATION))
//{
// if (!spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_TRIGGERED))
// return false;
//}
if (eventInfo.GetHitMask() & PROC_EX_INTERNAL_TRIGGERED && !(EventProcFlag & PROC_FLAG_DONE_TRAP_ACTIVATION))
{
if (!spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_FROM_PROCS))
return false;
}
// Xinef: additional check for player auras - only player spells can trigger player proc auras
// Xinef: skip victim auras

View File

@@ -4903,12 +4903,6 @@ void SpellMgr::LoadSpellInfoCorrections()
spellInfo->AttributesEx7 |= SPELL_ATTR7_TREAT_AS_NPC_AOE;
});
// Heal (Crystal Spire of Karabor)
ApplySpellFix({ 40972 }, [](SpellInfo* spellInfo)
{
spellInfo->AttributesEx3 |= SPELL_ATTR3_SUPPRESS_CASTER_PROCS;
});
// Torch (Death Knights near the Chapel)
ApplySpellFix({ 52953 }, [](SpellInfo* spellInfo)
{

View File

@@ -1756,7 +1756,6 @@ void World::SetInitialWorldSettings()
LOG_INFO("server.loading", "Loading WorldStates..."); // must be loaded before battleground, outdoor PvP and conditions
sWorldState->LoadWorldStates();
sWorldState->Load();
LOG_INFO("server.loading", "Loading Conditions...");
sConditionMgr->LoadConditions();
@@ -1881,6 +1880,9 @@ void World::SetInitialWorldSettings()
uint32 nextGameEvent = sGameEventMgr->StartSystem();
_timers[WUPDATE_EVENTS].SetInterval(nextGameEvent); //depend on next event
LOG_INFO("server.loading", "Loading WorldState...");
sWorldState->Load(); // must be called after loading game events
// Delete all characters which have been deleted X days before
Player::DeleteOldCharacters();

View File

@@ -259,12 +259,12 @@ struct boss_kiljaeden : public BossAI
ScheduleHealthCheckEvent(85, [&]{
_phase = PHASE_DARKNESS;
if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ))
kalec->AI()->Talk(SAY_KALECGOS_AWAKEN, 16s);
kalec->AI()->Talk(SAY_KALECGOS_AWAKEN, 21s);
if (Creature* anveena = instance->GetCreature(DATA_ANVEENA))
anveena->AI()->Talk(SAY_ANVEENA_IMPRISONED, 22s);
anveena->AI()->Talk(SAY_ANVEENA_IMPRISONED, 26s);
Talk(SAY_KJ_PHASE3, 28s);
Talk(SAY_KJ_PHASE3, 32s);
scheduler.CancelAll();
@@ -274,7 +274,7 @@ struct boss_kiljaeden : public BossAI
if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ))
kalec->AI()->Talk(SAY_KALECGOS_READY1);
EmpowerOrb(false);
}, 35s);
}, 38s);
me->m_Events.AddEventAtOffset([&] {
Talk(SAY_KJ_REFLECTION);
@@ -286,11 +286,11 @@ struct boss_kiljaeden : public BossAI
DoCastSelf(SPELL_SHADOW_SPIKE);
});
ScheduleTimedEvent(3s, [&] {
ScheduleTimedEvent(31s, [&] {
DoCastSelf(SPELL_FLAME_DART);
}, 10s);
}, 20s);
ScheduleTimedEvent(16s, [&] {
ScheduleTimedEvent(55s, [&] {
Talk(EMOTE_KJ_DARKNESS);
DoCastAOE(SPELL_DARKNESS_OF_A_THOUSAND_SOULS);
}, 45s);
@@ -299,12 +299,12 @@ struct boss_kiljaeden : public BossAI
ScheduleHealthCheckEvent(55, [&] {
_phase = PHASE_ARMAGEDDON;
if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ))
kalec->AI()->Talk(SAY_KALECGOS_LETGO, 16s);
kalec->AI()->Talk(SAY_KALECGOS_LETGO, 18s);
if (Creature* anveena = instance->GetCreature(DATA_ANVEENA))
anveena->AI()->Talk(SAY_ANVEENA_LOST, 22s);
anveena->AI()->Talk(SAY_ANVEENA_LOST, 25s);
Talk(SAY_KJ_PHASE4, 28s);
Talk(SAY_KJ_PHASE4, 32s);
scheduler.CancelAll();
@@ -312,7 +312,7 @@ struct boss_kiljaeden : public BossAI
if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ))
kalec->AI()->Talk(SAY_KALECGOS_READY2);
EmpowerOrb(false);
}, 35s);
}, 38s);
scheduler.Schedule(1s, [this](TaskContext)
{
@@ -326,7 +326,11 @@ struct boss_kiljaeden : public BossAI
ScheduleBasicAbilities();
});
ScheduleTimedEvent(15s, [&] {
ScheduleTimedEvent(28s, [&] {
DoCastSelf(SPELL_FLAME_DART);
}, 20s);
ScheduleTimedEvent(64s, [&] {
me->RemoveAurasDueToSpell(SPELL_ARMAGEDDON_PERIODIC);
Talk(EMOTE_KJ_DARKNESS);
DoCastAOE(SPELL_DARKNESS_OF_A_THOUSAND_SOULS);
@@ -362,14 +366,14 @@ struct boss_kiljaeden : public BossAI
if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ))
{
kalec->AI()->Talk(SAY_KALECGOS_FOCUS, 8s);
kalec->AI()->Talk(SAY_KALECGOS_FATE, 20s + 200ms);
kalec->AI()->Talk(SAY_KALECGOS_FOCUS, 9s);
kalec->AI()->Talk(SAY_KALECGOS_FATE, 22s + 200ms);
}
if (Creature* anveena = instance->GetCreature(DATA_ANVEENA))
{
anveena->AI()->Talk(SAY_ANVEENA_KALEC, 18s);
anveena->AI()->Talk(SAY_ANVEENA_GOODBYE, 25s);
anveena->AI()->Talk(SAY_ANVEENA_KALEC, 20s);
anveena->AI()->Talk(SAY_ANVEENA_GOODBYE, 29s);
}
me->m_Events.AddEventAtOffset([&] {
@@ -378,7 +382,7 @@ struct boss_kiljaeden : public BossAI
anveena->RemoveAllAuras();
anveena->DespawnOrUnsummon(3500);
}
}, 28s);
}, 34s);
me->m_Events.AddEventAtOffset([&] {
if (Creature* anveena = instance->GetCreature(DATA_ANVEENA))
@@ -394,7 +398,11 @@ struct boss_kiljaeden : public BossAI
ScheduleBasicAbilities();
ScheduleTimedEvent(25s, [&] {
ScheduleTimedEvent(16s, [&] {
DoCastSelf(SPELL_FLAME_DART);
}, 20s);
ScheduleTimedEvent(15s, [&] {
me->RemoveAurasDueToSpell(SPELL_ARMAGEDDON_PERIODIC);
Talk(EMOTE_KJ_DARKNESS);
DoCastAOE(SPELL_DARKNESS_OF_A_THOUSAND_SOULS);
@@ -411,13 +419,13 @@ struct boss_kiljaeden : public BossAI
}, 7s);
}
Talk(SAY_KJ_PHASE5);
}, 30s);
}, 36s);
me->m_Events.AddEventAtOffset([&] {
if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ))
kalec->AI()->Talk(SAY_KALECGOS_READY_ALL);
EmpowerOrb(true);
}, 61s);
}, 48s);
});
});
}

View File

@@ -336,6 +336,22 @@ private:
TaskScheduler scheduler;
};
class spell_spell_fury_aura : public AuraScript
{
PrepareAuraScript(spell_spell_fury_aura);
void OnApply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
{
if (GetUnitOwner()->ToPlayer())
ModStackAmount(5);
}
void Register() override
{
OnEffectApply += AuraEffectApplyFn(spell_spell_fury_aura::OnApply, EFFECT_0, SPELL_AURA_MOD_CASTING_SPEED_NOT_STACK, AURA_EFFECT_HANDLE_REAL);
}
};
void AddSC_instance_sunwell_plateau()
{
new instance_sunwell_plateau();
@@ -345,4 +361,5 @@ void AddSC_instance_sunwell_plateau()
RegisterSpellScriptWithArgs(spell_sunwell_teleport, "spell_teleport_to_apex_point", SPELL_TELEPORT_TO_APEX_POINT);
RegisterSpellScriptWithArgs(spell_sunwell_teleport, "spell_teleport_to_witchs_sanctum", SPELL_TELEPORT_TO_WITCHS_SANCTUM);
RegisterSpellScriptWithArgs(spell_sunwell_teleport, "spell_teleport_to_sunwell_plateau", SPELL_TELEPORT_TO_SUNWELL_PLATEAU);
RegisterSpellScript(spell_spell_fury_aura);
}

View File

@@ -473,7 +473,7 @@ public:
{
if (spell->Id == SPELL_KODO_KOMBO_ITEM)
{
if (!caster->HasAnyAuras(SPELL_KODO_KOMBO_PLAYER_BUFF, SPELL_KODO_KOMBO_DESPAWN_BUFF)
if (!(caster->HasAura(SPELL_KODO_KOMBO_PLAYER_BUFF) || me->HasAura(SPELL_KODO_KOMBO_DESPAWN_BUFF))
&& (me->GetEntry() == NPC_AGED_KODO || me->GetEntry() == NPC_DYING_KODO || me->GetEntry() == NPC_ANCIENT_KODO))
{
me->UpdateEntry(NPC_TAMED_KODO, nullptr, false);
@@ -494,7 +494,7 @@ public:
bool OnGossipHello(Player* player, Creature* creature) override
{
if (player->HasAllAuras(SPELL_KODO_KOMBO_PLAYER_BUFF, SPELL_KODO_KOMBO_DESPAWN_BUFF))
if (player->HasAura(SPELL_KODO_KOMBO_PLAYER_BUFF) && creature->HasAura(SPELL_KODO_KOMBO_DESPAWN_BUFF))
{
player->TalkedToCreature(creature->GetEntry(), ObjectGuid::Empty);
player->RemoveAurasDueToSpell(SPELL_KODO_KOMBO_PLAYER_BUFF);

View File

@@ -1150,6 +1150,36 @@ class spell_pal_seal_of_vengeance : public SpellScript
}
};
// 1022 - Hand of Protection
class spell_pal_hand_of_protection : public SpellScript
{
PrepareSpellScript(spell_pal_hand_of_protection);
SpellCastResult CheckCast()
{
Unit* caster = GetCaster();
if (!caster->GetTarget() || caster->GetTarget() == caster->GetGUID())
return SPELL_CAST_OK;
if (caster->HasStunAura())
return SPELL_FAILED_STUNNED;
if (caster->HasConfuseAura())
return SPELL_FAILED_CONFUSED;
if (caster->GetUnitFlags() & UNIT_FLAG_FLEEING)
return SPELL_FAILED_FLEEING;
return SPELL_CAST_OK;
}
void Register() override
{
OnCheckCast += SpellCheckCastFn(spell_pal_hand_of_protection::CheckCast);
}
};
void AddSC_paladin_spell_scripts()
{
RegisterSpellAndAuraScriptPair(spell_pal_seal_of_command, spell_pal_seal_of_command_aura);
@@ -1178,4 +1208,5 @@ void AddSC_paladin_spell_scripts()
RegisterSpellScript(spell_pal_righteous_defense);
RegisterSpellScript(spell_pal_seal_of_righteousness);
RegisterSpellScript(spell_pal_seal_of_vengeance);
RegisterSpellScript(spell_pal_hand_of_protection);
}

View File

@@ -458,7 +458,8 @@ public:
####*/
enum L70ETCMusic
{
MUSIC_L70_ETC_MUSIC = 11803
MUSIC_L70_ETC_MUSIC = 11803,
MUSIC_L70_ETC_MUSIC_LOUD = 12868
};
enum L70ETCMusicEvents
@@ -486,7 +487,10 @@ public:
switch (eventId)
{
case EVENT_ETC_START_MUSIC:
me->PlayDirectMusic(MUSIC_L70_ETC_MUSIC);
if (me->GetMapId() == MAP_BLACKROCK_DEPTHS)
me->PlayDirectMusic(MUSIC_L70_ETC_MUSIC_LOUD);
else
me->PlayDirectMusic(MUSIC_L70_ETC_MUSIC);
_events.ScheduleEvent(EVENT_ETC_START_MUSIC, 1600); // Every 1.6 seconds SMSG_PLAY_MUSIC packet (PlayDirectMusic) is pushed to the client (sniffed value)
break;
default: