mirror of
https://github.com/edubart/otclient.git
synced 2025-12-22 16:27:10 +01:00
Protocol 10.76, fixed death window & death packet
This commit is contained in:
@@ -228,12 +228,12 @@ void Game::processGameEnd()
|
||||
g_map.cleanDynamicThings();
|
||||
}
|
||||
|
||||
void Game::processDeath(int penality)
|
||||
void Game::processDeath(int deathType, int penality)
|
||||
{
|
||||
m_dead = true;
|
||||
m_localPlayer->stopWalk();
|
||||
|
||||
g_lua.callGlobalField("g_game", "onDeath", penality);
|
||||
g_lua.callGlobalField("g_game", "onDeath", deathType, penality);
|
||||
}
|
||||
|
||||
void Game::processGMActions(const std::vector<uint8>& actions)
|
||||
@@ -1450,7 +1450,7 @@ void Game::setProtocolVersion(int version)
|
||||
if(isOnline())
|
||||
stdext::throw_exception("Unable to change protocol version while online");
|
||||
|
||||
if(version != 0 && (version < 740 || version > 1075))
|
||||
if(version != 0 && (version < 740 || version > 1076))
|
||||
stdext::throw_exception(stdext::format("Protocol version %d not supported", version));
|
||||
|
||||
m_protocolVersion = version;
|
||||
@@ -1468,7 +1468,7 @@ void Game::setClientVersion(int version)
|
||||
if(isOnline())
|
||||
stdext::throw_exception("Unable to change client version while online");
|
||||
|
||||
if(version != 0 && (version < 740 || version > 1075))
|
||||
if(version != 0 && (version < 740 || version > 1076))
|
||||
stdext::throw_exception(stdext::format("Client version %d not supported", version));
|
||||
|
||||
m_features.reset();
|
||||
@@ -1596,6 +1596,10 @@ void Game::setClientVersion(int version)
|
||||
enableFeature(Otc::GameExperienceBonus);
|
||||
}
|
||||
|
||||
if(version >= 1055) {
|
||||
enableFeature(Otc::GameDeathType);
|
||||
}
|
||||
|
||||
if(version >= 1061) {
|
||||
enableFeature(Otc::GameOGLInformation);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user