Futurepack Mod - Now with flyable Spaceships!

Futurepack Mod - Now with flyable Spaceships!

1M Downloads

[1.16.5 - 31.1.8229] Aribrush deletes Tank when empty

Wugand opened this issue ยท 1 comments

commented

Version 31.1.8229 (2396c9ca70cdcdd3e98f855605a86ae0bc473277)

Empty LackTank of Airbrush is not replaced by empty tank when going empty on usage.

Debug:
futurepack.common.item.misc.ItemLackTank (setDamage)
DirtyHacks.replaceData works and ItemStack is overridden

net.minecraft.item.ItemStack (attemptDamageItem:332)
setDamage is invoked in 332 and stack content is changed
but: l (new damage amount) is calculated before in 331
return value is determined by l >= this.getMaxDamage() and since MiscItems.lack_tank_empty is not damageable this will always be true (means "item destroyed")

net.minecraft.item.ItemStack (damageItem :341)
calls this.shrink(1); and destroys the Empty Tank

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Add any other context about the problem here.

Logs
Please use a paste site for logs, instead of putting the file directly in the issue, not only is this easier but also means we can view on mobile when we are not at our computers.
Here's a list of some paste sites and their size limits:
https://pastebin.com/ 512KB
https://hastebin.com/ 400KB
https://gist.github.com/ 100MB Requires member (Free)

commented

should be solved now right ?