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).
exports['origen_hud']:showDeath(tiempo)| Parameter | Type | Description |
|---|---|---|
tiempo | number | Time 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.
exports['origen_hud']:hideDeath()Example usage in an ambulance script:
-- 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.
exports['origen_hud']:showRespawn(msg)| Parameter | Type | Description |
|---|---|---|
msg | string | Message 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.
exports['origen_hud']:setPlayerLoaded(bool)| Parameter | Type | Description |
|---|---|---|
bool | boolean | true 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().
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.
exports['origen_hud']:HideHud()Example — hide HUD during a cutscene:
exports['origen_hud']:HideHud()
-- ... cutscene logic ...
exports['origen_hud']:ShowHud()