How can I target a player with a specific score? For example: Set the score of Score to 100 for every player with 1 Point in the scoreboard objective ScoreB. I tried

/scoreboard players add @a[score_Score_min=1] Score 1

and it actually worked. But then i set the score for a "player" named "Test" to 1 and it didn't get points. What did I do wrong?

  • If "Test" is a fake player, he can not be targeted by target selectors, since those only resolve entities. – MrLemon Mar 4 '16 at 13:57
  • So what i used was actually right? – Rayset Mar 4 '16 at 14:04

It sounds like "Test" is not a real player.

The problem in this case is that target selectors like @a[...] can only resolve / find entities that exist somewhere in the world and are loaded.

This means that while you can change the scores of fake or offline players (scoreboard scores are stored in scoreboard.dat rather than playerdata) by specifying their name directly, i.e.

/scoreboard players set Rayset Score 29

You can not use target selectors unless there is an entity to resolve.

If an entity exists, your command is correct. @a[score_Score_min=1] resolves all player entities with a Score score of at least 1.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.