Jump to content

[1.8] Invalid Dimension at login


worldwidewoogie

Recommended Posts

I have a mod where dimensions can be created and deleted dynamically.  So it is possible that user can disconnect when in a dimension, but that dimension will not exist when they log in again.  The behavior is that the first time they attempt this they will get an exception and minecraft will exit, but then the 2nd time they will be able to log in fine and will be put in the overworld.  I'd like to handle this more cleanly, but haven't been able to figure out how to do that.  Is there an event I could write a handler for that would let me update the player's dimension at login time if their save dimension does not exist?

Link to comment
Share on other sites

They shouldn't get an exception we specifically put in code to prevent this so unless you've broken something they will just be spit into the overworld.

However, you should register all of your dimensions at start time having them registered does not mean they are loaded. They will be loaded on demand when a player trys to enter.

NOT having them registered means that if another mod comes along they can take the same dimension and there would be conflicts.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Link to comment
Share on other sites

I'm using Forge 11.14.4.1563 with Fedora Linux's OpenJDK 1.8.0_65-b17 (64 bit).

 

I do the following with no files in my mods directory:

 

[*]Create a new world and immediately exit Minecraft after joining the world

[*]Using NBTEdit, change the player's dimension to 2 in both level.data and the playerdata directory

[*]Start Minecraft again and join the world

 

I see the following in the fml-client-latest.log:

 

...

[14:17:45] [server thread/INFO] [FML/]: [server thread] Server side modded connection established

[14:17:45] [server thread/INFO] [sTDERR/]: [net.minecraftforge.common.DimensionManager:initDimension:239]: Cannot Hotload Dim: Could not get provider type for dimension 2, does not exist

[14:17:45] [server thread/INFO] [sTDERR/]: [net.minecraftforge.common.DimensionManager:initDimension:239]: Cannot Hotload Dim: Could not get provider type for dimension 2, does not exist

[14:17:45] [Client thread/DEBUG] [FML/]: Overriding dimension: using 2

[14:17:45] [Client thread/FATAL] [FML/]: Exception caught executing FutureTask: java.util.concurrent.ExecutionException: java.lang.IllegalArgumentException: Could not get provider type for dim

ension 2, does not exist

java.util.concurrent.ExecutionException: java.lang.IllegalArgumentException: Could not get provider type for dimension 2, does not exist

        at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[?:1.8.0_65]

        at java.util.concurrent.FutureTask.get(FutureTask.java:192) ~[?:1.8.0_65]

        at net.minecraftforge.fml.common.FMLCommonHandler.callFuture(FMLCommonHandler.java:715) [FMLCommonHandler.class:?]

        at net.minecraft.client.Minecraft.func_71411_J(Minecraft.java:1018) [bsu.class:?]

        at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:345) [bsu.class:?]

        at net.minecraft.client.main.Main.main(SourceFile:120) [Main.class:?]

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_65]

        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_65]

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_65]

        at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_65]

        at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]

        at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]

Caused by: java.lang.IllegalArgumentException: Could not get provider type for dimension 2, does not exist

        at net.minecraftforge.common.DimensionManager.getProviderType(DimensionManager.java:148) ~[DimensionManager.class:?]

        at net.minecraftforge.common.DimensionManager.createProviderFor(DimensionManager.java:303) ~[DimensionManager.class:?]

        at net.minecraft.world.WorldProvider.func_76570_a(WorldProvider.java:144) ~[bgd.class:?]

        at net.minecraft.client.multiplayer.WorldClient.<init>(WorldClient.java:54) ~[cen.class:?]

        at net.minecraft.client.network.NetHandlerPlayClient.func_147282_a(NetHandlerPlayClient.java:250) ~[cee.class:?]

        at net.minecraft.network.play.server.S01PacketJoinGame.func_148833_a(SourceFile:76) ~[jw.class:?]

        at net.minecraft.network.play.server.S01PacketJoinGame.func_148833_a(SourceFile:13) ~[jw.class:?]

        at net.minecraft.network.PacketThreadUtil$1.run(SourceFile:13) ~[ih.class:?]

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_65]

        at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_65]

        at net.minecraftforge.fml.common.FMLCommonHandler.callFuture(FMLCommonHandler.java:714) ~[FMLCommonHandler.class:?]

        ... 9 more

 

Then this exception just repeats until I close Minecraft:

 

[14:17:45] [Client thread/FATAL] [FML/]: Exception caught executing FutureTask: java.util.concurrent.ExecutionException: java.lang.NullPointerException

java.util.concurrent.ExecutionException: java.lang.NullPointerException

        at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[?:1.8.0_65]

        at java.util.concurrent.FutureTask.get(FutureTask.java:192) ~[?:1.8.0_65]

        at net.minecraftforge.fml.common.FMLCommonHandler.callFuture(FMLCommonHandler.java:715) [FMLCommonHandler.class:?]

        at net.minecraft.client.Minecraft.func_71411_J(Minecraft.java:1018) [bsu.class:?]

        at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:345) [bsu.class:?]

        at net.minecraft.client.main.Main.main(SourceFile:120) [Main.class:?]

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_65]

        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_65]

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_65]

        at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_65]

        at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]

        at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]

Caused by: java.lang.NullPointerException

        at net.minecraft.client.network.NetHandlerPlayClient.func_147240_a(NetHandlerPlayClient.java:1697) ~[cee.class:?]

        at net.minecraft.network.play.server.S3FPacketCustomPayload.func_180734_a(S3FPacketCustomPayload.java:58) ~[ji.class:?]

        at net.minecraft.network.play.server.S3FPacketCustomPayload.func_148833_a(S3FPacketCustomPayload.java:69) ~[ji.class:?]

        at net.minecraft.network.PacketThreadUtil$1.run(SourceFile:13) ~[ih.class:?]

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_65]

        at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_65]

        at net.minecraftforge.fml.common.FMLCommonHandler.callFuture(FMLCommonHandler.java:714) ~[FMLCommonHandler.class:?]

        ... 9 more

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

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