Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Level Blueprint and GameMode aren't working after a level change

I have a blank level i'm using as a placeholder menu level. In it i have a button event in the level blueprint to call ServerTravel(TestMap?Listen) from my custom GameMode TestGameMode_Menu in c++. The new level (TestMap) uses another GameMode called TestGameMode (when i switch levels in the editor the world setting gamemode are showing the correct ones) in which I have a begin play event that prints to the screen "new level loaded" in the level blueprint.

Everything works fine when I PIE, but when I click launch and run the game everything works for the blank level but when the new level loads the level blueprint isn't calling the begin play event.

I also have debug to screen calls in the PostLogin and BeginPlay functions in the TestGameMode which aren't getting called and debug calls in the TestGameMode_Menu are getting called again, but get called correctly when I PIE but not when i play through launch.

Any help would be appreciated.

Product Version: Not Selected
more ▼

asked Aug 08 '14 at 04:28 AM in Blueprint Scripting

avatar image

203 24 21 29

avatar image Ben Halliday STAFF Sep 09 '14 at 09:17 PM

Hey falola,

Are you still experiencing this issue? Have you upgraded your project to 4.4? If so, is this a code-based project or one built from source? If you use a GameMode created solely in the editor and use that instead of the custom GameMode you created, does the same thing happen?

avatar image falola Sep 09 '14 at 11:01 PM

I upgraded to 4.4 and its a code based. I gave up on trying to get it working in 4.3 but i'll revisit it now. I haven't tried to create a game mode in the editor yet but I will and get back to you as soon as I can.

avatar image falola Sep 10 '14 at 01:20 AM

It looks like the following code (located in my game mode code) isn't working when i try it from launch it just sits there and doesn't load the level:


Neither will calling OpenLevel with ?Listen in the options.

Calling the function / blueprint node from my level blueprint HandleMatchIsWaitingToStart is getting triggered though. This only happens in launch, everything works fine when i PIE

(comments are locked)
10|2000 characters needed characters left

3 answers: sort voted first

Ok so after further digging around I found the play game standalone which is what i needed and there the level loading and game mode works as intended. I also packaged the game and everything is working correctly So its only Launch which from what i read is meant to be used for mobile devices so i was using it wrong.

more ▼

answered Sep 11 '14 at 01:04 AM

avatar image

203 24 21 29

(comments are locked)
10|2000 characters needed characters left

Level blueprint will run with level, so if you change level it will run a blueprint of new level, and for the gamemode it will persist when it run whatever level you change unless you change the gamemode.

more ▼

answered Aug 08 '14 at 05:42 AM

avatar image

Duncan Dam
3k 121 50 164

avatar image falola Aug 08 '14 at 05:49 AM

I know, but that's not the behavior i'm seeing. When I load the new level the new level's level blueprint is not running nor is the new level's new game mode when i play the game going through the launch button. It only works when i PIE

(comments are locked)
10|2000 characters needed characters left

I have found PIE/launch doesn't consistently handle servertravel very well, and often behaves differently than a built exe or packaged game, so I would test all of your inter-level functionality that way.

Possibly unrelated, since you seem to have resolved your issue, I've also found that at least when using seamless travel, you can't guarantee that the level blueprint's Begin Play will get hit after the GameMode or PlayerControllers are initialized, so any functionality you have that's dependent on those won't work. See my question here.

more ▼

answered Sep 24 '14 at 12:03 PM

avatar image

21 2 6 7

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question