andrewtek
9 months agoMember
How can we use PropTypes.AssetArray?
Hi All,
When configuring a script's propsDefinition, I want to specify an array to hold a list of related assets. I saw the PropTypes.AssetArray type, but when I put this in my propsDefinition, I don't see any way to assign a value in the editor.
Are the Array PropTypes not usable?
Here is the API documentation. It does not provide a lot to go on. https://developers.meta.com/horizon-worlds/reference/2.0.0/core_proptypes
Thanks!
Unfortunately, we cannot make arrays visible in the property panel of an object. You will have to create a private array variable and add them on start. Alternatively, you can make a big int array and add the asset ids. You can do this right where you declare it as well.