Draconic Evolution

Draconic Evolution

77M Downloads

Draconic Capacitor Crashes World

NitroBrony opened this issue ยท 11 comments

commented

Base information

  • Minecraft version: 1.12.2
  • Mod version: 2.3.21.342
  • Minecraft Forge version: 1.12.2-14.23.5.2823
  • Mod Pack: (if applicable)

Crash report

https://pastebin.com/CjHQTR06

Info: I shift right clicked the Draconic Capacitor with the full draconic upgrade on it fully charged to change its mode and it crashed my game. I then could not load my world with out crashing until I went into an NBT Editor and changed its mode to 0 and its charge to 0. Pretty sure this is a pretty bad bug that could ruin players experience with the mod by breaking players worlds that don't know how to use an NBT Editor to fix the problem.

commented

Try loading the pack without galacticraft installed and see if you can reproduce the error

commented

Haven't tested this out myself, but to ease other people trying to see where the problem is, the exception is as follows:

java.lang.UnsupportedOperationException

The line of code that is causing this is pointed out in the arrow in the code below:

   public void updateEnergy(ItemStack capacitor, EntityPlayer player, List<ItemStack> stacks) {
        int mode = ItemNBTHelper.getShort(capacitor, "Mode", (short) 0);

        if (mode == 0) {
            return;
        }

        if (mode == 4) { //Charge All
            stacks.addAll(player.inventory.armorInventory);
            stacks.addAll(player.inventory.mainInventory);
            stacks.addAll(player.inventory.offHandInventory);
        }
        else {
            if (mode == 1 || mode == 3) { //Charge Armor
             -->stacks.addAll(player.inventory.armorInventory);<--
            }
            else {
                stacks.clear(); // Dont charge baubles
            }
            if (mode == 2 || mode == 3) { //Charge Held Items
                stacks.add(player.getHeldItemOffhand());
                stacks.add(player.getHeldItemMainhand());
            }
        }
commented

Well, the issue is I am using it in a 1.12 pack and not getting the crash, that usually indicates a conflict with another mod. the goal is to identify the mod causing the conflict to determine if the issue is something wrong in DE or the other mod.

commented

I can not easily remove Galactic Craft as I am running a self hosted Mod Pack (just running a lot of mods) on my forge. Since my entire base and a lot of tools I have is from Galactic Craft removing it could cause a world corruption if I load the game with out it. Essentially a giant hole where my base is. And I don't see how Galactic Craft would make me crash when shift right clicking a draconic Capacitor to change its mode.

commented

And to add I would crash on loading the world until I used an NBT editor and changed mode of the capacitor from 1 to 0 and its charge from 640,000,000 to 0 then I could load the world fine. To test I charged it again and shift right clicked crashed me the same way until I changed the values to 0 once again

commented

You run the pack in a single player world, and yes, if another mod is affecting the code then it will crash. Trust me, with as many packs as I have built it does happen. First step to finding a cause is to rule out mod interactions.

commented

As per the line of code causing the crash, what armor sets do you have on, and is there another mod that adds more armor slots?

commented

Ok this is my bad... The capacitor is basically guaranteed to crash you if you don't have Baubles installed.

commented

FoxMcloud5655 I have a full set of Draconic armor with max upgrades on all pieces. (Edit > Galactic Craft and Aether Legacy and Extra Planets)

Brandon you are right I do not have Baubles installed as I did not see it as a dependency

commented

Baubles is not a dependency its just supported.

commented

Just test it and it's not fixed
https://paste.ee/p/9R5x0