Carpet

Carpet

2M Downloads

In 1.20.5, the stackableShulkerBoxes rule causes stacked shulker boxes' stack size to appear incorrectly outside of the player's inventory

DorkOrc opened this issue · 9 comments

commented

Issue

In 1.20.5, there is a bug (MC-270846, marked as "Won't Fix") that causes items with a stack size higher than their max_stack_size component, to display their count incorrectly outside of the player's inventory.

This affects stackableShulkerBoxes as it does not modify the max_stack_size component for the client.

Steps for how to reproduce

  1. Enable the stackableShulkerBoxes carpet rule
  2. Stack some shulker boxes in your inventory. Observe that it displays the count correctly.
  3. Open a container, such as a chest, and move it into the container. Observe that it does not display the count correctly.
commented

This issue can be fixed using Tweakeroo's Stackable Shulker boxes feature in addition to the carpet rule; because the behavior you are referring to is Client side.

commented

Wondering how feasible it'd be to make it play nicer with vanilla clients with the new stack size stuff.

i tried that before realizing this BUG is just a special case of 1903, and tried to fix it by rewriting the encoding of items, to sent a extra max size tag to the client side when the default max size of shulker box is changed.

and found that the issue of this fixing method is that: if the client is in creative mode, and the user take the item out of the box to his/her inventory, the fake tag becomes real and will stay with the item forever....

maybe that is doable , maybe after digging the code of screen and editing it a lot? 🤔

commented

Is there an updated to Tweakeroo? The only version I can find is for 1.20.4

commented

Is there an updated to Tweakeroo? The only version I can find is for 1.20.4

See the Masa Modding discord for more information, as this is the Carpet GitHub.

commented

looks like this is just a special case of #1903 .
i tried to use the method mentioned in #1903, and this bug disappeared too.

commented

Wondering how feasible it'd be to make it play nicer with vanilla clients with the new stack size stuff.

commented

It could be the network rules being out of sync, but I have noticed this issue myself testing tweakeroo switching it's related settings on and off, when the server is carpet, and also on the client and wondered why it wasn't working....

I was primarily testing to see how "nice" the setting plays with Carpet Mod, and noticed that re-enabling the tweakeroo settings fixed it because it was all a Client-side problem.

You're always welcome to download my "sakura" builds for 1.20.5+, if you want to test these things for mod compatibility reasons ...

commented

Wondering how feasible it'd be to make it play nicer with vanilla clients with the new stack size stuff.

i tried that before realizing this BUG is just a special case of 1903, and tried to fix it by rewriting the encoding of items, to sent a extra max size tag to the client side when the default max size of shulker box is changed.

and found that the issue of this fixing method is that: if the client is in creative mode, and the user take the item out of the box to his/her inventory, the fake tag becomes real and will stay with the item forever....

maybe that is doable , maybe after digging the code of screen and editing it a lot? 🤔

Here’s a proposed solution for that:
If the player is in creative, send an additional client side tag like “stackableShulkerBox, and if any items have that tag on the server side as well as the custom stack size, then remove both tags.

commented

Wondering how feasible it'd be to make it play nicer with vanilla clients with the new stack size stuff.

i tried that before realizing this BUG is just a special case of 1903, and tried to fix it by rewriting the encoding of items, to sent a extra max size tag to the client side when the default max size of shulker box is changed.
and found that the issue of this fixing method is that: if the client is in creative mode, and the user take the item out of the box to his/her inventory, the fake tag becomes real and will stay with the item forever....
maybe that is doable , maybe after digging the code of screen and editing it a lot? 🤔

Here’s a proposed solution for that: If the player is in creative, send an additional client side tag like “stackableShulkerBox, and if any items have that tag on the server side as well as the custom stack size, then remove both tags.

i write some code to do the things you said.
https://github.com/ch-yx/fabric-carpet/actions/runs/9054860589/job/24875193573
but i have no time to test it.

i m looking forward to some advices.