-
Notifications
You must be signed in to change notification settings - Fork 10
HUD scenes
HUD scene is a cosmetic mechanic that allows displaying morphs on top of HUD elements. You can use this mechanic for multiple of things:
- Displaying additional information needed by your map (mana/energy bar, blood splatters, score, indicators, etc.).
- HUD cinematic scenes (hologram instructing you what to do, Black&White-esque scenes, additional HUD details in addition to in-game cutscene, etc.).
- Crossfading between a cinematic scene and game play using image morphs, etc.
Once you pick or create a crafting table, you'd see an editor like this:
There will be an empty editor. First thing you need to do is to add a HUD morph. You can do that by pressing three bar icon in the top left corner. After that, an overlay will popup where you can right click the main area to add a new HUD morph. You can add there as many morphs as you'd like, and you can drag them around to change the order in which they will be edited.
Once you pick an HUD morph, you'd be able to edit its properties.
Here is an overview of all fields presented in the screenshot above:
Pick and Edit buttons allow you to pick and edit any morph added by my mods. The only exception for that is, you can't use particle
and snowstorm
morphs. These will technically work but will do nothing. They work only in the world.
Orthographic toggle allows to enable orthographic projection for morph rendering. This means that morphs will have no projection distortion as opposed to default projection, which is perspective. Without going too much into technicalities, here is an example of how it looks.
These two HUD morphs are placed almost identical, but the difference is orthographic toggle is enabled for the left sheep. As you can see, it's rendered flat as opposed to the right sheep, whose sides are getting warped the closer they're to the screen's edge.
Orthographic toggle is useful, when you want to present information like text (using label
morph), as the morph won't get distorted by the perspective.
The two fields under orthographic are X and Y anchor points. These allow to align the HUD morph across the edges of the screen without having an information about screen's size. These values between 0
and 1
, where:
-
0
in the first field is aligned to the left edge -
1
in the first field is aligned to the right edge -
0
in the second field is aligned to the bottom edge -
1
in the second field is aligned to the top edge
And if you want to align the orthographic HUD morph in the center, just input 0.5
in both field.
Expiration field allows you to set for how many ticks (20
ticks = a second) will this HUD morph will be present. 0
means it will never disappear from the scene. You can use expiration for temporary HUD scene effects, like jump scares or crossfade.
Field of View field allows you to setup the FOV of all non-orthographic HUD morphs. The values supported between 0
and 180
. The lesser the value, the more it resembles orthographic projection, as in less perspective distortion, and morphs will appear bigger. The greater the value, the more there is distortion, and morphs will appear smaller.
Basically, it's like the FOV option in Options > Video Settings
that allows you to change the field of view.
As the name states, it allows to enable an ability to hide this entire scene when player hides the GUI using F1 key. By default, HUD scenes will be visible also when player hides the GUI using F1.
At the moment, the only way to use HUD scenes is by using /mp hud
subcommands. To show an HUD scene named jumpscare
, you need to execute:
/mp hud setup @a jumpscare
If your HUD scene is never expiring one, you'll need to either relog, or execute:
/mp hud close @a jumpscare
HUD scenes are not persisted, meaning that they are only active when you sent them to the player until they log off, so it's purely cosmetic. If you want to make some information to appear all the time, you'll need to setup the scene every time player joins the server, which can be done using On player log in trigger.
This limitation is a subject to change. The feature at the moment is still in testing. The feedback is welcomed.
If parts of the wiki don't make sense with Mappet's latest version, or you weren't able to recreate examples (i.e. outdated information), feel free to report the page and section that is out of date on community's Discord server (make sure to mention which Mappet’s version did you use).