TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
go_shadowforge_brazier Class Reference

Public Member Functions

 go_shadowforge_brazier ()
 
bool OnGossipHello (Player *, GameObject *go) override
 
- Public Member Functions inherited from GameObjectScript
virtual bool OnDummyEffect (Unit *, uint32, SpellEffIndex, GameObject *)
 
virtual bool OnGossipSelect (Player *, GameObject *, uint32, uint32)
 
virtual bool OnGossipSelectCode (Player *, GameObject *, uint32, uint32, const char *)
 
virtual bool OnQuestAccept (Player *, GameObject *, Quest const *)
 
virtual bool OnQuestReward (Player *, GameObject *, Quest const *, uint32)
 
virtual uint32 GetDialogStatus (Player *, GameObject *)
 
virtual void OnDestroyed (GameObject *, Player *)
 
virtual void OnDamaged (GameObject *, Player *)
 
virtual void OnLootStateChanged (GameObject *, uint32, Unit *)
 
virtual void OnGameObjectStateChanged (GameObject *, uint32)
 
virtual GameObjectAIGetAI (GameObject *) const
 
- Public Member Functions inherited from ScriptObject
const std::string & GetName () const
 
- Public Member Functions inherited from UpdatableScript< GameObject >
virtual void OnUpdate (GameObject *, uint32)
 

Additional Inherited Members

- Protected Member Functions inherited from GameObjectScript
 GameObjectScript (const char *name)
 
- Protected Member Functions inherited from ScriptObject
 ScriptObject (const char *name)
 
virtual ~ScriptObject ()
 
- Protected Member Functions inherited from UpdatableScript< GameObject >
 UpdatableScript ()
 
virtual ~UpdatableScript ()
 

Constructor & Destructor Documentation

go_shadowforge_brazier::go_shadowforge_brazier ( )
inline
30 : GameObjectScript("go_shadowforge_brazier") { }
GameObjectScript(const char *name)
Definition: ScriptMgr.cpp:1592

Member Function Documentation

bool go_shadowforge_brazier::OnGossipHello ( Player ,
GameObject go 
)
inlineoverridevirtual

Reimplemented from GameObjectScript.

33  {
34  if (InstanceScript* instance = go->GetInstanceScript())
35  {
36  if (instance->GetData(TYPE_LYCEUM) == IN_PROGRESS)
37  instance->SetData(TYPE_LYCEUM, DONE);
38  else
39  instance->SetData(TYPE_LYCEUM, IN_PROGRESS);
40  // If used brazier open linked doors (North or South)
41  if (go->GetGUID() == instance->GetGuidData(DATA_SF_BRAZIER_N))
42  instance->HandleGameObject(instance->GetGuidData(DATA_GOLEM_DOOR_N), true);
43  else if (go->GetGUID() == instance->GetGuidData(DATA_SF_BRAZIER_S))
44  instance->HandleGameObject(instance->GetGuidData(DATA_GOLEM_DOOR_S), true);
45  }
46  return false;
47  }
InstanceScript * GetInstanceScript()
Definition: Object.cpp:1540
Definition: blackrock_depths.h:62
Definition: inflate.h:49
Definition: blackrock_depths.h:56
Definition: blackrock_depths.h:61
Definition: blackrock_depths.h:57
Definition: blackrock_depths.h:37
Definition: InstanceScript.h:59
ObjectGuid const & GetGUID() const
Definition: Object.h:105
Definition: InstanceScript.h:141

+ Here is the call graph for this function:


The documentation for this class was generated from the following file: