English | French version
Every generated map root receives a Generated Map Info (GeneratedMapInfo)
component. Select that root in the Hierarchy, or click Select Map Information
below the generator's generation button.
The component stores the information for the visible map. Changing the generator's
recipe does not change this snapshot. Regenerate to capture new settings.
- Final seed, biome and optional biome preset, procedural/image generation mode.
- Map size, cell size, requested player count and generated start count.
- Player-start symmetry and effective full-map symmetry.
- Water layout, forest and mountain zones, plateaus, bridges and altitude settings.
- Whether optional Minimap and Aerial outputs were enabled.
- Gameplay score when available, generation diagnostics and strategic locations.
Settings are read-only in this Inspector. The saved biome preset is an asset
reference; the component does not duplicate the preset, the complete generation
recipe or the logical grid. Continue to save recipes through the generator when
you need to reproduce or edit a map.
Strategic markers
Enable Show Gizmos to draw the map's locations. Show Labels adds their short
identifiers. Both switches are saved with the map; regeneration retains their
values. Unity's global Gizmos switch in the Scene view must also be enabled.
| Label |
Location |
Shape |
P |
Player start |
Green sphere |
N |
Natural expansion |
Yellow sphere |
E |
Other player expansion |
Yellow sphere |
CE |
Contested expansion |
Yellow wire sphere |
CP |
Choke point |
Red cube |
The Inspector lists counts and, under Positions (map local space), the captured
positions and known player owners. Positions include the generated terrain/water
height and follow the map root when moved, rotated or reparented. These are
Editor markers; they do not add rendered objects or gameplay colliders.
Saving and runtime access
The information and marker positions are serialized on the generated root, so
they remain after saving/reloading the scene. If you remove the generator object,
first move the generated map out of its hierarchy to retain the map itself.
if (generator.TryGenerateRuntimeMap(out var result))
{
GeneratedMapInfo info = result.MapInformation;
Debug.Log($"Seed: {info.Seed}, biome: {info.Biome}");
foreach (GeneratedMapMarker marker in info.Markers)
Debug.Log($"{marker.Label}: {info.GetWorldPosition(marker)}");
}
You can also use mapRoot.GetComponent<GeneratedMapInfo>() without keeping a
reference to the generator. The component has no dependency on the generator
remaining in the scene or on an Editor/MCP connection.
Previews and older scenes
A failed generation can leave a Preview only map. Its information describes
the retained geometry and shows the diagnostics. A retained previous map keeps
its original seed and markers; it does not inherit the failed attempt's settings.
An emergency terrain preview cannot provide a reliable generation snapshot.
Always check result.Succeeded before treating output as a validated gameplay map.
For a map saved before this component existed, Restore Map Information (legacy
map) on the generator transfers its saved gizmo positions to the root. The
original seed/settings and the natural/other expansion distinction cannot be
reliably recovered from those positions. The Inspector identifies this state;
regenerate once to capture complete information. The generator no longer draws
these markers itself.