Mojira Archive
MC-276333

The player input predicate does not detect player input when inside a UI

The new field input can detect "which movement keys the player is pressing", quoting the official release note. 

However it does not work with players looking at UI, like inventory. I do not know if this is intended. but it says "which keys is pressing" and it suggests that it should always work when the key is being pressed.

Steps To Reproduce:

  1. Run the following command in a repeating command block:
    execute as @a at @s if predicate { "condition": "entity_properties", "entity": "this", "predicate": { "type_specific": { "type": "player", "input": { "right": true } } }} run say detected!
    
  2. Open inventory
  3. Press d, or the key that moves you to the right.

Expected Result:

The input would be detected inside the GUI.

Observed Result:

Nothing is detected, no say command is output.

Works As Intended

Dahesor

2024-09-04, 06:43 PM

2024-09-06, 07:15 AM

2024-09-06, 07:15 AM

0

0

Confirmed

(Unassigned)

input, predicate

24w36a

-