mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-18 08:28:32 +01:00
*Merge.
--HG-- branch : trunk
This commit is contained in:
@@ -387,11 +387,7 @@ SET(trinityscript_LIB_SRCS
|
||||
scripts/zone/utgarde_keep/utgarde_keep/boss_keleseth.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald_dalronn.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar_the_plunderer.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_keep/instance_keep.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_keep/boss_dalronn.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_keep/def_keep.h
|
||||
scripts/zone/utgarde_keep/utgarde_keep/def_utgarde_keep.h
|
||||
scripts/zone/utgarde_keep/utgarde_pinnacle/instance_pinnacle.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_pinnacle/boss_skadi.cpp
|
||||
scripts/zone/utgarde_keep/utgarde_pinnacle/boss_ymiron.cpp
|
||||
|
||||
@@ -1143,14 +1143,6 @@
|
||||
<Filter
|
||||
Name="Utgarde Keep"
|
||||
>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_dalronn.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_ingvar.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_ingvar_the_plunderer.cpp"
|
||||
>
|
||||
@@ -1159,26 +1151,14 @@
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_keleseth.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_skarvald.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_skarvald_dalronn.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\def_keep.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\def_utgarde_keep.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\instance_keep.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\instance_utgarde_keep.cpp"
|
||||
>
|
||||
|
||||
@@ -1,106 +0,0 @@
|
||||
/* Script Data Start
|
||||
SDName: Boss ingvar
|
||||
SDAuthor: LordVanMartin
|
||||
SD%Complete:
|
||||
SDComment:
|
||||
SDCategory:
|
||||
Script Data End */
|
||||
|
||||
/*** SQL START ***
|
||||
update creature_template set scriptname = 'boss_ingvar' where entry = '';
|
||||
*** SQL END ***/
|
||||
#include "precompiled.h"
|
||||
|
||||
//phase 1 Human
|
||||
#define SPELL_STAGGERING_ROAR 42708
|
||||
#define SPELL_DREADFUL_ROAR 42729
|
||||
#define SPELL_SMASH 42669
|
||||
#define SPELL_ENRAGE 42705
|
||||
#define SPELL_CLEAVE 42724
|
||||
//whed killed in phase1 is resurected by Annhylde the Caller and becomes Undead
|
||||
//only in phase 2
|
||||
#define INGVAR_RESURECTION_VISUAL 24012
|
||||
#define INGVAR_UNDEAD 23980
|
||||
#define INGVAR_IMAGE 31584
|
||||
#define INGVAR_THROW_TARGET 23996
|
||||
#define INGVAR_THROW_DUMMY 23997
|
||||
|
||||
#define TRANSFORM_INGVAR 42796
|
||||
#define INGVAR_FEIGN_DEATH 42795
|
||||
#define NPC_ANNHYLDE_THE_CALLER 24068
|
||||
#define SPELL_WOE_STRIKE 42730
|
||||
#define SPELL_DARK_SMASH 42723
|
||||
#define SPELL_SHADOW_AXE 42748
|
||||
|
||||
//Yell
|
||||
#define SAY_AGGRO -1574015
|
||||
#define SAY_KILL -1574016
|
||||
#define SAY_DEATH -1574017
|
||||
#define SAY_ATTACK_1 -1574018
|
||||
#define SAY_ATTACK_2 -1574019
|
||||
#define SAY_ATTACK_3 -1574020
|
||||
#define SAY_ATTACK_4 -1574021
|
||||
#define SAY_PHASE2_AGGRO -1574022
|
||||
#define SAY_PHASE2_KILL -1574023
|
||||
#define SAY_PHASE2_DEATH -1574024
|
||||
#define SAY_ANNHYLDE_THE_CALLER_RESURECTION -1574025
|
||||
|
||||
struct TRINITY_DLL_DECL boss_ingvarAI : public ScriptedAI
|
||||
{
|
||||
boss_ingvarAI(Creature *c) : ScriptedAI(c) {}
|
||||
|
||||
uint32 phase;
|
||||
|
||||
void Reset() {}
|
||||
void Aggro(Unit* who)
|
||||
{
|
||||
if(phase ==1)
|
||||
DoScriptText(SAY_AGGRO, m_creature);
|
||||
if(phase ==2)
|
||||
DoScriptText(SAY_PHASE2_AGGRO, m_creature);
|
||||
}
|
||||
void AttackStart(Unit* who) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
void UpdateAI(const uint32 diff)
|
||||
{
|
||||
//Return since we have no target
|
||||
if(!UpdateVictim())
|
||||
return;
|
||||
|
||||
phase =1;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
if(phase ==1)
|
||||
DoScriptText(SAY_DEATH, m_creature);
|
||||
if(phase ==2)
|
||||
DoScriptText(SAY_PHASE2_DEATH, m_creature);
|
||||
}
|
||||
void KilledUnit(Unit *victim)
|
||||
{
|
||||
if(victim == m_creature)
|
||||
return;
|
||||
if(phase == 1)
|
||||
DoScriptText(SAY_KILL, m_creature);
|
||||
//remove all auras, set unatackable and untargetable an begin resurection event and set to phase 2
|
||||
if(phase ==2)
|
||||
DoScriptText(SAY_PHASE2_KILL, m_creature);
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI_boss_ingvar(Creature *_Creature)
|
||||
{
|
||||
return new boss_ingvarAI (_Creature);
|
||||
}
|
||||
|
||||
void AddSC_boss_ingvar()
|
||||
{
|
||||
Script *newscript;
|
||||
|
||||
newscript = new Script;
|
||||
newscript->Name="boss_ingvar";
|
||||
newscript->GetAI = GetAI_boss_ingvar;
|
||||
newscript->RegisterSelf();
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
#ifndef DEF_KEEP_H
|
||||
#define DEF_KEEP_H
|
||||
|
||||
#define DATA_DALRONDEAD 1
|
||||
#define DATA_DALRON_DEATH 2
|
||||
#define DATA_SKARVALDDEAD 3
|
||||
#define DATA_SKARVALD_DEATH 4
|
||||
#define DATA_DALRON 5
|
||||
#define DATA_SKARVALD 6
|
||||
#endif
|
||||
@@ -1,98 +0,0 @@
|
||||
#include "precompiled.h"
|
||||
#include "def_keep.h"
|
||||
|
||||
struct TRINITY_DLL_DECL instance_keep : public ScriptedInstance
|
||||
{
|
||||
instance_keep(Map *Map) : ScriptedInstance(Map) {Initialize();};
|
||||
|
||||
uint64 Skarvald,
|
||||
Skarvald_ghost,
|
||||
Dalronn,
|
||||
Dalronn_ghost,
|
||||
Annhylde_thr_caller,
|
||||
Ingvar,
|
||||
Ingvar_undead;
|
||||
bool IsBossDied[2];
|
||||
|
||||
void Initialize()
|
||||
{
|
||||
Skarvald = 0;
|
||||
Skarvald_ghost = 0;
|
||||
Dalronn =0;
|
||||
Dalronn_ghost =0;
|
||||
Annhylde_thr_caller =0;
|
||||
Ingvar =0;
|
||||
Ingvar_undead =0;
|
||||
IsBossDied[0] = false;
|
||||
IsBossDied[1] = false;
|
||||
}
|
||||
|
||||
bool IsEncounterInProgress() const
|
||||
{
|
||||
//not active
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
|
||||
{
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 24200: Dalronn = creature->GetGUID(); break;
|
||||
case 27389: Dalronn_ghost = creature->GetGUID(); break;
|
||||
case 24201: Skarvald = creature->GetGUID(); break;
|
||||
case 27390: Skarvald_ghost = creature->GetGUID(); break;
|
||||
case 24068: Annhylde_thr_caller = creature->GetGUID(); break;
|
||||
case 23954: Ingvar = creature->GetGUID(); break;
|
||||
case 23980: Ingvar_undead = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
uint32 GetData(uint32 type)
|
||||
{
|
||||
switch(type)
|
||||
{
|
||||
case DATA_SKARVALDDEAD:
|
||||
if(IsBossDied[0])
|
||||
return 1;
|
||||
break;
|
||||
case DATA_DALRONDEAD:
|
||||
if(IsBossDied[1])
|
||||
return 1;
|
||||
break;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
uint64 GetData64 (uint32 identifier)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32 data)
|
||||
{
|
||||
switch(type)
|
||||
{
|
||||
case DATA_SKARVALD_DEATH:
|
||||
IsBossDied[0] = true;
|
||||
break;
|
||||
case DATA_DALRON_DEATH:
|
||||
IsBossDied[0] = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
InstanceData* GetInstanceData_instance_keep(Map* map)
|
||||
{
|
||||
return new instance_keep(map);
|
||||
}
|
||||
|
||||
void AddSC_instance_keep()
|
||||
{
|
||||
Script *newscript;
|
||||
newscript = new Script;
|
||||
newscript->Name = "instance_keep";
|
||||
newscript->GetInstanceData = GetInstanceData_instance_keep;
|
||||
newscript->RegisterSelf();
|
||||
}
|
||||
Reference in New Issue
Block a user