Jump to content

X-Lomir

Members
  • Posts

    97
  • Joined

  • Last visited

1 Follower

Converted

  • Gender
    Male
  • Location
    Italy

Recent Profile Visitors

20546 profile views

X-Lomir's Achievements

Stone Miner

Stone Miner (3/8)

0

Reputation

  1. You're right, changing my code to @Override public BakedModel applyTransform(TransformType transformType, PoseStack poseStack, boolean applyLeftHandTransform) { ItemTransform transform = VerticalSlabPerspectiveTransformer.getTransformation(transformType); if (transform != ItemTransform.NO_TRANSFORM) { transform.apply(applyLeftHandTransform, poseStack); } return this; } and public class VerticalSlabPerspectiveTransformer { /** * Map of all the Vertical Slab Item {@link Transformation transformations} associated with their respective {@link TransformType}. */ private static final Map<TransformType, ItemTransform> TRANSFORMATIONS = Map.ofEntries( entry(TransformType.GUI, getItemTransform(new Vector3f(0.1F, -0.05F, 0), new Vector3f(30, 45, 0), new Vector3f(0.625F, 0.625F, 0.625F))), entry(TransformType.GROUND, getItemTransform(new Vector3f(0, 0.015F, 0.075F), Vector3f.ZERO, new Vector3f(0.25F, 0.25F, 0.25F))), entry(TransformType.FIXED, getItemTransform(Vector3f.ZERO, Vector3f.ZERO, new Vector3f(0.5F, 0.5F, 0.5F))), entry(TransformType.FIRST_PERSON_LEFT_HAND, getItemTransform(Vector3f.ZERO, new Vector3f(0, 315, 0), new Vector3f(0.4F, 0.4F, 0.4F))), entry(TransformType.FIRST_PERSON_RIGHT_HAND, getItemTransform(Vector3f.ZERO, new Vector3f(0, 135, 0), new Vector3f(0.4F, 0.4F, 0.4F))), entry(TransformType.THIRD_PERSON_LEFT_HAND, getItemTransform(new Vector3f(0F, 0.175F, 0), new Vector3f(75, 315, 0), new Vector3f(0.375F, 0.375F, 0.375F))), entry(TransformType.THIRD_PERSON_RIGHT_HAND, getItemTransform(new Vector3f(0F, 0.175F, 0), new Vector3f(75, 135, 0), new Vector3f(0.375F, 0.375F, 0.375F))) ); /** * Returns the correct Vertical Slab Item {@link Transformation} given the {@link TransformType}. * * @param transformType - {@link TransformType}. * @return one of {@link #TRANSFORMATIONS Vertical Slab Item Transformations}. */ public static final ItemTransform getTransform(TransformType transformType) { return TRANSFORMATIONS.getOrDefault(transformType, ItemTransform.NO_TRANSFORM); } public static final ItemTransform getItemTransform(Vector3f translation, Vector3f rotation, Vector3f scale) { return new ItemTransform(rotation, translation, scale); } } works and doesn't make the game crash. Some left hand transformation are a bit off, but I guess that's because of the new boolean variable and only needs some tinkering to fix. Thanks
  2. The exception must have something to do with the item rendering. In the inventory it works fine, but as soon as I drop the item or try to look at it in F5, the game crashes with the following error: java.lang.IllegalStateException: Pose stack not empty at net.minecraft.client.renderer.LevelRenderer.checkPoseStack(LevelRenderer.java:1430) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.LevelRenderer.renderLevel(LevelRenderer.java:1229) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.GameRenderer.renderLevel(GameRenderer.java:1068) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.GameRenderer.render(GameRenderer.java:840) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.runTick(Minecraft.java:1115) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.run(Minecraft.java:700) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.main.Main.run(Main.java:212) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:runtimedistcleaner:A} at net.minecraft.client.main.Main.main(Main.java:51) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:runtimedistcleaner:A} at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?] {} at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:?] {} at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:?] {} at java.lang.reflect.Method.invoke(Unknown Source) ~[?:?] {} at net.minecraftforge.fml.loading.targets.ForgeClientUserdevLaunchHandler.lambda$launchService$0(ForgeClientUserdevLaunchHandler.java:25) ~[fmlloader-1.19.2-43.1.1.jar%2395!/:?] {} at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:30) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:53) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:71) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.Launcher.run(Launcher.java:106) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.Launcher.main(Launcher.java:77) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:26) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:23) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.bootstraplauncher.BootstrapLauncher.main(BootstrapLauncher.java:141) [bootstraplauncher-1.1.2.jar:?] {} A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- Head -- Thread: Render thread Stacktrace: at net.minecraft.client.renderer.LevelRenderer.checkPoseStack(LevelRenderer.java:1430) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.LevelRenderer.renderLevel(LevelRenderer.java:1229) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.GameRenderer.renderLevel(GameRenderer.java:1068) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} Below what I believe the relevant code is: // Inside my custom BakedModel @Override public BakedModel applyTransform(TransformType transformType, PoseStack poseStack, boolean applyLeftHandTransform) { Transformation transformation = VerticalSlabPerspectiveTransformer.getTransformation(transformType); if (!transformation.isIdentity()) { transformation.push(poseStack); } return this; } And in my VerticalSlabPerspectiveTransformer class: public class VerticalSlabPerspectiveTransformer { /** * Map of all the Vertical Slab Item {@link Transformation transformations} associated with their respective {@link TransformType}. */ private static final Map<TransformType, Transformation> TRANSFORMATIONS = Map.ofEntries( entry(TransformType.GUI, getTransformation(new Vector3f(0.1F, -0.05F, 0), new Vector3f(30, 45, 0), new Vector3f(0.625F, 0.625F, 0.625F))), entry(TransformType.GROUND, getTransformation(new Vector3f(0, 0.015F, 0.075F), Vector3f.ZERO, new Vector3f(0.25F, 0.25F, 0.25F))), entry(TransformType.FIXED, getTransformation(Vector3f.ZERO, Vector3f.ZERO, new Vector3f(0.5F, 0.5F, 0.5F))), entry(TransformType.FIRST_PERSON_LEFT_HAND, getTransformation(Vector3f.ZERO, new Vector3f(0, 315, 0), new Vector3f(0.4F, 0.4F, 0.4F))), entry(TransformType.FIRST_PERSON_RIGHT_HAND, getTransformation(Vector3f.ZERO, new Vector3f(0, 135, 0), new Vector3f(0.4F, 0.4F, 0.4F))), entry(TransformType.THIRD_PERSON_LEFT_HAND, getTransformation(new Vector3f(0F, 0.175F, 0), new Vector3f(75, 315, 0), new Vector3f(0.375F, 0.375F, 0.375F))), entry(TransformType.THIRD_PERSON_RIGHT_HAND, getTransformation(new Vector3f(0F, 0.175F, 0), new Vector3f(75, 135, 0), new Vector3f(0.375F, 0.375F, 0.375F))) ); /** * Returns a new {@link Transformation} given the translation, rotation and scale {@link Vector3f vectors}. * * @param translation - translation {@link Vector3f}. * @param rotation - rotation {@link Vector3f}, in degrees. * @param scale - scale {@link Vector3f}. * @return a new {@link Transformation}. */ private static final Transformation getTransformation(Vector3f translation, Vector3f rotation, Vector3f scale) { return new Transformation(translation, TransformationHelper.quatFromXYZ(rotation, true), scale, null); } /** * Returns the correct Vertical Slab Item {@link Transformation} given the {@link TransformType}. * * @param transformType - {@link TransformType}. * @return one of {@link #TRANSFORMATIONS Vertical Slab Item Transformations}. */ public static final Transformation getTransformation(TransformType transformType) { return TRANSFORMATIONS.getOrDefault(transformType, Transformation.identity()); } } All code is available here. I am porting my mod from 1.18.2 to 1.19.2, in 1.18.2 the same code works fine, but in 1.19.2 it breaks.
  3. This is my thread, I had created it for this mod. Since it's relevant to the same mod so I thought it would be fine to post here
  4. I also just found out a bug that makes the game crash... It has something to do with the item rendering. In the inventory it works fine, but as soon as I drop the item or try to look at it in F5, the game crashes. java.lang.IllegalStateException: Pose stack not empty at net.minecraft.client.renderer.LevelRenderer.checkPoseStack(LevelRenderer.java:1430) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.LevelRenderer.renderLevel(LevelRenderer.java:1229) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.GameRenderer.renderLevel(GameRenderer.java:1068) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.GameRenderer.render(GameRenderer.java:840) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.runTick(Minecraft.java:1115) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.run(Minecraft.java:700) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.main.Main.run(Main.java:212) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:runtimedistcleaner:A} at net.minecraft.client.main.Main.main(Main.java:51) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:runtimedistcleaner:A} at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?] {} at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:?] {} at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:?] {} at java.lang.reflect.Method.invoke(Unknown Source) ~[?:?] {} at net.minecraftforge.fml.loading.targets.ForgeClientUserdevLaunchHandler.lambda$launchService$0(ForgeClientUserdevLaunchHandler.java:25) ~[fmlloader-1.19.2-43.1.1.jar%2395!/:?] {} at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:30) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:53) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:71) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.Launcher.run(Launcher.java:106) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.Launcher.main(Launcher.java:77) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:26) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:23) [modlauncher-10.0.8.jar%23108!/:?] {} at cpw.mods.bootstraplauncher.BootstrapLauncher.main(BootstrapLauncher.java:141) [bootstraplauncher-1.1.2.jar:?] {} A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- Head -- Thread: Render thread Stacktrace: at net.minecraft.client.renderer.LevelRenderer.checkPoseStack(LevelRenderer.java:1430) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.LevelRenderer.renderLevel(LevelRenderer.java:1229) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.renderer.GameRenderer.renderLevel(GameRenderer.java:1068) ~[forge-1.19.2-43.1.1_mapped_official_1.19.2-recomp.jar%23183!/:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} Here the log of the crash and below what I believe the relevant code is: // Inside my VerticalSlabBakedModel @Override public BakedModel applyTransform(TransformType transformType, PoseStack poseStack, boolean applyLeftHandTransform) { Transformation transformation = VerticalSlabPerspectiveTransformer.getTransformation(transformType); if (!transformation.isIdentity()) { transformation.push(poseStack); } return this; } public class VerticalSlabPerspectiveTransformer { /** * Map of all the Vertical Slab Item {@link Transformation transformations} associated with their respective {@link TransformType}. */ private static final Map<TransformType, Transformation> TRANSFORMATIONS = Map.ofEntries( entry(TransformType.GUI, getTransformation(new Vector3f(0.1F, -0.05F, 0), new Vector3f(30, 45, 0), new Vector3f(0.625F, 0.625F, 0.625F))), entry(TransformType.GROUND, getTransformation(new Vector3f(0, 0.015F, 0.075F), Vector3f.ZERO, new Vector3f(0.25F, 0.25F, 0.25F))), entry(TransformType.FIXED, getTransformation(Vector3f.ZERO, Vector3f.ZERO, new Vector3f(0.5F, 0.5F, 0.5F))), entry(TransformType.FIRST_PERSON_LEFT_HAND, getTransformation(Vector3f.ZERO, new Vector3f(0, 315, 0), new Vector3f(0.4F, 0.4F, 0.4F))), entry(TransformType.FIRST_PERSON_RIGHT_HAND, getTransformation(Vector3f.ZERO, new Vector3f(0, 135, 0), new Vector3f(0.4F, 0.4F, 0.4F))), entry(TransformType.THIRD_PERSON_LEFT_HAND, getTransformation(new Vector3f(0F, 0.175F, 0), new Vector3f(75, 315, 0), new Vector3f(0.375F, 0.375F, 0.375F))), entry(TransformType.THIRD_PERSON_RIGHT_HAND, getTransformation(new Vector3f(0F, 0.175F, 0), new Vector3f(75, 135, 0), new Vector3f(0.375F, 0.375F, 0.375F))) ); /** * Returns a new {@link Transformation} given the translation, rotation and scale {@link Vector3f vectors}. * * @param translation - translation {@link Vector3f}. * @param rotation - rotation {@link Vector3f}, in degrees. * @param scale - scale {@link Vector3f}. * @return a new {@link Transformation}. */ private static final Transformation getTransformation(Vector3f translation, Vector3f rotation, Vector3f scale) { return new Transformation(translation, TransformationHelper.quatFromXYZ(rotation, true), scale, null); } /** * Returns the correct Vertical Slab Item {@link Transformation} given the {@link TransformType}. * * @param transformType - {@link TransformType}. * @return one of {@link #TRANSFORMATIONS Vertical Slab Item Transformations}. */ public static final Transformation getTransformation(TransformType transformType) { return TRANSFORMATIONS.getOrDefault(transformType, Transformation.identity()); } } All code is available here.
  5. I'm trying to port to 1.19 and I managed to updated everything but one thing: the creative tabs. I had the following method handle updating the creative search tree: public static final void addToSearchTree() { int intialSize = inSearchTree.size(); MutableSearchTree<ItemStack> creativeSearchTree = Minecraft.getInstance().getSearchTree(SearchRegistry.CREATIVE_NAMES); for(BlockState referredSlabState : MapsManager.slabStateMap.values()) { if (!inSearchTree.containsKey(referredSlabState)) { creativeSearchTree.add(VerticalSlabUtils.getVerticalSlabItem(referredSlabState, VerticalSlabUtils.isTranslucent(referredSlabState))); inSearchTree.put(referredSlabState, true); } } if (intialSize != inSearchTree.size()) { creativeSearchTree.refresh(); } } However in 1.19 it looks like getSearchTree returns a SearchTree and MutableSearchTree disappeared.
  6. In the end I was, by mistake, calling a method twice. I had already checked for the logical side, but the fact that the method was being called 2 times made me wonder. Thanks to your comment I realized my mistake, thanks!
  7. I know AttackEntityEvent fires 2 times, 1 for each hand. Is there a way to understand which hand the event is currently being fired for?
  8. Okay, adding the string you wrote works for me too, although I'm getting an error that says it can't find a mixin, but I guess this is another problem ahah Thanks!
  9. Yeah, that api properties file is where I store the api key for publishing on CurseForge and GitHub. I forgot to mention that either you have it or all the inherent part must be commented out (or create a mock file).
  10. I swear that is the log I got, I don't know why the error only appears in console and is not present in the debug log. Anyway, I will put below also the stacktrace I copied from the console: Exception in thread "main" java.lang.StringIndexOutOfBoundsException: begin 0, end -4, length 0 at java.base/java.lang.String.checkBoundsBeginEnd(Unknown Source) at java.base/java.lang.String.substring(Unknown Source) at [email protected]/cpw.mods.jarhandling.JarMetadata.fromFileName(JarMetadata.java:79) at [email protected]/cpw.mods.jarhandling.JarMetadata.from(JarMetadata.java:44) at MC-BOOTSTRAP/[email protected]/net.minecraftforge.fml.loading.moddiscovery.AbstractModLocator.lambda$createMod$0(AbstractModLocator.java:36) at [email protected]/cpw.mods.jarhandling.impl.Jar.<init>(Jar.java:134) at [email protected]/cpw.mods.jarhandling.SecureJar.from(SecureJar.java:58) at MC-BOOTSTRAP/[email protected]/net.minecraftforge.fml.loading.moddiscovery.AbstractModLocator.createMod(AbstractModLocator.java:34) at MC-BOOTSTRAP/[email protected]/net.minecraftforge.fml.loading.moddiscovery.MinecraftLocator.lambda$scanMods$6(MinecraftLocator.java:39) at java.base/java.util.stream.ReferencePipeline$3$1.accept(Unknown Source) at java.base/java.util.AbstractList$RandomAccessSpliterator.forEachRemaining(Unknown Source) at java.base/java.util.stream.AbstractPipeline.copyInto(Unknown Source) at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source) at java.base/java.util.stream.AbstractPipeline.evaluate(Unknown Source) at java.base/java.util.stream.AbstractPipeline.evaluateToArrayNode(Unknown Source) at java.base/java.util.stream.ReferencePipeline.toArray(Unknown Source) at java.base/java.util.stream.ReferencePipeline.toArray(Unknown Source) at java.base/java.util.stream.ReferencePipeline.toList(Unknown Source) at MC-BOOTSTRAP/[email protected]/net.minecraftforge.fml.loading.moddiscovery.MinecraftLocator.scanMods(MinecraftLocator.java:41) at MC-BOOTSTRAP/[email protected]/net.minecraftforge.fml.loading.moddiscovery.ModDiscoverer.discoverMods(ModDiscoverer.java:50) at MC-BOOTSTRAP/[email protected]/net.minecraftforge.fml.loading.FMLLoader.beginModScan(FMLLoader.java:166) at MC-BOOTSTRAP/[email protected]/net.minecraftforge.fml.loading.FMLServiceProvider.beginScanning(FMLServiceProvider.java:86) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.TransformationServiceDecorator.runScan(TransformationServiceDecorator.java:112) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.TransformationServicesHandler.lambda$runScanningTransformationServices$8(TransformationServicesHandler.java:100) at java.base/java.util.stream.ReferencePipeline$3$1.accept(Unknown Source) at java.base/java.util.HashMap$ValueSpliterator.forEachRemaining(Unknown Source) at java.base/java.util.stream.AbstractPipeline.copyInto(Unknown Source) at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source) at java.base/java.util.stream.AbstractPipeline.evaluate(Unknown Source) at java.base/java.util.stream.AbstractPipeline.evaluateToArrayNode(Unknown Source) at java.base/java.util.stream.ReferencePipeline.toArray(Unknown Source) at java.base/java.util.stream.ReferencePipeline.toArray(Unknown Source) at java.base/java.util.stream.ReferencePipeline.toList(Unknown Source) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.TransformationServicesHandler.runScanningTransformationServices(TransformationServicesHandler.java:102) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.TransformationServicesHandler.initializeTransformationServices(TransformationServicesHandler.java:55) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.Launcher.run(Launcher.java:87) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.Launcher.main(Launcher.java:77) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:26) at MC-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:23) at [email protected]/cpw.mods.bootstraplauncher.BootstrapLauncher.main(BootstrapLauncher.java:149)
  11. If I try to run Minecraft client from the dev environment, after generating the runs with gradlew genVSCodeRuns, I keep getting the following error: Exception in thread "main" java.lang.StringIndexOutOfBoundsException: begin 0, end -4, length 0 However the mod runs without problems if I put the jar in a modpack. My repo can be found here, I'm linking the whole repo because I don't know precisely what can be helpful to know for this error. I will also put below the debug log. [22ago2022 13:05:39.824] [main/INFO] [cpw.mods.modlauncher.Launcher/MODLAUNCHER]: ModLauncher running: args [--launchTarget, forgeclientuserdev, --version, MOD_DEV, --assetIndex, 1.18, --assetsDir, C:\Users\ricca\.gradle\caches\forge_gradle\assets, --gameDir, ., --fml.forgeVersion, 40.1.0, --fml.mcVersion, 1.18.2, --fml.forgeGroup, net.minecraftforge, --fml.mcpVersion, 20220404.173914, --mixin.config, soulfired.mixins.json] [22ago2022 13:05:39.829] [main/INFO] [cpw.mods.modlauncher.Launcher/MODLAUNCHER]: ModLauncher 9.1.3+9.1.3+main.9b69c82a starting: java version 17.0.3 by Eclipse Adoptium [22ago2022 13:05:39.850] [main/DEBUG] [cpw.mods.modlauncher.LaunchServiceHandler/MODLAUNCHER]: Found launch services [fmlclientdev,forgeclient,minecraft,forgegametestserverdev,fmlserveruserdev,fmlclient,fmldatauserdev,forgeserverdev,forgeserveruserdev,forgeclientdev,forgeclientuserdev,forgeserver,forgedatadev,fmlserver,fmlclientuserdev,fmlserverdev,forgedatauserdev,testharness,forgegametestserveruserdev] [22ago2022 13:05:39.867] [main/DEBUG] [cpw.mods.modlauncher.NameMappingServiceHandler/MODLAUNCHER]: Found naming services : [srgtomcp] [22ago2022 13:05:39.877] [main/DEBUG] [cpw.mods.modlauncher.LaunchPluginHandler/MODLAUNCHER]: Found launch plugins: [mixin,eventbus,slf4jfixer,object_holder_definalize,runtime_enum_extender,capability_token_subclass,accesstransformer,runtimedistcleaner] [22ago2022 13:05:39.886] [main/DEBUG] [cpw.mods.modlauncher.TransformationServicesHandler/MODLAUNCHER]: Discovering transformation services [22ago2022 13:05:39.893] [main/DEBUG] [cpw.mods.modlauncher.TransformationServicesHandler/MODLAUNCHER]: Found additional transformation services from discovery services: java.util.stream.ReferencePipeline$3@591e58fa [22ago2022 13:05:39.906] [main/DEBUG] [cpw.mods.modlauncher.TransformationServicesHandler/MODLAUNCHER]: Found transformer services : [mixin,fml] [22ago2022 13:05:39.906] [main/DEBUG] [cpw.mods.modlauncher.TransformationServicesHandler/MODLAUNCHER]: Transformation services loading [22ago2022 13:05:39.907] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Loading service mixin [22ago2022 13:05:39.908] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Loaded service mixin [22ago2022 13:05:39.909] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Loading service fml [22ago2022 13:05:39.912] [main/DEBUG] [net.minecraftforge.fml.loading.LauncherVersion/CORE]: Found FMLLauncher version 1.0 [22ago2022 13:05:39.912] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: FML 1.0 loading [22ago2022 13:05:39.913] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: FML found ModLauncher version : 9.1.3+9.1.3+main.9b69c82a [22ago2022 13:05:39.914] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: FML found AccessTransformer version : 8.0.4+66+master.c09db6d7 [22ago2022 13:05:39.915] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: FML found EventBus version : 5.0.7+5.0.7+master.6d3407cc [22ago2022 13:05:39.915] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: Found Runtime Dist Cleaner [22ago2022 13:05:39.917] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: FML found CoreMod version : 5.0.2+5.0.2+master.303343f8 [22ago2022 13:05:39.918] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: Found ForgeSPI package implementation version 4.0.15-4.x+4.0.15-4.x+4.x.038e91c0 [22ago2022 13:05:39.919] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: Found ForgeSPI package specification 4 [22ago2022 13:05:39.921] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Loaded service fml [22ago2022 13:05:39.923] [main/DEBUG] [cpw.mods.modlauncher.TransformationServicesHandler/MODLAUNCHER]: Configuring option handling for services [22ago2022 13:05:39.929] [main/DEBUG] [cpw.mods.modlauncher.TransformationServicesHandler/MODLAUNCHER]: Transformation services initializing [22ago2022 13:05:39.930] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Initializing transformation service mixin [22ago2022 13:05:39.953] [main/DEBUG] [mixin/]: MixinService [ModLauncher] was successfully booted in cpw.mods.cl.ModuleClassLoader@7e07db1f [22ago2022 13:05:39.970] [main/INFO] [mixin/]: SpongePowered MIXIN Subsystem Version=0.8.5 Source=union:/C:/Users/ricca/.gradle/caches/modules-2/files-2.1/org.spongepowered/mixin/0.8.5/9d1c0c3a304ae6697ecd477218fa61b850bf57fc/mixin-0.8.5.jar%2322!/ Service=ModLauncher Env=CLIENT [22ago2022 13:05:39.975] [main/DEBUG] [mixin/]: Initialising Mixin Platform Manager [22ago2022 13:05:39.976] [main/DEBUG] [mixin/]: Adding mixin platform agents for container ModLauncher Root Container(ModLauncher:4f56a0a2) [22ago2022 13:05:39.977] [main/DEBUG] [mixin/]: Instancing new MixinPlatformAgentMinecraftForge for ModLauncher Root Container(ModLauncher:4f56a0a2) [22ago2022 13:05:39.978] [main/DEBUG] [mixin/]: MixinPlatformAgentMinecraftForge rejected container ModLauncher Root Container(ModLauncher:4f56a0a2) [22ago2022 13:05:39.979] [main/DEBUG] [mixin/]: Instancing new MixinPlatformAgentDefault for ModLauncher Root Container(ModLauncher:4f56a0a2) [22ago2022 13:05:39.979] [main/DEBUG] [mixin/]: MixinPlatformAgentDefault accepted container ModLauncher Root Container(ModLauncher:4f56a0a2) [22ago2022 13:05:39.981] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Initialized transformation service mixin [22ago2022 13:05:39.981] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Initializing transformation service fml [22ago2022 13:05:39.982] [main/DEBUG] [net.minecraftforge.fml.loading.FMLServiceProvider/CORE]: Setting up basic FML game directories [22ago2022 13:05:39.983] [main/DEBUG] [net.minecraftforge.fml.loading.FileUtils/CORE]: Found existing GAMEDIR directory : C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run [22ago2022 13:05:39.984] [main/DEBUG] [net.minecraftforge.fml.loading.FMLPaths/CORE]: Path GAMEDIR is C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run [22ago2022 13:05:39.984] [main/DEBUG] [net.minecraftforge.fml.loading.FileUtils/CORE]: Found existing MODSDIR directory : C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run\mods [22ago2022 13:05:39.984] [main/DEBUG] [net.minecraftforge.fml.loading.FMLPaths/CORE]: Path MODSDIR is C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run\mods [22ago2022 13:05:39.985] [main/DEBUG] [net.minecraftforge.fml.loading.FileUtils/CORE]: Found existing CONFIGDIR directory : C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run\config [22ago2022 13:05:39.985] [main/DEBUG] [net.minecraftforge.fml.loading.FMLPaths/CORE]: Path CONFIGDIR is C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run\config [22ago2022 13:05:39.985] [main/DEBUG] [net.minecraftforge.fml.loading.FMLPaths/CORE]: Path FMLCONFIG is C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run\config\fml.toml [22ago2022 13:05:39.985] [main/DEBUG] [net.minecraftforge.fml.loading.FMLServiceProvider/CORE]: Loading configuration [22ago2022 13:05:40.027] [main/DEBUG] [net.minecraftforge.fml.loading.FileUtils/CORE]: Found existing default config directory directory : C:\Users\ricca\Desktop\mods\1.18\.2\soul-fire-d\forge\run\defaultconfigs [22ago2022 13:05:40.028] [main/DEBUG] [net.minecraftforge.fml.loading.FMLServiceProvider/CORE]: Preparing ModFile [22ago2022 13:05:40.031] [main/DEBUG] [net.minecraftforge.fml.loading.FMLServiceProvider/CORE]: Preparing launch handler [22ago2022 13:05:40.032] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: Using forgeclientuserdev as launch service [22ago2022 13:05:40.052] [main/DEBUG] [net.minecraftforge.fml.loading.FMLLoader/CORE]: Received command line version data : VersionInfo[forgeVersion=40.1.0, mcVersion=1.18.2, mcpVersion=20220404.173914, forgeGroup=net.minecraftforge] [22ago2022 13:05:40.054] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Initialized transformation service fml [22ago2022 13:05:40.055] [main/DEBUG] [cpw.mods.modlauncher.NameMappingServiceHandler/MODLAUNCHER]: Current naming domain is 'mcp' [22ago2022 13:05:40.057] [main/DEBUG] [cpw.mods.modlauncher.NameMappingServiceHandler/MODLAUNCHER]: Identified name mapping providers {srg=srgtomcp:1234} [22ago2022 13:05:40.057] [main/DEBUG] [cpw.mods.modlauncher.TransformationServicesHandler/MODLAUNCHER]: Transformation services begin scanning [22ago2022 13:05:40.059] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Beginning scan trigger - transformation service mixin [22ago2022 13:05:40.059] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: End scan trigger - transformation service mixin [22ago2022 13:05:40.060] [main/DEBUG] [cpw.mods.modlauncher.TransformationServiceDecorator/MODLAUNCHER]: Beginning scan trigger - transformation service fml [22ago2022 13:05:40.060] [main/DEBUG] [net.minecraftforge.fml.loading.FMLServiceProvider/CORE]: Initiating mod scan [22ago2022 13:05:40.068] [main/DEBUG] [net.minecraftforge.fml.loading.moddiscovery.ModListHandler/CORE]: Found mod coordinates from lists: [] [22ago2022 13:05:40.070] [main/DEBUG] [net.minecraftforge.fml.loading.moddiscovery.ModDiscoverer/CORE]: Found Mod Locators : (mods folder:null),(maven libs:null),(exploded directory:null),(minecraft:null),(userdev classpath:null) [22ago2022 13:05:40.076] [main/DEBUG] [net.minecraftforge.fml.loading.targets.CommonLaunchHandler/CORE]: Got mod coordinates from env [22ago2022 13:05:40.078] [main/DEBUG] [net.minecraftforge.fml.loading.targets.CommonLaunchHandler/CORE]: Found supplied mod coordinates [{defaultmodid=[]}]
  12. Is there any way to change how runs are generated? My use case is the following: I have setup a task in my build.gradle to change some otherwise invalid values in my mods.toml. However, since the bin folder is constructed without running the build.gradle file, the mods.toml used to run and test the mod has all the invalid values instead of the correct ones. I would like to change how runs are generated, at least for VSCode, so that each run configuration has this extra property: "preLaunchTask": "prelaunch", And also a tasks.json gets generated with the following content: { "version": "2.0.0", "tasks": [{ "label": "prelaunch", "command": "./gradlew processResources", "type": "shell" }] } Is there any way to accomplish this? Is it possible to make it work also on other editors (IntelliJ and Eclipse) other than VSCode?
  13. Okay, I actually finally managed to solve it and, as usual, it was a very trivial mistake: I had useShapeForLightOcclusion returning true regardless of whether the vertical slab was supposed to emit light. Adding a check for the light emission level solved my issue.
  14. Update: I discovered that it's not just a bug of double vertical slabs, it affects also normal vertical slabs. The actual bug is the following: "external" faces (faces that align with the edge of the block) do not emit light, only "internal" (faces within the block) do. Here a couple of images to better understand the situation: https://imgur.com/a/ryaevWb (I used the hardcoding trick explained before here, that's why a oak slab is emitting light). So at first I noticed the bug only with double vertical slabs as they are naturally without "internal" faces that can emit light, but upon further inspection this is what the bug actually was. Honestly I still have no idea on how to fix this, but maybe this new info can help in getting some help ๐Ÿ˜„
  15. If it's needed to test it out, you can just hardcode the LEVEL values in both methods to 15, removing the 0 in the constructor and removing the calls to getReferredProperty. Btw getReferredProperty I'm sure works fine because it works with normal vertical slabs and it keeps the correct light level for double vertical slabs, and anyway the bug is still there even when hardcoding 15. I really have no clue on why this happens, it's the last bug I have to fix before I can release a new stable version and I've been trying to solve this for days and I made no progress ๐Ÿ˜…
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.