Support MM1 in addition to MM2 (fixes #162)
Cause the latest OptiFabric on 1.14.4 still ships that and it has no support for entrypoints.
This commit is contained in:
@@ -12,8 +12,18 @@ import java.util.Optional;
|
||||
// We need to wait for MM to call us, otherwise we might initialize our mixins before it calls optifabric which would
|
||||
// result in OF classes not existing while our mixins get resolved.
|
||||
public class ReplayModMMLauncher implements Runnable {
|
||||
private static boolean ran;
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
// If this is MM2, then we're currently getting called because of our entrypoint declaration.
|
||||
// For backwards compatibility with MM1, we also declare our early_riser via custom metadata and MM2 supports
|
||||
// that as well and will therefore call us twice.
|
||||
if (ran) {
|
||||
return;
|
||||
}
|
||||
ran = true;
|
||||
|
||||
Mixins.addConfiguration("mixins.compat.mapwriter.replaymod.json");
|
||||
Mixins.addConfiguration("mixins.compat.shaders.replaymod.json");
|
||||
Mixins.addConfiguration("mixins.core.replaymod.json");
|
||||
|
||||
Reference in New Issue
Block a user