> For the complete documentation index, see [llms.txt](https://guide.cronuszen.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://guide.cronuszen.com/gpcscripting/gpc-script-guide/learn-gpc/raw-data-section.md).

# Raw data section

`data(...)` stores immutable bytes at the start of the compiled virtual data space:

{% code title="raw-data-section.gpc" %}

```cpp
data(20, 42, 35, 255, 1, 100, 0, 86);

int signed_value;
int unsigned_value;

main {
    signed_value = dint8(3);    // -1 from byte 0xFF
    unsigned_value = duint8(3); // 255
}
```

{% endcode %}

`data(...)` also accepts values wider than one byte. The compiler splits a wider value into multiple bytes and warns because every later byte offset moves:

| Source value range                         | Storage on the current Zen target | Warning                  |
| ------------------------------------------ | --------------------------------: | ------------------------ |
| `-128..255`                                |                            1 byte | None for width           |
| `-32768..65535` outside the one-byte range |                           2 bytes | Later indexes shift by 1 |
| Values outside the two-byte range          |                           4 bytes | Later indexes shift by 3 |

{% code title="raw-data-widths.gpc" %}

```cpp
data(0x12, 0x1234, 0x12345678);

int byte_value;
int word_value;
int dword_value;

main {
    byte_value = duint8(0);
    word_value = duint16(1);
    dword_value = dint32(3);
}
```

{% endcode %}

If exact packed bytes matter, spelling out each byte is easier to audit and avoids accidental offset changes.

Live readers:

| Reader           | Bytes | Interpretation  |
| ---------------- | ----: | --------------- |
| `dint8(index)`   |     1 | signed 8-bit    |
| `duint8(index)`  |     1 | unsigned 8-bit  |
| `dint16(index)`  |     2 | signed 16-bit   |
| `duint16(index)` |     2 | unsigned 16-bit |
| `dint32(index)`  |     4 | signed 32-bit   |

Indexes are **byte offsets**. A wider entry shifts every following offset. Prefer compiler-managed const arrays for ordinary tables; use raw data when exact packed layout is the point.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://guide.cronuszen.com/gpcscripting/gpc-script-guide/learn-gpc/raw-data-section.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
