Skip to content
This repository has been archived by the owner on Dec 16, 2023. It is now read-only.

GTNewHorizons/GTNHMixins

Repository files navigation

GTNH Mixins

Library that provides mixin functionality

  • Includes a shadowed Sponge Powered Mixins fork - Currently 0.8.5-GTNH
  • Shades the required libraries that previously made 0.8.5 challenging to use with MC 1.7.10
  • Shades MixinExtras - For documentation refer to the official wiki
  • Adds two additional loading strategies for mixins, inspired by Mixin Booter Legacy
    • IEarlyMixinLoader - For Mixins targetting Minecraft, Forge, and CoreMods [Note: Currently also requires IFMLLoadingPlugin for FML to force early loading]
    • ILateMixinLoader & @LateMixin - For mixins that target other (non core) mods. Requires both the interface and the Annotation due to limitations in the 1.7.10 ASMDataTable

Starting magic with mixins or how to add its config

Create mixins.<yourmodid>.json file directly in resources folder. Example Below. A mixinPlugin, or mixin list is acceptable here. For early/late mixins you must use the provided interfaces.

{
  "required": true,
  "minVersion": "0.8.3-GTNH",
  "package": "com.company.mypackage.mixins",
  "refmap": "mixins.yourmodid.refmap.json",
  "target": "@env(DEFAULT)",
  "compatibilityLevel": "JAVA_8"
}

Early Mixins

Create mixins.<yourmodid>.early.json. Have it reference the base refmap. The mixin package can be the same or different.

Late Mixins

Create mixins.<yourmodid>.late.json. Have it reference the base refmap. The mixin package can be the same or different.

License

GTNHMixins

Lesser GNU Public License 3.0 - see License

SpongeMixins

Inspired by SpongeMixins by TimeConqueror. Includes backwards compatability with previous versions, used under the MIT License

Mixin Booter Legacy

Inspiration and code adapated from https://github.com/tox1cozZ/mixin-booter-legacy under the LGPL-2.0 License

MixinExtras

MixinExtras by LlamaLad7 is included in binary files of GTNH Mixins. It is licensed under the MIT License and can be found at https://github.com/LlamaLad7/MixinExtras

Credits

Inspiration and skeleton code for the backwards compat with SpongeMixins (MinecraftURLClassPath) derived from Falsepattern under either the Fair Use Doctrine, MIT License, or LGPL license.

mitchej123 for adding the original MinecraftURLClassPath!