Tetra

Tetra

25M Downloads

[Bug] 1.20.1 Better Combat disabling offhand will void items upon swaping offhand tool via toolbelt

Shibva opened this issue ยท 1 comments

commented

Observed behaviour

This is a more detailed report based on bug #883.

This issue is caused by the two-handed weapon mechanic added by Better Combat, which disables the offhand slot while holding a weapon with this attribute.

This cannot be observed with just Better Combat present, as no item in the mod comes with a two-handed attribute, if I recall correctly. Simply Swords adds a plethora of weapons that use Better Combat for an enhanced experience, and is recommended to use to gain access to a weapon with the two-handed attribute quickly.

This issue consists of the following bugs as a result of this with the toolbelt:

  • Swapping a tool into the toolbelt from the offhand while holding a two-handed weapon will replace the item in the belt in the offhand, but not set the item swapped into the toolbelt; voiding it.
  • Two-handed weapons held in the offhand may cause problems with swapping, as mentioned above. This is likely the same thing, but I figured id mention it just in case.

Expected behaviour

The behavior should not voided the item in the offhand if the offhand slot is disabled. Based on previous interactions with working around this using a kubeJS script, it disables the offhand returns, which would otherwise reference the player as empty, while the inventory itself still holds the item.

Steps to reproduce

  1. Get a belt
  2. Get any weapon that has the Two-Handed property; it would look something like this in the tooltip
Image ( do note better combat on its implements the system but has no vanilla weapon that uses it, Simply Swords is recommended as its has integration)

3.a put any item into the belt and a different item in the offhand; hold the two-handed weapon and perform a offhand swap via use of the swap tool keybind (you will notice the offhand item in the belt was put in the offhand slot but not the other way around, demonstrated by using two different items to visualy confirm)

3.b hold the two-handed weapon in the offhand slot (it will vanish, but if you look in your inventory, you will still see it in the offhand slot; this is normal as two-handed weapons require to be held in the mainhand). from there, store the weapon using the stock toolbelt keybind [NOTE: this is not confirmed but given the nature of the bug demonstrated in 3.a, it's plausible that this will have the same results.

Possible Solution: change how offhand items are referenced or include a check in the inventory of the player directly as a fallback. It's possible other mods that disable offhand would have the same issue as with Better Combat, though this is just a speculation.

Crashlog

No response

Tetra version

6.9.0 (not adressed in changelog for 6.9.10; high likeyhood its present

mutil/mGui version

6.2.0

Forge version

1.20.1 - 47.4.2 & presumably present on other game versions

Other mods

  • Better Combat (required)
  • Simply Swords (strongly recommended, provides weapons that use the two-handed attribute; BC on its own doesn't have any vanilla weapons that use it)
commented

any word on this bug getting fixed?