LucunJi / PortalSuperCacheForge112

Your nether portals become suuuuuper faaaaaast
Other
11 stars 3 forks source link

Incompatibility with FTB Utilities #001 #1

Open Delfite opened 2 years ago

Delfite commented 2 years ago

MC Version: 1.12.2 Forge Version: 14.23.5.2860 Mod Version: [Alpha] 0.2

Instructions to recreate the error are at the bottom of this report

Description: Whenever the player uses any command to teleport from the nether to the overworld and vice versa, an error is thrown in latest.log. HOWEVER, this issue is more complex than I first thought; After the error appears in the latest.log file (which you can see at the bottom of this issue) leaving the world and joining another world will cause no nether portals to generate in either dimension and the error will no longer appear in latest.log as seen in the below screenshots.

Position of the portal as seen in the top right. 2022-09-27_12 12 32

Where I end up... 2022-09-27_12 12 39

...no Portal generates, which is not supposed to happen. This happens whenever you join another world beforehand then try to enter the nether on a different world. 2022-09-27_12 12 44

I perform the /spawn command while in the nether and end up at these coordinates. 2022-09-27_12 12 55

Still no portal, which is what's supposed to happen when executing /home and /spawn, but I still don't end up at the correct coordinates... 2022-09-27_12 12 58

Relaunched my game... 2022-09-27_12 27 18

...portal now generates correctly in the nether... 2022-09-27_12 27 39

...but now using /home and /spawn to teleport between dimensions takes me to the overworld portal at spawn when near the newly-generated portal in the nether. 2022-09-27_12 28 10

Going a few hundred blocks away from the portal in the nether, I use /spawn... 2022-09-27_12 31 07

...and a portal generates in the overworld and I'm at random coordinates yet again. 2022-09-27_12 31 33

Everything shown and described here was tested in Singleplayer only. I have no idea why any of this happens but it's pretty dang annoying to have happen all the time. Removing PortalSuperCache fixes all the issues listed here.

The Error made in latest.log:

java.lang.NullPointerException: null
    at com.lucunji.superportalcache.SuperCacheTeleporter.placeInExistingPortal(SuperCacheTeleporter.java:108) ~[SuperCacheTeleporter.class:?]
    at net.minecraft.world.Teleporter.placeInPortal(Teleporter.java:37) ~[anc.class:?]
    at net.minecraft.world.Teleporter.placeEntity(Teleporter.java:436) ~[anc.class:?]
    at net.minecraft.server.management.PlayerList.transferEntityToWorld(PlayerList.java:721) ~[pl.class:?]
    at net.minecraft.server.management.PlayerList.transferPlayerToDimension(PlayerList.java:624) ~[pl.class:?]
    at net.minecraft.server.management.PlayerList.transferPlayerToDimension(PlayerList.java:611) ~[pl.class:?]
    at com.lucunji.superportalcache.PortalEventHandler.onPlayerTeleport(PortalEventHandler.java:140) ~[PortalEventHandler.class:?]
    at com.lucunji.superportalcache.PortalEventHandler.onPortalTeleport(PortalEventHandler.java:54) ~[PortalEventHandler.class:?]
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_887_PortalEventHandler_onPortalTeleport_EntityTravelToDimensionEvent.invoke(.dynamic) ~[?:?]
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90) ~[ASMEventHandler.class:?]
    at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:182) [EventBus.class:?]
    at net.minecraftforge.common.ForgeHooks.onTravelToDimension(ForgeHooks.java:1073) [ForgeHooks.class:14.23.5.2860]
    at net.minecraft.entity.player.EntityPlayerMP.changeDimension(EntityPlayerMP.java:663) [oq.class:?]
    at com.feed_the_beast.ftblib.lib.math.TeleporterDimPos.teleport(TeleporterDimPos.java:81) [TeleporterDimPos.class:?]
    at com.feed_the_beast.ftbutilities.data.FTBUtilitiesPlayerData$TeleportTask.execute(FTBUtilitiesPlayerData.java:123) [FTBUtilitiesPlayerData$TeleportTask.class:?]
    at com.feed_the_beast.ftbutilities.data.FTBUtilitiesPlayerData$Timer.teleport(FTBUtilitiesPlayerData.java:79) [FTBUtilitiesPlayerData$Timer.class:?]
    at com.feed_the_beast.ftbutilities.command.tp.CmdHome.execute(CmdHome.java:125) [CmdHome.class:?]
    at com.feed_the_beast.ftbutilities.ranks.CommandOverride.execute(CommandOverride.java:83) [CommandOverride.class:?]
    at net.minecraft.command.CommandHandler.tryExecute(CommandHandler.java:119) [bj.class:?]
    at net.minecraft.command.CommandHandler.executeCommand(CommandHandler.java:91) [bj.class:?]
    at net.minecraft.network.NetHandlerPlayServer.handleSlashCommand(NetHandlerPlayServer.java:962) [pa.class:?]
    at net.minecraft.network.NetHandlerPlayServer.processChatMessage(NetHandlerPlayServer.java:941) [pa.class:?]
    at net.minecraft.network.play.client.CPacketChatMessage.processPacket(SourceFile:37) [la.class:?]
    at net.minecraft.network.play.client.CPacketChatMessage.processPacket(SourceFile:9) [la.class:?]
    at net.minecraft.network.PacketThreadUtil$1.run(SourceFile:13) [hv$1.class:?]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_51]
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_51]
    at net.minecraft.util.Util.runTask(SourceFile:529) [h.class:?]
    at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:723) [MinecraftServer.class:?]
    at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:668) [MinecraftServer.class:?]
    at net.minecraft.server.integrated.IntegratedServer.tick(IntegratedServer.java:185) [chd.class:?]
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526) [MinecraftServer.class:?]
    at java.lang.Thread.run(Thread.java:745) [?:1.8.0_51]

How to recreate the above error:

  1. Launch the game with the following mods active: FTB Utilities, FTB Library, and PortalSuperCache (the versions of each installed mod shouldn't matter)

  2. Create a new world and enter the nether

  3. Once in the nether, simply leave the world and relaunch Minecraft

  4. Join back into the world, move at least 128 blocks away from where you entered the nether at, and use /spawn (or /home if you used /sethome before entering the nether)

  5. You should see "An unknown error occurred while attempting to perform this command" show up in chat followed by the world around you looking something like this if you have Nothirium installed: 2022-09-18_20 36 21 Either that or you'll just be stuck on the "Loading Terrain" Screen like I was during standalone testing.

  6. Check your latest.log and the error should be there

Delfite commented 2 years ago

@LucunJi

Delfite commented 2 years ago

It is now November 2nd, if someone could make a fix for this issue then that would help immensely.

LucunJi commented 2 years ago

This mod was originally made as an extension for 1.13.2 carpetmod, and is discontinued now since I have no time to look into it and it changes the vanilla portal by too much.

Delfite commented 2 years ago

This issue will remain open for anyone who decides to make a fork of this one with a fix included. Thank you for responding at least.