Skip to content

OryUIProgressIndicator

Kevin Cross edited this page Sep 11, 2019 · 9 revisions

Available Functions

OryUIAnimateProgressIndicator(progressID)

Required for indeterminate progress indicators. It will animate the progress bar by growing and shrinking it, as well as moving it at different speeds.

OryUICreateProgressIndicator(parameters$)

Creates a progress indicator and returns a progress indicator ID. See Available Parameters section below for the options.

OryUIDeleteProgressIndicator(progressID)

Deletes a progress indicator.

OryUIGetProgressIndicatorHeight(progressID)

Returns the height of the progress indicator.

OryUIGetProgressIndicatorPercentage(progressID)

Returns the current percentage of the progress indicator.

OryUIGetProgressIndicatorWidth(progressID)

Returns the width of the progress indicator.

OryUIGetProgressIndicatorX(progressID)

Returns the x position of the progress indicator.

OryUIGetProgressIndicatorY(progressID)

Returns the y position of the progress indicator.

OryUISetProgressIndicatorPercentage(progressID, percentage#)

Sets the percentage of the progress indicator, from 0 to 100. Decimals accepted.

OryUIUpdateProgressIndicator(progressID, parameters$)

Updates a progress indicator. See Available Parameters section below for the options.

Available Parameters (all optional)

Parameter Description
color The colour of the progress indicator. Accepts RGB values, and RGBA values (comma delimited) Also accepts MakeColor() value/id, and hex color codes.
depth The depth of the progress indicator.
fixToScreen Fixes the progress indicator to screen.
height The height of the progress indicator. Accepts decimals.
offset The x and y position where the offset should be placed, comma delimited. Also accepts a single value 'center'. Accepts decimals.
position The x and y position where the progress indicator should be placed, comma delimited.
progressType Either "Determinate" or "Indeterminate". Determinate (default) is used to show the status of a process. Indeterminate is used when you don't know how long the process will take (requires OryUIAnimateProgressIndicator)
size The width and height of the progress indicator, comma delimited. Also accepts -1 in either one to create a square button. Accepts decimals.
width The width of the progress indicator. Accepts decimals.
x The x position where the progress indicator should be placed.
y The y position where the progress indicator should be placed.

Example Code

Example

progressBar1 = OryUICreateProgressIndicator("color:255,0,0;size:50,2;offset:center;position:50,40")
progressBar2 = OryUICreateProgressIndicator("progressType:indeterminate;color:0,0,255;size:50,1;offset:center;position:50,60")
progress# = 0

do
    progress# = progress# + 0.5
    if (progress# > 100) then progress# = 0
    OryUISetProgressIndicatorPercentage(progressBar1, progress#)
    OryUIAnimateProgressIndicator(progressBar2)
    Sync()
loop

Clone this wiki locally