I'm creating a command which is supposed to execute a message just once when a certain score is reached.

It worked once, but I made some changes to display a better word separation by adding some whitespace in the text sections within the tellraw section. It stopped working from there, even as I undid, switched world etc. These are the commands I am using at the moment. When I am changing the command to only execute when I am below or above a certain score (elytraFlight=5000.., elytraFlight=..5000) it works fine, but obviously keeps spamming.

/scoreboard objectives add elytraFlight minecraft.custom:minecraft.aviate_one_cm
/execute as @a[scores={elytraFlight=5000}] run tellraw @a [{"text":"[Abgehoben...]: "}, {"selector":"@p[scores={elytraFlight=5000}]"}, {"text":" flog 5 Meter!"}]

I don't want to reset the scoreboard - so that I am able to execute another command once a certain second score is reached.

  • Additional remark: When that scoreboard is at 5000, you have flown 50 meters, not 5. Apr 14, 2020 at 1:20

1 Answer 1


The selector @a[scores={elytraFlight=5000}] only matches players whose score is exactly 5000. Gliding happens much faster than the very slow speed of 1/100 block per tick, so, the overwhelming majority of the time, the score will jump from <5000 to >5000 without actually hitting 5000. Try @a[scores={elytraFlight=5000..}] instead.

  • He mentioned this solution in the question, I would suggest elytraFlight=5000..5100 instead. This way it consistently registers the match, but doesn't spam after the fact.
    – AMJ
    Apr 3, 2020 at 3:32
  • 1
    The correct solution would be an additional scoreboard objective tracking whether a print has happened, or maybe an advancement. Oh well, at least I explained why =5000 doesn't work.
    – pppery
    Apr 3, 2020 at 23:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .