Specialized ManipulationData for the DEMOLISH action. Carries a live Manipulatable reference for pre-destroy inspection and exposes a veto() hook that listeners can call from the ManipulationState.pre_demolish callback to cancel the demolition. The base ManipulationData.target is also populated (it was historically null on the demolish path) so existing consumers that walk the data shape don't have to special-case demolish. Lifecycle (5.1.0-C): try_demolish: status = STARTED emit pre_demolish(data) # listeners may call data.veto() if data.vetoed: status = CANCELED return root.queue_free() status = FINISHED
Source: addons/grid_placement/systems/manipulation/manipulation_data_demolish.gd
Syntax
class DemolishData extends ManipulationDataMembers
| Name | Kind | Summary |
|---|---|---|
demolish_target | Property | Live Manipulatable that will be destroyed if no listener vetoes. This is the same reference that flows through ManipulationData.source but exposed explicitly on the demolish data so listeners can read it without walking the data shape. |
Tutorials built on Grid Placement
- Godot multiplayer grid placement: one host, four sessions
- Godot 2D grid building system: paint, place, save
- Godot 3D grid building system: the runtime loop
- Godot 4 grid-building plugins: build mode vs editor tools
- 3D room placement in Godot: build rooms and stack storeys
- 3D grid placement in Godot 4: full setup tutorial
- Snap to a TileMap in Godot: 2D grid placement
- How to make a farming system in Godot
- How to snap objects to a 3D grid in Godot