I'm making a spellbook in Minecraft, and I want to make a spell that affects everyone in a certain radius except me, so I just made this:
/effect @a[r=10,type=!@p] 15 60
It doesn't seem to work. What is wrong with it?
Try rm
, e.g. /effect @a[r=10,rm=1] 15 60
. Then it will only work on players at least one block away from you, so not you.
You can use /effect @a[r=10,name=!YourPlayerName] 15 60
If you want to use it with different playernames, you can do this:
/scoreboard objectives add someName dummy
)/scoreboard players set @a someName 1
)/scoreboard players set @p someName 0
)/effect @a[r=10,score_someName_min=1] 15 60
@a
not@A