Fire-Resistance type potion for custom fluid

Started by TheGreenFax on

Topic category: Help with Minecraft modding (Java Edition)

Joined Mar 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Fire-Resistance type potion for custom fluid

Hi. So, I made a custom fluid that damages the player and gives an effect when they step in it. I'm now trying to create a potion that prevents that from happening. I'm using a procedure, but I'm not sure how to do this and what blocks I should try and use. Any idea on how to do this?

Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
If the damage to the entity …
Sun, 08/16/2020 - 04:29

If the damage to the entity (player in this case) is in the "OnEntityCollides" trigger of the fluid you can do the following:

Before hurting the entity that is colliding with the fluid, you can check if the potion (effect) that you created is active in the entity and if it is, you can skip the part where you damage it.

 

Hope it helps!

Joined Mar 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
It worked! Thank you so much…
Sun, 08/16/2020 - 18:31

It worked! Thank you so much. :)