Additions To Packets

Posts 1–10 of 10 · Page 1 of 1
Additions To Packets
As of the X34.2.1 a few things were changed + added to packets, namely the addition of something called "CompressedInt" and 2 extra variables received with NewTick, one of which now also needs to be sent with Move
CompressedInt is used for both short and normal integers and is only read, never written from the client
Code:
int m_nRead(Packet* m_pPacket)
{
	byte m_nStartByte = m_pPacket->m_pReadBytes<byte>();
	bool m_bFlipValue = (m_nStartByte & 64) != 0;
	int m_nShiftAmmount = 6;
	int m_nFinalValue = m_nStartByte & 63;
	while (m_nStartByte & 128)
	{
		m_nStartByte = m_pPacket->m_pReadBytes<byte>();
		m_nFinalValue = m_nFinalValue | (m_nStartByte & 127) << m_nShiftAmmount;
		m_nShiftAmmount += 7;
	}
	if (m_bFlipValue)
	{
		m_nFinalValue = int(-m_nFinalValue);
	}
	return m_nFinalValue;
}
Its used in StatData for the value if its an integer as well for all the counts in the Update packets
It might also be used somewhere else but I havent encountered any issue ever since adding the compressed int to those 2
Yeah, like you said move also got one added
"serverRealTimeMSofLastNewTick_") type QName(PackageNamespace(""), "uint") end

So you fixed new tick and I assume your proxy is working?
Quote Originally Posted by smackerROTMG View Post
Yeah, like you said move also got one added
"serverRealTimeMSofLastNewTick_") type QName(PackageNamespace(""), "uint") end

So you fixed new tick and I assume your proxy is working?
Not a proxy and it indeed works, moving around, getting all entities, tiles, connecting to portals and so on
Okay, I'm updating proxy and having issues but think I'll get it, just need to mess around with statdata then
message me if you need an updated version of nrelay with the compressedint change
Quote Originally Posted by enmity4 View Post
message me if you need an updated version of nrelay with the compressedint change
can u im it to me? i have no idea how this shitty website works
I had my krelay updated, but after this couldn't figure it out. Anyone else?
Quote Originally Posted by smackerROTMG View Post
I had my krelay updated, but after this couldn't figure it out. Anyone else?
to anyone wondering, it's "Variable Length Quantity"
I used the C# one here as a reference after figuring out what it was:
https://stackoverflow.com/a/51352160
Quote Originally Posted by 059 View Post
to anyone wondering, it's "Variable Length Quantity"
I used the C# one here as a reference after figuring out what it was:
https://stackoverflow.com/a/51352160
Thank you good sir, will look into it
Posts 1–10 of 10 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Need help?