Make Potion Effect Immune to Milk

Started by Skittlq on

Topic category: Help with Minecraft modding (Java Edition)

Joined May 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Make Potion Effect Immune to Milk

Pretty self-explanatory, I just need a way for a potion effect to not be cured when the player drinks Milk. Any ideas?

Joined Apr 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
put an nbt tag on the entity…
Mon, 10/10/2022 - 08:24

put an nbt tag on the entity called "time left of effect" or something and decrease it each tick

and on when effect expires event (in potion effect's triggers) check if time left is more than 0, reapply the effect

Joined Mar 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Just do a procedure that…
Mon, 10/24/2022 - 14:46

Just do a procedure that gets the time left for the potion, and when players finishes drinking milk, give the effect again with the time left.