# Custom Triggers

**Triggers** are the bridge between some kind of input and the execution of **Actions** and **Events**. What receives this input and decides whether the Trigger should be fired or not are a hidden component called **Igniters**.

![(An Igniter tells the Trigger: Hey! Invoke the Actions & Events)](/files/-LDvsj-V5l-a_Z0Y6QpK)

So when we talk about creating custom **Triggers**, we're actually talking about custom **Igniters**. And these work pretty much the same way as **Actions** and **Conditions**.

{% code title="IgniterExample.cs" %}

```csharp

[AddComponentMenu("")]
public class IgniterCollisionEnter : Igniter 
{
    #if UNITY_EDITOR
    public new static string NAME = "Example/Example";
    public new static bool REQUIRES_COLLIDER = true;
    #endif

    void Start()
    {
        this.ExecuteTrigger(null);
    }
}
```

{% endcode %}

In the example above you see an example of Igniter that tells the **Trigger** to fire the **Actions** and **Events** as soon as the **`Start`** method is called.

It is worth noting that it requires the static property **`NAME`** and this needs to be unique. The **`REQUIRES_COLLIDER`** property is optional and tells the Editor that this Trigger needs to have a collider attached.

{% hint style="info" %}
Unlike **Actions** and **Conditions**, **Igniters** don't an Editor section to display the Inspector's UI
{% endhint %}

The **Igniter** class inherits from **MonoBehaviour**. That means that you have all the typical methods at your disposal, including the **`Awake`**, **`Update`**, **`OnColliderEnter`**, ...


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.gamecreator.one/game-creator/systems/game-creator-api/custom-triggers.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
