x

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"

Streaming Level not loaded in replay

Hello,

I'm trying to implement a Replay System in my game. My game is composed of 1 level with 4 sublevels. at the beginning of the game I use Load Stream Level in the Persistent Level Blueprint to Preload the sublevels and later on with a Multicast Event I get the streaming level I want to show and Set "Should Be visible" to true.

When I'm recording I see the levels show/Hide but when I replay I only see the movement of my Pawn. Is there any solution for loading the sublevels in runtime while replaying ?

PS: If you need more details I can provide some.

Product Version: UE 4.18
Tags:
more ▼

asked May 01 '18 at 04:15 PM in Blueprint Scripting

avatar image

ttdburnout
1 1 7

avatar image ttdburnout May 02 '18 at 05:00 PM

To reproduce this bug:

  • Have a Persistent Level with 4 SubLevels, all sublevels streaming method must be blueprint and by default they must not be loaded/visible

  • In the Persistent Level Blueprint, at Begin Play, Use "Load Stream Level" for 1 sublevel and set Make Visible After Load to True

  • Add a Has Authority node, on authority , Use "Load Stream Level" again for the 3 other sublevels but don't check Make Visible After Load. don't load stream level if remote

  • Create an Actor that has an Event Dispatcher that is called when you press H and you have authority, then place this actor in the Persistent Level

  • Back in the Persistent Level Blueprint after the 3 Load Stream Level (and still in has authority) Bind a Custom Event (no replication) to the Previously Placed Actor's Event Dispatcher, don't do it for remote

  • In this custom event call a Multicast Event that get the first Streaming Level and set Should Be Visible/ Should be Loaded (both) to false, tehn get the Second Streaming Level and Set Should Be Visible/ Should be Loaded (both) to true.

  • Package the game

  • Play, start demorec

  • Move around and Press H to load the second sublevel, in the game the levels should have switch, Move some more before next step

  • demostop

  • demoplay

  • Expected : The first sublevel disapear while the second Appear in replay

  • What realy Happens : The first level is still here and the Second is hidden But I can still see my Pawn moving like in the record

PS: if you use ?listen and connect an other player to the game both player will see the levels switching. The problem only occur while replaying a recorded demo

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Okay, figured out a way to trick the game (Not an actual fix, just a workaround)

I created a GameInstance c++ file following the Replay System Tutorial (https://wiki.unrealengine.com/Replay_System_Tutorial) and I added a bool IsReplay Accessible in Blueprint, when ever I do a Has Authority node I check if I'm in replay and if this is the case I byPass it and execute the code that should only be executed by the Authority path, so that the DemoNetDriver can show/hide the levels.

I think the problem come from the Multicast not being received by the DemoNetDriver.

more ▼

answered May 02 '18 at 08:12 PM

avatar image

ttdburnout
1 1 7

avatar image 三尺剑 Jun 06 '18 at 07:07 AM

Hi,I have a same problem as yours,could you tell me the detailed solution.How to make the DemoNetDriver show the sub levels?Thank you!

avatar image ttdburnout Jun 19 '18 at 08:11 PM

![alt text][1]

For my needs this is how I did GI_Recordable is my C++ GameInstance, this Gameinstance has a public boolean that is called IsReplay and is set to true when you are in replay (I set it manually to true when I press the replay Input which can be whatever you want it to be) This might not be what you want but this is how I did it.

capturee.png (84.9 kB)
capturee.png (84.9 kB)
avatar image pushmatrix Jun 08 '18 at 08:29 PM

Could the issue be that multicast isn't being recorded for replays? I'm running into that issue where my multicasts work fine when playing multiplayer, but when I go to replay, none of them fire.

avatar image ttdburnout Jun 19 '18 at 06:46 PM

Yep that's exactly what issue I had. So I had to make a change when I was calling stuff from the server side I forced them to be called on client side only when I was in replay mode. BTW I think 4.20 is coming with a new replay system

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
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