2
Need some help command
So I was making a survival map, and I want to make ores will automatically respawn in 10 seconds at their position. I know how to do it block by block, but is there anyway i can do it like all in one series of command combination?
4
note it will change the /give @p minecraft:iron_ore will not work you will half to do /give @p minecraft:Iron
first command
/datafile ({ID;"Iron_ore";replace}name="Iron";replace)
second
/execute @e[type=Iron] if @e[type=Iron] replace ~ ~ ~ air run setblock ({getitem,getspawed,getlocation};name=Iron 1 1 1) summon armorstand ~ ~ ~ {ID;name="Iron";}
put second command in repeat
/datafile ({ID;"Iron_ore";replace}name="Iron";replace)
second
/execute @e[type=Iron] if @e[type=Iron] replace ~ ~ ~ air run setblock ({getitem,getspawed,getlocation};name=Iron 1 1 1) summon armorstand ~ ~ ~ {ID;name="Iron";}
put second command in repeat
If you want to make an ore re-spawn every 10 sec just make a redstone timer & type the command
/fill block ~ ~ ~ ~ ~ ~ minecraft:diamond_ore replace minecraft:air
or
/setblock ~ ~ ~ minecraft:diamond_ore
into a command block & here's a simple half quarter second timer that you can prolong by adding more redstone repeaters & changing their tick.

/fill block ~ ~ ~ ~ ~ ~ minecraft:diamond_ore replace minecraft:air
or
/setblock ~ ~ ~ minecraft:diamond_ore
into a command block & here's a simple half quarter second timer that you can prolong by adding more redstone repeaters & changing their tick.

I really dont think so.
Maybe while you look at an ore it spawns an armorstand or area effect cloud that will respawn that block in 10 seconds
Maybe while you look at an ore it spawns an armorstand or area effect cloud that will respawn that block in 10 seconds
