Method CreateColorPicker
| Improve this Doc View SourceCreateColorPicker(Vector2, Vector2, Vector2, Color, string, ColorEvent, ColorEvent, bool)
Creates and displays a Valheim style ColorPicker
Declaration
public void CreateColorPicker(Vector2 anchorMin, Vector2 anchorMax, Vector2 position, Color original, string message, ColorPicker.ColorEvent onColorChanged, ColorPicker.ColorEvent onColorSelected, bool useAlpha = false)
Parameters
Type | Name | Description |
---|---|---|
Vector2 | anchorMin | Min anchor on first instantiation |
Vector2 | anchorMax | Max anchor on first instantiation |
Vector2 | position | Position on first instantiation |
Color | original | Color before editing |
string | message | Display message |
ColorPicker.ColorEvent | onColorChanged | Event that gets called when the color gets modified |
ColorPicker.ColorEvent | onColorSelected | Event that gets called when one of the buttons done or cancel get pressed |
bool | useAlpha | When set to false the colors used don't have an alpha channel |