Add stonecutter functionality #3999

Merged
the-real-herowl merged 36 commits from stonecutter_functionality into master 2023-11-28 00:38:06 +01:00

Adoption of #3866

Adoption of #3866
the-real-herowl added the
nodes
gameplay
GUI/HUD
items
#P4 priority: medium
labels 2023-11-06 21:57:20 +01:00
the-real-herowl added this to the 0.85.0 - Fire and Stone milestone 2023-11-06 21:57:43 +01:00
the-real-herowl force-pushed stonecutter_functionality from 16df1bcd92 to 89730b65fb 2023-11-06 21:59:04 +01:00 Compare
the-real-herowl added 1 commit 2023-11-13 17:04:19 +01:00
the-real-herowl added 5 commits 2023-11-13 21:20:00 +01:00
the-real-herowl added 2 commits 2023-11-13 21:50:16 +01:00
the-real-herowl changed title from WIP: Add stonecutter functionality to Add stonecutter functionality 2023-11-13 21:51:56 +01:00
the-real-herowl added the
Testing / Retest
label 2023-11-13 21:52:05 +01:00
Author
Owner

I reimplemented the stonecutter recipes with a brand new API. Fixed a few bugs. Leaving this up for testing, as this is massive and contains large bits of code by other authors, which I have only reviewed.

I reimplemented the stonecutter recipes with a brand new API. Fixed a few bugs. Leaving this up for testing, as this is massive and contains large bits of code by other authors, which I have only reviewed.
AFCMS requested review from AFCMS 2023-11-13 21:59:09 +01:00
Contributor

There is an issue when we took item from the output.

  • By doing a right click , it takes half the constructed item but still consume the full entry
  • The middle click in output item don't allow to take 10 times the output, has it is possible for crafting table.

Question : Is it possible to put the number of item to craft bottom right instead of in center?
And maybe hide this number if it's 1 (like in output)
image

There is an issue when we took item from the output. - By doing a right click , it takes half the constructed item but still consume the full entry - The middle click in output item don't allow to take 10 times the output, has it is possible for crafting table. Question : Is it possible to put the number of item to craft bottom right instead of in center? And maybe hide this number if it's 1 (like in output) ![image](/attachments/3d941ea0-9db5-451a-8e9e-5def102edd0b)
Member

I will do a PR on this branch with a V4 formspec and also remove dependency on node meta/inventory just like crafting table.

I will do a PR on this branch with a V4 formspec and also remove dependency on node meta/inventory just like crafting table.
Author
Owner

I will do a PR on this branch with a V4 formspec and also remove dependency on node meta/inventory just like crafting table.

I mean, if you add to this branch it will all apply to this PR.

> I will do a PR on this branch with a V4 formspec and also remove dependency on node meta/inventory just like crafting table. I mean, if you add to this branch it will all apply to this PR.
the-real-herowl added a new dependency 2023-11-20 21:15:42 +01:00
the-real-herowl force-pushed stonecutter_functionality from 4f05e64daf to 7fb1bf6e98 2023-11-23 02:22:39 +01:00 Compare
Author
Owner

This should be ready, except for the fact that there are no labels in the result choosing menu anymore. I'm not sure if we really need them though, especially that the buttons are smaller now.

This should be ready, except for the fact that there are no labels in the result choosing menu anymore. I'm not sure if we really need them though, especially that the buttons are smaller now.
Member

IMO the labels are not needed. Its duplicated with the output preview and would require doubling the amount of formspec elements for the item grid (there is no way to move the centered builtin button label to the bottom right).

IMO the labels are not needed. Its duplicated with the output preview and would require doubling the amount of formspec elements for the item grid (there is no way to move the centered builtin button label to the bottom right).
AFCMS reviewed 2023-11-23 10:24:18 +01:00
@ -7,0 +9,4 @@
-- * stonecutter_input (1)
-- * stonecutter_output (1)
-- Player meta:
-- * stonecutter_selected (string, wanted item name)
Member

The second metadata field mcl_stonecutter:switch_stack isn't mentioned here.

