Class ScenePlacementEntry
- Namespace
- GridPlacement.GDScript
- Assembly
- MoonBark.GridPlacement.GDScript.dll
Placement entry for instancing scene objects into the game world.\n\nCarries a [member packed_scene] plus object-specific tool/rule overrides. The canonical replacement for [Placeable] (which is kept as a deprecated alias through 6.0 and removed in 6.1).
class ScenePlacementEntry extends PlacementEntry
Fields
UID
const UID = "uid"
FILE_PATH
const FILE_PATH = "file_path"
Properties
display_name
Display name for in-game reading.
@export var display_name: StringName
packed_scene
Scene to instance when placed.
@export var packed_scene: PackedScene
profiles
Placement profiles for grouping entries with shared behavior. Profiles carry their own [member PlacementProfile.placement_rules] and [member PlacementProfile.supported_object_tools] that layer into the three-tier rule/tool resolution.
@export var profiles: Array[PlacementProfile]
tool_override_mode
How this entry's [member tool_overrides] interact with its profiles' [member PlacementProfile.supported_object_tools]. See [enum ToolOverrideMode].
@export var tool_override_mode: PlacementEnums.ToolOverrideMode = PlacementEnums.ToolOverrideMode.INHERIT
tool_overrides
Tools added or removed depending on [member tool_override_mode]. - [enum INHERIT]: ignored (profiles provide the full list) - [enum REPLACE]: this list IS the full tool set - [enum ADD]: these are unioned with profile tools - [enum REMOVE]: these are subtracted from profile tools
@export var tool_overrides: Array[PlacementEnums.ObjectTool] = []
costs
var costs: Dictionary[StringName, int] = {}
dictionary
var dictionary = {
entry
var entry: ScenePlacementEntry
uid_str
var uid_str: String = p_load_data[Names.UID]
uid_int
var uid_int: int = ResourceUID.text_to_id(uid_str)
file_path
var file_path = p_load_data[Names.FILE_PATH]
tools
var tools: Array
issues
var issues: Array[String] = []
valid_rule_count
var valid_rule_count = 0
issues
var issues: Array[String] = []
valid_rule_count
var valid_rule_count = 0
Methods
get_build_costs
func get_build_costs() -> Dictionary[StringName, int]:
Returns
get_display_name
func get_display_name() -> StringName:
Returns
get_load_data
func get_load_data(p_include_uid: bool) -> Dictionary:
Parameters
p_include_uid
Returns
load_resource
static func load_resource(p_load_data: Dictionary) -> ScenePlacementEntry:
Parameters
p_load_data
Returns
get_packed_root_name
func get_packed_root_name() -> StringName:
Returns
resolve_object_tools
func resolve_object_tools() -> Array:
Returns
get_editor_issues
func get_editor_issues() -> Array[String]:
Returns
get_runtime_issues
func get_runtime_issues() -> Array[String]: