More fixes and edits!

* Fixed a bug with client_exit module button appearing on full reload.
* Fixed the battle window to work properly now (left click: attack, right click: menu).
* Added auto walk checker for more accurate aut walking:
  - It will always find the path now, except in rare occasions gets stuck running back and forward
  - Re-calculates path every 10 steps and also when you hit an object that cancels your step.
  - Right now this is just a temporary method.
  - Cancels the checker when you move or press escape (has to be done client-side).
* Added a new setting to UIComboBox class 'mouse-scroll' to enable/disable mouse wheel scrolling.
* Added support for no ping in cooldowns.
* Added missing PlayerStates (hungry and bleeding).
This commit is contained in:
BeniS
2013-01-08 06:17:01 +13:00
parent fddbafebd3
commit bb139955dc
12 changed files with 139 additions and 24 deletions

View File

@@ -5,7 +5,7 @@ endif(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} EQUAL 6)
# otclient options
add_definitions(-DOTCLIENT)
option(BOT_PROTECTION "Enable bot protection" ON)
option(BOT_PROTECTION "Enable bot protection" OFF)
if(BOT_PROTECTION)
add_definitions(-DBOT_PROTECTION)
message(STATUS "Bot protection: ON")

View File

@@ -255,7 +255,9 @@ namespace Otc
IconCursed = 2048,
IconPartyBuff = 4096,
IconPzBlock = 8192,
IconPz = 16384
IconPz = 16384,
IconBleeding = 32768,
IconHungry = 65536
};
enum MessageMode {

View File

@@ -158,7 +158,7 @@ void Game::processGameStart()
m_protocolGame->sendPing();
disableBotCall();
}
}, 4000);
}, 3000);
}
}

View File

@@ -160,6 +160,8 @@ void LocalPlayer::cancelWalk(Otc::Direction direction)
// turn to the cancel direction
if(direction != Otc::InvalidDirection)
setDirection(direction);
callLuaField("onCancelWalk", direction);
}
void LocalPlayer::stopWalk()

View File

@@ -458,6 +458,7 @@ void OTClient::registerLuaFunctions()
g_lua.bindClassMemberFunction<LocalPlayer>("isKnown", &LocalPlayer::isKnown);
g_lua.bindClassMemberFunction<LocalPlayer>("isPreWalking", &LocalPlayer::isPreWalking);
g_lua.bindClassMemberFunction<LocalPlayer>("hasSight", &LocalPlayer::hasSight);
g_lua.bindClassMemberFunction<LocalPlayer>("isAutoWalking", &LocalPlayer::isAutoWalking);
g_lua.registerClass<Tile>();
g_lua.bindClassMemberFunction<Tile>("clean", &Tile::clean);