Closed qouteall closed 1 year ago
Are there any specific mod versions that I can look at, or does it happen on latest version?
Can only reproduce it once, and that's when I didn't place a breakpoint :/.
Looks like Bad Packets' sync task is called first somehow even though Fabric API's mixin has higher priority? Even then the synced channel ids should still be there by the time the event callback is called.
Are there any specific mod versions that I can look at, or does it happen on latest version?
The latest version of ImmPtl.
Fabric API testmod has similar things https://github.com/FabricMC/fabric/blob/1.20.2/fabric-networking-api-v1/src/testmod/java/net/fabricmc/fabric/test/networking/configuration/NetworkingConfigurationTest.java#L42
The randomness may be caused by multithreading. I guess that bad packets packet handling happens concurrently with Fabric API's (not sure). Breakpoint may interfere with it by slowing down some code.
The latest version of ImmPtl added the code of rejecting vanilla clients using Fabric API functionality
https://github.com/iPortalTeam/ImmersivePortalsMod/blob/1.20.2/imm_ptl_core/src/main/java/qouteall/imm_ptl/core/network/ImmPtlNetworkConfig.java#L209
(following the doc of https://fabricmc.net/2023/09/12/1202.html)
Someone reported that it will wrongly recognize the client as not having ImmPtl when entering singleplayer world, when using bad packets mod, thus disconnecting the client. As I tested, this issue occurs randomly.
https://github.com/iPortalTeam/ImmersivePortalsMod/issues/1456