> ## Documentation Index
> Fetch the complete documentation index at: https://nonkit.rlaneth.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Visual Commands

> Control backgrounds, characters, CGs, and visual effects

Visual commands control what appears on screen during dialogue sequences.

<Warning>
  These function signatures are based on analysis of the game's files. Some behaviors and parameter descriptions are inferred and may not be fully accurate. Furthermore, the game is in Early Access and may change over time.
</Warning>

## Background Commands

### back\_creat

Creates or changes the background image.

```yarn theme={null}
<<back_creat BG-1 false 0,0 1 0>>
<<back_creat BG-4 true 0,0 3.4 0>>
```

| Parameter | Type   | Default  | Description                    |
| --------- | ------ | -------- | ------------------------------ |
| `name`    | string | required | Background asset name          |
| `wait`    | bool   | `false`  | Wait for animation to complete |
| `pos`     | string | `0,0`    | Position as x,y                |
| `scale`   | float  | `1`      | Scale factor                   |
| `time`    | float  | `0`      | Animation duration in seconds  |

### back\_remove

Removes a background.

```yarn theme={null}
<<back_remove BG-1>>
<<back_remove Test1 false 1>>
```

| Parameter | Type   | Default  | Description          |
| --------- | ------ | -------- | -------------------- |
| `name`    | string | required | Background to remove |
| `wait`    | bool   | `false`  | Wait for animation   |
| `time`    | float  | `0`      | Animation duration   |

### back\_move

Animates background position.

```yarn theme={null}
<<back_move Test1 true 100,100 1.2 1 2>>
```

| Parameter | Type   | Default  | Description         |
| --------- | ------ | -------- | ------------------- |
| `name`    | string | required | Background name     |
| `wait`    | bool   | `false`  | Wait for animation  |
| `pos`     | string | `0,0`    | Target position x,y |
| `scale`   | float  | `1`      | Target scale        |
| `time`    | float  | `0`      | Animation duration  |
| `easing`  | int    | `0`      | Easing function     |

### back\_shake

Shakes the background.

```yarn theme={null}
<<back_shake Test1 true 4 50,0 1 0 false>>
```

| Parameter    | Type   | Default  | Description        |
| ------------ | ------ | -------- | ------------------ |
| `name`       | string | required | Background name    |
| `wait`       | bool   | `false`  | Wait for animation |
| `duration`   | float  | `1`      | Shake duration     |
| `strength`   | string | `1,1`    | Shake strength x,y |
| `vibrato`    | int    | `10`     | Vibration count    |
| `randomness` | float  | `90`     | Randomness factor  |
| `fadeOut`    | bool   | `false`  | Fade out shake     |

### back\_tint

Applies a color tint to background.

```yarn theme={null}
<<back_tint Test1 true "FF0000">>
```

| Parameter | Type   | Default  | Description             |
| --------- | ------ | -------- | ----------------------- |
| `name`    | string | required | Background name         |
| `wait`    | bool   | `false`  | Wait for animation      |
| `color`   | string | `FFFFFF` | Hex color code (quoted) |
| `time`    | float  | `0`      | Transition duration     |

### back\_rotate

Rotates the background.

```yarn theme={null}
<<back_rotate Test1 960 3 true>>
```

| Parameter  | Type   | Default  | Description               |
| ---------- | ------ | -------- | ------------------------- |
| `name`     | string | required | Background name           |
| `angle`    | float  | required | Rotation angle in degrees |
| `duration` | float  | required | Animation duration        |
| `wait`     | bool   | `false`  | Wait for animation        |

### splash\_screen

Shows a splash screen effect.

```yarn theme={null}
<<splash_screen 1 1 2 false>>
```

| Parameter     | Type  | Default  | Description         |
| ------------- | ----- | -------- | ------------------- |
| `fadeInTime`  | float | required | Fade in duration    |
| `fadeOutTime` | float | required | Fade out duration   |
| `duration`    | float | required | Display duration    |
| `wait`        | bool  | `false`  | Wait for completion |

## CG Commands

### cg\_creat

Displays a CG (full-screen image).

```yarn theme={null}
<<cg_creat CG_Temp true 1>>
<<cg_creat END true 1 "fade" true>>
```

| Parameter | Type   | Default  | Description           |
| --------- | ------ | -------- | --------------------- |
| `name`    | string | required | CG asset name         |
| `wait`    | bool   | `false`  | Wait for animation    |
| `time`    | float  | `0`      | Fade duration         |
| `effect`  | string | `fade`   | Transition effect     |
| `l10n`    | bool   | `false`  | Use localized variant |

