While working on my project a bug appeared that I eventually traced to the Level Blueprint’s ‘Event Begin Play’, which had started firing twice for no reason. I began removing things from the project to try and figure out where the problem was, but I removed absolutely everything - all assets, actors, variables and blueprints - leaving only a blank project with this code:
This had no effect:
I tried importing the project into the 4.19 preview version, but it still behaves the same. You can download the project files here: [Project Files (813kb)][3]
We’ve recently made a switch to a new bug reporting method using a more structured form. Please visit the link below for more details and report the issue using the new Bug Submission Form. Feel free to continue to use this thread for community discussion around the issue.
No streaming or level instances. As stated above, everything in project was removed except for the code shown above. The project files are available to download.
I got your bug submission, replying here for visibility.
This is… maddening. I’m not seeing this in a new map, so my best guess is that this is a result of the map being created in a previous engine version. (Riftris map is 31kB, and a new blank map with same nodes is 26kB) I moved your map into a blank project and it’s still printing twice.
Best workaround would be to migrate assets/nodes/macros to a newly created map.
Thank you for all your work and sharing with Riftris!
I figured this would end up being be the case. Since only the map itself was left, it suggested something rather fundamental was off. Mind you, I had been upgrading the same project across most new engine versions since 4.5.
Nothing left but to port it over then. Cheers for having a look anyway.
So I recreated everything in a new map and it was working fine for a week until I started adding stuff to the Event Begin Play again. Now it’s firing three times!
I’m beginning to think the Delay node is the thing that’s causing irreparable damage to the map file.
I just wanted to add that I looked at this with by debugging the project and it seems that, for whatever reason, the Level is being recreated 2 times, resulting in BeginPlay being called 3 times in total. It would be helpful if, as mentioned, get a good repro and provide us with the map with all of the logic that is causing this to occur in the first place.
I’ve been trying to recreate the steps that led to this for a few hours with no success. I’ll keep at it, but for now here’s the project files that I saved just after it started firing three times.
I ran into the same problem, that suddenly the Level Blueprint created, although I used a DoOnce Node, 2 Widgets at the same time. When I printed the Display Name of the Level Blueprint to Screen, it showed “MyLevel1” and “MyLevel5”.
The Bug occured randomly when I was working on the Level Blueprint. The only things I recognized before were that when I pressed “create new Variable” an unrecognized “MyBlueprint” Tab occured and “Save All” showed some Blueprints I did not edit.
any news on this ?
i just had the same problem event begin play fires twice even using do once it keeps firing twice im using 4.18.3 this is the second time it happens to me
Did someone found any solutions to this? After two months on working on a project all my actions from my level bp are fired twice. The problem occurred after I’ve updated to 4.21.2 but in the same day I’ve create streaming levels, so I don’t know exactly what is the problem.
I’ve created a copy to the project and delete everything and Begin Play still fired twice. I also have another level and there is working without any problems.
Thank you!