1

/testfor help 5

TSchweibz's Avatar TSchweibz3/21/15 9:26 pm
1 emeralds 362 9
3/22/2015 11:18 am
TheArchitect_95's Avatar TheArchitect_95
Can you testfor if a mob is close to a player?

Also Can you test for when a mob is at a Certain health or Low health?

Any Ideas?
Posted by TSchweibz's Avatar
TSchweibz
Level 2 : Apprentice Miner
0

Create an account or sign in to comment.

9

1
03/22/2015 11:18 am
Level 32 : Artisan Architect
TheArchitect_95
TheArchitect_95's Avatar
Now you can use statistics in scoreboards, you can actually query an entity's health as an objective criterion, health is read only and cannot be modified this way but changes when the entity is damaged or healed. There is more about this on the Minecraft Wiki Scoreboard page.

eg.
testfor @e[r=200,score_health_min=1,score_health=10]
where health is the objective name.
1
03/22/2015 12:27 am
Level 42 : Master Architect
TextualJavakid
TextualJavakid's Avatar
I am using testfor commands for a map i'm currently making, but nothing this complicated. search around YouTube for more videos if you haven't already. Your other best bet is to check out the minecraft wiki, helped me out with a win detection system, maybe it might help you?
1
03/21/2015 10:43 pm
Level 7 : Apprentice Crafter
Server_Help32
Server_Help32's Avatar
ya that would probrobally work
1
03/21/2015 10:31 pm
Level 2 : Apprentice Miner
TSchweibz
TSchweibz's Avatar
No it's for a map I'm making but I guess I could just use a strip of command blocks which each testing for a health from 1-10
1
03/21/2015 10:23 pm
Level 7 : Apprentice Crafter
Server_Help32
Server_Help32's Avatar
Are you doing this for a server or what ? If it is for a server we could help out alot as we have a strong background in command blocks
1
03/21/2015 10:08 pm
Level 2 : Apprentice Miner
TSchweibz
TSchweibz's Avatar
got a command that works for the radius I had just messed up on the one in the video
/execute @e[type=Blaze,name=DLS_Android] ~ ~ ~ /execute @p[r=6] ~ ~ ~ /setblock ...

but can i compact the health testor for like a min/max health?
1
03/21/2015 9:59 pm
Level 2 : Apprentice Miner
TSchweibz
TSchweibz's Avatar
I found this command for testing for low health: /testfor @e[type=Blaze] {CustomName:"DLS_Android",Health:100s}

but is there anyway to make a health range?
1
03/21/2015 9:51 pm
Level 2 : Apprentice Miner
TSchweibz
TSchweibz's Avatar
No sorry the video must be not updated because the command he uses doesn't work, any ideas?
1
03/21/2015 9:34 pm
Level 42 : Master Architect
TextualJavakid
TextualJavakid's Avatar
This video could answer everything: https://www.youtube.com/watch?v=UnoLSSUAUMM (Might not work because some people in the comments are saying they have trouble with it)
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome