Let actors Appear and Disappear ( Spawn )

Hey everyone,

I’m making a Horror Game.

I want that the Player pick ups a collectable (Picture 1) and then a big version of it spawns in the end of the hallway (Picture 2). In the middle of the hallway is a Triggerbox with a Jumpscare (Picture 3).

I want that those two components (2&3) only get placed (Or activated) when Player collected the first component.

And then let 2&3 Actor get destroyed.

Thank you! :slight_smile:

Picture 1 & Collectable Blueprint


Picture 2

Picture 3

Picture 4 - Level Blueprint

Inside your TriggerBoxBP, add a variable “CollectMesh” of type Actor.

Inside your CollectableBP(or child bp) , create a custom event such as “Collect”, that event will spawn your mesh at x location and spawn your triggerbox at x location. Then wiith the triggerbox, set the variable of your mesh to the "CollectMesh ".

When the player overlap CollectableBP, you can call Collect.

In your triggerboxBP, you can use an OverlapEvent with a delay that will destroy your CollectMesh.

Thank you for your fast reply!

I’m gonna try that out but first i wanted to ask you if you know how to manage the multicast on the Collectable?

Only the Player who runs the server can pick it up.

When the Server runned player picks it up, the player 2 sees that it got picked up, but he cannot pick it up himself.

The TriggerBox doesnt have a Blueprint yet, should i convert it to one?

Yes it should be easier to manage the workflow making it own bp, but you can change it to a simpler or dynamic one (with interface, reuse etc…) after everything workout :innocent:

For the multiplayer, am not well experienced on that sadly, but should be something like Host/Authority can call event “Collect” but not client, and the visibility is for everyone.

The BP_TriggerBox

The BP_Collectible

and the collision sphere when the player hit that sphere:

Note that Actor are like living things in the memory, for example, your asset file BP_SkinnyMan in your content browser are classes, when you place/spawn that bp in the level map, it become an actor and we can have many instance of that same bp, that why we need to keep a variable reference to exactly this one.

Sorry for the late response, i bought an interaction system from the Marketplace and had it solve with that!

But thank you very much for the solution! I appreciate it :slight_smile:

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.