Paying 5 Euro for that. (VIA PAYPAL, I WILL PAY AS A GIFT)
If I push a player from distance there is no delay I want it to be 1 sec delay I've searched and tried everything, it's not via config so don't tell me to change that, also I tried via source code.
(config)
(game.cpp) I have this but it not working
I also tried to compile game.cpp like that
but getting some errors...
also tried this
with error's or still 0 sec delay :S
ONLY PAYING VIA PAYPAL
If I push a player from distance there is no delay I want it to be 1 sec delay I've searched and tried everything, it's not via config so don't tell me to change that, also I tried via source code.
(config)
Code:
pushCreatureDelay = 1 * 1000
(game.cpp) I have this but it not working
Code:
{
SchedulerTask* task = createSchedulerTask(g_config.getNumber(ConfigManager::PUSH_CREATURE_DELAY),
boost::bind(&Game::playerMoveCreature, this, player->getID(),
movingCreature->getID(), movingCreature->getPosition(), toCylinder->getPosition()));
player->setNextActionTask(task);
}
I also tried to compile game.cpp like that
Code:
{
//need to walk to the creature first before moving it
std::list<Direction> listDir;
if(getPathToEx(player, movingCreaturePos, listDir, 0, 1, true, true))
{
Dispatcher::getInstance().addTask(createTask(boost::bind(&Game::playerAutoWalk,
this, player->getID(), listDir)));
SchedulerTask* task = createSchedulerTask(std::max((int32_t)SCHEDULER_MINTICKS, player->getStepDuration()),
boost::bind(&Game::playerMoveCreature, this, playerId, movingCreatureId, movingCreaturePos, toPos, true));
player->setNextWalkActionTask(task);
return true;
}
player->sendCancelMessage(RET_THEREISNOWAY);
return false;
}
else if(delay)
{
uint32_t delayTime = g_config.getNumber(ConfigManager::PUSH_CREATURE_DELAY);
if(delayTime > 0)
{
SchedulerTask* task = createSchedulerTask(delayTime,
boost::bind(&Game::playerMoveCreature, this, playerId, movingCreatureId, movingCreaturePos, toPos, false));
player->setNextActionTask(task);
return true;
}
}
but getting some errors...
also tried this
Code:
if(Creature* movingCreature = thing->getCreature()){
if(Position::areInRange<1,1,0>(movingCreature->getPosition(), player->getPosition())){
SchedulerTask* task = createSchedulerTask(2000,
boost::bind(&Game::playerMoveCreature, this, player->getID(),
movingCreature->getID(), movingCreature->getPosition(), toCylinder->getPosition()));
player->setNextActionTask(task);
}
else{
playerMoveCreature(playerId, movingCreature->getID(), movingCreature->getPosition(),
toCylinder->getPosition());
}
}
else if(thing->getItem()){
playerMoveItem(playerId, fromPos, spriteId, fromStackPos, toPos, count);
}
return true;
}
with error's or still 0 sec delay :S
ONLY PAYING VIA PAYPAL
Last edited: