1
I need help with command block. I want to build drawbridge
So, I builded a drawbridge for my new walkthrough map. It's working on button and two command blocks. 1st command block (next CB) are deleting vertical blocks of bridge, 2nd CB are filling horizontal floor of bridge, so, it looks like bridge drops, BUT I want to do next: near of button I set a chest. So, you must find 2 details and put it to the chest (if you willn't do It - button willn't droped bridge). I don't know how to do it. Any ideas?
Create an account or sign in to comment.
9
1
The following should detect a chest that has 1 stone in the first slot, and 1 dirt in the second slot.
After that, put down a conditional chain command block and insert whatever command you want to use...
~SUPERIONtheKnight
/testforblock <x> <y> <z> minecraft:chest -1 {Items:[{Slot:0b,id:"minecraft:stone",Count:1b,Damage:0s},{Slot:1b,id:"minecraft:dirt",Count:1b,Damage:0s}]}
After that, put down a conditional chain command block and insert whatever command you want to use...
~SUPERIONtheKnight
2
Hey, thank you! It's really work! I didn't know that the CB need one direction, so my CBs was different directions and I thinked about your command, what I did not right, but I did all right, it's just CB's problems :)
Thanks!
Thanks!
2
Maybe you could replace the chest with a redstone block which will power the bridge once certain items are in it.
example:
example:
/fill ~0 ~1 ~0 ~0 ~1 ~0 minecraft:chest 0 replace minecraft:redstone_block 0 {Items:[{Slot:0b,id:"minecraft:stone",Damage:3,Count:1b},{Slot:1b,id:"minecraft:stone",Damage:1,Count:1b}]}
this will replace the chest with a redstone block once there is diorite in the first slot and granite in the second. There are probably easier ways, but this is the only thing i could think of really quick.1
[00:25:19] Data tag parsing failed: Expected '{' but got 'm' at: m<--[HERE]
What is this? I tried write your command by myself with mcstacker, but I had this error over and over. Or this, or something another about minecraft:chest - not right, but I tried "minecraft:chest", "minecraft:trapped_chest", 154, 054, 54 - error! What I'm doing not right?
What is this? I tried write your command by myself with mcstacker, but I had this error over and over. Or this, or something another about minecraft:chest - not right, but I tried "minecraft:chest", "minecraft:trapped_chest", 154, 054, 54 - error! What I'm doing not right?
1
Are you doing this in 1.12.2?
1
Yep. It's 1.12.2
2
Hmm... instead of using a chest try using hoppers. I know there's a way that if you put a specific item into a hopper it'll send out a red stone signal so look up something like that.
1
Player may put in hopper something another instead of that what I need. Or not?
1
Sorry I honestly don't know. There's a way to avoid it look up things like hopper cash registers. It'll use the same principle. Or, making a hopper key card. There's a way to do it I just don't know it. Hope this helped!