# Proximity Prompts

Proximity prompts are a fast way to listen for player input in world.

<figure><img src="/files/fp5IkPynspGfNwk9jZqw" alt="" width="235"><figcaption></figcaption></figure>

### Creating Prompts

The simplest way to create a prompt is to drag Core's ProximityPrompt prefab onto your game object.&#x20;

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

To listen to prompt input you can use `onActivated`:

```typescript
import ProximityPrompt from "@Easy/Core/Shared/Input/ProximityPrompts/ProximityPrompt";

export default class PromptExample extends AirshipBehaviour {
	public prompt: ProximityPrompt;
	override Start(): void {
		this.prompt.onActivated.Connect(() => {
			print("Activated prompt");
		});
	}
}

```

<figure><img src="/files/Eoj7h3NhLp0aZzCi0Mkv" alt="" width="375"><figcaption><p>PromptExample component on Cube Game Object</p></figcaption></figure>

{% hint style="info" %}
onActivated will only ever be fired when the local client interacts with a prompt. This cannot be listened to on the server. To network the result check out [Network Signals](/networking/network-signals.md).
{% endhint %}

### Customization

Because a Proximity Prompt is a prefab you can entirely change how it displays.

<figure><img src="/files/o1qmXMeBZT2JuSXDfCWV" alt="" width="168"><figcaption></figcaption></figure>

There are a few core customization fields on the Proximity Prompt that you can change in editor or through code:

<figure><img src="/files/DFrU3g5KHADF4y1AXnTJ" alt="" width="375"><figcaption></figcaption></figure>

If you're looking to change how a proximity prompt looks entirely you can modify it directly in your object. If you are wanting to repeat the same style of prompt throughout your game you'll want to set it up as a [Prefab Variant](https://docs.unity3d.com/Manual/PrefabVariants.html).

### Cross Platform

Prompts automatically work across platforms. On mobile prompts can be tapped to activate.


---

# 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.airship.gg/core-package/proximity-prompts.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.
