Value in struct not changing on spawned actor

So I spawn an actor into my level, It has an array of structs inside it (editable). I am attempting to assign a value to one of the members with the “Set members in struct” node. However when I click on the object in my level it shows me that the value is not set.

(the nodes off screen are just adding the actor to an array)

101335-runtime.png

The struct out node does show that the value is set if I print it, but since it is passed by reference I don’t understand why it is not showing up in simulate mode.

Any idea on why it is still showing 0s?

I’m pretty sure this is a known issue with Structs and arrays

Basically i think its the Get() function in blueprints that always gets a copy of the struct. A little strange that printing the struct out reference doesn’t show anything but makes sense that checking the actors array structs shows nothing.

From memory the workaround is to make the change to the struct and use set array element to reinsert the struct back into the array replacing the instance already there… going off memory here so if i’m a bit off hopefully get you started on the right solution anyway :slight_smile:

Thanks! This fixes the issue. A fairly easy fix once you know the bug is there.