# Introduction

AngelScript scripting API reference for the fvc framework.

## Overview

fvc exposes a comprehensive AngelScript API that allows scripts to interact with the game engine, entities, rendering system, and more. Scripts are loaded from `.as` files placed in the scripts directory.

**Script Location:** `%ProgramData%\vlm\scripts\`

## Quick Start

Create a file called `hello.as` in the scripts directory:

```cpp
void main() {
    println("Hello from AngelScript!");

    if (engine::in_game()) {
        println("Map: " + game::map_name_short());
        println("Tick: " + formatInt(game::tick_count()));
    }
}
```

Run it from the in-game console with: `run hello`

## API Categories

| Category                                          | Description                                                                                                                                                                       |
| ------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [Types](/scripting-api/types.md)                  | `vec2`, `vec3`, `qangle`, `color` — value types for math and rendering                                                                                                            |
| [engine](/scripting-api/namespaces/engine.md)     | Engine build info, console commands, connection state                                                                                                                             |
| [game](/scripting-api/namespaces/game.md)         | Timing, map info, screen dimensions                                                                                                                                               |
| [entities](/scripting-api/namespaces/entities.md) | Player iteration, properties, bones, relationships                                                                                                                                |
| [cmd](/scripting-api/namespaces/cmd.md)           | User command manipulation in create\_move hooks                                                                                                                                   |
| [events](/scripting-api/namespaces/events.md)     | Engine-frame hooks (create\_move, render, override\_view, mouse\_input, main\_menu) and CS2 game-event listeners (player\_death, player\_hurt, player\_sound, weapon\_fire, etc.) |
| [draw](/scripting-api/namespaces/draw.md)         | Screen-space rendering primitives                                                                                                                                                 |
| [cvar](/scripting-api/namespaces/cvar.md)         | Console variable access                                                                                                                                                           |
| [math](/scripting-api/namespaces/math.md)         | Trigonometry, angles, interpolation                                                                                                                                               |
| [utils](/scripting-api/namespaces/utils.md)       | Timestamps and timing                                                                                                                                                             |
| [vars](/scripting-api/namespaces/vars.md)         | Feature toggle get/set                                                                                                                                                            |
| [Enums](/scripting-api/enums.md)                  | InputBitMask, MoveType, LifeState, Team, Bone                                                                                                                                     |
| [Globals](/scripting-api/globals.md)              | `print()`, `println()`                                                                                                                                                            |


---

# 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.vaclive.me/readme.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.
