ive recently been toying around with command blocks and I was wondering if theres a way to have something kind of like an if statement. for example, if there is a testforblock command and it successfully finds the block, then do the next command.
if its not successful in finding the block, then don't do the command.
if it helps I'm in 1.10
if its not successful in finding the block, then don't do the command.
if it helps I'm in 1.10
1
There are 2 ways to do this.
You can use a chain command block - then set it to conditional mode. This will make it run its command when the command block before it ran its command successfully.
The other (older) way is to use a comparator. Having a command block with a comparator coming out from it will make the comparator power on when the command block successfully runs a command.
You can use a chain command block - then set it to conditional mode. This will make it run its command when the command block before it ran its command successfully.
The other (older) way is to use a comparator. Having a command block with a comparator coming out from it will make the comparator power on when the command block successfully runs a command.
