# Adding Abilities to Your Actors

Beyond our pre-built actors, ShikorDriftXR provides a library of powerful **Actor Components**. Think of these as reusable "ability packs" that you can add to **any actor** in your level to give it new functionalities.

This modular approach gives you incredible flexibility to create unique, interactive objects.

**How to Add a Component:**

1. Select any actor in your level.
2. In the **Details** panel, click **"+ Add"** and search for the component by name (e.g., BPC\_Highlight).
3. Select it from the list to add it to your actor.

{% tabs %}
{% tab title="BPC\_Highlight" %}
The BPC\_Highlight component is a versatile tool for providing clear visual feedback when an object is targeted or focused on by the player. It is driven by the Event Tick, ensuring a smooth and responsive effect. When you add this component to an actor, it will automatically highlight when the player looks at it.

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

**1. Highlight (Default)**

This is a soft, glow-like effect that appears around the edges of the object.

* **Highlight Color:** Sets the color of the fresnel glow.
* **Highlight Radius:** Controls the thickness or spread of the glow. (Technically, this adjusts the Exponent value of a Fresnel node in the material).
* **Highlight Opacity:** Controls the transparency of the glow effect.

***

**2. Outline Setup**

This style creates a hard, cartoon-like outline around the object.

* **Use Outline:** Check this box (true) to enable this mode. This will automatically disable the Fresnel and Animation modes.
* **Outline Expand:** Controls the thickness of the outline by adjusting the World Position Offset.

***

**3. Highlight Animation**

This style creates a dynamic, animated effect that can be used for a more stylized highlight.

* **Use Animation:** Check this box (true) to enable this mode.
* **Animation Speed:** Controls how fast the animation plays.
* **Animation Width:** Defines the size or spread of the animated effect.
* **Animation Opacity:** Controls the transparency of the animation.

***

**Technical Note for Advanced Users:**

The dynamic material effects of this component are powered by the **M\_Transparent** Master Material.
{% endtab %}

{% tab title="BPC\_XrayMode" %}
The BPC\_XrayMode component is a powerful visualization tool designed to reveal hidden details within your models, such as BIM connections, electrical wiring, or plumbing inside walls.

When this component is added to a static mesh, it allows that mesh to be turned semi-transparent via a global toggle in the runtime UI, creating an "X-Ray" effect that reveals whatever is inside or behind it.

**How it Works:**

1. Add the BPC\_XrayMode component to any static mesh actor in your level that you want to make "X-Ray-able" (e.g., a wall, a floor, a machine casing).
2. When the game is running, a new **"X-Ray Mode" button** will automatically become visible in the main UI.
3. Clicking this button will toggle the X-Ray effect ON and OFF for **all actors** in the level that have this component. When ON, the meshes will switch to the specified transparent material, making any objects behind them visible.

**Configuration (Details Panel):**

The setup for this component is incredibly simple

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

* **Xray Material:**
  * **What it does:** This is the most important setting. It defines the transparent material that will be applied to the mesh when X-Ray mode is activated.
  * **How to use:** We provide a default MI\_Xray material instance that you can use out-of-the-box. However, for full control, you can create and assign your own custom transparent or semi-translucent material here to achieve the exact visual style you want.
    {% endtab %}

{% tab title="BPC\_ShowDotWidget" %}
The BPC\_ShowDotWidget component is a simple but essential tool for improving user experience. Its primary job is to display a widget on the screen when the player focuses on an interactable object, signaling that an action can be performed (e.g., "Press F to open").

**How it Works:**

When you add this component to any actor that requires player interaction (like our BP\_InteractDirectional or BP\_ManualDirectional actors), this widget will automatically appear in the viewport when the player looks at the actor, and disappear when they look away.

<div align="center" data-full-width="false"><figure><img src="/files/dZz2KHTeZARheKqCoE38" alt="Default interaction prompt shown by the component." width="165"><figcaption></figcaption></figure></div>

**Configuration (Details Panel):**

This component is designed for simplicity, with one powerful customization option.

<figure><img src="/files/dQbKYHx055e6JVI6ggO3" alt=""><figcaption><p><strong>BPC_ShowDotWidget</strong></p></figcaption></figure>

* **Chose Widget:**
  * **What it does:** This is the only setting for this component. It allows you to select which User Widget should be displayed on the screen when the actor is focused on.
  * **How to use:**
    * **Default:** By default, it is set to our pre-built WBP\_Interact widget, which shows a simple "Press F" prompt.
    * **Customization:** For full creative control, you can create your own unique UI widget (e.g., with a different icon, text, or animation) and assign it here to perfectly match the visual style of your project.
      {% endtab %}
      {% endtabs %}


---

# 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://shikorviz.gitbook.io/shikordriftxr/adding-abilities-to-your-actors.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.
