Astral Sorcery

Astral Sorcery

63M Downloads

Prism Whitelist not respected on second world load

StygianNights opened this issue ยท 6 comments

commented

The Resplendant Prism will only respect the whitelist of the first world loaded after a fresh launch of minecraft. From that point on, the prism, if crafted or given by commands, will have enchantments that match the whitelist of that first loaded world, even if a second world is loaded with a completely different whitelist. This is easy to replicate:

  • Make a new minecraft world, then close minecraft.
  • Edit whitelist to whatever you wish, I did protection and fire protection for simplicity.
  • Launch minecraft, and load that world.
  • Give or craft a prism, to test whitelist works.
  • Exit world
  • make a new world, fresh.
  • Craft or give yourself another prism, the enchantments should be the exact same as the previous whitelist.

Versions used for this particular discovery
Minecraft Forge 1.16.5-36.2.20
Astral Sorcery 1.13.12
ObserverLib 1.5.3
Patchouli 53.2
Curios API 4.0.8.0

Reason for Discovery: Testing a weird mod interaction in the mod Enigmatic Legacy.

commented

You edited that world's config, not the default config directory's config. Changes made to the config of a world in 1.16 will not persist into other created worlds unless that world's config file is fixed copied to the "defaultconfig" directory of the pack.

commented

I made no edits to the default config or the config that exists outside the world save. What I am attempting to convey is that a whitelist set in a world save will persist to other world saves with completely different whitelists, with the whitelist being used being the one of the first loaded world.
I am sorry if I was confusing before.

commented

You edited that world's config, not the default config directory's config. Changes made to the config of a world in 1.16 will not persist into other created worlds unless that world's config file is fixed copied to the "defaultconfig" directory of the pack.

That has nothing to do with the bug described. The problem is not that the change made in one world does not persist into another, the problem is that two worlds have two different configs, and after loading into one of them, leaving, and entering the other config of the first world will have effect. Same is true regardless of how many worlds with different configs you enter after that first one.

From my own tests, it seems like the whitelist of enchantments gets frozen as soon as EnchantmentHelper is classloaded.

commented

Single player or dedicated server?

commented

Singleplayer.

I'm not exactly sure a dedicated server can load a second world without shutting down fully first.

commented

That was the intent behind my question. Ssp does janky things with server threads and not unloading some things.

Will try to replicate later.