How to respawn pickups after repositioning of floor?

I am trying an Endless Runner (Side Scroller Game). I’m creating x number of floors, when user pass current floor, I’m re-positioning current floor to the end of last floor.

Floor contains Obstacles (Rock) and Coin, which randomly spawn, either Rock or Coin.

But since I’m re-positioning floor. If I pass current floor and collect all coins I won’t see coins again. How can I reset it?

I can Destroy and Spawn floor again and again. But somebody told me that it is not good approach. So can anybody tell me how do I re-spawn coins again after re-positioning of floor?

Update: I want to spawn multiple Obstacles but one at a . And multiple pickups at different location on floor.
Spawning is 2nd step. First I want to destroy child actor (rock/pickups). How can I do it?

Are the Coins part of the floor blueprint? If not, just call the function that was originally used to spawn them again.

Part of floor.

Is there a specific reason for that? Why not make them their own blueprint?

Ohh Sorry Sorry misunderstood. There is Separate Blueprint called BP_Coin which I’m calling inside Construction Script of BP_Floor.

When I call BP_Floor, it call BP_Coin as well in background.

Hi

You could set it up that after going through the trigger point, wait 2 secs, destroy all the old ones (If any left) and then spawn more.

I just added “Spawn Pickups” function in the end of “End Trigger” event.
It can spawn Pickups but now these appears with Obstacles (Rock) as well. o.O

How to solve this new problem? I want to spawn either Rock or Pickups.

They are 2 different functions.

Are you dealing with these differently?

Yep.

In construction script I’m randomly calling either Rock or Pickup via two different functions. When character collect Pickups, I can call function to respawn coins. But then pickups also spawn on Obstacle/Rock Floor.

How to destroy Child Actors?