ISMC Assert when adding removing Instances

Hi,
after changing to UE5 my project throws this assert when i add and remove instances from the component.


Assertion failed: UploadInfo.InstanceCustomDataCount * InstanceCount == UploadInfo.InstanceCustomData.Num()

i checked the ue4 source code for this and this assert is new in UE5.
the function “ValidateInstanceUploadInfo(…)” does this check.

I was not able to reproduce this with a fresh project.

Some numbers:
i have 300+ Actors each with ISMC, but only a few have instances they get added or removed based on position and view of the player. the maximum amount of instances of a single actor was 300. the others had < 50.

can removing and adding instances in tick cause the custom floats upload to the material?

trying to reproduce this in a fresh project was no success…

could this happen during the converting to ue5 from ue4.27?

I created a fresh project and copied the source files to it and it still throws this assert…

Is there any way to ensure this does not happen? it looks like the data on gamethread is not the same on renderthread. or am i missing something?

After hours of debugging i found the issue. Somehow my render data got corrupted during frustum check. i don’t know why…
but the ISMC has nothing to do with this for sure :slight_smile:

Hi @HOUmmel I have the same issue and i was wondering if you figured out why the data got corrupted because I’m really stuck on this issue, thx you in advance

Nevermind I solved it by switching to unreal 5.1, apparently the bug is solved in this version