What it does
hud.updateBar takes id, value and max. max is optional.
Signature
hud.updateBar(id, value, max?)Arguments
idvaluemaxoptional
Example · generated
function start() { hud.createBar('bar', { value: 1, max: 1, label: 'Hello' }); hud.updateBar('bar', 1);}hud.createBar is there to give the call something to act on; hud.updateBar is the line that matters. The code sits in start(), which the engine calls once, when the entity spawns.