mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-19 00:48:56 +01:00
*Add missing script functions. Without these the program can be compiled but cannot run.
--HG-- branch : trunk
This commit is contained in:
@@ -2243,3 +2243,32 @@ InstanceData* CreateInstanceData(Map *map)
|
||||
return tmpscript->GetInstanceData(map);
|
||||
}
|
||||
|
||||
TRINITY_DLL_EXPORT
|
||||
bool EffectDummyGameObj(Unit *caster, uint32 spellId, uint32 effIndex, GameObject *gameObjTarget )
|
||||
{
|
||||
Script *tmpscript = m_scripts[gameObjTarget->GetGOInfo()->ScriptId];
|
||||
|
||||
if (!tmpscript || !tmpscript->pEffectDummyGameObj) return false;
|
||||
|
||||
return tmpscript->pEffectDummyGameObj(caster, spellId,effIndex,gameObjTarget);
|
||||
}
|
||||
|
||||
TRINITY_DLL_EXPORT
|
||||
bool EffectDummyCreature(Unit *caster, uint32 spellId, uint32 effIndex, Creature *crTarget )
|
||||
{
|
||||
Script *tmpscript = m_scripts[crTarget->GetScriptId()];
|
||||
|
||||
if (!tmpscript || !tmpscript->pEffectDummyCreature) return false;
|
||||
|
||||
return tmpscript->pEffectDummyCreature(caster, spellId,effIndex,crTarget);
|
||||
}
|
||||
|
||||
TRINITY_DLL_EXPORT
|
||||
bool EffectDummyItem(Unit *caster, uint32 spellId, uint32 effIndex, Item *itemTarget )
|
||||
{
|
||||
Script *tmpscript = m_scripts[itemTarget->GetProto()->ScriptId];
|
||||
|
||||
if (!tmpscript || !tmpscript->pEffectDummyItem) return false;
|
||||
|
||||
return tmpscript->pEffectDummyItem(caster, spellId,effIndex,itemTarget);
|
||||
}
|
||||
|
||||
@@ -34,7 +34,8 @@ struct Script
|
||||
pGossipHello(NULL), pQuestAccept(NULL), pGossipSelect(NULL), pGossipSelectWithCode(NULL),
|
||||
pQuestSelect(NULL), pQuestComplete(NULL), pNPCDialogStatus(NULL), pGODialogStatus(NULL), pChooseReward(NULL),
|
||||
pItemHello(NULL), pGOHello(NULL), pAreaTrigger(NULL), pItemQuestAccept(NULL), pGOQuestAccept(NULL),
|
||||
pGOChooseReward(NULL),pReceiveEmote(NULL),pItemUse(NULL), GetAI(NULL), GetInstanceData(NULL)
|
||||
pGOChooseReward(NULL), pReceiveEmote(NULL), pItemUse(NULL), pEffectDummyGameObj(NULL), pEffectDummyCreature(NULL),
|
||||
pEffectDummyItem(NULL), GetAI(NULL)
|
||||
{}
|
||||
|
||||
std::string Name;
|
||||
@@ -57,6 +58,9 @@ struct Script
|
||||
bool (*pGOChooseReward )(Player*, GameObject*, Quest const*, uint32 );
|
||||
bool (*pReceiveEmote )(Player*, Creature*, uint32 );
|
||||
bool (*pItemUse )(Player*, Item*, SpellCastTargets const& );
|
||||
bool (*pEffectDummyGameObj )(Unit*, uint32, uint32, GameObject* );
|
||||
bool (*pEffectDummyCreature )(Unit*, uint32, uint32, Creature* );
|
||||
bool (*pEffectDummyItem )(Unit*, uint32, uint32, Item* );
|
||||
|
||||
CreatureAI* (*GetAI)(Creature*);
|
||||
InstanceData* (*GetInstanceData)(Map*);
|
||||
|
||||
Reference in New Issue
Block a user