Unity Bone Rotation (Preserving Volume)

hey fellow game devs ^^, trying to rotate this gattling turret’s barrel (on the x axis in unity), and I can, but with the mesh scaling down itself, happens in blender(modeling software) too but the software provides a feature called “Preserve Volume” which fixes that but it’s a blender thing and is not in unity, I tried looking into shape keys, same result ><, then went for googly gooing and searching and found some similar posts to mine

and finally found someone who found a solution

yippy for me :slight_smile: except wait…

https://blender.stackexchange.com/questions/110047/blender-to-unity-animation-volume-preservation

the solution doesn’t work properly for my case because my bones aren’t joined like an arm, my barrel bones are individual bones parented to another bone, and the barrel bone rotates itself, I tried experimenting with some settings and things but no luck and here I’m posting this

(Unity) barrel scaling down it self when rotating bone on the X axis

(Blender), enabling preserving volume and rotation

UPDATE: found a solution, the solution for me was I had to unassign all weights of barrels from vertex groups panel and assign the barrel weight only to the barrel bone, yippy 4 me

the last picture seems to fail everytime after uploading:

lemme upload it here:

P.S: weird can’t seem to upload the last image, seems to fail for some reason, the last gif shows enabling and disabling “Preserve Volume” and how the barrel is rotated

Unity uses linear skin calculations, not quaternion. This is the reason.