I am trying to use protocollib,but it too hard to me,I tried use MAP_CHUNK event listener but I dont know where is blockdata and I cant understand what is bytedata for, anyone can help me? Thanks
Do you want to change it per player or for everyone? If you want to change it for everyone just use Block#setType method.
only change one bro, I want do is when chunk load change, but sendBlockChange //mspt high and MutliBlockChange //I don't know how to use and it not good,I want do change block when send chunk.
https://gist.github.com/aadnk/5596971 I already look it,but that outdated and I dont know how change it to 1.16.5 or above version. anyone help?
It'll be harder to do it with protocollib since it requires a block id which is obtainable with nms Block#getCombinedId
if you know how to let it can use in 1.16.5 please add my discord: TJServer#6370 if you dont know clearly,we can try fix together. thanks for help
https://www.spigotmc.org/threads/tutorial-quick-method-for-more-efficient-block-disguising.102606/ This explains that sendBlockChange is slowing the client too. However, it uses nms. And I found this https://github.com/dmulloy2/PacketW...cketwrapper/WrapperPlayServerBlockChange.java. I think it will work for 1.16 too
hmm I think use my second way is use mutliblockchange, this is why I dont want send another packet,I want change packet send another packet: chunk already loaded(packet 1) edit all blocks(packet 2) change packet: chunk load with changed packet(packet only one and faster)
Pass a list of MultiBlockChangeInfo that takes Location and WrappedBlockData which can be created with WrappedBlockData#createData(Material) as a parameter in the setRecord method of this?