Alex's Caves

Alex's Caves

5M Downloads

[1.20.1 Forge] Replace Entity Data Accessors with Forge Capability

TelepathicGrunt opened this issue ยท 1 comments

commented

Entity Data Accessors should only be ever set by the creator of the entity. Never added to by other mods

This is very important because Entity Data Accessors is order dependent so if multiple mods tries to add these entity data accessors to mobs and on client, they run in a different order than the server did (because mod load order is not guaranteed), the client will break connecting to server.

Instead, this mixin part needs to be removed and migrated properly to a Forge Capability because capabilities were designed specifically for this use case of attaching data to arbitrary entities. It is safer for mods as the vanilla system is designed specifically only for vanilla and unsafe for mods.

private void citadel_registerData(CallbackInfo ci) {

commented

This is still an issue. Too many people now are injecting Entity Data Accessors and the order is getting scrambled on client vs server to the point that packs like TNPLimitless 7 are getting lots of reports of people getting disconnected from server due to:
image