Select Page

Difficulty: MEDIUM (3/5)
Commands in the mechanic: MEDIUM (7)
External commands: NORMAL (3)

/scoreboard objectives add block dummy

Adds a score called "block": it can be changed only using commands

/summon Chicken ~ ~1 ~ {Silent:1b,CustomName:"block",Invisible:1b,Passengers:[{id:Zombie,IsBaby:1b,CustomName:"block",Silent:1b},{id:FallingSand,Time:1b,TileID:87,CustomName:"block"},{id:Shulker,NoAI:1b,Silent:1b,CustomName:"block"}]}

Summons a chicken with a zombie, a falling sand with custom id (basically every block/item has a numeric id, and you can know it by pressing f3+h [windows] or fn+f3+h [mac/linux]: to summon a different block just replace the "87" with the number of the block you want) and a shulker on it

/summon Chicken ~ ~1 ~ {Silent:1b,CustomName:"block",Invisible:1b,Passengers:[{id:Creeper,CustomName:"block",Silent:1b},{id:FallingSand,Time:1b,TileID:46,CustomName:"block"},{id:Shulker,NoAI:1b,Silent:1b,CustomName:"block"}]}

The same of the first, but with a creeper on the chicken

/effect @e[type=!Player,name=block] 14 1 1 true

Gives invisibility effect to all the entities that aren't players and are called "block"

/entitydata @e[type=FallingSand,name=block] {Time:1b}

Changes sand's despawn time, so it doesn't despawn

/scoreboard players set @e[type=!Chicken,name=block] block 1 {OnGround:1b}

Sets at 1 the score of all the entities that aren't chickens, only if they are on the ground and are called "block"

/kill @e[type=!Player,score_block_min=1]

Kills all the entyties that have the score at 1 and aren't players

/scoreboard players set @a block 0

Resets the score of all the players

/execute @a ~ ~ ~ execute @e[type=Chicken,name=block,r=5] ~ ~ ~ scoreboard players add @a[r=5] block 1

Sets at 1 the score of a player in the range of 5 blocks nearby a zombie

/execute @a[score_block=0] ~ ~ ~ kill @e[type=Shulker,name=block,r=5]

If a player has the score at 0 (the chicken have been killed), the shucker will be killed