Patched

Patched

Mod

Allows data/resource packs and mods to modify parts of json files instead of completely replacing them.

Client or server Utility

44.3k downloads
63 followers
Follow Save
Filter loader...
Filter versions...

Changes

  • Fix a crash on 1.21.6 when running any of Patched's commands.

Changes

  • Inter-patch application order has been reversed, aligning it with expectations. Previously, if you had two packs A and B which both contain patches modifying the same part of the same file, then whichever pack came first (i.e. bottom of the resource pack screen or first in the data pack list) would win. In other words, patches are applied in order of highest to lowest priority. This is generally undesirable behavior because it means you can't write a data pack that modifies a mod's patched-in world gen changes without placing the data pack below the mod in the data pack list. Now patches are applied in order of least to highest priority. This is a breaking change for anyone relying on the previous order. However, the vast majority of people will not be affected by this change as it requires a situation like the earlier example, which is not very common.

Changes

  • Fix server-side resource reloads (via the /reload command) breaking dynamic patches
  • Fix a potential error when using the patched:registered test condition on 1.21.4

Changes

  • Fix data generation crashing on 1.21.3.

Changes

  • The version number now includes the platform. For example, 7.3.1+1.21.1 is now 7.3.1+1.21.1-neoforge (corresponding to the platform it was built for). This means that modders depending on the mod via Modrinth's maven do not need to use a version number like 'EddDSwpM'. The names of each file have also changed slightly to reflect this.

New Features

  • Patches can now be applied to tags/sounds json/blockstates(?)/etc. or so-called "merged files". These only work for files defined in the same pack. That is, you cannot patch a tag defined by Minecraft (although you could patch your own contributions to it). This opens up the possibility for configurable tags, among other things.

New Features (modder-facing)

  • Added the paste patch type, which allows 'pasting' arbitrary code-defined data in json files. The intended purpose of this patch type is to make it possible to get config values into otherwise-unconfigurable things like biomes. For example, making a feature's spawn rate configurable without needing data packs. See the documentation and SingleDataSource for more information.
  • On (Neo)Forge, mods may now use IMC (InterModComms) to register data sources (for the paste operation) and test conditions (for test patches with a type field). See the documentation for details.

Changes (modder-facing)

  • Custom test registration has changed — they are now registered using Patched.registerTestCondition() and Patched.registerSimpleTestCondition(). Test conditions registered the old way will still work.

Features

  • Added a new test type: patched:pack_enabled, which allows checking for the existence of data/resource packs. See the documentation for details.

Changes

  • Rewrote Patched's primary mixin for better compatibility with mods that cause re-entrant resource queries, such as Tiny Skeletons.

Changes (for mod developers)

  • Patched's library sources are now included in the mod's sources jar.
  • Patched's internals (or most of them) are now in an internal package, rather than spread out all over the place. This will break code using or mixing into these internals, but you shouldn't be doing that anyway.

Project members

EnderTurret

Owner

Details

Licensed LGPL-2.1-only
Published 3 years ago
Updated 4 months ago