OrigenNetwork
Docs

Exports · origen_hud

All exports are registered on the client side under the resource name origen_hud.

There are no server-side exports.


Client-side exports

showDeath(tiempo)void

Displays the death/bleedout timer on screen. Use this when Config.AutoDeath = false and you want to trigger the death screen manually from an external script (e.g. an ambulance or laststand resource).

lua
exports['origen_hud']:showDeath(tiempo)
ParameterTypeDescription
tiemponumberTime in seconds to display in the death countdown.

Only call this export when Config.AutoDeath = false. If AutoDeath is enabled, the HUD detects death automatically via game events and this export will conflict.


hideDeath()void

Hides the death timer and removes the death screen. Call this when the player is revived.

lua
exports['origen_hud']:hideDeath()

Example usage in an ambulance script:

lua
-- Show death screen when player enters laststand
exports['origen_hud']:showDeath(math.ceil(LaststandTime))
 
-- Hide death screen after revive
exports['origen_hud']:hideDeath()

showRespawn(msg)void

Displays a respawn message on screen.

lua
exports['origen_hud']:showRespawn(msg)
ParameterTypeDescription
msgstringMessage to display in the respawn screen.

setPlayerLoaded(bool)void

Manually sets the player login state inside the HUD. Used to force-show or force-hide the HUD without waiting for framework login events.

lua
exports['origen_hud']:setPlayerLoaded(bool)
ParameterTypeDescription
boolbooleantrue to mark player as loaded and show the HUD. false to hide it.

This export is only necessary in edge cases where the HUD does not detect the login state automatically. In most setups, Config.ForceLogin = true handles this internally.


ShowHud()void

Makes the HUD visible. Use this to restore the HUD after hiding it via HideHud().

lua
exports['origen_hud']:ShowHud()

HideHud()void

Completely hides the HUD from the screen. Useful for cutscenes, custom menus, or any situation where the HUD should not be visible.

lua
exports['origen_hud']:HideHud()

Example — hide HUD during a cutscene:

lua
exports['origen_hud']:HideHud()
-- ... cutscene logic ...
exports['origen_hud']:ShowHud()