Creating Material Instance Dynamic (MID) via Blueprint construction script results in object leak and memory leak.

Hello,

My goal was to create customizable chairs via blueprint where each chair could have its own color. Right now I am creating a MID via the construction script through blueprint so that I can expose the color property of the material and set it manually for each chair. The problem is every time the construction script runs, my object count in the editor goes up and so does the memory. I am guessing a lot of MIDs are being created everytime the script runs and is not being cleaned up. I tried hooking up a ‘DoOnce’ blueprint node before the create MID node, but the construction script seems to ignore this. I am guessing this is a bug. I maybe wrong. If so how should I go about doing this without having an object and memory leak?

Thanks.

Hello,

Thank you for your report. Could you please post an image of your construction script? That will help us recreate and test the issue.

Thanks!

I unfortunately cannot paste the construction script for the chairs. But I shall copy paste a very simillar one where I am modifying float properties instead of color properties and it gives me the same issue.

Let me know If I can provide any more information to help out.

Thanks!

Seems to be fixed in 4.2