Improvement: Behavior of item name field in anvil menu #4486
Labels
No Label
#P1 CRITICAL
#P2: HIGH
#P3: elevated
#P4 priority: medium
#P6: low
#Review
annoying
API
bug
code quality
combat
commands
compatibility
configurability
contribution inside
controls
core feature
creative mode
delayed for engine release
documentation
duplicate
enhancement
environment
gameplay
graphics
ground content conflict
GUI/HUD
help wanted
incomplete feature
invalid / won't fix
items
looking for contributor
mapgen
meta
mineclone2+
Minecraft >= 1.13
Minecraft >= 1.17
missing feature
mobile
mobs
mod support
model needed
multiplayer
Needs adoption
needs discussion
needs engine change
needs more information
needs research
nodes
non-Minecraft feature
non-mob entities
performance
player
possible close
redstone
release notes
schematics
Skyblock
sounds
Testing / Retest
tools
translation
unconfirmed
mcl5
mcla
Media missing
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: VoxeLibre/VoxeLibre#4486
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Feature
Why
At the moment, the old name will be shown, possibly leading to naming problems (unintentionally changed or deleted names). Also leaving the name of an item or changing it will be easier.
Hmmm, this is actually an annoying issue. The reason is that the anvil is like an inventory - the item you take out of the output slot exists all the time, but will delete the input item when you take it.
This means that the output item (and its name) is stored in the anvil metadata.
(The formspec which appears on rightclicking the anvil is also stored in the anvil's metadata, and even if it weren't this would still be an issue as the inventory item must be)
This basically means that the formspec (and the rename) must be the same for all players who use the anvil, and there appears to be no good solution for resetting the name - imagine the case where a different player had the formspec open the whole time you were away.
Does anyone know how to fix this?
@WillConker, if I understand you correctly, the problem is that different players can use the anvil simultaneously and the name is stored in the anvil's metadata?
But then it should be possible (and please correct me if I'm wrong) that the naming/renaming is also on a per-player-basis:
If the player leaves the UI without taking the item out of the input or output slot, either the content will be saved (the name can be saved but does not have to be, as when you open the UI it can take the name from the item in the input slot) or the anvil will drop the input item like with other tables/workplaces/machines.
So the only thing that changes IMHO is that the name won't be saved in the anvil metadata for this player, the UI will always get it from the item in the input slot either if there's one present if you open the UI (not taken out before closing the UI last time) or if the player puts one in there when the UI is open.
Yes, this might be possible. We would have to make it more like the crafting table, we (i think) the crafting table slots are stored as an extension of the player's inventory.