Advanced Command that affects multiple people

Started by MrBelles on Mon, 12/14/2020 - 22:07

Topic category: Help with modding (Java Edition)

Last seen on 17:08, 30. Apr 2022
Joined Dec 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Advanced Command that affects multiple people
Mon, 12/14/2020 - 22:07

I recently made my mod have a /heal command that reset's your health to max. I wanted to know how I could use this command to heal my friends doing something like /heal @e or /heal (Playername). How would I do this? And how would I do something even more advanced like /heal @e[type=iron_golem]?

Use for each player in world…
Tue, 12/15/2020 - 09:42

Use for each player in world procedure block as a starting point

Last seen on 17:08, 30. Apr 2022
Joined Dec 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
So I have to make a seperate…
Thu, 12/17/2020 - 03:05

So I have to make a seperate command for /heal @e, /heal @p etc?

Last seen on 18:39, 18. May 2022
Joined Apr 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
No, you can do this with…
Wed, 01/20/2021 - 23:00

No, you can do this with only procedures

If you want to heal people around you,

"For each entity as Entity iterator at x y z in square cube with size [Put the radius in which players will be affected]" do "Set health of Entity iterator to Max Health of Entity iterator"

 

If you want to heal all players, do,

"For each player in the current world as Entity iterator" do "Set health of Entity iterator to Max Health of Entity iterator"