Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion docs/LEVEL_EDITOR.md
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,9 @@ Level_NN
Mobys/Vendor_0012 one node per placed moby (crates, enemies, NPCs...), named
after its class and its place in the level's table
LevelSettings the gameplay data (Gameplay data, below): fog, death height,
MobyGroups, Cameras, ship; groups; cameras; sounds; volumes; paths
LightSets, ship; the mobys' light sets and the hero's light zones;
LightZones, groups; cameras; sounds; volumes; paths
MobyGroups, Cameras,
Sounds, Volumes,
Paths, GrindPaths
```
Expand Down Expand Up @@ -549,13 +551,17 @@ and packed back like the mobys ([gamedata.py](../openrac/tools/gamedata.py); the
|---|---|---|
| `Game/LevelSettings` | `rc1_background`, `rc1_fog_colour` (r, g, b), `rc1_fog_near`, `rc1_fog_far` and their `_intensity`, `rc1_death_height`, `rc1_ship_path`, `rc1_ship_camera_cuboids` (first, last) | values |
| `Game/LevelSettings/Ship` | where the player's ship lands; turn it about Z only | moved |
| `Game/LightSets` | `rc1_set_<n>`: each light set's 16 numbers: colour A (r, g, b, back light), direction A (x, y, z, 0), colour B, direction B; 1 is full light. Mobys name a set in `rc1_light` | values; sets added, up to 12 |
| `Game/LightZones/LightZone_NNNN` | where the hero takes his light from: a box (hidden until you show `LightZones`), `rc1_colour_a` and `rc1_colour_b` (r, g, b, a; 128 is full light), blended from A at the box's -x side to B at its +x side, `rc1_set_a` and `rc1_set_b` the same way, `rc1_on`, `rc1_reach` | moved, turned, scaled, edited, added, removed, up to 32 |
| `Game/MobyGroups` | `rc1_group_<n>`: each group's members, by node name | members |
| `Game/Cameras/Camera_NNNN` | position and rotation (the game's Euler angles), `rc1_class`, the common camera header and known class-specific pvars | edited in place; cameras may be added by copying a same-class record and pvars, up to 48 |
| `Game/Sounds/Sound_NNNN` | the record's matrix, `rc1_class`, `rc1_m_class`, `rc1_range`, pvars (hidden) | edited in place |
| `Game/Volumes/Cuboids/Cuboid_NNNN`, `Spheres`, `Cylinders`, `Pills` | the unit shape through the record's matrix, translucent (hidden until you show `Volumes`) | moved, turned, scaled, added |
| `Game/Paths/Path_NNNN` | a `Path3D`: the points in its curve, `rc1_w` each point's fourth float | points moved, added or removed; paths added; records cannot be deleted |
| `Game/GrindPaths/GrindPath_NNNN` | as paths, with `rc1_bounding_sphere` (x, y, z, r) and `rc1_flag` (1: the rail loops) | the same; pack sets each point's fourth float to the length to the next point, as the game needs |

Light zones: the game takes the first zone, in the order of the nodes, whose circle (`rc1_reach` round the box's middle, across x and y; left out, the circle that holds the box) holds the hero, and lights him from it only if he is inside its box too; else he keeps the light he had. Put small zones before the big ones round them, and give every place the hero can reach a zone. The game applies them to the hero only; other mobys keep their own `rc1_colour` and `rc1_light`.

`rc1_background` is the colour the game clears the frame to before it draws the sky (SetBackgroundColor). It is not a sky tint: it shows only where the sky's shells leave gaps or are see-through. In 15 of the 19 levels the sky's first shell is an opaque dome coloured per vertex (Novalis, Kerwan, Pokitaru and most others), which hides the background completely; there the sky's colour is that dome's, part of the sky model. The background shows in Rilgar and Umbris, and below the horizon in Orxon and Quartu. `rc1_background` and `rc1_fog_colour` take red, green and blue from 0 to 255. The editor's sky panorama is baked over the background when the level is extracted, so an edit shows in the game, not in the editor's sky until the next extraction.

On a moby, camera or sound with a pvar block (its class's private
Expand Down
4 changes: 2 additions & 2 deletions openrac/project/rc1/check.gd
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ extends SceneTree
# =============================================================================

## The nodes under Game that hold the gameplay data (editor/gamedata.py's GROUPS).
const GAMEPLAY: Array[String] = ["LevelSettings", "MobyGroups", "Cameras", "Sounds", "Volumes", "Paths",
"GrindPaths"]
const GAMEPLAY: Array[String] = ["LevelSettings", "LightSets", "LightZones", "MobyGroups", "Cameras", "Sounds",
"Volumes", "Paths", "GrindPaths"]

# =============================================================================
# METHODS
Expand Down
6 changes: 3 additions & 3 deletions openrac/tools/carry.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
instance of, after the level's mobys.

What is not carried, and listed so the player can redo it: edits of cameras, volumes, sounds,
paths, grind paths, moby groups and level settings; ties and shrubs; the level's collision and
the moby classes' collision; imported static models. Matching a moby of the old project to the
paths, grind paths, moby groups, level settings, light sets and light zones; ties and shrubs; the
level's collision and the moby classes' collision; imported static models. Matching a moby of the old project to the
fresh one is by its place in the level's table when both tables list the same classes in the same
order (true of the two gameplay copies of every PAL level), else by class and spawn number.

Expand Down Expand Up @@ -50,7 +50,7 @@
# What the report calls each kind of node that is not carried.
KINDS = (("Game/Cameras", "cameras"), ("Game/Sounds", "sounds"), ("Game/Volumes", "volumes"),
("Game/Paths", "paths"), ("Game/GrindPaths", "grind paths"), ("Game/LevelSettings", "level settings"),
("Game/MobyGroups", "moby groups"))
("Game/MobyGroups", "moby groups"), ("Game/LightSets", "light sets"), ("Game/LightZones", "light zones"))


class Block:
Expand Down
Loading
Loading