EnderTurret / PatchedMod

A Minecraft mod that adds the ability to patch Json files for resource and data packs.
GNU Lesser General Public License v2.1
2 stars 0 forks source link

Patched isn't working in 1.19.2 #4

Closed Cristelknight999 closed 1 year ago

Cristelknight999 commented 1 year ago

pack.zip I tried to use patched to modify biomes. i could only get this pack to work in 1.20.1, but not in 1.19.2.

EnderTurret commented 1 year ago

The reason you only got modifying biomes working in 1.20.1 is because in 1.19.3 Mojang converted all the biomes to json files. In 1.19.2 they were still hard-coded (which is why you can't patch them.)

The only way you can patch biomes in 1.19.2 is if some other data pack or mod defines every vanilla biome in json (using say, the worldgen export). However, this would likely break any mod that does the fancy modifying-code-biomes-using-loader-provided-utilities thing (i.e., Forge biome modifiers or the Fabric biome modification API).

Cristelknight999 commented 1 year ago

Oh i read that. I got confused that it didn't show any packs when using the command I thought it would still display the packs which have the flag on in the pack.mcmeta file. I tested so long that I forgot that biome thing. How could I be so stupid xD

Cristelknight999 commented 1 year ago

i can't get it to work in 1.19.2 idk what i'm doing wrong.

EnderTurret commented 1 year ago

Likely you're running into some more 1.19.2 era bugs.

In particular, 1.19.2 Patched doesn't correctly handle Fabric's every-mod-in-one resource/data pack class (GroupResourcePack). This is because Patched asks it for the pack.mcmeta file and since it's a collection of many packs, it (correctly) doesn't give Patched one (because there could be many of them). Patched does correctly handle Forge's multi-pack class (DelegatingPackResources), but I only recently fixed the Fabric side of things (in 1.19.3).

If I remember correctly, the other major bug on 1.19.2 is that due to some funny Mojang code .zip resource/data packs don't allow listing files in all namespaces (something Patched tries to do). This only affects /patched list patches [...] (and it's been fixed in the most recent 1.20 build), so it's more of a cosmetic problem.

My guess (based on your original message) is that you're running into the first issue I've listed (Fabric mods not being handled correctly).

Cristelknight999 commented 1 year ago

maybe also the one with the display thing. i tried it also with normal datapacks and it only showed me 2 times, that it has patches activated.and then it showed, that the pack has 0 patches

Cristelknight999 commented 1 year ago

i wanted to use patched for a mod of mine. but with this bugs i'll maybe use it in 1.20 not in 1.19.2