Stat Element UGUI

Scripting with the StatElementUGUI class.

The StatElementUGUI class is a UI element that represents a stat. Used for the hover details UGUI.

Name
Description
Type
Access

icon

The image used to display the stat icon.

Image

public

statLabel

The label used to display the stat text.

TextMeshProUGUI

public

stat

The stat to represent.

Stat

public

Set Stat

The SetStat method sets the stat field and refreshes the element.

myStatElement.SetStat(myStat);

Refresh

The Refresh method simply updates the icon and stat text.

myStatElement.Refresh();

Last updated