GithubHelp home page GithubHelp logo

includedberry11 / mixinextras Goto Github PK

View Code? Open in Web Editor NEW

This project forked from llamalad7/mixinextras

0.0 0.0 0.0 341 KB

Companion library to SpongePowered Mixin with many custom injectors for a more expressive experience.

License: MIT License

Java 100.00%

mixinextras's Introduction

MixinExtras

A small companion library to Mixin, designed to help you write your Mixins in a more expressive and compatible way.

More information about each feature offered can be found at the Wiki.

Setup

MixinExtras is available on Maven Central.

The setup steps vary based on your platform:

Fabric / Quilt

FabricLoader 0.15.0+ includes MixinExtras already. If you want to maintain compatibility with older versions, or want to use a different version than is provided, see below:

dependencies {
    include(implementation(annotationProcessor("io.github.llamalad7:mixinextras-fabric:0.2.2")))
}
NeoForge with NeoGradle

NeoForge 20.2.84+ includes MixinExtras already. If you want to maintain compatibility with older versions, or want to use a different version than is provided, see below:

dependencies {
    implementation(jarJar("io.github.llamalad7:mixinextras-neoforge:0.3.2")) {
        jarJar.ranged(it, "[0.3.2,)")
    }
}
Forge 1.18.2+ with ForgeGradle
dependencies {
    compileOnly(annotationProcessor("io.github.llamalad7:mixinextras-common:0.3.2"))
    implementation(jarJar("io.github.llamalad7:mixinextras-forge:0.3.2")) {
        jarJar.ranged(it, "[0.3.2,)")
    }
}
Forge 1.18.2+ with Architectury Loom
dependencies {
    compileOnly(annotationProcessor("io.github.llamalad7:mixinextras-common:0.3.2"))
    implementation(include("io.github.llamalad7:mixinextras-forge:0.3.2"))
}
Any other platform

This is only a rough guide. You will need to look into the specifics of setting up ShadowJar for your platform.

plugins {
    id "com.github.johnrengelman.shadow" version "8.1.0"
}

configurations {
    implementation.extendsFrom shadow
}

dependencies {
    shadow(annotationProcessor("io.github.llamalad7:mixinextras-common:0.3.2"))
}

shadowJar {
    configurations = [project.configurations.shadow]
    relocate("com.llamalad7.mixinextras", "your.package.goes.here.mixinextras")
    mergeServiceFiles() // Very important!
}

To initialize MixinExtras, simply call

MixinExtrasBootstrap.init();

somewhere suitably early. In almost all cases I would recommend making an IMixinConfigPlugin and initializing MixinExtras in its onLoad method.

You're good to go!

Enjoy using the library, and don't hesitate to open an issue if you have any feedback, questions or suggestions.

Acknowledgements

I use YourKit's Java profiler when working on MixinExtras. Many thanks to them for providing a free license for the project.

mixinextras's People

Contributors

llamalad7 avatar benonardo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.