Skip to content

Modflower/bytecode-junkie

This branch is 8 commits ahead of gudenau/minecraft-gudasm:master.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

1764757 · Dec 22, 2023

History

36 Commits
Dec 11, 2021
Dec 22, 2023
Sep 4, 2020
Sep 5, 2020
Jan 23, 2023
Dec 11, 2021
Dec 19, 2023
Sep 4, 2020
Sep 4, 2020
Jan 23, 2023

Repository files navigation

Bytecode Junkie

A mass assembly transformation mod based off of GudASM by Gudenau.

The following README.MD is the original readme from GudASM.

gudASM

The worst best thing to happen to Fabric modding.

TL;DR

It allows you to do direct bytecode manipulation and aims to make it "easy". You should only use this when mixins really can't do what you need.

What can this do?

Anything you want it to, since it allows you to edit classes at the most basic level.

Just be mindful of what classes you load and things should work fine.

Features

  • Raw class transformations
  • A large collection of helper methods
  • @ForceBootstrap and @ForceInline for when you need to break things speed.
  • Custom entry point

How to use

Create a class the implements AsmInitializer and put it in your mod config file as an entrypoint, something like:

{
  ...
  "entrypoints": {
    "gud_asm": [
      "com.example.mod.ILikeBreakingThings"
    ]
  },
  ...
}

Then implement the AsmInitializer.onInitializeAsm() method and do something like this:

package com.example.mod;

import net.gudenau.asm.api.v0.AsmInitializer;
import net.gudenau.asm.api.v0.AsmRegistry;

public class ILikeBreakingThings implements AsmInitializer{
    @Override
    public void onInitializeAsm(){
        AsmRegistry.getInstance().registerTransformer(new AmazingTransformer());
    }
}

The rest should be pretty straight forward.

Also, please don't combine AsmInitializer with other initializers. That is just asking for crashes.

Packages

No packages published

Languages

  • Java 100.0%