DarkStorm652 / DarkBot

Minecraft thin client and automation framework
BSD 2-Clause "Simplified" License
124 stars 53 forks source link

BlockChangeEvent fired with coordinates of block within chunk #22

Closed opl- closed 9 years ago

opl- commented 10 years ago

In some cases the BlockChangeEvent is fired with wrong coordinates. In many cases these coordinates appear to be block coordinates within chunks. It happened in these cases:

DarkStorm652 commented 9 years ago

This explains a lot... including that the protocol system really needs to conform to DRY.

t81lal commented 9 years ago

i think the protocl version is fine i even modelled my own around the system http://λ.pw/gdk i think the problem is the api needs to be protocol specific because the version changes are too significant to allow for a multi version compatible system

DarkStorm652 commented 9 years ago

Nah, protocols just need to represent only their changes from the previous version, rather than being completely new implementations. The change will require some work, but it will make updating much less of a hassle in the future.

t81lal commented 9 years ago

a lot changed from 1.7 to 1.8 if u look at it in the long run would it always remain backwards compatible?

DarkStorm652 commented 9 years ago

No amount of changes warrants creating a copy of the code of a previous (and potentially buggy) protocol version. It would be much better if bug fixes to an older protocol version fixed the same bugs that transitioned over in newer protocol versions without having to make the change in all of them separately.

DarkStorm652 commented 9 years ago

My lord how disguised this was. Damn low precedences of bitwise operators! *mutters angrily

https://github.com/DarkStorm652/DarkBot/commit/13e6fe0d093321c015501a4a987f4f39d152f047