Level Blueprints can no longer make any Multicast calls with any parameters in 4.16. Doing so will crash the engine in the following way:
Steps to reproduce from Blank Project:
1: Create a new empty 4.16 project with 2 levels. Call them LevelA and LevelB.
2: In LevelA, create a level blueprint that calls a reliable Multicast elsewhere in the same Level Blueprint. Make sure the Multicast has a parameter.
3: Enable Seamless Travel (Subclass the GameMode with a TestGameMode class with Seamless travel set to True. Make sure the Maps & Modes in the project settings are set to use your new custom game mode).
TO REPRODUCE CRASH:
- Package this project
- On the server computer run console command: open LevelB?listen
- Have a remote client connect and join the game (i.e. open the IP address of the server)
- With the remote client connected, go back to your server computer use the console command: Servertravel LevelA
- Trigger the multicast call in the LevelA’s Level blueprint (in the example above, you press ‘H’). At this point LevelA is now ticking time-bomb ready to crash the engine.
- ServerTravel back to LevelB
- ServerTravel back to LevelA
If the multicast call was made on the server in the Level Blueprint (step 5), it should now hard-crash to desktop with the following error in the Log:
[206]LogWindows:Error: === Critical error: ===
[206]LogWindows:Error:
[206]LogWindows:Error: Fatal error: [File:D:\Build\++UE4+Release-4.16+Compile\Sync\Engine\Source\Runtime\CoreUObject\Private\Serialization\AsyncLoading.cpp] [Line: 5431]
[206]LogWindows:Error: Package /Game/LevelA was reloaded before it even closed the linker from a previous load. Seems like a waste of time eh?
Note:
- For the crash to occur, the Multicast
must have a parameter. The data-type
of the parameter doesn’t seem to
matter, and it doesn’t matter if you
actually use it. - There must be at least 1 remote client connected for the bug to present itself
- It doesn’t seem to matter what the multicast actually does (I just put debug text there to highlight the next point:)
It Gets Worse: Level Streaming Also Broken
This exact same issue also breaks Level Streaming, but in different, weird way: For example, in the case above you could Stream in LevelA (through blueprint nodes), trigger the multicast, unload LevelA, and then stream in LevelA again. Rather than crashing this time, a rather bizarre broken state is reached: LevelA will stream-in just fine, but all direct references to objects in the Level Blueprint (like the PlayerStart) in the example above will fail. The log will be filled with Warnings that it failed to find these objects, and all scripts will treat these objects as though they are all replaced with None. In most cases, this basically renders the Level Blueprint completely useless as it will fail to obtain a proper reference to any object in the Level. This almost deserves its own separate bug report to fully explain, but the cause is exactly the same, so it’s likely the same Engine bug just manifesting in a new way.
Related:
It’s possible this bug is the root cause of (or perhaps related to) a few other issues people have reported
[here][3] or
[here][4] or maybe even [here][5]
Sadly, my multiplayer game uses a lot of Level-streaming and Seamless ServerTravel. We’re having to hunt down and rip out any Level Blueprints that have a Multicast call with a parameter, and move them into replicated dummy actors. Needless to say, it’s kind of a disaster.