I am trying to execute a command to see if there are no slimes within a distance of 70 blocks with the tag, "arenaslime" (as shown in picture) so that the command block can run the next command.
/execute unless entity @e[tag=arenaslime,type=slime,distance=..70] run tellraw @a "there are no slimes"
To me, this is saying to not execute the "run" command unless there are slimes with the tag of "arenaslime" and are within a distance of less than and equal to 70 blocks. Please correct me if I am wrong or missing something.
I am trying to execute a command to see if there are no slimes within a distance of 70 blocks with the tag, "arenaslime" (as shown in picture) so that the command block can run the next command.
/execute unless entity @e[tag=arenaslime,type=slime,distance=..70] run tellraw @a "there are no slimes"
To me, this is saying to not execute the "run" command unless there are slimes with the tag of "arenaslime" and are within a distance of less than and equal to 70 blocks. Please correct me if I am wrong or missing something.
Thank you for your time!
The command looks good to me.
If it's not working, either you didn't run the command, or the slimes weren't tagged.
Yes the command looks fine but I dont get why you need to specify
type=slime
in
@e[tag=arenaslime,type=slime,distance=..70]
if only the slimes get the tag of arenaslime. Also not bad to use ArenaSlime as tag since its easier to read.
Anyway as YMbrothers sais the slimes might not have the tag
/tag @e[type=slime,distance=..70] add ArenaSlime
I once heard the specify the type of mobs can make the command run a tiny bit faster? Not too sure how people tested that, but I feel like, might as well?
The Meaning of Life, the Universe, and Everything.
Location:
Gent
Join Date:
10/25/2017
Posts:
67
Location:
Belgium
Minecraft:
Khoeckman
Discord:
bledder#4820
Member Details
Its always important to write commands as short as possible and yes It improves the run time a bit faster, on a large scale it may defenitely reduce your world respond time.
For example I never the CustomName:'{"text";"Position"}' anymore since its way shorter to use Tags:['Position']
also in the way of getting data
execute as @e[name=Position]
execute as @e[tag=Position]
I am trying to execute a command to see if there are no slimes within a distance of 70 blocks with the tag, "arenaslime" (as shown in picture) so that the command block can run the next command.
To me, this is saying to not execute the "run" command unless there are slimes with the tag of "arenaslime" and are within a distance of less than and equal to 70 blocks. Please correct me if I am wrong or missing something.
Thank you for your time!
The command looks good to me.
If it's not working, either you didn't run the command, or the slimes weren't tagged.
Yes the command looks fine but I dont get why you need to specify
in
if only the slimes get the tag of arenaslime. Also not bad to use ArenaSlime as tag since its easier to read.
Anyway as YMbrothers sais the slimes might not have the tag
I once heard the specify the type of mobs can make the command run a tiny bit faster? Not too sure how people tested that, but I feel like, might as well?
Its always important to write commands as short as possible and yes It improves the run time a bit faster, on a large scale it may defenitely reduce your world respond time.
For example I never the CustomName:'{"text";"Position"}' anymore since its way shorter to use Tags:['Position']
also in the way of getting data