Spawn parent and hand IK can't be used together on a weapon

Cheo

Active member
Hello, it seems there is some sort of conflict between the Spawn parent and non-dominant hand IK target parameters on the Third Person Perspective Item, as they cannot be used together. Here's a video to illustrate :


Each works correctly when used alone, but it is impossible to place the weapon correctly when using both. Can someone try this on their end ? Thanks in advance !
 
Oh well I had forgotten to test one thing : when adding the parent object identifier on the Items object to which the Character Item Slot is attached, it can be used to position and rotate the weapon correctly ! Still it should be possible to do the same for a child of this object, and it seems necessary to me also in order to position the weapon correctly for each character.
 
The non-dominant hand IK target should generally be set to a child of the weapon so there's no need to use the object identifier. I actually can't think of a use case when you'd want it to be something other than a child of the weapon so I am going to remove the option to use the object identifier.

When spawning the item you can either position it with the local spawn position/rotation settings or as we do in the demo scene you can have a different parent that is unique for each weapon. This makes it easy to transfer between characters.
 
Yeah I made a weird mistake, I should have known the IK target is meant to be on the weapon but the object identifier must have made me think I had to put an ID on the character. Removing the object identifier for this parameter should prevent someone else from making the same mistake !

Still, when using an IK target on the weapon and a spawn parent designed by an ID, the issue remains : it is impossible to adjust the weapon or its parent's position and rotation, just like you see on the video. To be absolutely sure I added an IK target to the AssaultRifleWeapon prefab's Third Person Perspective Item and the exact same issue happened on Atlas in the demo scene. Could I please ask you to test this on your end ?
 
In the demo scene I set the non-dominant hand IK and was able to adjust the IK position. IK doesn't adjust the weapons position - that is done by the local spawn position/rotation.
 
Well yes, precisely - and the transform can't be adjusted if both a spawn parent and an IK target are set. Here is another test in the demo scene using Atlas, with an IK target and a spawn parent :


By the way you'll notice the object identifier component that must be attached to the parent at 1:15 doesn't show up. I tested with the IK target only which results in an incorrect initial transform which can be fixed, as well as a correct IK.
 
Did you change the location of the Assault Rifle Parent? When I tried in the demo scene with an IK value set only the left hand moved - the item was spawned correctly.

1669630102080.png
 
Damn this is getting even stranger, I just created two new blank projects (one in 2021.3 and the other in 2022.1.23, with UCC3 redownloaded for each) to be absolutely sure and confirm that the issue is still here despite the assault rifle's Third Person Perspective Item component being exactly the same as what you showed in your screenshot, and with the only modification added to UCC3's default settings being the IK target added on the AssaultRifleWeapon's grip.

Capture d’écran (337).png

By the way I assume this is where the IK target is supposed to be set ?

Capture d’écran (338).png

At this point I can only propose to send you a copy of one of these test projects, if you're okay with that and don't have any other lead ? I see you removed the object identifier for the IK but frankly I doubt this has had any effect on this matter.
 
Yes, that's the correct location. I have made some IK changes to the base class related to this but I wouldn't have thought that this would have been affected. I am close to being done with the Agility Pack and will be releasing an update to go along with that. Let's give it another try after that since I have made changes to both the IK base class and not using the Object Identifier.
 
Top