No announcement yet.

Going from Map 1 to Map 2 then back to Map 1

  • Filter
  • Time
  • Show
Clear All
new posts

    Going from Map 1 to Map 2 then back to Map 1

    Hello Unreal Community ,
    I'm building a couple of scenes that I would like to play back to back in Virtual Reality. (Beginner in Unreal FYI).
    I'm trying to figure out the following in blueprints:
    Play Map 1.
    Pauses 30 seconds in on Map 1.
    Jumps and plays Map 2.
    Map 2 ends and goes back to Map 1 where it was paused.

    The following is so far the blueprints for MAP 2 that I figured out. I know how to play Map 1 then to Map 2, but once going to Map 1 it resets event and I would like it to start Map 1 (30 seconds in).
    Any help would be appreciated. I hope this all makes sense.

    Not sure if this is the best solution, but this is just off the top of my head.

    You need to use savegame

    When switching to map 2 you will need to save information about your level that you can load up once you switch back from level 2 to level 1.

    Decide what information is important to save. Not sure what you need to save since i have no context for your game, but for example you might need to save Actor transforms, health, points, etc.

    like i said you will know better than I will what info you need to save. Take a look at savegame and see what you can figure out.
    Last edited by beanswaggle; 04-30-2018, 05:53 PM.


      The way I would do this is add a vector variable to my game instance and call it lastLocation. So before traveling to map 2 I'd store the player location into the lastLocation in the gameinstance.

      Now on my map 1 begin play event I'd check if my lastLocation isn't 0,0,0 (that is if the character can't switch maps from 0,0,0.). So if lastLocation isnt 0,0,0 that means it's not a new game and should set my character location to lastLocation.

      The key here is gameinstance. You should search it up on YouTube or Google if you don't know what it is.
      Checkout Project "TwinBlaster" my current game in progress.
      [FREE] - 2D ROPE! Find out more here!
      Forgive my username... It's an old game name and wrote it down as a habit.