stonecutter_selected should be renamed to mcl_stonecutter:selected, I didn't think about it in my PR, just moved the mata field from node to player.

The second metadata field `mcl_stonecutter:switch_stack` isn't mentioned here. `stonecutter_selected` should be renamed to `mcl_stonecutter:selected`, I didn't think about it in my PR, just moved the mata field from node to player.
Author
Owner

You're right. Done.

You're right. Done.
the-real-herowl marked this conversation as resolved
Author
Owner

This should be all ready to merge now, but leaving it up for testing for now. Will merge in 2-3 days if no new problems surface.

This should be all ready to merge now, but leaving it up for testing for now. Will merge in 2-3 days if no new problems surface.
Contributor

I found a bug. It allows for item duplication.

Steps to Reproduce:

  1. Place an item that can be stone cutted e.g. stone.
  2. Select one of the options.
  3. Hit Escape/Quit the form-spec.
  4. Player get both the material and the output.

This seems to work with both stack sizes.

P.S. Kinda interesting that the stone cutter saves the previous selected option.

I found a bug. It allows for item duplication. Steps to Reproduce: 1. Place an item that can be stone cutted e.g. stone. 2. Select one of the options. 3. Hit Escape/Quit the form-spec. 4. Player get both the material and the output. This seems to work with both stack sizes. P.S. Kinda interesting that the stone cutter saves the previous selected option.
Contributor

Seems like the output count for the copper recipes are wrong.

https://minecraft.fandom.com/wiki/Block_of_Copper
https://minecraft.fandom.com/wiki/Stonecutter

One copper block should produce 4 cut copper. This also applies to the other variants and the slabs which produce 4 times the normal amount (8) and stairs (4).

Seems like the output count for the copper recipes are wrong. https://minecraft.fandom.com/wiki/Block_of_Copper https://minecraft.fandom.com/wiki/Stonecutter One copper block should produce 4 cut copper. This also applies to the other variants and the slabs which produce 4 times the normal amount (8) and stairs (4).
Author
Owner

Seems like the output count for the copper recipes are wrong.

https://minecraft.fandom.com/wiki/Block_of_Copper
https://minecraft.fandom.com/wiki/Stonecutter

One copper block should produce 4 cut copper. This also applies to the other variants and the slabs which produce 4 times the normal amount (8) and stairs (4).

Fallthrough recipes multiply automatically, so it's just adding the cut copper thing... I remember seeing that and considering it a bug though.

> Seems like the output count for the copper recipes are wrong. > > https://minecraft.fandom.com/wiki/Block_of_Copper > https://minecraft.fandom.com/wiki/Stonecutter > > One copper block should produce 4 cut copper. This also applies to the other variants and the slabs which produce 4 times the normal amount (8) and stairs (4). Fallthrough recipes multiply automatically, so it's just adding the cut copper thing... I remember seeing that and considering it a bug though.
Author
Owner

P.S. Kinda interesting that the stone cutter saves the previous selected option.

It's a side effect of how it's implemented, but it's nice so of course I kept it.

> P.S. Kinda interesting that the stone cutter saves the previous selected option. It's a side effect of how it's implemented, but it's nice so of course I kept it.
Author
Owner

Problems fixed, I'm merging this in 2-3 days if nothing new surfaces.

Problems fixed, I'm merging this in 2-3 days if nothing new surfaces.
the-real-herowl force-pushed stonecutter_functionality from bcaaccd461 to 8fd988da11 2023-11-26 00:52:14 +01:00 Compare
Member

Sorry for the duplication bug, I really don't know how I didn't catch this 🙃

Sorry for the duplication bug, I really don't know how I didn't catch this 🙃
the-real-herowl merged commit cd40861b3b into master 2023-11-28 00:38:06 +01:00
the-real-herowl deleted branch stonecutter_functionality 2023-11-28 00:38:13 +01:00
the-real-herowl removed the
Testing / Retest
label 2023-11-28 04:39:35 +01:00
Sign in to join this conversation.
No reviewers
No project
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Depends on
Reference: VoxeLibre/VoxeLibre#3999
No description provided.