Add platform name to hooks

This commit is contained in:
embeddedt 2023-06-26 14:21:07 -04:00
parent 60525ad594
commit 4943702061
No known key found for this signature in database
GPG Key ID: A69433EC199B5613
3 changed files with 13 additions and 0 deletions

View File

@ -96,4 +96,9 @@ public class ModernFixPlatformHooks {
public static void onLaunchComplete() {
}
@ExpectPlatform
public static String getPlatformName() {
throw new AssertionError();
}
}

View File

@ -118,4 +118,8 @@ public class ModernFixPlatformHooksImpl {
CommonModUtil.runWithoutCrash(() -> SparkLaunchProfiler.stop("launch"), "Failed to stop profiler");
}
}
public static String getPlatformName() {
return "Fabric";
}
}

View File

@ -257,4 +257,8 @@ public class ModernFixPlatformHooksImpl {
CommonModUtil.runWithoutCrash(() -> SparkLaunchProfiler.stop("launch"), "Failed to stop profiler");
}
}
public static String getPlatformName() {
return "Forge";
}
}