mojira.dev
MCPE-165158

Cannot duplicate negated game mode selector argument 'm=!'

The bug

The gamemode target selector argument can normally only be written once, as a player can only be in one game mode at a time; this behavior can also be seen when using two type= arguments, as an entity can only have one identifier. Trying to use two m=! arguments within a target selector fails however, even though this should be valid as a player can possibly be not one of the currently five game modes available.

Steps to reproduce:

  • Set your game mode to Creative mode.

  • Go in game and try running the following command. This should return "Test passed," as you are not in survival nor Adventure mode.

    /execute if entity @a[m=!survival,m=!adventure]

→❌ "Duplicate m selector arguments"

Attachments

Comments 1

Same problem. A work around is to do if entity twice for each negated mode.

Example: /execute if entity @a[m=!survival] if entity @a[m=!adventure]
or
/execute as @a[m=!survival] if entity @s[m=!adventure]

Sprunkles

(Unassigned)

946105

Confirmed

Windows

1.19.60.25 Preview, 1.19.60.23 Preview, 1.19.50, 1.19.51

Retrieved