mirror of
https://github.com/edubart/otclient.git
synced 2025-12-22 16:27:10 +01:00
Add missing changes for protocol > 1000
This commit is contained in:
@@ -239,6 +239,17 @@ void Game::processPlayerHelpers(int helpers)
|
||||
g_lua.callGlobalField("g_game", "onPlayerHelpersUpdate", helpers);
|
||||
}
|
||||
|
||||
void Game::processPlayerModes(Otc::FightModes fightMode, Otc::ChaseModes chaseMode, bool safeMode)
|
||||
{
|
||||
m_fightMode = fightMode;
|
||||
m_chaseMode = chaseMode;
|
||||
m_safeFight = safeMode;
|
||||
|
||||
g_lua.callGlobalField("g_game", "onFightModeChange", fightMode);
|
||||
g_lua.callGlobalField("g_game", "onChaseModeChange", chaseMode);
|
||||
g_lua.callGlobalField("g_game", "onSafeFightChange", safeMode);
|
||||
}
|
||||
|
||||
void Game::processPing()
|
||||
{
|
||||
g_lua.callGlobalField("g_game", "onPing");
|
||||
@@ -1507,6 +1518,10 @@ void Game::setProtocolVersion(int version)
|
||||
enableFeature(Otc::GameThingMarks);
|
||||
}
|
||||
|
||||
if(version >= 1000) {
|
||||
enableFeature(Otc::GamePVPMode);
|
||||
}
|
||||
|
||||
m_protocolVersion = version;
|
||||
|
||||
Proto::buildMessageModesMap(version);
|
||||
|
||||
Reference in New Issue
Block a user