1

Giving score to entities in certain radius of players

Veritas025's Avatar Veritas0257/16/15 1:09 pm
1 emeralds 235 2
7/16/2015 6:25 pm
SquidMannn's Avatar SquidMannn
So my idea was when you are wearing a chestplate flame particles spawn around them /execute @a[score_ARMOR_min=1] ~ ~ ~ /particle flame ~ ~-1 ~ .01 5 5 5 50 then if the score of "ARMOR" is 1 it detects all entities in a radius of 5 from the player /execute @a[score_ARMOR_min=1] ~ ~ ~ /testfor @e[type=!Player,r=5] it doesn't update though even though I'm standing right next to a cow it won't give me an output and the fill clock is on. What I wanted to know can I give a score to those entities, so I can /execute @e[score_BurnMobs_min=1] ~ ~ ~ /setblock fire ~ ~-1 ~ 0 replace air
Posted by Veritas025's Avatar
Veritas025
Level 55 : Grandmaster Engineer
37

Create an account or sign in to comment.

2

1
07/16/2015 6:25 pm
Level 19 : Journeyman Robot
SquidMannn
SquidMannn's Avatar
Well to give someone a score in a certain radius of a player you will do /execute @p ~ ~ ~ scoreboard players set @e[r=INSTERTRADIUSHERE] OBJECTIVE VALUE
1
07/16/2015 3:33 pm
Level 33 : Artisan Engineer
Jmal116
Jmal116's Avatar
I created a similar setup to what you have here, but I was only using a /say command instead of the testfor. It seemed to work fine, which leads to me to believe it's just an issue with using the comparator, and giving the mobs a scoreboard value when they get close to you should work. You'd also be able to nest another execute command directly after the first one, which would eliminate the need for the scoreboard. I'm thinking something like this:execute @a[score_ARMOR_min=1] ~ ~ ~ execute @e[type=!Player,r=5] ~ ~ ~ setblock ~ ~-1 ~ fire
Only thing to keep in mind is that setblock's replace doesn't work the same as fill's replace, and if you only want to replace air then you'll have to use fill instead.
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome