MineColonies

MineColonies

53M Downloads

[BUG] Game crash on Cancelling WorkOrder and assign a new one - getWorkOrder(int) is null

TheRocket81 opened this issue ยท 3 comments

commented

Is there an existing issue for this?

  • I have searched the existing issues

Are you using the latest MineColonies Version?

  • I am running the latest beta version of MineColonies for my Minecraft version.

Did you check on the Wiki? or ask on Discord?

  • I checked the MineColonies Wiki and made sure my issue is not covered there. Or I was sent from discord to open an issue here.

What were you playing at the time? Were you able to reproduce it in both settings?

  • Single Player
  • Multi Player

Minecraft Version

1.20.1

MineColonies Version

1.1.624-BETA

Structurize Version

1.0.742-RELEASE

Related Mods and their Versions

Hello! I've got a Minecraft crash on this code line, while trying to cancel a workorder for a builder, and assigning a new one, and looking at the required materials.

java.lang.NullPointerException: Cannot invoke "com.minecolonies.api.colony.workorders.IWorkOrderView.getDisplayName()" because the return value of "com.minecolonies.api.colony.IColonyView.getWorkOrder(int)" is null
at com.minecolonies.core.client.gui.modules.WindowBuilderResModule.onOpened(WindowBuilderResModule.java:147) ~[minecolonies-1.20.1-1.1.624-BETA.jar%23240!/:1.20.1-1.1.624-BETA] {re:classloading}

Current Behavior

Minecraft client crashes

Expected Behavior

No text to display for the workorder

Reproduction Steps

Go to a builder
Cancel the workorder,
assign another one,
return to the task list and scroll / look at the required items.

Logs

https://pastebin.com/DMKK4Yuz

Anything else?

  • Add a thumbs-up to the bug report if you are also affected. This helps the bug report become more visible to the team and doesn't clutter the comments.
  • Add a comment if you have any insights or background information that isn't already part of the conversation.
commented

Can you please post a mod list?

commented

BuilderRes module probably stores the work order id which isn't reset upon cancellation

commented