Drathonix / LoadMyChunks

A server friendly chunk loading mod
MIT License
5 stars 0 forks source link

[BUG] Serverside Failure to remove Chunk Loader from CDM #15

Closed Drathonix closed 3 months ago

Drathonix commented 3 months ago

This is a mistake in MixinLevelChunk.properlyDestroyTileEntities where the call is assumed to be serversided. Turns out this method is only ever called on the client side, causing the BlockEntityChunkLoader.destroy call to not be made on the server, and resulting in ghost chunk loader creation when breaking chunk loaders.

The solution is twofold:

  1. Also inject into the method "getBlockEntity(BlockPos, EntityCreationType)" which is called on the serverside.
  2. Do level.isClientSide() check in both mixin impls.

In addition, any servers currently using LMC will need to wipe their loadmychunks_manager.dat file, which they can do manually, the number of mod downloads is small enough currently that it has likely only affected a few people, it is therefore not worth having some sort of data check.

The effect can be severe but seems to have only reared its ugly head today in my 1.16.5 tests, nonetheless I'll just assume it affects all vers. This will be fixed in 1.0.5

Drathonix commented 3 months ago

Fixed in 1.0.5