How can I try to show the potion duration using the "/title" command

Started by AidenR0 on Sun, 12/27/2020 - 12:53

Topic category: Help with modding (Java Edition)

Last seen on 11:52, 29. Sep 2021
Joined Apr 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
How can I try to show the potion duration using the "/title" command
Sun, 12/27/2020 - 12:53

Hello there!

So I'm currently working on a mod, one of the parts required to make the mod work is the potion effect being displayed on the screen using the /title command

I've seen the procedure "get potion duration.." but I've been messing with it to no luck

So I was hoping you guys would help out! Thanks in advance

 

Last seen on 08:59, 21. May 2022
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Try this:   Execute command …
Sun, 12/27/2020 - 15:19

Try this:

 

Execute command / title @p times 1 20 1

 ⚙ If  Has  Event/target entity  active potion  <Select your potion>

do Execute command / title @p title [{"text":"<Write your potion name>","color":"<Write your text color>"}]