Hi ^^ Im trying to make an inventory system where the items would attach themself on sockets placed on a character. And later when he look at them he’d be able to take them from there.
But i have a problem with how can i find if a perticular socket is taken ( already has an item placed )
I used the standard grab tutorial - but i detach actor from actor on the grabbed object ( in case its already attached )
And for dropping instead of throwing them on the ground I attack to component (where later ill give a socket, that is free ) ← and this is one of the places my problem lies.
Socket is just position points on mesh, which isn’t something that can be “taken”, but actors and components can be attached to them, once you do that actor or component will align it self to socket on every frame. So you should check attached actors or components.
Maybe try to keep track if something is attached to socket by yourself with bool varable. Make functions to attach and deattach to specific socket and use them so bool seamlesly change and you can use that information somewhere else as you want.
Thanks. Ill try to add a bool array to keep track inside the character for each slot. And use maybe some string in the grabbed item them self to keep track of which slot they occupy. And checking attach actors would come in handy ^^ thanks again, i really thought that sockets acted as slots and not only as positions.