# Built-in Setup

### Do you need a URP / HDRP version of the APK?

{% hint style="info" %}
Just send an email to: **<speedtutoruk@gmail.com>** via my [website](https://www.speed-tutor.com/pages/contact) with your **invoice number** and I'll happily send it your way. If not check the URP / HDRP setup guides to do it all yourself!
{% endhint %}

## Importing Notes & Troubleshooting

### Layers & Tags Reference Guide

{% hint style="info" %}

* Make sure to create tags called:
  * **InteractiveObject**
  * **ExaminePoint:** Tag for the **ExaminePoint** gameobject parented to the **ExamineCamera**
  * **InspectPoint:** Tag for every single inspect point that exists for an object
* Create Layers:&#x20;
  * User Layer 8: **ExamineLayer** (Doesn't need to be added to objects, referenced in code)
  * User Layer 9: **InspectPointLayer** (Tag for every single inspect point)
  * User Layer 10: **PostProcess**
  * User Layer 11: **PadlockSpinner**
    {% endhint %}

{% hint style="warning" %}
**LAYER NOTE:** If you can place these on the corresponding User Layers (As below) it is easier for setup, as Unity will automatically place them in the correct places so the below information might not be all relevant to you. (It's worth checking through just in case)

* IF NOT added to these layers check the sections below on **Checking Prefabs (See side bar)** - Just to confirm all appropriate layers are added and no issues arise.
  {% endhint %}

### TextMeshPro Required

{% hint style="info" %}

* Please note that TMP will appear as a popup if not installed in your project
* Click **Import TMP Essentials** to use the system fully
  {% endhint %}

### DontDestroyOnLoad yellow warning

{% hint style="info" %}
This just means that objects that use **DontDestroyOnLoad** shouldn't be children of a parent. Just make sure they exist in your hierarchy without a parent, when you choose to finalise your product. I just kept them in little organised areas for the sake of visuals.&#x20;
{% endhint %}

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

### Other Issues? Contact Me

{% content-ref url="/pages/Yb25K5PcHe5zTDcsLjzg" %}
[Contact Me](/apk-doc-v1.7/contact-me/contact-me.md)
{% endcontent-ref %}

## (Please Read) Important Import Suggestions

{% hint style="info" %}
Download and import the Adventure Puzzle Kit from the package manager.&#x20;

* Window > Package Manager > Search for "Adventure Puzzle Kit"
  {% endhint %}

{% hint style="danger" %}
**Importing Tips:**

1. Import into a fresh project rather than a working project (To avoid issues or conflicts)
2. Always keep a backup of your working project **BEFORE** importing **ANY** assets
3. In the **Import Unity Package** dialog box that appears when you first click to import the asset (It will show all the folder structure in a last)
   1. Choose the first **Next** button which will lead to the **Project Settings**
   2. **UNTICK** the project settings folder (None of the items will be ticked at this point)
   3. Select the Import button to start the new import
      {% endhint %}

### Step 1 - Errors & FIxes On Import (Built-in Pipeline)

You will get import errors that refer to **Post Processing (**&#x49;mport PP package to fix)

{% hint style="info" %}

1. Go to the **Package Manager** (Window > Package Manager)
2. Filter by **Unity Registry**
3. Search "**Post Process**". You will see **Post Processing** appear in the list (Make sure to install this package)
   {% endhint %}

<figure><img src="/files/O0C30Cy6KsayxheLMfbj" alt=""><figcaption><p>Errors that can be seen when imported into the Built-in render pipeline version of Unity</p></figcaption></figure>

### Step 2 - APK Startup Window

{% hint style="info" %}
The APK startup window should appear, you may need to expand the window to see all the button links (If they aren't visible).&#x20;

* You can dock this window if you wish and has FAQ information, contact buttons and helpful information.
  {% endhint %}

{% hint style="success" %}
Open APK help window for easy links and advice: **APK** > **Tools** > **Adventure Kit Support Hub**&#x20;
{% endhint %}

### Step 3 - Open Demo Scene

We'll open the demo scene so we can get the basics setup to be used, follow steps below

{% hint style="info" %}

1. Navigate to Assets > Adventure Puzzle Kit > Scenes > FirstPerson\_AdventureKit\_Demo
2. Double click to open this scene to start using it
   {% endhint %}

### Step 4 - Creating Tags & Layers

Select any GameObject in the Hierarchy and then create tags and layers in the top right of the inspector (Some or all tags may already be created)

{% hint style="info" %}

* Make sure to create tags called:
  * **InteractiveObject**
  * **ExaminePoint:** Tag for the **ExaminePoint** gameobject parented to the **ExamineCamera**
  * **InspectPoint:** Tag for every single inspect point that exists for an object
* Create Layers:&#x20;
  * User Layer 8: **ExamineLayer** (Doesn't need to be added to objects, referenced in code)
  * User Layer 9: **InspectPointLayer** (Tag for every single inspect point)
  * User Layer 10: **PostProcess**
  * User Layer 11: **PadlockSpinner**
    {% endhint %}

{% hint style="warning" %}
**LAYER NOTE:** If you can place these on the corresponding User Layers (As above) it is easier for setup, as Unity will automatically place them in the correct places so the below information might not be relevant to you.

* If you can't use the user layers above, follow the setup bellow and the "**Checking prefabs**" section will have the information you need to check all your assets use the correct layers!
  {% endhint %}

### Step 5 - Setting Up Main Camera

{% hint style="info" %}

1. Select the **Main Camera** (APK\_FPSContainer > FPSController > MainCamera)
   1. **Physics Raycaster** script - Make sure the **Event Mask** has the layer of **PadlockSpinner**
      * Leave Max Ray Intersections at 0
   2. **Post-Process Layer**: Set the Layer to: **Post Process**
   3. Select the **Culling Mask** dropdown (On the MainCamera) and make sure:&#x20;
      1. **ExamineLayer, InspectPointLayer** and **PostProcess** are **UNTICKED** (Everything else can be ticked)
         {% endhint %}

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

### Step 6 - Setting Up Examine Camera

{% hint style="info" %}

1. Select the **Examine Camera** (Child of the Main Camera):
   1. Select the **Culling Mask** and make sure **ExamineLayer** and **InspectPointLayer** are **TICKED** **ONLY**
   2. Clear Flags Set To: **Depth Only**
      {% endhint %}

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

### Step 7 - Post Processing Volume Layer

{% hint style="info" %}

1. Select the **PostProcessingVolume** GameObject
   1. Set the layer to **PostProcess** (Top Right of the Inspector)
      {% endhint %}

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

{% hint style="danger" %}
If you do have any runtime errors with post processing, you may need to remove the "**Post-Process Layer**" from the main camera and re-add it.
{% endhint %}

### Step 8 - Checking Prefabs

We just need to check we have the correct layers on the padlock spinners or they won't be detected properly

{% hint style="info" %}

1. Go into the **Prefabs** > **Spawnable** > **Padlock** folder
   1. Open the brass and black padlocks seperately (By double clicking the prefabs)&#x20;
   2. Select all of the **combination spinners** and make sure the all have the layer of **PadlockSpinner** (In the top right of the inspector when you select the spinners)
      {% endhint %}

### Step 9 - Check Examination Objects

We just need to check examine objects have the correct layers on their inspect points (So they render correctly)

{% hint style="info" %}

1. Inside the Puzzle Objects GameObject folder in the Hierarchy&#x20;
2. Open the **Examine - Objects**
   1. Find any object which has I**nspect Points** (The knife will have some by default)
   2. Make sure these inspect points have a layer of **InspectPointLayer** (Or they will not render correctly)
3. You can check any other object which has inspect points but should be setup by default!
   {% endhint %}

<figure><img src="/files/822wm49vZPgEFkvMZvSC" alt=""><figcaption></figcaption></figure>

### Step 10 - Enable Legacy Input System

We'll need to enable the legacy system if you're using Unity 6+ and it isn't enabled by default

**NOTE: New input system support is coming in v1.8**

{% hint style="info" %}

1. Go to **Edit > Project Settings > Player > Other Settings**
2. Scroll down half way and you'll see **Active Input Handling**
3. Set this dropdown to **BOTH** and press **Apply (**&#x54;he editor will restart)
   {% endhint %}

### Others Issues? Contact Me!

{% content-ref url="/pages/Yb25K5PcHe5zTDcsLjzg" %}
[Contact Me](/apk-doc-v1.7/contact-me/contact-me.md)
{% endcontent-ref %}


---

# 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://speedtutoruk.gitbook.io/apk-doc-v1.7/getting-started/built-in-setup.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.
