implicit operator Color32
Color32 can be implicitly converted to and from Color.
Read time 1 minuteLast updated 5 days ago
Definition
- Type: Operator
- Namespace: UnityEngine
- Assembly: UnityEngine.CoreModule
implicit operator Color32(Color3)
Color32 can be implicitly converted to and from Color.
public static implicit operator Color32(Color c)
Parameters
Returns
Type | Description |
|---|---|
| Color32 |
Examples
using UnityEngine;public class Example : MonoBehaviour{ void Start() { Color32 color = new Color(0.5f, 1f, 0.5f, 1f); }}
implicit operator Color(Colo)
Color32 can be implicitly converted to and from Color.
public static implicit operator Color(Color32 c)
Parameters
Returns
Type | Description |
|---|---|
| Color |
Examples
using UnityEngine;public class Example : MonoBehaviour{ void Start() { Color color = new Color32(128, 255, 128, 255); }}