Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Open the game.cpp file from your source and look for the following function.
- bool Game::playerMove(uint32_t playerId, Direction dir)
- Se sua source for OTX2 a função completa deve estar desta maneira.
- bool Game::playerMove(uint32_t playerId, Direction dir)
- {
- Player* player = getPlayerByID(playerId);
- if(!player || player->isRemoved())
- return false;
- player->setIdleTime(0);
- if(player->getNoMove())
- {
- player->sendCancelWalk();
- return false;
- }
- std::list<Direction> dirs;
- dirs.push_back(dir);
- player->setNextWalkActionTask(NULL);
- return player->startAutoWalk(dirs);
- }
- Look for the following line in the code.
- player->setNextWalkActionTask(NULL);
- E adicione essa linha logo acima.
- if(!g_config.getBool(ConfigManager::PUSH_CRUZADO))
- The full function should look like this:
- bool Game::playerMove(uint32_t playerId, Direction dir)
- {
- Player* player = getPlayerByID(playerId);
- if(!player || player->isRemoved())
- return false;
- player->setIdleTime(0);
- if(player->getNoMove())
- {
- player->sendCancelWalk();
- return false;
- }
- std::list<Direction> dirs;
- dirs.push_back(dir);
- if(!g_config.getBool(ConfigManager::PUSH_CRUZADO))
- player->setNextWalkActionTask(NULL);
- return player->startAutoWalk(dirs);
- }
- After that, add the following line to the configmanager.cpp file inside the bool function ConfigManager :: load ()
- m_confBool[PUSH_CRUZADO] = getGlobalBool("PushCruzado", false);
- In the configmanager.h file look for enum bool_config_t and you will see a list, add the line below in this list
-
- PUSH_CRUZADO,
- Now in your config.lua add:
- PushCruzado = true
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement