LanguageEnglish
  • C#
  • JS

Script language

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

This version of Unity is unsupported.

Color.a

public float a;

Description

Alpha component of the color (0 is transparent, 1 is opaque).

using UnityEngine;

public class Example : MonoBehaviour { public Color color = Color.white;

void Start() { color.a = 0.42f; } }