1

Detecting Players

Dudamesh •5/22/15 3:55 am
•
230
•
5/24/2015 10:35 am
How can I detect Players that have a certain score...

Example:

There are 3 Scores,
A, B, and C.

In A and B, there are only 1 player that has A and another one for B.
Once there are 1 player on A and B, other players will get their score to C.

How can I detect how many Players that has C?
Posted by
Dudamesh
Level 62 : High Grandmaster Senpai
74

  Have something to say?

Join • Sign in

5

Pepijn
• 05/24/2015 8:23 am
• Level 58 : Grandmaster Cyborg
To count how many players have a certain score you can either use the /stats command (which is in this case the hardest option) or do this:

- Create a dummy objective: /scoreboard objectives add Count dummy
- Run this command (once) when you want to count how many players have a score of C: /execute @a[score_C_min=1] ~ ~ ~ /scoreboard players add Counter Count 1 (this basicly adds 1 score to a fake player for every person who has a score for C greater or equal to 1, and thus acts as a counter)
- You can test for this score with: /scoreboard players test Counter Count <minimumscore> <maximumscore> (without the "< >")
1
Dudamesh
• 05/24/2015 10:35 am
• Level 62 : High Grandmaster Senpai
I salute you sir!
1
YTCereal
• 05/22/2015 8:26 am
• Level 22 : Expert Network
answer is there.
1
kungfue
• 05/22/2015 8:21 am
• Level 47 : Master Turtle
This is possible!
I Believe using the /stats command
However i haven't had a chance to use this yet so sorry that's all i can say
Or i guess you could do this:
So every player (except those who have a score for A/B have a score of C)
so /scoreboard players set @r[score_C_min=1] C 0
then have a comperator that comes out of that leading to a command block with this in it:
/scoreboard players test @a C 1 2
With a comperator coming out of that leading to your output

Then just count the number of pulsed you need to send it until it outputs!

Another idea is make everyone join a team then have anyone who has a score of A or B leave the team! Then use a scoreboard operation to get the number of players playing -2

IDK
drop me a pm if ytou need any help
Hope i helped
-Kungfue
1
Dudamesh
• 05/22/2015 8:01 am
• Level 62 : High Grandmaster Senpai
DudameshHow can I detect Players that have a certain score...

Example:

There are 3 Scores,
A, B, and C.

In A and B, there are only 1 player that has A and another one for B.
Once there are 1 player on A and B, other players will get their score to C.

How can I detect how many Players that has C?



bumppppp
1

Welcome