Table of Contents

Interface IColorPresets

Namespace
Vintagestory.API.Client
Assembly
VintagestoryAPI.dll

Facilitates the Accessibility tab wireframe colors setting. Offers three preset color options, "Default", "Preset2" and "Preset3". The selection between these three options is chosen by the ClientSettings int value "guiColorsPreset". Within these presets, individual color values are stored by string key.

public interface IColorPresets
Extension Methods

Methods

GetColor(string)

Called to fetch a color value from the currently selected preset colors

int GetColor(string key)

Parameters

key string

Returns

int

Initialize(IAsset)

Mods (e.g. VSSurvivalMod) can call this to insert into the presets their configured color keys and values, which will be specific to mod content

void Initialize(IAsset asset)

Parameters

asset IAsset

OnUpdateSetting()

To be called when the ClientSetting "guiColorsPreset" is changed

void OnUpdateSetting()