M_MSCLoader_Settings_AddButton_4 - piotrulos/MSCModLoader GitHub Wiki
Add button that can execute function.
Namespace: MSCLoader
Assembly: MSCLoader (in MSCLoader.dll) Version: 1.3.1.346
C#
public static <a href="T_MSCLoader_SettingsButton">SettingsButton</a> AddButton(
string name,
Action onClick,
Color btnColor,
Color buttonTextColor,
Texture2D customIcon,
bool visibleByDefault = true
)
View Source
- String
- Text on the button
- Action
- What to do when button is clicked
- Color
- Button background color
- Color
- Button text color
- Texture2D
- Custom icon (Texture2D, should be POT minimum 16x16, no bigger than 64x64)
- Boolean (Optional)
- Visible by default (default=true)
SettingsButton
SettingsButton