> For the complete documentation index, see [llms.txt](https://malbersanimations.gitbook.io/animal-controller/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://malbersanimations.gitbook.io/animal-controller/global-components/interactable.md).

# Interactable

## &#x20;Overview

This component is often used to create interaction with the animals, even though it has no dependencies with the Animal Controller,  it can be used as a stand-alone component, along with the Interactor script.

{% hint style="info" %}
The script for the Interactable is **MInteract**.
{% endhint %}

<figure><img src="/files/LEaAsr8tC3nCrQwAjFC5" alt=""><figcaption></figcaption></figure>

## Parameters

### Index

Index of the Interactable. This value is used by the [Interactor](/animal-controller/global-components/interactor.md) as an Event to identify with which interactable the [Interactor](/animal-controller/global-components/interactor.md) is interacting.

### Interactor ID

Which [Interactors ](/animal-controller/global-components/interactor.md)can interact with this Interactable, by default is set to -1 which means this interactable can interact will all interactors.

### Auto Interact

If the [Interactor](/animal-controller/global-components/interactor.md) has this interactable focus, it will apply the Interaction logic automatically, without having to call the Interact() method.

### Single Interaction

Interact once. After an interaction is executed with this interactable, this component will be disabled, so it no longer can be used.

### Delay

Delay time to execute/call the interaction logic.

### Cooldown

The time needed to elapse between interactions. This only works when Single Interaction is set to false

## Events

<figure><img src="/files/8YNUKwmoPQNosq6IuJ8w" alt=""><figcaption></figcaption></figure>

### On Interact with GO (GameObject)

Invoked when the Interactor executes an interaction. The parameter is the [Interactor](/animal-controller/global-components/interactor.md) Gameobject

### On Interact with (Int)

Invoked when the Interactor executes an interaction. The parameter is the [Interactor](/animal-controller/global-components/interactor.md) Index. this is called right after the Event OnInteractWithGo(GameObject).

### On Focused

Invoked when the [Interactor](/animal-controller/global-components/interactor.md) has this Interactable as the focused Interactable.&#x20;

### On Unfocused

Invoked when the [Interactor](/animal-controller/global-components/interactor.md) has **lost** this Interactable as the focused Interactable.&#x20;
