Skip to content

Examples — Wall Plugin

Examples

The plugin ships with a test map and a set of example Blueprints to demonstrate the core workflows.


Included example assets

AssetDescription
PlaceableWall_BPThe base Blueprint wall actor. Place this in any level or spawn it at runtime. Extends AWallLineActor.
Window_BPExample window reveal. A rectangular window opening with a frame mesh.
Door_BPExample door reveal. A door-shaped opening with a frame mesh.
PluginExampleController_BPExample player controller demonstrating the runtime placement workflow, including reveal dragging. Used in the test map.

Test map

The plugin includes one test map that demonstrates:

  • Multiple connected walls forming room layouts
  • Walls with doors and windows registered
  • Runtime wall placement via PluginExampleController_BP
  • Example walls with different reveal shapes (rectangular, and custom shapes such as circular and star-shaped openings)

Example: Editor wall placement

See Build Mode for a complete walkthrough of:

  • Placing walls by clicking in the viewport
  • Setting height and width
  • Using grid snap
  • Painting wall surfaces from the editor

Example: Runtime wall placement (player-controlled)

The general runtime workflow:

  1. Line-trace from the camera to find the floor position.
  2. Spawn PlaceableWall_BP at the start point.
  3. Each tick: call Set Start And End and Construct Wall to follow the cursor.
  4. On confirm (second click): call Construct Wall and Positioning Finalised.
  5. Check for neighboring walls, set neighbor references, call Construct Wall on neighbors.

See Wall Placement for the full Blueprint workflow.


Example: Runtime reveal dragging

From the PluginExampleController_BP behavior (described in official documentation):

  1. Press Play in the example map.
  2. Click on an existing reveal actor (door or window).
  3. Move the cursor to a different position on the same or another wall.
  4. The reveal snaps to the wall’s surface and updates the hole.

This demonstrates Setup Yourself and Register Reveal / Un Register Reveal being called at runtime.

See Doors and Windows for the Blueprint implementation.


Example: Custom reveal shape

The official documentation describes creating a custom reveal texture in Blender:

  1. Create a plane in Blender with a boolean cutout in the desired shape.
  2. Bake the result to a texture where the hole area is white.
  3. Import into Unreal Engine as a Texture2D.
  4. In a Blueprint child of ARevealBase, override Draw Your Reveal Form and draw the texture onto the canvas at PosOnTexture.

See Doors and Windows – Creating a custom reveal shape.


Example: Saving and loading walls at runtime

// Save
GetWorldSubsystem<UWallGameSubsystem> -> Save Walls
Slot Name: "" ← uses default slot (map name)
User Index: 0
// Load
// Register a Blueprint that implements IWallLoadListener
GetWorldSubsystem<UWallGameSubsystem> -> Register Wall Load Listener (self)
GetWorldSubsystem<UWallGameSubsystem> -> Load Walls
Slot Name: ""
User Index: 0
// In OnWallLinesLoaded(Lines):
// For each line in Lines:
// Spawn PlaceableWall_BP
// Call possess_basic_line(line)

See also the editor panel’s Save Walls and Load Walls buttons in Build Mode.