How to disable a specific UI if Player is in a specific dimension

Started by Hygerian on

Topic category: Help with Minecraft modding (Java Edition)

Joined Feb 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to disable a specific UI if Player is in a specific dimension

Hello!
I am currently making a very interesting mod and I wanted to add a feature that I don't know how to add.
Basically if you are in a specific dimension like the Nether and you want to use F3 for the coordinates, it will not show the F3 menu but it will open a completely different "Overlay" and say something like: "Isn't possible here" 
So player can't abuse coordinated in my dimension, which makes things much more interesting!
I would really appreciate if someone would know the answer!
If someone knows how to I would also really appreciate if you could send pictures of the procedure and what you did so I can understand things better.
Thanks!