> For the complete documentation index, see [llms.txt](https://outreal-xr.gitbook.io/holofair-sdk/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://outreal-xr.gitbook.io/holofair-sdk/development/features/respawn.md).

# Respawn

Respawn players around

When enabling respawn points for users you need at least one of the interaction handlers or some sort of triggers and a component RespawnController.cs. So, first, create an empty gameObject and add a component on it called RespawnController. This is enough for now. You may also define the respawn radius in case if you wish to randomly distribute the spawn points. So, your gameObject may look like this:

<figure><img src="https://2540630353-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fk4EogWusoxJQBt7VlQ6B%2Fuploads%2Fjzm9zG5CSa2EyqeHj8od%2FRespawnExample.JPG?alt=media&amp;token=05079a13-e419-4200-9376-6688cc61dbae" alt=""><figcaption><p>Player variable should remain empty, because it is assigned by HoloFair on start</p></figcaption></figure>

Then a trigger of your choice should reference the component and call method Respawn. For example in the image below, OnClickHandler is used as a trigger, so whenever user clicks on the collider with such component, it calls the method:

<figure><img src="https://2540630353-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fk4EogWusoxJQBt7VlQ6B%2Fuploads%2FXZO5Ex3QTeOED6PgGNo3%2FRespawnTriggerExample.JPG?alt=media&amp;token=5ef1e173-677c-4f78-9198-949fc37840c7" alt=""><figcaption></figcaption></figure>

Similarly it may work with OnTriggerHandler or VisualScripting or BehaviorTree. See the video below to see how it works with OnClickHandler:

{% embed url="<https://youtu.be/4CqMICxpAC4>" %}
