Google.Play.Common.LoadingScreen.LoadingBar

A loading bar that can be used to display download progress to the user.

Summary

Inheritance

Inherits from: MonoBehaviour

Public attributes

AssetBundleDownloadToInstallRatio = 0.8f
float
Proportion of the loading bar allocated to AssetBundle download progress.
Background
RectTransform
The loading bar background.
InnerBorderWidth = 6f
float
The inner border width.
Outline
RectTransform
The loading bar outline.
OutlineWidth = 6f
float
The outline width.
Progress = 0.25f
float
AssetBundle download and install progress.
ProgressFill
RectTransform
The loading bar progress fill.
ProgressHolder
RectTransform
The loading bar progress holder.
ResizeAutomatically = true
bool
If true, the Outline and Background RectTransforms will update to match the outline and border width.

Public functions

ApplyBorderWidth()
void
Applies the border width to the loading bar.
FillUntilDone(AsyncOperation operation, float startingFillProportion, float endingFillProportion, bool skipFinalUpdate)
IEnumerator
Updates a loading bar by the progress made by an asynchronous operation.
SetProgress(float proportionOfLoadingBar)
void
Sets the loading bar progress to the specified value in the range [0,1].

Public attributes

AssetBundleDownloadToInstallRatio

float AssetBundleDownloadToInstallRatio = 0.8f

Proportion of the loading bar allocated to AssetBundle download progress.

The remainder of the loading bar is allocated to install progress.

Background

RectTransform Background

The loading bar background.

InnerBorderWidth

float InnerBorderWidth = 6f

The inner border width.

Outline

RectTransform Outline

The loading bar outline.

OutlineWidth

float OutlineWidth = 6f

The outline width.

Progress

float Progress = 0.25f

AssetBundle download and install progress.

The value set in the Editor is ignored at runtime.

ProgressFill

RectTransform ProgressFill

The loading bar progress fill.

ProgressHolder

RectTransform ProgressHolder

The loading bar progress holder.

ResizeAutomatically

bool ResizeAutomatically = true

If true, the Outline and Background RectTransforms will update to match the outline and border width.

Public functions

ApplyBorderWidth

void ApplyBorderWidth()

Applies the border width to the loading bar.

FillUntilDone

IEnumerator FillUntilDone(
  AsyncOperation operation,
  float startingFillProportion,
  float endingFillProportion,
  bool skipFinalUpdate
)

Updates a loading bar by the progress made by an asynchronous operation.

The bar will interpolate between startingFillProportion and endingFillProportion as the operation progresses.

Details
Parameters
operation
The AsyncOperation indicating progress.
startingFillProportion
The starting position from which to fill.
endingFillProportion
The ending position to fill to.
skipFinalUpdate
If true, the bar will only fill before the operation has finished. This is useful in cases where an async operation will set its progress to 1, even when it has failed.

SetProgress

void SetProgress(
  float proportionOfLoadingBar
)

Sets the loading bar progress to the specified value in the range [0,1].

Details
Parameters
proportionOfLoadingBar
The loading bar's current progress in the range [0,1].