Recurrent Complex

Recurrent Complex

35M Downloads

[1.7.10] #gen command doesn't work if you change the Z to a dimension ID that doesn't exist

Mikki-m8 opened this issue ยท 2 comments

commented

Alright, I know the title can be a bit confusing.

The command is: /#gen <x> <z> <dimension>

I'm trying to use Recurrent Complex to generate a structure at a specific location (in a specific dimension too) on command.

I can change X to whatever number I want, and Dimension to any valid Dimension ID, but if I change Z to a number that isn't also a Dimension ID, the command will fail saying:

java.lang.NullPointerException
	at ivorius.reccomplex.commands.CommandGenerateStructure.func_71515_b(CommandGenerateStructure.java:79) ~[CommandGenerateStructure.class:?]
	at net.minecraft.command.CommandHandler.func_71556_a(CommandHandler.java:94) [z.class:?]
	at net.minecraft.network.NetHandlerPlayServer.func_147361_d(NetHandlerPlayServer.java:739) [nh.class:?]
	at net.minecraft.network.NetHandlerPlayServer.func_147354_a(NetHandlerPlayServer.java:718) [nh.class:?]
	at net.minecraft.network.play.client.C01PacketChatMessage.func_148833_a(SourceFile:37) [ir.class:?]
	at net.minecraft.network.play.client.C01PacketChatMessage.func_148833_a(SourceFile:9) [ir.class:?]
	at net.minecraft.network.NetworkManager.func_74428_b(NetworkManager.java:212) [ej.class:?]
	at net.minecraft.network.NetworkSystem.func_151269_c(NetworkSystem.java:165) [nc.class:?]
	at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:659) [MinecraftServer.class:?]
	at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:547) [MinecraftServer.class:?]
	at net.minecraft.server.integrated.IntegratedServer.func_71217_p(IntegratedServer.java:111) [bsx.class:?]
	at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:427) [MinecraftServer.class:?]
	at net.minecraft.server.MinecraftServer$2.run(MinecraftServer.java:685) [?:?]

I know the 1.7.10 version hasn't been updated in a really long time but I'm hoping there's some sort of quick fix or workaround other than me changing all the Dimension IDs to the Z coordinates of the structures I want to spawn?

commented

The fix is as simple as changing a 2 to a 3 at line 61 in CommandGenerateStructure.java

if I knew how to submit a Pull Request properly, I would, but I'm pretty clueless about this stuff.

commented

I just tried to get a 1.7 build running but it fails at setup for some reason. Sorry - no clue what exactly is going wrong, but I guess 1.7 isn't supported any longer by Forge itself. Seemed like an easy fix but if I can't get a workspace running I can't make a build either way.