mojira.dev
MC-74231

Flower pot's blockdata won't visually update

The bug

You can't see the blockdata of a flower pot change after using a /blockdata command.

How to reproduce

  1. Place down an empty flower pot

  2. Use /blockdata x y z {Item:"cactus"}
    → Nothing happens

  3. Press F3+A (to reload all chunks), or force a block update, or log out and log back in
    → Now the flower pot has a cactus in it

Why this should be fixed

If a custom map maker has a flower pot on a piston head (a block that will disappear if there is a block update) then setblock would not be an option since the piston head will disappear. Blockdata doesn't make the piston head disappear but it does require a client-side refresh.

Code analysis

Code analysis by @unknown can be found in this comment.

Linked issues

Comments 13

Picture 1: Empty Flower Pot
Picture 2: Command
Picture 3: Notice it SAYS there is a cactus on right hand side of F3 Menu
Picture 4: AFTER pressing F3+A

Also on step 4, you can do any form of a block update where the pot is, such as placing a block next to the pot.

This bug is not fixed, it still occurs in 1.8.1-pre6.
Please change to "Unresolved".

3 more comments

Btw, this also happens on multiplayer when someone else places a flower in a pot.

Confirmed for

  • 1.9-pre4

Confirmed for 1.9, 1.9.1, 1.9.2, and 16w15b.

Please link to this comment in the description

The following is based on decompiled version of Minecraft 1.9 using MCP 9.24 beta. All method and class names are the names used in the decompiled version.

The reason why this happens is very likely that changes to the NBT data do not cause a description packet of the tile entity being send. This makes sense because in some situations the NBT data has no effect on the client and only increases the packet size. For the brewing stand for example this seems to be solved by having the property net.minecraft.block.BlockBrewingStand.HAS_BOTTLE for the block state. Setting this causes a packet to be send to the client. For flower pots no property is used and no method is called to send the data to the player.

Flower pots are no longer block entities in 17w47a, so this is no longer an issue.

the1kingsam

(Unassigned)

Confirmed

/blockdata, flower_pot, nbt

Minecraft 1.8.1-pre4, Minecraft 1.8.1-pre5, Minecraft 15w51b, Minecraft 16w04a, Minecraft 1.9 Pre-Release 4, ..., Minecraft 17w06a, Minecraft 1.12.1, Minecraft 1.12.2, Minecraft 17w43a, Minecraft 17w43b

Minecraft 1.8.1, Minecraft 17w47a

Retrieved