# Variables

### Description

Variables are, by definition, data structures holding a specific value that can be edited during runtime.

Each variable is defined by its name, type, and scope inside [OverScriptManager](/over-sdk-manual/over-visual-scripting-legacy/visual-scripting-essentials/overscriptmanager.md) and [OverScript](/over-sdk-manual/over-visual-scripting-legacy/visual-scripting-essentials/overscript.md).

In general, variables can be distinguished into two main categories:

* **GLOBAL**: Variables having the widest scope possible, that can be accessed by every script in a Scene. [OverScriptManager](/over-sdk-manual/over-visual-scripting-legacy/visual-scripting-essentials/overscriptmanager.md) is responsible for handling global variables and it is the only place in which they can be defined
* **LOCAL**: Variables that have their scope limited only to a specific [OverScript](/over-sdk-manual/over-visual-scripting-legacy/visual-scripting-essentials/overscript.md), in which they are defined and reside. Local variables cannot be referenced by a different script.

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

#### Handling variables

Once a variable is correctly defined, a variable is listed in the Graph. A variable can be presented in two kinds of nodes, depending on its usage:

* **GET Node**: a Plain Node whose purpose is to deliver the current value of the variable.
* **SET Node**: a Flow Node whose purpose is to edit the value of the variable.

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

A variable may be defined for any type of object. It is therefore possible, thanks to variables, to interact with any component associated with objects in the scene.


---

# 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.overthereality.ai/over-sdk-manual/over-visual-scripting-legacy/nodes/variables.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.
