Core/Scripts/SmartAI: add test for TextMgr (temp)
Core/CreatureTextMgr: added basic chat function, you can now experiment with it if bored --HG-- branch : trunk
This commit is contained in:
1 parent
a1358880c2
commit
9ea9effadd
4 files changed
+158
-4
No files matched your search
@@ -25,15 +25,17 @@
|
||||
#include "ObjectDefines.h"
|
||||
#include "GridDefines.h"
|
||||
#include "ConditionMgr.h"
|
||||
#include "CreatureTextMgr.h"
|
||||
|
||||
void SmartAIMgr::LoadSmartAIFromDB()
|
||||
{
|
||||
//Drop Existing SmartAI List
|
||||
}
|
||||
|
||||
SmartAI::SmartAI(Creature *c) : CreatureAI(c), me(c)
|
||||
SmartAI::SmartAI(Creature *c) : CreatureAI(c)
|
||||
{
|
||||
// copy script to local (pretection for table reload)
|
||||
mTestTimer = 0;
|
||||
}
|
||||
|
||||
int SmartAI::Permissible(const Creature *creature)
|
||||
@@ -45,6 +47,11 @@ int SmartAI::Permissible(const Creature *creature)
|
||||
|
||||
void SmartAI::UpdateAI(const uint32 diff)
|
||||
{
|
||||
if (mTestTimer < diff)
|
||||
{
|
||||
mTestTimer = 60000;
|
||||
sCreatureTextMgr.SendChat(me,"CHAT_TYPE_SAY", CHAT_TYPE_SAY);
|
||||
} else mTestTimer -= diff;
|
||||
}
|
||||
|
||||
void SmartAI::JustRespawned()
|
||||
|
||||
Reference in new issue
Block a user