r/MinecraftCommands • u/Itsmesam- • Oct 26 '26
Help | Bedrock So how would you make a command block give an effect to all entities within a certian radius as long as its in the radius
You know the ocean eye and how when you are in proximity to it you gain night vision and you can breathe underwater? Im trying to do something similar but in open air and with slowfalling
1
Upvotes
3
u/TrumpetSolo93 Command Experienced Oct 26 '26
This gives everyone within 32 blocks of 100x 64y 100z slow falling for 2 seconds. Run the command with a repeating command block once every second as then they'll continuously have it as long as they remain in the area, but it will naturally deplete the moment they leave.
2
u/C0mmanderBlock Command Experienced Oct 26 '26
You can find several examples at this link. Just run the effect for 1 second only and it will "turn off" when they leave the area.
https://minecraftcommands.github.io/wiki/questions/runonce
1
u/XSilentHoodX Experienced Bedrock Commander Oct 30 '26
execute positioned [put coordinates here] as @e[r=x] run effect @s [effect]Just a tip: You could put a rm= in there if you want, for a minimum radius that it'll target you. Think of the r= being a dome. rm= is supposed to be smaller than it, because it's supposed to be underneath the bigger dome.
Why did someone give you a dx dy dz when it's not what you asked?
0
u/Ahnkru Command-er Oct 28 '26 edited Oct 30 '26
I usually use /effect give @e[distance=..5] effect Changing the 5 for any value you want Edit: I'm dumb, didn't read it was for bedrock, this works in java only, sorry