# FixupEmissiveFlag

> Properly sets up the globalIllumination flag on the given Material depending on the current flag's state and the material's emission property.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor](/engine/6000.0/script-reference/unityeditor.md)
* **Assembly:** UnityEditor

## FixupEmissiveFlag(Material)

Properly sets up the globalIllumination flag on the given Material depending on the current flag's state and the material's emission property.

```csharp
public static void FixupEmissiveFlag(Material mat)
```

### Parameters

**** (\[Material]\(/engine/6000.0/script-reference/unityengine/material)): The material to be fixed up.

## FixupEmissiveFlag(Color, MaterialGlobalIlluminationFlags)

Returns a properly set global illlumination flag based on the passed in flag and the given color.

```csharp
public static MaterialGlobalIlluminationFlags FixupEmissiveFlag(Color col, MaterialGlobalIlluminationFlags flags)
```

### Parameters

**** (\[Color]\(/engine/6000.0/script-reference/unityengine/color)): Emission color.**** (\[MaterialGlobalIlluminationFlags]\(/engine/6000.0/script-reference/unityengine/materialglobalilluminationflags)): Current global illumination flag.

### Returns

| Type                                                                                                              | Description        |
| ----------------------------------------------------------------------------------------------------------------- | ------------------ |
| [MaterialGlobalIlluminationFlags](/engine/6000.0/script-reference/unityengine/materialglobalilluminationflags.md) | The fixed up flag. |
