Class ContentTextSection

Namespace
SurvivorsMaker.Editor
Assembly
SurvivorsMaker.Editor.dll

DisplayName / Description / TextKey of a content asset, with the text the game will show: the chosen translation table's "<key>.name" and "<key>.description" per language, else the authored text, else the id.

public static class ContentTextSection
Inheritance
ContentTextSection
Inherited Members

Fields

DescriptionField

public const string DescriptionField = "Description"

Field Value

string

KeyField

public const string KeyField = "TextKey"

Field Value

string

NameField

public const string NameField = "DisplayName"

Field Value

string

Methods

Build(MakerAssetEditor, VisualElement, ContentTextKind)

public static VisualElement Build(MakerAssetEditor editor, VisualElement root, ContentTextKind kind)

Parameters

editor MakerAssetEditor
root VisualElement
kind ContentTextKind

Returns

VisualElement

ContentKeys(ContentAsset)

Every name and description key of the content's characters, weapons, items, sets and enemies, in reference order.

public static List<string> ContentKeys(ContentAsset content)

Parameters

content ContentAsset

Returns

List<string>

DefaultTable()

The only translation table in the project, or null.

public static LocalizedTextAsset DefaultTable()

Returns

LocalizedTextAsset

Describe(IContentTextSource, ContentTextKind, LocalizedTextAsset)

public static string Describe(IContentTextSource source, ContentTextKind kind, LocalizedTextAsset table)

Parameters

source IContentTextSource
kind ContentTextKind
table LocalizedTextAsset

Returns

string

KeyOf(IContentTextSource)

The localization key base of a source: its TextKey, else "<kind>.<id>".

public static string KeyOf(IContentTextSource source)

Parameters

source IContentTextSource

Returns

string