Skip to content

Grid Placement v6.0

Advanced Setup

Manual host/session wiring, per-controller registration, terrain painting, manipulation, and refunds.

Status
Current
Version
v6.0
Source updated
Active v6.0 guide line from Grid Placement repo
Generated on
2026-09-01

Use this after Getting Started when the starter templates no longer fit your integration.

Manual host/session setup

For a code-built single-player scene, configure the host with one PlacementSession:

host.configure(session)

For controller-specific sessions:

host.register_session(controller_node, session, device_id)

Unregister the controller/session when its owning scene/controller leaves.

Keep one session per independent player/controller interaction. Do not share a session accidentally between players that need different selection, targeting, coordinate mode, or pending manipulation state.

Composition

The host routes interaction through services composed from the active session/configuration. Game-owned scene/world facts enter through the documented context/provider surfaces.

Prefer the shipped templates for normal editor composition. Hand-wire services only when you have a concrete integration need; see Composition & Injection.

2D terrain painting

Terrain painting applies to TileMapLayer.

Start with one terrain entry and SINGLE, then add:

  • LINE
  • RECTANGLE_FILL
  • RECTANGLE_OUTLINE
  • FLOOD_FILL

TerrainPreview owns the preview-layer plumbing. Do not mutate the real TileMapLayer during preview.

See Surface & Brush Reference.

3D GRID and SMOOTH

For 3D object placement:

  1. configure the 3D target surface/context;
  2. prove one GRID CELL object;
  3. add footprints/yaw/support rules;
  4. add EDGE/FACE mounts for modular structures;
  5. add SMOOTH only for entries/workflows that need free placement;
  6. configure slope/support or physics-required behavior only when your world needs it.

Do not use this path for 3D terrain editing; it is not a 6.0 feature.

See 3D Object Placement.

Manipulation

A placed object must opt into the operations it supports through the manipulation components/settings.

Keep manipulation inside the plugin lifecycle so move/rotate/remove keeps transform, occupancy/mount state, placement identity, and persistence consistent.

Refunds

Demolish refunds are optional. Connect the refund service to your game's id-keyed inventory/economy bridge and choose the refund ratio/policy there.

The demo inventory is an example, not a required production inventory architecture.

See Refund on Demolish.

Multiple players/controllers

Each controller should own an independent PlacementSession while sessions in the same placement world share authoritative committed placement/occupancy.

This gives you independent selection/preview/action state without allowing two players to occupy the same world position/mount incorrectly.

See Multiplayer & Split-Screen.

Game-owned policy

Keep these outside the addon unless they are genuinely reusable placement mechanics:

  • faction/ownership rules;
  • construction progress;
  • resource economy;
  • quest/progression logic;
  • pathfinding/vision consequences;
  • game-specific save schema.

Feed the relevant facts into Grid Placement and consume typed placement results rather than duplicating placement authority.