mojira.dev
MC-121377

First character typed in command blocks doesn't let you hit "done"

The bug

When in any command block, the first button press locks the "Done" button. When copying a command into the block if you haven't typed a character in it first (such as / ), this also locks the done button.

The second

[media]

was a pasted in command.

Code analysis

In 18w05a it looks like the reason is that bsq.keyPressed(int, int, int) disables the button before calling the parent method which likely writes the text in the text field.

However, the "Done" button should not be disabled at all because an empty command block has valid use cases if your command structure has to match a certain layout and you have to use empty chain command blocks to not break the chain.

Note: You can find this class by search for the string advMode.mode.redstoneTriggered and then opening the parent class of the found class.

Linked issues

MC-122015 Command Blocks' "Done" button behaves weirdly Resolved MC-121779 Commandblock "Done" button Resolved MC-121902 Ctrl key disables done button in empty command block and turns on done button in a full one Resolved MC-122087 Command block "Done" button does not update properly Resolved MC-122553 Using a command-block doesn't allow save Resolved

Attachments

Comments 5

Very weird behavior and reminiscent of MC-121302. I've observed the button being enabled with no text, then becoming disabled after pressing any key (e.g. numlock).

After 1.9, normal command blocks were never supposed to have the "Done" button disabled.

The bug still appears in 17w49b.

Confirmed for 18w19b.

Hi Bob

michael

Confirmed

button, command_block, gui, text-field

Minecraft 17w43a, Minecraft 17w43b, Minecraft 17w45a, Minecraft 17w45b, Minecraft 17w46a, ..., Minecraft 18w11a, Minecraft 18w16a, Minecraft 18w19b, Minecraft 18w20a, Minecraft 18w20b

Minecraft 18w20c

Retrieved