Closed Bosek closed 6 years ago
After a bit of fiddling I've found out that the information is properly sent by the server(Stealth), but the packet is different than expected(X,Y,Z make no sense). I forgot to mention that I am using Stealth v8.8.0 and I guess dev changed something. Sadly the Stealth wiki is horrible. Every language version has different information(EN version saying, that X and Y are bytes, RU version says that they are shorts).
Stealth is obviously no longer sending Packet SCReadStaticsXY
with amount of items. So in order to calculate it, I had to manually specify block size and divide.
case PacketType.SCReadStaticsXY:
var dataSize = 9;
itemCount = (uint)(barray.Length / dataSize);
break;
And it works like a charm. Is it ideal solution though? Should I create a PR? I am not sure if it's behaviour new to Stealth 8.8 or it was just untested.
I am getting really weird tile IDs from Stealth.Client.ReadStatics.XY method. infotile says it's ID 3299 (=>CE3), but from the method I get 920C (=>37388). I was thinking there is maybe an offset, but nope.