Chris' Tutorials
Docs/Grid Placement

Class

WithinTilemapBoundsRule

Generated GDScript class reference for GridPlacement.WithinTilemapBoundsRule.

StatusDraft
Versionv6.0
UpdatedDevelopment docs generated from GDScript source

This is unreleased documentation in active development. APIs, class names, and behavior may change before the final release.

Draft — Unreleased:This page is in active development. APIs, class names, and behavior may change before the release is finalized. Use it as a preview of what's coming — not as a stable integration target.

A rule that validates placement is within the boundaries of a tilemap. This rule works by checking if a tile exists at a proposed placement position on the target TileMapLayer. It ensures that a player or system cannot place objects in empty, unmapped areas of the scene. Behavior:

  • The rule passes if every indicator is positioned over a cell that has an assigned TileData object on the target map.
  • The rule fails if any indicator is over a cell that returns null for TileData, indicating that the cell is outside of the mapped region. Usage:
  • Attach this rule to a PlacementContainer for context wide injection OR a ScenePlacementEntry for placeable specific rule evaluation
  • The GridTargetingState must provide a valid TileMapLayer for the rule to check against.

Source: addons/grid_placement/placement/placement_rules/template_rules/within_tilemap_bounds_rule.gd

Syntax

class WithinTilemapBoundsRule extends TileCheckRule

Members

NameKindSummary
success_messagePropertySuccess message for valid placement.
failed_messagePropertyFailure message for out-of-bounds placement.
no_indicators_messageProperty
enable_debug_diagnosticsPropertyOptional: enable extra per-indicator diagnostics during tile lookups (very verbose)
NON_CRITICAL_ISSUE_KEYWORDSFieldIssue keywords considered non-critical for bounds checking (cosmetic/setup)
setupMethod
tear_downMethod
validate_placementMethod
failing_indicatorsProperty
get_failing_indicatorsMethod
failing_indicatorsProperty
target_mapProperty
resultsProperty
resultsProperty
indicator_issuesProperty
critical_issuesProperty
local_posProperty
tile_underProperty
cell_dataProperty
criticalProperty

Source

addons/grid_placement/placement/placement_rules/template_rules/within_tilemap_bounds_rule.gd

Plugin docs root:gdscript/plugins/grid_placement_dev/docs