Hey! I’m attempting to create a Verse script that manages the movement of a bunch of moving target devices. To do so, I created a list of structs containing a reference to the target device and the reference to the base prop.
target_type := enum{Body,Short,Long}
target_container := struct<concrete> {
@editable Type : target_type = target_type.Body
@editable Targets : []target_object = array{}
}
target_object := struct<concrete> {
@editable Prop : creative_prop = creative_prop{}
@editable Target : shooting_range_target_device = shooting_range_target_device{}
}
The code compiles, but when trying to set these values in editor however, the values are not shown - it’s mentioned that they are properties of the struct, but they aren’t visible/modifiable directly.
The struct in general is able to be modified outside of the array as an individual object. In fact, when trying to experiment with this issue, I found that if in the struct I initialized the variables as arrays instead of a single prop/device and only used the first index, I was able to modify them once, before they were blocked off in a similar manner (non-viewable members).
target_object := struct<concrete> {
@editable Prop : []creative_prop = array{}
@editable Target : []shooting_range_target_device = array{}
}
(When running the game, these values get blocked off like in the original, unable to access the properties. This persists after game has concluded, and to set them again you need to delete the element and reset it.)
Running my code with the variables locked off seemed to work, it’s just near impossible to actually set the values without jumping through hoops. I was wondering if this was a bug, or there’s something I’m missing that would resolve the issue.
I’m very new to UEFN/Verse/Fortnite development as a whole, and am doing my best to try and pick it up. Thanks for your support!