Legacy Documentation: Version 5.0
Language: English
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

ColorBlock.pressedColor

Switch to Manual
public var pressedColor: Color;

Description

Pressed Color.

#pragma strict
// Required when Using UI elements.
public var button;
public var newColor;
function Start() {
	//Changes the button's Pressed color to the new color.
	button.colors.pressedColor = newColor;
}