Struggling to setup the Holster for my melee weapon

RaeJjin0

Member
Hello ! Sorry to disturb you, but after taking a look at the documentation and after founding close to none websites/forums talking about the holster, i needed to come here for a potential rescue x)

After following the documentation, I made a Child object under the joint i wanted the sword to end up when unequipped. I named it Holster, and then selected it in the "Third Person Perspective Item" component under the sword item.
Every time i press T when playing, the sword got placed far away from the holster point. I tried to move it while being in test but it won't move, and if i move only the sword object and copy component, i have no use of it since the object get instantly placed back in the Items hierarchy.
It would take an infinite amount of time setting up the holster position since it's an invisible object and the sword doesn't spawn on it anyway... So where could i properly setup the holster position, or even more precisely the position where my item will end up when getting unequipped ? Isn't there somewhere in components a section where i can set a transform position for the unequipped sword specifically or something like this ?

Thank you in advance and sorry for your time x)
 
Can you post a picture of your hierarchy, with both an image of the hierarchy as well as the sword?
 
It doesn't look like your Epee weapon is currently holstered - when the weapon goes to being holstered it should be a child of the Holster Transform under your scabbard_join_end GameObject. Is the weapon unequipped?
 
Oh sorry ! Okay, so the first picture shows you the hierarchy of the sword when it's equipped. Here is the hierarchy of the sword Unequipped :
(as you can see, the sword item moved from the right hand to the holster. My only problem is that i don't know how to setup the transform, so that i can choose by myself where i exactly want the sword to end up when being unequipped...)
Thank you again and sorry if i am not very clear, your work is truly amazing, I am the one who isn't :D
 

Attachments

  • ethrhr2.png
    ethrhr2.png
    106.6 KB · Views: 15
The Epee position looks good. What is the position of the parent GameObject, Holster? This position is probably really far away from your desired position so that is what is making the item holster in the wrong location.
 
Well the Holster is positioned under "scabbard joint end" so that the sword would move dynamically the same way than the scabbard does (if i do not put the Holster under it, i think that the sword will look like it gets out of the scabbard when the character moves, right ?)
I just tried something :
I hit play > Press T to unequip the sword > Select the sword (that is now positioned far away from the character) > Just do a 90° rotation to it > Copy transform values > Quit the game > Paste transform values on the Holster > Play again to see if the sword is only rotated to 90° now when unequiped.

Result : When it normally would be turned in a 90° angle like i did on the first play test, the sword has been deplaced lol it looks like the rotation center pivot isn't when it normally would have to be... I don't understand uh sorry if that's a mess :(
 
You don't want to rotate the actual sword, that will get reset the next time that you run the game. You'll instead want to rotate the holster as that transform value will be persisted.
 
Okay, i ended up recording a video to show you what exactly is my problem sir :)


So, i would like to know how i can setup the position And rotation where the sword will end up when unequipped ?
Isn't there any sliders, anything in the item component so that we can setup the unequipped position ? Because in the way i am doing it on the video,
please tell me how i can make it work, please...
After recording it, i even tried to duplicate the sword under the Holster hierarchy, then move the holster, delete the duplicated sword but it did not work either.
 
The holster position doesn't change once you have set it, and the sword gets parented to the holster object with a 0 position and rotation. This means that you need to adjust the holster position while the game is running and the sword is holstered, copy the transform, and then in edit mode paste the copied transform value.
 
Okay i got it finally working !

Just in case someone has the same problem someday :

I decided to put the Holster gameobject in MyCharacter hierarchy, but outside the bones (i thought that i had to put it under the scabbard or however you call it, but no you don't have to). Then, i added a Parent Constraint component, added the scabbard_joint as the Source, Then launch Play game, move the Holster object BUT move it only toying with the Source Offsets under the Parent Constraint component. When the sword gets placed as you like, DO NOT click on "Copy Component", the copy bugged for me and i didn't get the right offsets uh... Take a screenshot.
After making sure that you got the screenshot of the offsets values, stop Play Testing, and copy every values inside Source Offsets again, and There you go :D
 
Top