Traveler's Backpack [Fabric]

Traveler's Backpack [Fabric]

11M Downloads

In multiplayer, only the newest backpack can craft

ILikePizza555 opened this issue ยท 4 comments

commented

ALWAYS PROVIDE INFORMATION ABOUT MODLOADER (Fabric / Forge) AND MOD VERSION (For Example 1.19.2-8.2.10)

Fabric - v1.20.1-9.15, Multiplayer

Describe the bug

What it says on the tin: In multiplayer, only the newest backpack can craft. If a player crafts a backpack, that's the only backpack on the server with crafting ability. If a zombie spawns wearing a backpack and drops it, that becomes the only backpack on the server with crafting ability. If a player upgrades a backpack that's the only backpack with crafting ability.

Write steps to reproduce the bug

  1. Create a backpack on a multiplayer server.
  2. Try to craft, observe that it works
  3. Create a new backpack on that server
  4. Try to craft with the old backpack, observe that nothing appears in the crafting result
  5. Try to craft with the new backpack, observe that it works

What is expected behaviour

I think all players should be able to craft.

commented

This is not strictly correct, any backpack can work at any time, but the result slot is disabled under incorrect circumstances.

case BUCKET_IN_LEFT -> 0;//17 + (this.getAllSlots() - LEATHER.getAllSlots());
case BUCKET_OUT_LEFT -> 1; //18 + (this.getAllSlots() - LEATHER.getAllSlots());
case BUCKET_IN_RIGHT -> 2; //19 + (this.getAllSlots() - LEATHER.getAllSlots());
case BUCKET_OUT_RIGHT -> 3; //20 + (this.getAllSlots() - LEATHER.getAllSlots());
was updated to use these tiny slot numbers, instead of the correct calculation, which would be a slightly adjusted version of what is commented out. The effect is that putting an item in slot 2 or 3 of the backpack will disable the result slot, instead of the right bucket slots as intended.

commented

This is not strictly correct, any backpack can work at any time, but the result slot is disabled under incorrect circumstances.

case BUCKET_IN_LEFT -> 0;//17 + (this.getAllSlots() - LEATHER.getAllSlots());
case BUCKET_OUT_LEFT -> 1; //18 + (this.getAllSlots() - LEATHER.getAllSlots());
case BUCKET_IN_RIGHT -> 2; //19 + (this.getAllSlots() - LEATHER.getAllSlots());
case BUCKET_OUT_RIGHT -> 3; //20 + (this.getAllSlots() - LEATHER.getAllSlots());

was updated to use these tiny slot numbers, instead of the correct calculation, which would be a slightly adjusted version of what is commented out. The effect is that putting an item in slot 2 or 3 of the backpack will disable the result slot, instead of the right bucket slots as intended.

Thank you for your comment, I forgot to edit result slot code while I was moving bucket slots out of saveable backpack inventory, fix should be available today