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

Classes

struct  npc_sinclariAI
 

Public Member Functions

 npc_sinclari_vh ()
 
bool OnGossipHello (Player *player, Creature *creature) override
 
CreatureAIGetAI (Creature *creature) const override
 
- Public Member Functions inherited from CreatureScript
virtual bool OnDummyEffect (Unit *, uint32, SpellEffIndex, Creature *)
 
virtual bool OnGossipSelect (Player *, Creature *, uint32, uint32)
 
virtual bool OnGossipSelectCode (Player *, Creature *, uint32, uint32, const char *)
 
virtual bool OnQuestAccept (Player *, Creature *, Quest const *)
 
virtual bool OnQuestSelect (Player *, Creature *, Quest const *)
 
virtual bool OnQuestReward (Player *, Creature *, Quest const *, uint32)
 
virtual uint32 GetDialogStatus (Player *, Creature *)
 
- Public Member Functions inherited from UnitScript
virtual void OnHeal (Unit *, Unit *, uint32 &)
 
virtual void OnDamage (Unit *, Unit *, uint32 &)
 
virtual void ModifyPeriodicDamageAurasTick (Unit *, Unit *, uint32 &)
 
virtual void ModifyMeleeDamage (Unit *, Unit *, uint32 &)
 
virtual void ModifySpellDamageTaken (Unit *, Unit *, int32 &)
 
- Public Member Functions inherited from ScriptObject
const std::string & GetName () const
 
- Public Member Functions inherited from UpdatableScript< Creature >
virtual void OnUpdate (Creature *, uint32)
 

Additional Inherited Members

- Protected Member Functions inherited from CreatureScript
 CreatureScript (const char *name)
 
- Protected Member Functions inherited from UnitScript
 UnitScript (const char *name, bool addToScripts=true)
 
- Protected Member Functions inherited from ScriptObject
 ScriptObject (const char *name)
 
virtual ~ScriptObject ()
 
- Protected Member Functions inherited from UpdatableScript< Creature >
 UpdatableScript ()
 
virtual ~UpdatableScript ()
 

Constructor & Destructor Documentation

npc_sinclari_vh::npc_sinclari_vh ( )
inline
318 : CreatureScript("npc_sinclari_vh") { }
CreatureScript(const char *name)
Definition: ScriptMgr.cpp:1586

Member Function Documentation

CreatureAI* npc_sinclari_vh::GetAI ( Creature creature) const
inlineoverridevirtual

Reimplemented from CreatureScript.

523  {
524  return GetVioletHoldAI<npc_sinclariAI>(creature);
525  }
bool npc_sinclari_vh::OnGossipHello ( Player player,
Creature creature 
)
inlineoverridevirtual

Reimplemented from CreatureScript.

321  {
322  // override default gossip
323  if (InstanceScript* instance = creature->GetInstanceScript())
324  {
325  switch (instance->GetData(DATA_MAIN_EVENT_STATE))
326  {
327  case IN_PROGRESS:
328  player->PrepareGossipMenu(creature, GOSSIP_MENU_SEND_ME_IN, true);
329  player->SendPreparedGossip(creature);
330  return true;
331  case DONE:
332  return true; // NYI
333  case NOT_STARTED:
334  case FAIL:
335  default:
336  break;
337  }
338  }
339 
340  // load default gossip
341  return false;
342  }
InstanceScript * GetInstanceScript()
Definition: Object.cpp:1540
Definition: inflate.h:49
Definition: InstanceScript.h:60
Definition: InstanceScript.h:59
Definition: InstanceScript.h:58
Definition: violet_hold.cpp:150
Definition: InstanceScript.h:141
Definition: violet_hold.h:58

+ Here is the call graph for this function:


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