Skinned MeshPart Studio Beta

When I have the animation in the animation editor it looks perfectly fine and useable.

As you can see here:
https://gyazo.com/dc5fd89c210f457cce0bdaed66327ba7

However, when I make the startercharacter and load up the animation it turns disfigured and ends up looking like this for whatever reason?

As you can see here:
https://gyazo.com/82bfcf4b2733b5f60d45026f262f9746

I really do not know if I am doing something wrong, please correct me if I am.

Here is how the children of the startercharacter look like:

ss

1 Like

I just figured out it is due the animation size being not the same as the character resulting in the deformity.

I hope that in the future roblox will be able to do something about editing the size of the animation or make it automatically resize.

Hey awesome stuff so far! However I’ve ran into a bit of a serious bug.

When importing the same mesh using the avatar importer(in order to support bones),
it messes up the PBR SurfaceAppearance, making it super tiled.

here is a comparison image for the same mesh fbx

Top Image is SurfaceAppearance using the same mesh imported just by the default mesh importer - works fine

Bottom image is that same mesh imported via the avatar editor to support bones.

I’d really love to continue tinkering with some stuff I was working on , but this is preventing me from both having PBR + Bones, which I both need.

6 Likes

Yes, this is a bug.
The workaround is to put any texture id on the MeshPart.
The SurfaceAppearance will override that texture, so you will not see it - but it will prevent the distortion.

5 Likes

found an annoying bug
resizing a skinned mesh can cause to make the mesh extremely deformed and unrecognisable

2 Likes

This is a known issue. See the known issues section in the initial posting.

You can run this script to scale the Bones. You’ll need to edit two lines; to point to your MeshPart and give it the scale factor you want. You can then paste this into the Studio Command Bar:

Note: this script has been updated and fixed based on feedback from @SelDraken

function scaleRecursive(part, instance, scaleFactor)
	if instance:isA("Bone") then
		-- move bone local translation to part space, scale xyz in part space, then move back to bone parent space
		local bone = instance
		local parentCFrame
		if (bone.Parent:IsA("Bone")) then -- parent can be either the MeshPart or another Bone
			parentCFrame = bone.Parent.WorldCFrame
		else
			parentCFrame = bone.Parent.CFrame
		end
		local parentInPartCFrame = meshPart.CFrame:Inverse() * parentCFrame
		local parentInPartRotationCFrame = parentInPartCFrame - > 	parentInPartCFrame.Position --rotation only
		local pivotOffsetInPartSpace = parentInPartRotationCFrame * bone.Position 
		local scaledPivotOffsetInPartSpace = pivotOffsetInPartSpace * scaleVector3
		local partToParentRotationCFrame = parentInPartRotationCFrame:inverse()  
		bone.Position = partToParentRotationCFrame * scaledPivotOffsetInPartSpace
	end
	local children = instance:GetChildren()
	for i = 1, #children do
		local child = children[i]
		scaleRecursive(part, child, scaleFactor)
	end
end

print("Scaling Part and Bone hierarchy ...")
local scaleFactor = 2.0 -- edit this to your scale factor
local part = workspace.FBXImportGeneric. -- edit this to point to the MeshPart you are scaling
scaleRecursive(part, part, scaleFactor)
part.Size = Vector3.new(part.Size.x * scaleFactor, part.Size.y * scaleFactor, part.Size.z * scaleFactor)
print("Done.")

However, any translation in imported animation will also need to be scaled to look correct, and this needs to be done manually per animation if you use this approach.
It’s much easier to scale at export for both mesh and animation.
If you are animating in Studio, you will be fine to use the script until Studio is updated to do this automatically.

8 Likes

my rig has multiple part and this did not work, it still deformed very badly so im starting to assume it could be how many bones the rig has or how i exported it

1 Like

You would have to run the script for each MeshPart with Bones under it.

Or, you can put in a scale on export instead. For Blender:
image

6 Likes

I remember seeing this a year ago and getting excited about it:

Is there/will there an option to add a mesh deformer in a part. Or is this already a thing?

(if this isnt) I kinda want to have a deformation part that deforms when close. So making vehicle crashes, craters, and maybe a trampoline possible. Basically an option to make this scriptable instead of having an already animated track.

8 Likes

@RobieTheCat 3 Questions More:

  1. If i have a rig that i made in roblox (and i animated it), Does the old animations work, or i need to redo all the animations?

  2. The bones can be edited in the studio, or i need blender to edit them?

  3. Can Motor6D be converted to bones when exporting a model as Wavefont object (OBJ File)

Im waiting for your answers, Thank You!

@NerfLambdaWarrior120

  1. If i have a rig that i made in roblox (and i animated it), Does the old animations work, or i need to redo all the animations?

Old animations will work.

  1. The bones can be edited in the studio, or i need blender to edit them?

You can move the Bones in Studio, but that will also move the mesh. If you want to move the Bones without moving the mesh you’d need to go back into the authoring package, detract the skin, move the bone, re-attach the skin and re-export. I am not sure if Blender has a way to move the bone without detaching/re-binding the skin.

  1. Can Motor6D be converted to bones when exporting a model as Wavefont object (OBJ File)

No, .obj files only contain mesh. They do not hold bones.

1 Like

When is this coming out? I have already made several creatures using this in studio beta and a new game i’m making is going to heavily utilize this feature.

There is actually a bug with this beta, When I try to import a custom rig with say 17k triangles which according to the original post is allowed just like in the original avatar evolution beta build, It claims “ERR! WRONG!, 10K LIMIT BOI” and I’m super confused.

Yeah I’m having the same problem here with pretty much all of my custom rigs, its quite annoying and I hope its fixed.

As per the posting, “Note: the triangle limits for this Beta are increased from a rig limit of 10k to 50k and an individual mesh limit of 5k to 10k.”
The individual mesh limit is 10k for the Studio Beta.

3 Likes

I also found a way to scale animations with a few clicks of a button which has come in handy, I made a video tutorial for everyone on this post to see:

Get the plugin here:

20 Likes

Does anyone have any examples of playable skinned meshes yet? Like, how does one make a skinned and animated mesh into a playable character? Same way as normal r15?

1 Like

another way is you to export the character using the r6 rig as size base.
and exporting as fbx with size of 0.02

I tried just scaling the rig on export to roblox size, It scaled the bones and mesh but not the animation translations which is what the video is for.

after resizing any part or rig in blender, you need to set the the current scale to become 1 as base.

ctrl+A with an object or rig or both selected to pop up the options them select scale
image

Video Example

2 Likes