Skip to main content
This page gives practical examples of how to use the Respawn Manager in common gameplay scenarios:
  • Resource nodes (trees, rocks, ore)
  • Loot chests
  • Foliage-based harvestables
  • Enemy spawners
  • Traps / destructibles
Use these as templates and adapt to your own systems.

1. Resource Node — Tree (Blueprint)

A classic “harvest → wait → regrow” pattern.

Setup

Blueprint: BP_TreeNode
  • Components:
    • StaticMesh (TreeMesh)
    • LootComponent (optional, for logs, sticks, sap)
  • Variables:
    • RespawnTime (float, e.g. 300.0)
    • bHasBeenHarvested (bool)
Implements BPI_Respawnable.

On Harvest (Blueprint)


On Respawn (Blueprint)

That’s a full, renewable tree node.

2. Resource Node — Ore Vein (C++)

Source


3. Respawnable Loot Chest (Blueprint)

Chest that refills over time.

Setup

Blueprint: BP_RespawnChest
  • Components:
    • StaticMesh (ChestMesh)
    • LootComponent
  • Variables:
    • RespawnTime
    • bIsOpen (bool)
Implements BPI_Respawnable.

On Chest Opened (Blueprint)


On Respawn (Blueprint)

This gives you a camp/world chest that periodically refills.

4. Foliage Harvest (Instance-Based) + Respawn (C++ Pseudocode)

For truly instanced foliage via UHierarchicalInstancedStaticMeshComponent:

On Harvest (C++ Pseudocode in FoliageInteractionManager)

On Foliage Respawn (called by Respawn Manager)

This keeps foliage purely instanced, with Respawn Manager only scheduling when instances come back.

5. Enemy Spawner with Respawn Manager (C++)

Spawner uses Respawn Manager, enemy uses LootComponent.

Spawner Header

Spawner Source

Enemy Death (simplified)

This cleanly separates:
  • LootComponent → what drops
  • Respawn Manager + Spawner → when a new enemy appears

6. Trap / Destructible with Cooldown (Blueprint)

Example: a spike trap that fires, disables, then resets after a delay.

Setup

Blueprint: BP_SpikeTrap
  • Components:
    • Mesh, Collision, maybe a skeletal mesh for animation
  • Variables:
    • RespawnTime
    • bIsActive
Implements BPI_Respawnable.

When Triggered

On Respawn (Reset)

Now the trap behaves like any other timed game element.

7. Quick Checklist for Implementations

When you create a new respawnable:
  1. Decide: Actor-based or foliage-instance based?
  2. Implement “inactive” state (hidden, no collision, no interaction)
  3. On “used/harvested/depleted”:
    • Do your game logic (loot / damage / destruction)
    • Call RegisterRespawnRequest on the manager
  4. Implement OnRespawnRequested (via interface or Blueprint event):
    • Reset flags
    • Reset loot / state
    • Re-enable visuals, collision, interaction
If you follow that pattern everywhere, everything that “comes back later” in your game will feel consistent and be easy to tune.