PaperMC / paperweight

Gradle build system plugin for Paper and Paper forks

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

More Missed Mappings (after 1.17.1 update)

fierceeo opened this issue · comments

Some mappings that are incorrect after the 1.17.1 update.

  1. The GeneratorSettings object named "Y" in net.minecraft.server.dedicated.DedicatedServerProperties now has a private access modifier instead of public
  2. The Executor object named "aA" in net.minecraft.server.MinecraftServer has been renamed to "az"
  3. The DataPackResources object named "aC" in net.minecraft.server.MinecraftServer has been renamed to "aB"
  1. is a vanilla change, not a mapping change, mojang made the field private and exposed a public getter
    2, 3) Have these been checked against spigot? Spigot often has random renamed fields during patch releases
  1. The getter code is the same as 1.17.
  2. and 3. Spigot has the same mappings. (Does this mean that this is a spigot issue and not paper?)
  1. https://hub.spigotmc.org/stash/projects/SPIGOT/repos/builddata/commits/a4785704979a469daa2b7f6826c84e7fe886bb03#mappings/bukkit-1.17.1.at

L380, spigot removed the AT so this is no longer public

2. 3. That means that the mappings are correct, spigot ended up with a mapping change between the two versions, which is not uncommon for there to be a generally small number of mapping changes between patch versions, they're not guaranteed to be consistent at all between versions

Understood.

For future reference, how can developers maintain backwards compatibility if nms mappings vary inside a version?

"good luck", most people just try to determine it through code, try latest method, if not exists, go to next, ofc, this will be "fun" in some cases

(best solution is basically to replace your nms needs with API, PR'ing, creating an issue, etc, where needed)

https://papermc.io/javadocs/paper/1.17/org/bukkit/UnsafeValues.html#getDataVersion()

That is unique for every version and should be the only used data point to change your mappings on. The package version was always unreliable.