4.5 Blueprint Memory Leaks?

I was working with ue4 4.5 for class when i had some problems said below. i asked about it to my teacher and he is having the same problems.

I’m having some increasingly odd problem with 2 of my blueprints that are breaking more and more. It has a public array variable of the type that itself has as there are multiple instances (32) in the scene. Everytime I hit play or complie blueprints every reference (each has 2 - 5) is cleared to none. Unplaying it won’t bring the references back either. Only if I reload the scene without saving. I don’t have any thing that clears it either. sometimes when I hit stop it crashes.

My teacher. “This could be a bug with 4.5. It seems to be getting memory leaks caused by selecting actors in the outliner when working in a simple scene. This ends up causing UE4 to crash when I hit the stop button.”

Hi ,

If you open up your task manager on your pc with your project open and go to the processes tab. Find the process “UE4Editor.exe”. When, in the scene outliner, you select different objects, does the amount of memory increase? If so by how much? Once you stop selecting objects does it start to go back down or does it stay at the new point for a few minutes? Does this occur on a blank project with no additional content?

I don’t notice any irregularities. Although it did keep the references for a few plays but then went back to clearing on compile/play, sometimes crashing on unplaying. The blueprint was working when I started in 4.5 too. It only seems to clear references to other instances of itself in the scene.

Same project

After some more testing and crashes, I’m so far keeping references on play but I’m getting infinite loop warnings somehow? The only loops are for-each ones with at most 3 references that just do stuff to themselves and not others to loop a chain. Though I’m only getting it when the player falls too far down. PlayerBP calls Custom event in controllerBP to reset the pieces and to back to the start It resets (custom event in a different controller BP to call custom events in the pieces to play a timeline of a dynamic material scalar and set collision on all but one to witch that does not work correctly), fall again and the error occurs.

New project with ame BPs

Yes it does occur crashing while unplaying still crashes it sometimes even with the default scene and a few custom objects to test. References do not stick sometimes. Some elements in the arrays don’t activate at all.

*When I get a chance should I post a link to download the project?

Can you post a screenshot of your blueprints? Additionally, if you have a crash log Can you post that in a . here as well? These can be found in the filepath \UnrealProjects\PROJECTNAME\saved\logs. Thank you!

No problem.The bp images and log files are in the . Sorry it took awhile. I was just busy. And thank you.

the pics are from the new project so some simple stuff like particle activate have are not included. but the problem consists.
link text

Hi ,

Thus far I haven’t been able to see what is causing your infinite loop error. Do you have a stripped down version of the project that I can have a look at to see what may be occurring? If you are comfortable with it you can post it here so I can have a look (post in a . file).

Thanks for the help so far. im not quite sure what to isolate right now as im not quite sure what to get rid of but ill do some more testing to see how small I can get the project to.

An Update. havent done the isolate part quite yet.

  1. the crashing was because of this - https://answers.unrealengine.com/questions/122295/consistent-crash-bug-in-editor-on-45-and-451.html
    I thought this was related to my problem but maybe not
  1. the infinite loop does not seem to occur any more in 4.5.1 in my testing. Do you have a changeLog for the list of all the small fixes/changes in 4.5.X versions btw?

  2. Clearing references on the maze pieces on play still occurs, and its only on them as well. It seems when I load the project and play w/o touching anything but the play button to test, 99% of the time it stays. When I compile a seemingly unrelated BP, it starts clearing after every play that session. If I close and reload the project it will be fine again.

I’ve noticed that if I recompile the Boss BP or player BP the problem occurs. These all have “in the scene” references connecting each other. The Boss has ref to player and back. Player to MazeMaster. MazeMaster to all the pieces. And the peices to a few of each other. Any other not connected BP doesn’t seem to make this occur. My teacher said that it might have something to do with default values being affected or something like that. I think the problem might have to do with the same BP Type referencing a different instance of itself in the scene is causing the problem to occur, and that recompiling something in the chain does something to start the problem

Thank you again. Starting the isolation now.

Project link: Dropbox - Error - Simplify your life

Hi ,

Here is a link to the patch notes for 4.5.1: 4.5.1 Hotfix is Live! - Announcements - Epic Developer Community Forums! . When you compile, are you making sure to compile all blueprints that are referenced or do reference the blueprint you have compiled as well? The reason I ask this is because there is a known issue with blueprints becoming dirty when a referenced blueprint is changed and compiled. Try re-compiling all of them before hitting play and see if that is a viable workaround.

Ah yes, it is. And is there a list of known issues, I can only Linux known issues, and it would help so that i do not repeat what you already know? There is also a loop where not all can be compiled, so I’ll have to keep that in mind. Didn’t notice this before, sorry about that. But would this also cause the one blueprint (mazepeice BP) somewhere in the chain is compiled to clear its variable refs on play? (The bp is never touched either) It also clears var refs after I hit compile on it directly while the others keep theirs. It’s the only blueprint that acts this way so far. Even when others are “dirty” they would still work fine.

And it doesn’t seem like a workaround as MazePeice bp is still being problematic on anything I try to do it.

Hi ,

Can you recreate the blueprint to see if it occurs in a fresh blueprint?

New Bp, New project. So far so good, mostly. It keeps references on play but it still clears any referenced variables in the instances on compile, and it also developed later in the initail project. Althogh, that may be because of the dirtyness though as I’m not getting it in the new proj as of yet.

Hi ,

Does everything seem to be working without the errors you were experiencing earlier?

Hi ,

We have not heard from you in quite some time. I am marking this thread as answered for tracking purposes. If you are still experiencing this error, please let us know. Thank you.

Sorry about that. I just got really busy and had to move on to a new project/assignment. In the isolated project it seemed to still be acting the same when compiling itself sofar where it does not keep variable refs. Though I did not get the dirty another BP on compile problem as of that new project and it was keeping the vars on play so far. The dirtyness issue may of been affecting the references it the problem BP, though I dont know. I’ll get more time in a few weeks to do more testing. Right now I just don’t have the time.

Hi ,

That is not a problem at all. I am going to remark this as answered for tracking, However if you are able to provide reproduction steps or a problem asset/project that I can take a look at please comment and I’d be more than happy to take a look.