I've been trying some things with scoreboard lately and I always get to the point where I need to use the following commands.

/scoreboard players set @a Holding 0
/scoreboard players set @a Holding 1 {DataTag}
/execute @e[score_Holding_min=1] ~ ~ ~ /summon LightningBolt ~ ~ ~

People tell me to connect these to the same setblock clock but in order. I do that this way.

But nothing happens. The problem seems that the Holding score is set back to 0 too fast for the execute command to work. Does anyone know how to make this setup work?

  • Maybe set Holding to 0 after the /execute? Just an idea to reset after executing.
    – GiantTree
    Aug 23, 2015 at 15:02
  • Tried it, No result. It seems that, wherever the Holding 0 is placed in the setup, it always errors. Aug 23, 2015 at 15:06
  • 3
    I see you are using the 1.9 snapshot. Are you comfortable with using chain command blocks to get this working?
    – Judge2020
    Aug 23, 2015 at 15:09
  • No, and how are you seeing I'm using 1.9? Aug 23, 2015 at 15:14
  • I'm going out on a limb here and proclaim that the execute command is at a lower X or Z coordinate than the other two blocks, making your commands run backwards.
    – MrLemon
    Aug 23, 2015 at 15:43

2 Answers 2


Your command blocks are placed in the wrong order in the world.

When multiple command blocks are powered at the same time, they are executed in the direction of +X, +Y and +Z. It is very likely that your line of redstone "points" in the -X or -Z direction, thus making the game run the commands in reverse order:

/execute @e[score_Holding_min=1] ~ ~ ~ /summon LightningBolt ~ ~ ~
/scoreboard players set @a Holding 1 {DataTag}
/scoreboard players set @a Holding 0

This leaves every players Holding score at 0 at when the execute command is run, therefore it does not execute properly.

In 1.9+, chain command blocks should be used to easily prevent such issues.


I have already found a solution myself. This is the working setup:

Take note that the Holding 0 block is at the end and that no redstone is on top of it. This worked for me. After reading some comments, it seems that the location of the redstone blocks was the problem. The order in which the commands are executed goes from low to high, so from a low X to a higher X. The same goes for the Y and Z coordinates.

  • Personally i suggest a fill clock, not a setblock redstone clock. The fill clock is more reliable than this. youtube.com/watch?v=o2M5n1oIbmQ
    – Moddl
    Aug 23, 2015 at 19:01
  • 2
    Also check the direction the command blocks are, the commands are executed in the direction of +X, +Y, and +Z, they may be running in the inverse order.
    – Moddl
    Aug 23, 2015 at 19:03
  • Thanks for the tip. Here, the command blocks are in correct XYZ but in my original setup, they aren't. You might have saved my day. Aug 24, 2015 at 20:07
  • These little things that aren't that hard to solve but can ruin your day is one of the perks of minecraft. Got screwed over more than once by this particular one.
    – Moddl
    Aug 24, 2015 at 20:12

You must log in to answer this question.

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