Tutorials
Learn RedScript step-by-step, from installation to building complete mini-games.
Learning Path
Start here if you're new:
| # | Tutorial | Time | Focus |
|---|---|---|---|
| 1 | Getting Started | 20 min | Install CLI, first compile |
| 2 | Variables and Types | 25 min | let, const, basic types |
| 3 | Control Flow | 30 min | if, for, while, match |
| 4 | Functions | 25 min | Parameters, returns, recursion |
| 5 | Structs and Enums | 30 min | Data modeling, impl blocks |
| 6 | Stdlib Tour | 20 min | Math, random, particles |
| 7 | Events and Ticks | 25 min | @load, @tick, @on(...) |
| 8 | Advanced | 30 min | @coroutine, optimizer |
Language Detail Coverage
The beginner path now introduces the language surface in layers instead of leaving key details only in the reference:
| Feature area | First tutorial touchpoint | Full reference |
|---|---|---|
let, const, inference | 02 — Variables and Types | Syntax |
int, fixed, double, string, bool | 02 — Variables and Types, 09 — Precision Arithmetic | Types |
| arrays and dynamic indexing | 02 — Variables and Types, 03 — Control Flow | Expressions |
if, while, range for, array for, foreach | 03 — Control Flow | Syntax |
match, _, integer ranges, enum cases | 03 — Control Flow, 05 — Structs and Enums | Expressions |
Option<T>, Some, None, if let | 03 — Control Flow | Expressions |
struct, enum, impl | 05 — Structs and Enums | Types |
selectors, @s, execute context | 04 — Functions, 04 — Selectors & Execute Context | Syntax |
| decorators, load/tick/trigger hooks | 07 — Events and Ticks | Decorators |
| imports, retention, coroutines, optimizer | 08 — Advanced | CLI |
Project Tutorials
Complete mini-game examples:
| Tutorial | Difficulty | Description |
|---|---|---|
| Hello World | Beginner | Player greetings, scoreboards, titles |
| Zombie Survival | Intermediate | Waves, spawning, difficulty scaling |
| Parkour Race | Intermediate | Checkpoints, timers, leaderboards |
| Capture the Flag | Advanced | Teams, scoring, respawns |