void Module::think() { if(mSourceSystem.isAwake()) mSourceSystem.think(); if(mAwake) onThink(); }
void Monster::startThink() { if(!eventCheck){ //eventCheck = g_game.addEvent(makeTask(500, std::bind2nd(std::mem_fun(&Game::checkCreature), getID()))); onThink(1000); } if(!eventCheckAttacking){ eventCheckAttacking = g_game.addEvent(makeTask(500, boost::bind(&Game::checkCreatureAttacking, &g_game, getID(), 500))); } }