Healed when attacked

Started by Trehmor on Sat, 08/15/2020 - 23:02

Topic category: Help with modding (Java Edition)

Last seen on 20:54, 5. Jul 2021
Joined Feb 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Healed when attacked
Sat, 08/15/2020 - 23:02

Im making a potion that when someone attacks you during night, there is a chance that it heals you by 1 but i dont know how to do this. help me please 

Last seen on 21:17, 16. Sep 2021
Joined Jun 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Just make a procedure Global…
Sun, 08/16/2020 - 09:36

Just make a procedure
Global trigger : Entity attacked
Procedure : If (is day in world = false) AND (has event/target entity potion effect CUSTOM:YOUR_POTION) AND (Random[0,1) < 0,5) Do : Heal event/target entity by 1

You just need to find the correct procedure blocks.

Last seen on 20:54, 5. Jul 2021
Joined Feb 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
i cant find the heal…
Sun, 08/16/2020 - 14:08

i cant find the heal procedure block

Last seen on 21:17, 16. Sep 2021
Joined Jun 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Just do that :
Mon, 08/17/2020 - 11:06

Just do that :

procedure

Last seen on 21:17, 16. Sep 2021
Joined Jun 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
My plugin ExtraProcedures…
Mon, 08/17/2020 - 11:19

My plugin ExtraProcedures contains a "Heal entity" procedure block that is easier to use that what I showed you. You can download last update here : https://github.com/Max094Reikeb/ExtraProceduresPlugin/releases

Last seen on 20:54, 5. Jul 2021
Joined Feb 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Thank you so much, your…
Mon, 08/17/2020 - 20:20

Thank you so much, your plugin is great, but what happens if i update mcreator when the new release is out ? 

Last seen on 21:17, 16. Sep 2021
Joined Jun 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
In general, code doesn't…
Mon, 08/17/2020 - 21:47

In general, code doesn't change. For the 2020.4 update, only one block's code changed, and as you see, I made a patch a few days after the release so don't worry ;)

Last seen on 20:54, 5. Jul 2021
Joined Feb 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Thank you so much, you…
Tue, 08/18/2020 - 02:18

Thank you so much, you really helped me :D