Hey guys!
I am getting this error "Can not delete subinstances of spine or model components"
Can someone explain to me what it means and what causes it?
Hey guys!
I am getting this error "Can not delete subinstances of spine or model components"
Can someone explain to me what it means and what causes it?
What are you doing when you get the message?
There’s a pop-up menu through which a GO is created when the user clicks ok. This generates the GO and closes the pop-up menu… And it works fine. But then when I try to access the menu again it opens and whenever I try to close it, I get this message.
Note: I tried commenting out the statement that creates the GO when the user clicks ok and the error disappeared
Can you share some code as well? Does it happen when you call go.delete()?
Yes it all happens when I use go.delete() to delete the pop-up menu objects. Sure, I’ll post code in a few
I was adding the menu’s landing screen components to a lua table when they are generated by the factory. Thus, i was using go.delete_all(tableName) to delete them.
I tried deleting the components separately using go.delete(component) for each component and the error disappeared.
It seems that go.delete_all is messing things up for some reason
I believe go.delete_all
is deprecated. You can pass go.delete
a table. You can also do go.delete(true)
to delete a game object and all of its children. I don’t know if either of those options will solve your error though. It sounds like it is trying to delete a bone from your spine skeleton, and “Game objects corresponding to a spine model skeleton bone can not be individually deleted.” (from here)
I believe Ross is on the right track. Deleting individual bones is not possible. It’s also not possible to delete individual components on a game object. You always delete the entire game object.
Thank you!
Using go.delete(component) instead of go.delete_all() solves the problem
Thanks guys