Download

Changing/shifting rooms while playing

So is it possible to change a room while playing. So when you go into a room and when you turn around the room changed. For example in Layers of Fear. The player enters a room, turns around, room changes (e.g door moved), player turns again, room changes again.

Thank you in advance

Yes, possible and not too difficult.

You can do this using Blueprints.

  1. make an empty BluePrint set the class as actor
  2. Select the static mesh you want to move in the content browser
  3. With the mesh selected, click that big green +Add Component button in the BluePrint
  4. Go to the event graph, right click and type custom event, select add a custom event, give the event a meaningful name
  5. Drag out a reference to the static mesh onto the graph, (It will be in the top left corner just click and drag it out)
  6. Drag a wire off the mesh reference and create a setworldlocation node.
  7. Type in the coordinates for the new location where it says “New Location”
  8. Connect a wire from the custom event node to the SetWorldLocation Node

It should look something like this:
61a8c04c8ee498638bddc0186d4bb6aab5d4e43c.png

Once that is all setup, you just need to figure out what will be the trigger to call that custom event

You can put box triggers into the room that fire off custom events based on the player colliding with them
or a more elaborate solution from within the players Blue print that determines if he is in the room, and what direction he is facing.

Thank you so much.

Really helped me out !

Strange enough I was looking for this exact concept but all I found was rather unhelpful videos on how to change levels via Blueprint… could you make a video on how to do it? I know it’s a lot to ask from you! Thanks, Tasten: Liquid Stone - JDSweet