Core/Scripts: Scripting of Dragonspire Hall Runes "UBRS"
Additional work to do.
This commit is contained in:
@@ -0,0 +1,2 @@
|
|||||||
|
-- Add script to Dragonspire Hall Runes "UBRS"
|
||||||
|
UPDATE `gameobject_template` SET `ScriptName`= 'go_dragonspire_hall_rune' WHERE `entry` BETWEEN 175194 AND 175200;
|
||||||
@@ -57,6 +57,7 @@ enum AdditionalData
|
|||||||
{
|
{
|
||||||
SPELL_SUMMON_ROOKERY_WHELP = 15745,
|
SPELL_SUMMON_ROOKERY_WHELP = 15745,
|
||||||
MAX_ENCOUNTER = 14,
|
MAX_ENCOUNTER = 14,
|
||||||
|
MAX_DRAGONSPIRE_HALL_RUNES = 7,
|
||||||
};
|
};
|
||||||
|
|
||||||
enum GameObjects
|
enum GameObjects
|
||||||
|
|||||||
@@ -247,7 +247,30 @@ public:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
uint8 ActivatedRunes = 0;
|
||||||
|
|
||||||
|
class go_dragonspire_hall_rune : public GameObjectScript
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
go_dragonspire_hall_rune() : GameObjectScript("go_dragonspire_hall_rune") { }
|
||||||
|
|
||||||
|
void OnGameObjectStateChanged(GameObject* go, uint32 state)
|
||||||
|
{
|
||||||
|
if (state == GO_STATE_READY)
|
||||||
|
{
|
||||||
|
if (++ActivatedRunes == MAX_DRAGONSPIRE_HALL_RUNES)
|
||||||
|
{
|
||||||
|
if (GameObject* door1 = GetClosestGameObjectWithEntry(go, GO_EMBERSEER_IN, 150.0f))
|
||||||
|
door1->SetGoState(GO_STATE_ACTIVE);
|
||||||
|
if (GameObject* door2 = GetClosestGameObjectWithEntry(go, GO_DOORS, 150.0f))
|
||||||
|
door2->SetGoState(GO_STATE_ACTIVE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
void AddSC_instance_blackrock_spire()
|
void AddSC_instance_blackrock_spire()
|
||||||
{
|
{
|
||||||
new instance_blackrock_spire();
|
new instance_blackrock_spire();
|
||||||
|
new go_dragonspire_hall_rune;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user