Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[1.12.2 v6.1.0] ALL upgrades work on wooden chests #118

Open
thephoenixlodge opened this issue Sep 12, 2020 · 2 comments
Open

[1.12.2 v6.1.0] ALL upgrades work on wooden chests #118

thephoenixlodge opened this issue Sep 12, 2020 · 2 comments

Comments

@thephoenixlodge
Copy link

Problem Details

As per the title, using ANY upgrade on a wooden chest will upgrade it, even if the chest isn't a "wood to ___" upgrade. E.g., a Gold to Diamond upgrade will work on a wooden chest upgrading it to Diamond, potentially allowing significant resource savings if the player does it with the highest tier single level upgrade. Other tiers are correctly only accepting upgrades meant for them (E.g Iron chest will not accept a Gold to ____ upgrade).

Environment

@s3ptum
Copy link

s3ptum commented Sep 27, 2020

can confirm this is reporduced in my personal modpack with no config changes

@eSonOfAnder
Copy link

The problem is in the items/ItemChestUpgrade.java class. It is missing the null check to verify that the base upgrade is for a wooden/vanilla chest on lines 63 and 71 (I'm unsure what the EnderChest section is intended for, as there don't appear to be any upgrades that target it, but left the change there for completeness. The change on line 63 is the important one). Because the codebase appears to be in a state of flux for a complete re-write from scratch, I can't easily submit a PR with this change, but below are what the lines should read:

if (vanillaChest.lidAngle > 0 || base != null)
...
if (enderChest.lidAngle > 0 || base != null)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants