[MC-9185] the /list command in a command block does not output a signal the size of the number of players online Created: 04/Feb/13  Updated: 04/Feb/13  Resolved: 04/Feb/13

Status: Resolved
Project: Minecraft: Java Edition
Component/s: None
Affects Version/s: Snapshot 13w05b
Fix Version/s: None

Type: Bug
Reporter: Andrew Harwood Assignee: Unassigned
Resolution: Works As Intended Votes: 0
Labels: None
Environment:

any


Confirmation Status: Unconfirmed

 Description   

I was trying to figure a way out to test for the number of players on the server and compare it to a dummy number. I would subtract the two and if everyone's ruReady dummy objective was set to 2 then doors would open. I was using "scoreboard players list" to get the number of players. However, that list outputs the number of people on the scoreboard and the scoreboard doesn't update when someone leaves the game. So for instance if I had 4 players and we all were ready (had ruReady set to 1) then the doors would open, but if that person left before they were ready then the doors would never open even though all the players online are ready because that one last person had not hit the button to be ready. So I thought about using /list instead of /scoreboard players list. List gives only the players online. However list only outputs one block of signal no matter how many people are on.



 Comments   
Comment by Andrew Harwood [ 04/Feb/13 ]

oh thanks for that

testing...

testfor @a[c]
Comment by Kumasasa [ 04/Feb/13 ]

Tipp: If you want to write brackets, embed it with {code}

testfor @a[c]
Comment by Kumasasa [ 04/Feb/13 ]

Reseolved.

Comment by Andrew Harwood [ 04/Feb/13 ]

crap this system gets rid of brackets. it should be "testfor @a[[c]]"

Comment by Howzieky [ 04/Feb/13 ]

Hey what do you mean "testfor @ac"? I get everything BUT the 'c'

Comment by Andrew Harwood [ 04/Feb/13 ]

I can't resolve it and can't remove it. I will let a mod get rid of it.

Comment by Andrew Harwood [ 04/Feb/13 ]

Oh man you are right. I am so very sorry to waste time...i didn't see the "testfor @a[c]" command. Thanks for this. I will resolve this bug.

Comment by Kumasasa [ 04/Feb/13 ]

Is the comparator supposed to send a signal proportinoal with the number of players ?

http://www.minecraftwiki.net/wiki/Redstone_Comparator says

Comparators fed by command blocks will now indicate whether the last run command was run successfully

and

Comparators can be used to get an analog redstone signal indicating the amount of found players by using the new /testfor command.

Generated at Sun Jan 12 12:20:14 UTC 2025 using Jira 9.12.2#9120002-sha1:301bf498dd45d800842af0b84230f1bb58606c13.