### cg\_remove

Removes the CG.

```yarn theme={null}
<<cg_remove CG_Temp>>
<<cg_remove CG_Temp true 0.5>>
```

| Parameter | Type   | Default  | Description        |
| --------- | ------ | -------- | ------------------ |
| `name`    | string | required | CG to remove       |
| `wait`    | bool   | `false`  | Wait for animation |
| `time`    | float  | `0`      | Fade duration      |

## Character Commands

<Note>
  Character body and face can be specified as numeric indices (e.g., `1`, `9`) or string names (e.g., `laugh1`, `angry1`). Numeric indices are more commonly used in the game scripts.
</Note>

### char\_creat

Creates a character on screen.

```yarn theme={null}
<<char_creat Lilith 1 1 false 0,-1200 0.7 0 0.3>>
<<char_creat Fouco 1 laugh1 true -200,-233 0.5 0 1>>
```

| Parameter   | Type       | Default  | Description                                                     |
| ----------- | ---------- | -------- | --------------------------------------------------------------- |
| `name`      | string     | required | Character identifier (Lilith, Karen, Sartre, Fouco, Green)      |
| `bodyName`  | string/int | required | Body sprite (usually `1`)                                       |
| `facesName` | string/int | required | Face/expression (numeric like `1`, `9` or string like `laugh1`) |
| `wait`      | bool       | `false`  | Wait for animation                                              |
| `pos`       | string     | `0,0`    | Position x,y                                                    |
| `scale`     | float      | `1`      | Scale factor                                                    |
| `rotate`    | float      | `0`      | Rotation angle                                                  |
| `time`      | float      | `0`      | Animation duration                                              |

### char

Changes a character's appearance (body and/or face).

```yarn theme={null}
<<char Lilith 1 54 true 0.7>>
<<char Fouco 1 9 true 0.3>>
```

| Parameter  | Type   | Default  | Description          |
| ---------- | ------ | -------- | -------------------- |
| `name`     | string | required | Character identifier |
| `bodyName` | string | required | New body sprite      |
| `faces`    | string | required | New face sprite      |
| `wait`     | bool   | `false`  | Wait for animation   |
| `time`     | float  | `0`      | Transition duration  |
| `effect`   | string | `"fade"` | Transition effect    |

### char\_remove

Removes a character from screen.

```yarn theme={null}
<<char_remove Lilith>>
<<char_remove Fouco true 0.5>>
```

| Parameter | Type   | Default  | Description         |
| --------- | ------ | -------- | ------------------- |
| `name`    | string | required | Character to remove |
| `wait`    | bool   | `false`  | Wait for animation  |
| `time`    | float  | `0`      | Fade duration       |

### char\_move

Moves a character to a new position.

```yarn theme={null}
<<char_move Lilith false 100,0 1 0.5 0>>
```

| Parameter | Type   | Default  | Description        |
| --------- | ------ | -------- | ------------------ |
| `name`    | string | required | Character name     |
| `wait`    | bool   | `false`  | Wait for animation |
| `pos`     | string | `0,0`    | Target position    |
| `scale`   | float  | `1`      | Target scale       |
| `time`    | float  | `0`      | Animation duration |
| `easing`  | int    | `0`      | Easing function    |

### char\_shake

Shakes a character.

```yarn theme={null}
<<char_shake Lilith false 0.5 1 10 90 false>>
```

| Parameter    | Type   | Default  | Description        |
| ------------ | ------ | -------- | ------------------ |
| `name`       | string | required | Character name     |
| `wait`       | bool   | `false`  | Wait for animation |
| `duration`   | float  | `1`      | Shake duration     |
| `strength`   | float  | `1`      | Shake intensity    |
| `vibrato`    | int    | `10`     | Vibration count    |
| `randomness` | float  | `90`     | Randomness factor  |
| `fadeOut`    | bool   | `false`  | Fade out shake     |

### char\_flip

Flips a character horizontally.

```yarn theme={null}
<<char_flip Lilith>>
<<char_flip Lilith false -1,1 0.3>>
```

