Armor Health boost help!

Started by iYurY on Sat, 06/13/2020 - 01:23

Topic category: Help with modding (Java Edition)

Last seen on 22:55, 22. Jun 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Armor Health boost help!
Sat, 06/13/2020 - 01:23

Hi, sorry for bad english, im from south america

I want to recreate the Netherite armor, that includes the Health Boost, but i have problem, i dont know how to make that the effect apply one time.

im not expert at creating with Mcreator, but i know that using the global trigger "on player tick update" will make that the effect apply every tick, turning the health back to 10, making imposible to regenerate the "extra hearts" that the Health Boost give you

Pls help :/

Last seen on 13:57, 17. Apr 2021
Joined Jul 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
You can make a procedure…
Sat, 06/13/2020 - 02:41

You can make a procedure that instead of giving the effect every ticks its give you the effect every 2 secondes for exemple. The procedure should be like that i think:

if entity have status effect health_boost then

...

else

give entity status effects health_boost for 2 sec(write the equivalence in minecraft ticks)

--------------------------------------------------------------------------------------------

Sorry if im not clear, i hope you understand my answer

Last seen on 23:27, 4. Apr 2021
Joined May 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Create a timer using nbt tag…
Sun, 06/14/2020 - 02:38

Create a timer using nbt tag on the same player tick update procedure, make as so IF time > determined value DO add potion effect for determined value + and set time to 0.

Last seen on 22:55, 22. Jun 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Sorry i still dont…
Sun, 06/14/2020 - 20:15

Sorry i still dont understand, i guess a Photo can help me :D

Last seen on 05:05, 21. Jun 2021
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Global variable(Not for…
Mon, 06/29/2020 - 04:54

Global variable(Not for multiplayer):TicksLeft

default=0 type=number

when armor tick(head,chestplate,boots or leggings):

if TicksLeft = 0:

    then  TicksLeft=SomeValue

give player effect(health boost for time SomeValue+1)

PS:+1 is used to prevent the player lose effect and health=10 and then give it will keep heart in 10 so...

when armor is off:

check player armor slot

if none of them was the type of armor:

    then  TicksLeft=0

    remove the effect(using procedure execute_command_as_entity(/effect clear @s id_got_by_autocomplete_in_minecraft) or just clear_effect)