I made a map that uses a lot of commandblocks and fillclocks. The map is now in Beta and there are several Beta testers that are testing this map. One problem I found, was that the map really laggy is on servers. I suggested them to use more ram, but even 3gb of ram and 2-3 players online would have a lot of lagg. Recently Qmagnet(https://www.youtube.com/user/theqmagnet) said in his Diversity DevCom(https://www.youtube.com/watch?v=FpkCp8gbAt4) (Arround 09:09) that running testfor commands with a fillclock will cause a lot of lagg on multiplayer servers. And I don't think that's intended. I think it has to do with the /testfor command being slow, and that it can't finish before having to run again. So I think this is the thing that causes lagg on my map. I really need this getting fixed, cause my map is almost inpossible to play now(with all the lagg)(on multiplayer)(while it is a multiplayer map D: ).
Steps to reproduce:
On multiplayer:
1. Make a fill clock:
Commands:
Top: fill ~ ~-1 ~ ~ ~-1 ~10 redstone_block,
1 air block in between,
Bottom: fill ~ ~1 ~ ~ ~1 ~10 clay
Now place a redstone block in the middle and the clock will start running. To stop the thing, power the top command block.
2. Add a lot of /testfor commands to it.
Thanks for your time,
-JustRamon
PS: This map was made (and is being made) on a Realm. On the Realm we didn't have any lagg. I don't know if this is because that server has a lot of ram, or that those servers are magical 😛
PS2: If you look at the screenshots you can see the commands, and the screenshots of the commandblocks. Almost all the commandblocks at the fillclock have testfor commands in them.
Attachments
Comments 7
I can confirm that this is a serious problem, and that it exists with /testforblocks as well. On both my realm and a server I rented from a different host I have TERRIBLE lag problems when I activate a fill clock with /testforblock and /testfor commands on it.
Do you have the command blocks set to track output? If so disable that it may help some. Also If you set limitations to the testfor commands such as
"/execute @p[score_test=0] ~ ~ ~ /testfor @p {Thing you are testing for}"
This way the command is not ALWAYS running and only runs when it is needed. All you would need to do is set the players score of test to 0 then the command will run the testfor or testforblocks at that point only causing less lag. If i could see the map i would be better able to help you.
I added some screenshots about the tracking output. The difference between the two is the X and O on the bottom right of the photo.
Is this still an issue in the current Minecraft Snapshot 15w45b or later? If so, please update the affected versions in order to best aid Mojang ensuring bugs are still valid in the latest releases/pre-releases.
Maybe relates to: MC-74599