• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

C++ Player Cant Push after attack

Lipezito

New Member
Joined
Mar 10, 2016
Messages
10
Reaction score
0
Hello, where i can solve this?
TFS 1.3
Usually a player can pull after or before attacking even during a hit.
After attack is give a delay, i try this:

game.cpp
I try set delay to = 0 but it did not work
void Game::playerMoveCreature(Player* player, Creature* movingCreature, const Position& movingCreatureOrigPos, Tile* toTile)
{
if (!player->canDoAction()) {
uint32_t delay = player->getNextActionTime();
SchedulerTask* task = createSchedulerTask(delay, std::bind(&Game::playerMoveCreatureByID,
this, player->getID(), movingCreature->getID(), movingCreatureOrigPos, toTile->getPosition()));
player->setNextActionTask(task);
return;
}
 
Hello, where i can solve this?
TFS 1.3
Usually a player can pull after or before attacking even during a hit.
After attack is give a delay, i try this:

game.cpp
I try set delay to = 0 but it did not work

It doesnt work because !player->canDoAction() is still being executed, so remove/comment that part
 
Back
Top