This commit is contained in:
parent
34cd3f1dac
commit
a4ab17f5a8
|
@ -7,7 +7,7 @@ plugins {
|
|||
}
|
||||
|
||||
group = "dev.frogmc"
|
||||
version = "0.0.1-alpha.16"
|
||||
version = "0.0.1-alpha.17"
|
||||
|
||||
repositories {
|
||||
maven {
|
||||
|
@ -18,8 +18,6 @@ repositories {
|
|||
name = "FrogMC Releases"
|
||||
url = uri("https://maven.frogmc.dev/releases")
|
||||
}
|
||||
maven("https://maven.fabricmc.net/")
|
||||
maven("https://repo.spongepowered.org/maven")
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
thyroxine = "0.0.1-alpha.9"
|
||||
nightconfig = "3.7.3"
|
||||
mixin = "0.14.0+mixin.0.8.6"
|
||||
mixin = "0.15.0+mixin.0.8.7"
|
||||
annotations = "24.1.0"
|
||||
mixinextras = "0.3.6"
|
||||
|
||||
|
|
|
@ -146,16 +146,15 @@ public class FrogMixinService implements IMixinService, IClassProvider, IClassBy
|
|||
|
||||
@Override
|
||||
public ClassNode getClassNode(String name, boolean runTransformers) throws IOException {
|
||||
byte[] bytes;
|
||||
if (runTransformers && transformer != null) {
|
||||
bytes = transformer.transformClass(MixinEnvironment.getCurrentEnvironment(), name,
|
||||
FrogLauncher.getInstance().getTargetClassLoader().getClassBytes(name));
|
||||
} else {
|
||||
bytes = FrogLauncher.getInstance().getTargetClassLoader().getClassBytes(name);
|
||||
}
|
||||
return getClassNode(name, runTransformers, 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ClassNode getClassNode(String name, boolean runTransformers, int readerFlags) throws IOException {
|
||||
byte[] bytes = FrogLauncher.getInstance().getTargetClassLoader().getClassBytes(name);
|
||||
ClassReader reader = new MixinClassReader(bytes, name);
|
||||
ClassNode node = new ClassNode();
|
||||
reader.accept(node, 0);
|
||||
reader.accept(node, readerFlags);
|
||||
return node;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package dev.frogmc.frogloader.impl.mod;
|
||||
|
||||
import java.nio.file.Path;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
import java.util.stream.Collectors;
|
||||
|
@ -51,9 +50,7 @@ public class ModUtil {
|
|||
|
||||
builder.append(p.id()).append(" (").append(p.name()).append(") ").append(" ").append(p.version());
|
||||
if (indent.get() == 2 && !p.paths().isEmpty()) {
|
||||
Path source = p.paths().stream().findFirst().orElseThrow();
|
||||
System.out.println(source);
|
||||
String path = source.toString();
|
||||
String path = p.paths().stream().findFirst().orElseThrow().toString();
|
||||
if (path.startsWith(".")) {
|
||||
builder.append(" from ").append(path.substring(2));
|
||||
} else if (path.length() > 2) {
|
||||
|
|
|
@ -66,11 +66,13 @@ public class MinecraftGamePlugin implements GamePlugin {
|
|||
LOGGER.info("Locating game..");
|
||||
String jar = System.getProperty(SystemProperties.MINECRAFT_GAME_JAR);
|
||||
if (jar != null) {
|
||||
LOGGER.debug("Checking game jar path provided via system property..");
|
||||
Path p = Paths.get(jar);
|
||||
if (checkLocation(p)) {
|
||||
return p;
|
||||
}
|
||||
}
|
||||
LOGGER.debug("Locating game jar on classpath..");
|
||||
|
||||
for (String s : System.getProperty("java.class.path", "").split(File.pathSeparator)) {
|
||||
Path p = Paths.get(s);
|
||||
|
|
Loading…
Reference in a new issue