| Parameter | Type   | Default  | Description                  |
| --------- | ------ | -------- | ---------------------------- |
| `name`    | string | required | Character name               |
| `wait`    | bool   | `false`  | Wait for animation           |
| `scale`   | string | `1,1`    | Scale x,y (use -1,1 to flip) |
| `time`    | float  | `0`      | Animation duration           |

### char\_tint

Applies color tint to a character.

```yarn theme={null}
<<char_tint Lilith false "FFCCCC">>
```

| Parameter | Type   | Default  | Description             |
| --------- | ------ | -------- | ----------------------- |
| `name`    | string | required | Character name          |
| `wait`    | bool   | `false`  | Wait for animation      |
| `color`   | string | `FFFFFF` | Hex color code (quoted) |

### char\_rename

Renames a character identifier.

```yarn theme={null}
<<char_rename OldName NewName>>
```

| Parameter | Type   | Description  |
| --------- | ------ | ------------ |
| `oldName` | string | Current name |
| `newName` | string | New name     |

## Effect Commands

### blink

Screen blink effect.

```yarn theme={null}
<<blink 3 100 true>>
```

| Parameter   | Type  | Default  | Description         |
| ----------- | ----- | -------- | ------------------- |
| `duration`  | float | required | Blink duration      |
| `intensity` | int   | required | Blink intensity     |
| `wait`      | bool  | `false`  | Wait for completion |

### open\_eyes / close\_eyes

Eye opening/closing transition effects.

```yarn theme={null}
<<open_eyes 1 true>>
<<close_eyes 1 true>>
```

| Parameter | Type  | Default  | Description        |
| --------- | ----- | -------- | ------------------ |
| `time`    | float | required | Animation duration |
| `wait`    | bool  | `false`  | Wait for animation |

### enable\_vignette / disable\_vignette

Controls vignette effect.

```yarn theme={null}
<<enable_vignette 0.5 false 1>>
<<disable_vignette 0.5>>
```

**enable\_vignette:**

| Parameter | Type  | Default  | Description         |
| --------- | ----- | -------- | ------------------- |
| `time`    | float | required | Transition duration |
| `wait`    | bool  | `false`  | Wait for animation  |
| `value`   | float | `1`      | Vignette intensity  |

**disable\_vignette:**

| Parameter | Type  | Default  | Description         |
| --------- | ----- | -------- | ------------------- |
| `time`    | float | required | Transition duration |
| `wait`    | bool  | `false`  | Wait for animation  |

### set\_blur

Applies blur effect.

```yarn theme={null}
<<set_blur 3 1 true>>
<<set_blur 2 0 true>>
```

| Parameter | Type  | Default  | Description                |
| --------- | ----- | -------- | -------------------------- |
| `time`    | float | required | Transition duration        |
| `value`   | float | required | Blur amount (0 to disable) |
| `wait`    | bool  | `false`  | Wait for animation         |

### set\_lift

Adjusts color lift (brightness).

```yarn theme={null}
<<set_lift 2 -1 true>>
<<set_lift 2 0 true>>
```

| Parameter | Type  | Default  | Description                              |
| --------- | ----- | -------- | ---------------------------------------- |
| `time`    | float | required | Transition duration                      |
| `value`   | float | required | Lift amount (-1 to darken, 0 for normal) |
| `wait`    | bool  | `false`  | Wait for animation                       |

### bg\_cross\_fade / bg\_slide\_in

Background transition effects.

```yarn theme={null}
<<bg_cross_fade BG-1 BG-2 1 true>>
<<bg_slide_in BG-1 BG-2 1>>
```

| Parameter | Type   | Default  | Description         |
| --------- | ------ | -------- | ------------------- |
| `bg1`     | string | required | First background    |
| `bg2`     | string | required | Second background   |
| `time`    | float  | required | Transition duration |
| `wait`    | bool   | `false`  | Wait for completion |

## Common Patterns

### Scene Setup

```yarn theme={null}
<<back_creat BG-1 false 0,0 1 0>>
<<char_creat Lilith 1 1 false 0,-1200 0.7 0 0.3>>
```

### Expression Change

```yarn theme={null}
<<char Lilith 1 54 true 0.3>>
```

### Scene Transition

```yarn theme={null}
<<close_eyes 1 true>>
<<back_creat BG-2 false 0,0 1 0>>
<<open_eyes 0.3 true>>
```

### Dramatic Effect

```yarn theme={null}
<<char_shake Lilith false 0.5 2 10 90 false>>
<<back_shake BG-1 false 0.5 2,2 10 90 false>>
```
