*Add function Gobject::sendcustomanim
--HG-- branch : trunk
This commit is contained in:
@@ -218,10 +218,7 @@ void GameObject::Update(uint32 /*p_time*/)
|
||||
udata.BuildPacket(&packet);
|
||||
((Player*)caster)->GetSession()->SendPacket(&packet);
|
||||
|
||||
WorldPacket data(SMSG_GAMEOBJECT_CUSTOM_ANIM,8+4);
|
||||
data << GetGUID();
|
||||
data << (uint32)(0);
|
||||
((Player*)caster)->SendMessageToSet(&data,true);
|
||||
SendCustomAnim();
|
||||
}
|
||||
|
||||
m_lootState = GO_READY; // can be successfully open with some chance
|
||||
@@ -1385,6 +1382,14 @@ void GameObject::CastSpell(Unit* target, uint32 spellId)
|
||||
//trigger->RemoveCorpse();
|
||||
}
|
||||
|
||||
void GameObject::SendCustomAnim()
|
||||
{
|
||||
WorldPacket data(SMSG_GAMEOBJECT_CUSTOM_ANIM,8+4);
|
||||
data << GetGUID();
|
||||
data << (uint32)0;
|
||||
SendMessageToSet(&data, true);
|
||||
}
|
||||
|
||||
// overwrite WorldObject function for proper name localization
|
||||
const char* GameObject::GetNameForLocaleIdx(int32 loc_idx) const
|
||||
{
|
||||
|
||||
@@ -613,6 +613,7 @@ class TRINITY_DLL_SPEC GameObject : public WorldObject
|
||||
GridReference<GameObject> &GetGridRef() { return m_gridRef; }
|
||||
|
||||
void CastSpell(Unit *target, uint32 spell);
|
||||
void SendCustomAnim();
|
||||
protected:
|
||||
uint32 m_charges; // Spell charges for GAMEOBJECT_TYPE_SPELLCASTER (22)
|
||||
uint32 m_spellId;
|
||||
|
||||
Reference in New Issue
Block a user