#Help with weapon setup.

1 messages · Page 1 of 1 (latest)

buoyant pawn
#

It's less about the "proper way" and more about "the way that makes the most sense". In this case, I don't think having a separate script specific to the WeaponHolder is the right move, mostly because you're creating needless modularity which is more difficult to build upon and maintain. Instead, I'd handle it all from the same script that handles your player (which I assume is attached to the root CharacterBody3D node?). A section of that script dedicated to handling weapons makes a lot more sense in my opinion.

Now, if you've got a mechanic where your NPCs or enemies can also pick up weapons, that's a different story.

red gust
#

I just need to make it so that the weapon itself attaches to the hands. But I don’t understand how to do this correctly. I’ve seen a lot of videos of people who managed to do exactly what I need, but there’s no tutorial anywhere to give at least some idea of how it works.

#

As I understand it from the translator, WeaponHolder is not the best idea.

stoic rover
#

i think a good way maybe would be to specify in the weapon scene itself where the left and right hands should attach with something like a marker3d, then the player script could look for where that particular weapon's attachments are and move the bones there?