Terraria ModLoader  0.10.1.5
A framework for Terraria mods
Terraria.ModLoader.Config.LabelAttribute Class Reference

This attribute sets a label for the property, field, or class for use in the ModConfig UI. Starting the label with $ means the label should be interpreted as a Localization key. More...

+ Inheritance diagram for Terraria.ModLoader.Config.LabelAttribute:
+ Collaboration diagram for Terraria.ModLoader.Config.LabelAttribute:

Public Member Functions

 LabelAttribute (string label)
 

Public Attributes

string Label => label.StartsWith("$") ? Localization.Language.GetTextValue(label.Substring(1)) : label
 

Private Attributes

readonly string label
 

Detailed Description

This attribute sets a label for the property, field, or class for use in the ModConfig UI. Starting the label with $ means the label should be interpreted as a Localization key.

Definition at line 32 of file ConfigAttributes.cs.

Constructor & Destructor Documentation

Terraria.ModLoader.Config.LabelAttribute.LabelAttribute ( string  label)

Definition at line 35 of file ConfigAttributes.cs.

36  {
37  this.label = label;
38  }

Member Data Documentation

readonly string Terraria.ModLoader.Config.LabelAttribute.label
private

Definition at line 34 of file ConfigAttributes.cs.

string Terraria.ModLoader.Config.LabelAttribute.Label => label.StartsWith("$") ? Localization.Language.GetTextValue(label.Substring(1)) : label

Definition at line 39 of file ConfigAttributes.cs.