Announcement

Collapse
No announcement yet.

Keep a persistent BP across all levels?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Keep a persistent BP across all levels?

    How can I have a persistent BP across all levels? I set up a bunch of things in the playerController that's used as default in my start screen, which is a map. This playerController gets killed as soon as the first level loads, and it'd be a hassle to load everything, store local data, re-initialize this main menu playerController at the start of each level.

    I don't want the main menu PC to always be the actually used PC in-game either.

    I hear you can create a persistent level, which led me to instructions telling me one had to activate world composition - which seems to have to do with streaming levels and managing large maps. My levels are pretty tiny so it seems hacky and I'm thinking there might be another way.

    Looking in window - levels show whatever map I have loaded as the persistent map, which has something to do with the above I'm guessing.

    It'd be great to just be able to hit something like a 'make blueprint persistent', and make that blueprint accessible at all times.

    I'm sure there's an easy and logical solution, I just can't find it.

    Thanks.

    #2
    In your project settings under maps and modes, you can specify a game instance blueprint. Game instance persists for the life of the game, so you can use it to store variables you need to persist through the game. You can create a game instance blueprint just like any other; just search for game instance when choosing a class.
    iTween For UE4
    Procedural pathed animation for actors, components & UMG - $0
    Runtime DataTable
    DataTables dynamically loaded from text or Google Sheets while your game is running!
    easyCSV
    Fast, cheap, and accurate CSV parsing at runtime!

    Comment


      #3
      Awesome. I haven't tried it yet but that seems to be just what the doctor ordered.

      Big thanks!

      Comment

      Working...
      X