Tfarcenim / DankStorageFabric

Creative Commons Zero v1.0 Universal
11 stars 9 forks source link

Locking a slot does virtually nothing #14

Closed Fourmisain closed 3 years ago

Fourmisain commented 3 years ago

Locked slots can be emptied

Locking a slot should ensure that there's always 1 item left in that slot.

But you can:

Slots unlocking themselves

There's also the issue that locked slots can unlock themselves by:

I'm not sure what the exact conditions are, but slots can randomly unlock themselves as well and even worse: Locking does sometimes not actually lock the slot; it shows the slot is red, but opening the dank again shows it is unlocked.

When a slot is locked, you see the dank moving up in your hand as if you freshly picked it up. This is because the NBT has changed. When slot locking doesn't work, this animation is missing, suggesting it doesn't set the NBT.

Steps to reproduce

If you look at the NBT of the item, it should correctly have the item inside and the slot locked.

At this point, trying to lock slots doesn't update NBT, but adding items does, which can be used to force slots to lock.

Tfarcenim commented 3 years ago

Problem was lack of nbt saving, fixed.