> For the complete documentation index, see [llms.txt](https://niam.gitbook.io/documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://niam.gitbook.io/documentation/game-creator-2/inline-variables/getting-started.md).

# Getting Started

Get started with Inline Variables for Game Creator 2. This guide covers the installation process and its basic usage.

## Prerequisites <a href="#prerequisites" id="prerequisites"></a>

Before you begin, ensure you have the following:

* Unity 6 LTS or higher
* Game Creator 2

## Installation

To install the Editor Expansion Kit package, follow the instructions below.

{% stepper %}
{% step %}

### <i class="fa-book-open">:book-open:</i> Open Unity Package Manager

Navigate to `Window → Package Manager` in the top menu.
{% endstep %}

{% step %}

### <i class="fa-search">:search:</i> Search for the Package

In the **My Assets** tab, use the search bar to find `Inline Variables | Game Creator 2`.
{% endstep %}

{% step %}

### <i class="fa-download">:download:</i> Download and Import the Package

Once found, select the package. Then click **Download** and **Import**.
{% endstep %}

{% step %}

### <i class="fa-check">:check:</i> Verify Installation

After importing, the `Inline Variables` folder should appear in `Assets/Plugins/GameCreator/Packages`.
{% endstep %}
{% endstepper %}

## Optional Addons

The Inline Variables module ships with optional add-on packages that extend support for other GC2 modules. Each add-on provides additional Value List sources and Get/Set Properties specific to that module.

<div align="left"><figure><img src="https://348920791-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeQ7CIxHuad77enwt80mG%2Fuploads%2FjEoOjmghrMGxcljG1YKZ%2Fimage.png?alt=media&amp;token=c38ec68e-4a9c-4479-8d6d-9cc4c6b81467" alt="" width="563"><figcaption></figcaption></figure></div>

{% stepper %}
{% step %}

### Open Game Creator Install Window

Navigate to `Game Creator → Install...` in the top menu.
{% endstep %}

{% step %}

### Find Inline Variables Drawer

On the left panel, find and expand the `Inline Variables` drawer.
{% endstep %}

{% step %}

### Install the Addons

Select the modules you have and click the `Install` button at the lower right corner.
{% endstep %}
{% endstepper %}

{% hint style="danger" %}
**Note:** Only install add-ons for modules you have installed. For instance, installing the Stats add-on without the Stats module will cause compile errors due to missing namespace or assembly references.
{% endhint %}

## Basic Usage

A common workflow looks like this:

<div align="left"><figure><img src="https://348920791-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeQ7CIxHuad77enwt80mG%2Fuploads%2FwfAoPh5svI0VHZSE8b4U%2Fimage.png?alt=media&amp;token=f38703b2-9ac8-42df-9195-f59023dad47e" alt="" width="375"><figcaption></figcaption></figure></div>

{% stepper %}
{% step %}

### Create Inline Variable

Add an inline variable to any Instruction List. Give it a name, value type, and initial value.
{% endstep %}

{% step %}

### Modify Inline Variable

Change the value as needed in subsequent instructions.
{% endstep %}

{% step %}

### Access Inline Variable

You can access inline variables through properties, like local and global variables.
{% endstep %}

{% step %}

### Dispose Inline Variable

Inline variables are automatically disposed at the end of execution of the last instruction.
{% endstep %}
{% endstepper %}

{% hint style="info" %}
The variable exists only while the parent `InstructionList` is running. Once it finishes, the variable is discarded and its value is reset to its initial state — unless `Is Persistent` field is checked.
{% endhint %}
