Partial support for protocol 1020 and minimize lag

I am able to login in global Tibia however there are game protocol errors
* there is a new opcode 167, which I dont know what it is
* there are changes in opcode 147 which handles text messages that I don't know too

Connection writing was optimized, playing "lag" should improve by 10ms,
and improve much more in systems with low fps
master
Eduardo Bart 11 years ago
parent 3cff331723
commit d32f71c2b9

@ -172,7 +172,7 @@ CIPSOFT_RSA = "1321277432058722840622950990822933849527763264961655079678763618"
"88792221429527047321331896351555606801473202394175817"
-- set to the latest Tibia.pic signature to make otclient compatible with official tibia
PIC_SIGNATURE = 0x50a6469d
PIC_SIGNATURE = 0x52131b61
OsTypes = {
Linux = 1,

@ -52,7 +52,7 @@ function g_game.getSupportedClients()
854, 860, 861, 862, 870, 910, 940,
944, 953, 954, 960, 961, 963, 970,
980, 981, 982, 983, 984, 985, 986,
1001, 1002, 1010
1001, 1002, 1010, 1020, 1021, 1022,
}
end

@ -147,6 +147,11 @@ void Application::poll()
#endif
g_dispatcher.poll();
// poll connection again to flush pending write
#ifdef FW_NET
Connection::poll();
#endif
}
void Application::exit()

@ -126,7 +126,7 @@ void Connection::write(uint8* buffer, size_t size)
m_outputStream = std::shared_ptr<asio::streambuf>(new asio::streambuf);
m_delayedWriteTimer.cancel();
m_delayedWriteTimer.expires_from_now(boost::posix_time::milliseconds(10));
m_delayedWriteTimer.expires_from_now(boost::posix_time::milliseconds(0));
m_delayedWriteTimer.async_wait(std::bind(&Connection::onCanWrite, asConnection(), std::placeholders::_1));
}

Loading…
Cancel
Save