also your arrows have to be pointing at the next command block in the chain. So I would move your top command block so it's in front of the impulse command blocks arrow. Then I would put a button on the impulse command block. After you throw in the item. Press the button
I would even just activate each command separately by my chat, in order, just to see if it works
also your arrows have to be pointing at the next command block in the chain. So I would move your top command block so it's in front of the impulse command blocks arrow. Then I would put a button on the impulse command block. After you throw in the item. Press the button
I would even just activate each command separately by my chat, in order, just to see if it works
Oh!!
Now whan I press the button, I see clearly the signals going in the repeater.
But my lapis block desn't change.
I guess that I only have to place a setblock command in the second Command block?
But what about the button? I don't want the player to press abutton.
Should I now add a similar comparator clock linked to the first command block?
What do you think?
** I didn't see this part of your reply while I was answering:
I would even just activate each command separately by my chat, in order, just to see if it works
also your arrows have to be pointing at the next command block in the chain. So I would move your top command block so it's in front of the impulse command blocks arrow. Then I would put a button on the impulse command block. After you throw in the item. Press the button
I would even just activate each command separately by my chat, in order, just to see if it works
Even if my sword is on the ground, it says "No Entity Found" when I execute both commands in the chat.
You need to put your command blocks like in the first picture you showed me.
Lets just get the thing working first and then you can worry about automatically detecting. You'll just change your first command to a repeating command block but don't do that yet. Just set up your command blocks up like in the first picture, put a button on it, and just get it working.
I think I got it! You guys now have "distance" and not "r"
/tag @e[name=Blade,type=item,x=11,y=71,z=110,distance=..4] add Blade
/execute as @e[tag=Blade,x=11,y=71,z=110,distance=..4] at @s run setblock 9 74 111 redstone_block
When I execute this command in the chat menu:
/tag @e[name=Blade,type=item,x=11,y=71,z=110,r=4] add Blade /execute as @e[tag=Blade,x=11,y=71,z=110,r=4] at @s run setblock 9 74 111 redstone_block
(i put it all in one line)
In Java Edition, the radius target selector seems to be changed with a distance argument;
ref.: https://minecraft.gamepedia.com/Commands#Target_selector_arguments
So, I will write "distance=4" instead of "r=4"
Let me verify...
try the:
/tag @e[name=Blade,type=item,x=11,y=71,z=110,distance=..4] add Blade
/execute as @e[tag=Blade,x=11,y=71,z=110,distance=..4] at @s run setblock 9 74 111 redstone_block
I hope it works
Ok, so here what the console has to say when I'm executing this new command you gave me:
You're not running that all at once are you? It should be two separate commands.
Oh! two separate commands!! ok, let me retry.
Is the first a impulse-needs redstone and the second attached to it is repeater-always active??
First one impulse
Second one on top just do a chain command block set to always active
1. /tag @e[name=Blade,type=item,x=11,y=71,z=110,distance=..4] add Blade (in a impulse/need redstone) - done
2. /execute as @e[tag=Blade,x=11,y=71,z=110,[/b]distance=..4] at @s run setblock 9 74 111 redstone_block (in a chain/always active) - done
I put the second command on top of the first.
I throw the sword and it goes out and nothing happened after.
** In the first command block, "Blade" is in yellow letters.
In the second, "redstone_block" is in yellow letters.
Does this mean that those elements are not there yet?
can you turn on your command block output and tell me what that says?
You are activating the command blocks after the sword comes out of the dropper correct?
This is what it looks like now:
The sword is ejected on the diamond block.
You can see the sword is ejected on the diamond block.
I attached a repeater and a redstone dust on the first command block and there's no signal!
K now put a button towards that impulse CB.
also your arrows have to be pointing at the next command block in the chain. So I would move your top command block so it's in front of the impulse command blocks arrow. Then I would put a button on the impulse command block. After you throw in the item. Press the button
I would even just activate each command separately by my chat, in order, just to see if it works
Oh!!
Now whan I press the button, I see clearly the signals going in the repeater.
But my lapis block desn't change.
I guess that I only have to place a setblock command in the second Command block?
But what about the button? I don't want the player to press abutton.
Should I now add a similar comparator clock linked to the first command block?
What do you think?
** I didn't see this part of your reply while I was answering:
I would even just activate each command separately by my chat, in order, just to see if it works
Even if my sword is on the ground, it says "No Entity Found" when I execute both commands in the chat.
You need to put your command blocks like in the first picture you showed me.
Lets just get the thing working first and then you can worry about automatically detecting. You'll just change your first command to a repeating command block but don't do that yet. Just set up your command blocks up like in the first picture, put a button on it, and just get it working.
try
/execute as @e[name=Blade,x=11,y=71,z=110,distance=..4] at @s run setblock 9 74 111 redstone_block
Your item is named Blade correct?
im curious, try throwing the blade from your inventory instead of the dropper and running those commands. Make sure it drops on your coordinate
Ok, I'll do, but can you just remind me of the kind of command blocks I need and how to place them.. I messed a bit and I'm quite lost now.
1. impulse/need redstone.. is this one conditional or unconditional?
2. repeater/always active... unconditional?
And the fist picture I've showed you... is this the repeater one on top of the impulse one?
And yes, "Blade" is the name of the sword in question.
impulse, needs redstone, unconditional
chain, always active, unconditional
I just did this in Bedrock in 2 seconds
Just try throwing Blade out of your inventory on the x,y,z coordinate you recorded and running
/execute as @e[name=Blade,x=11,y=71,z=110,distance=..4] at @s run setblock 9 74 111 redstone_block
Verify this thing even can work before worrying about command blocks
Ok, I throw the sword on the lapis block in front of the dropper.
Then, I execute the command in the chat.
Nothing happens
11 71 110 are the coordinates of the lapis block in question.
And the other coordinates is good.
does the chat give you an error?
lets see if your selectors are ruining it. Try Running;
/execute as @e[name=Blade] at @s run setblock 9 74 111 redstone_block
no, nothing
Try running
/execute at @e[name=Blade] run setblock 9 74 111 redstone_block
if that doesn't work try
/execute as @e[name=Blade] at @s run setblock 9 74 111 redstone_block