add_foliage_instances
Place foliage instances of a UFoliageType at explicit transforms in the level's InstancedFoliageActor. Warning: this path can crash the editor; use instanced static mesh components instead.
Instructions
Place foliage instances of a UFoliageType at explicit transforms in the level's InstancedFoliageActor. DANGER: measured CRASHING the editor process (access violation inside UnrealEditor-FoliageEdit.dll) -- reproducibly, and a single instance crashes just like a thousand, so trimming the count does not help. The reply you see is a "Connection reset", which reads like a network hiccup and is not. Use add_instanced_static_mesh_component + add_ism_instance instead: an InstancedFoliageActor is itself an actor holding instanced-static-mesh components, so it is the same code path minus the crash. Save your work before calling this at all.
Returns: { foliage_type_path: string, foliage_type: string, requested: int, instances_added: int, instance_count_before: int, instance_count: int, placed_instance_count: int, instances_added_ok: bool, foliage_actor: string }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| transforms | Yes | List of [x,y,z] locations or objects with location, rotation, scale | |
| foliage_type_path | Yes | Full path of the UFoliageType asset |