Skip to content

Return of Reckoning

Wiki

RoR Wiki

API:LCDProgressBarGetProgress

From RoR Wiki

UI Lua API · LCD functions
Version: WAR 1.4.8

Returns the value of an LCD progress bar.

value = LCDProgressBarGetProgress(pageName, barName)

Arguments

pageName
string – Name of the page.
barName
string – Name of a progress bar created with LCDCreateProgressBar.

Returns

value
number – The bar's current value.

Details

  • If the page or element does not exist, or the element is not a progress bar, an error below is logged and nothing is returned.
  • The function needs at least two arguments and only reads the last two.
  • The stock UI never calls this function.

Errors

  • Error in function call 'LCDProgressBarGetProgress': Page '%s' does not exist.
  • Error in function call 'LCDProgressBarGetProgress': Page '%s' does not have a child named '%s'.
  • Error in function call 'LCDProgressBarGetProgress': '%s' on page '%s' is not a/an ProgressBar.

Example

A minimal example built from the signature:

local hp = LCDProgressBarGetProgress( "MyPage", "HP" )

See also