Eating an item gives the Player Oxygen

Started by Youtuber87 on

Topic category: Help with Minecraft modding (Java Edition)

Joined Dec 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Eating an item gives the Player Oxygen
Wed, 02/19/2025 - 05:51 (edited)

I wanna make something where if consumed underwater, They consumer gets Oxygen. Is there any way to do this?

Edited by Youtuber87 on Wed, 02/19/2025 - 05:51
Joined Feb 2025
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Simply go to triggers and…
Tue, 03/04/2025 - 21:52

Simply go to triggers and create a procedure for when the player finishes using the item. Search for the "Set Oxygen" block. Change the provided number to whatever you want. The higher the number the more oxygen gets restored. You can even make it temporarily increase the max oxygen by setting the number higher than the default max oxygen.