Accessory position when player grows

I have the ability to get gigantic, but how do I fix it?

  1. ** What do you want to achieve? **
    I want the hair to be in the right position as I become giant

  2. ** What’s the problem? **
    when I use it the hair is inside the head

  3. ** What solutions have you tried so far? **
    I tried to make a hair removal system but it didn’t work.

For R15 characters, you should only have to change the Scale values under the Humanoid: HeadScale, BodyDepthScale, BodyWidthScale, BodyHeightScale
From that then Accessories should scale correctly.
I’ve had a similar issue when rescaling some but not all R6 based characters which I think is caused by Mesh.Scale working differently for the Head and Hair. I haven’t bothered fixing it as only affects clones.

for my game, I’m using a “Character Customization” that has multiple hair types, and that happens for everyone.
This is my script:

Scale = 5.5
	local Humanoid = Character.Humanoid
	Humanoid.BodyWidthScale.Value = Humanoid.BodyWidthScale.Value * Scale
	Humanoid.BodyTypeScale.Value = Humanoid.BodyTypeScale.Value * Scale
	Humanoid.BodyHeightScale.Value = Humanoid.BodyHeightScale.Value * Scale
	Humanoid.BodyDepthScale.Value = Humanoid.BodyDepthScale.Value * Scale
	Humanoid.HeadScale.Value = Humanoid.HeadScale.Value * Scale

What do I do to solve?

That’s pretty much what I also do with R15 rigs. Are you sure the problem is affecting R15s and not solely R6?

My character is R15 and it works but when I change my hair using the “Character Customization” I get the problem

Is “Character Customization” a script? If yes then it might be that the hair mesh is not scaling properly when added to the character.

yes it is a script,I use this to change my hair :

for i,Acessory in pairs(Character:GetChildren()) do
				if Acessory:IsA("Accessory") then
					Acessory:Remove()
				end
			end
			
			local NewHair = Hairs["Hair"..HairNumber.Value]:Clone()
			NewHair.Parent = Character

If the hair is a standard Accessory and is a MeshPart, then before you Parent it, set it’s Size parameters:


NewHair.Size = Vector3.new(NewHair.Size.X * Scale, NewHair.Size.Y * Scale, NewHair.Size.Z * Scale)

After I did that the hair disappeared, I think it must be the weld Hair

When the character gets larger, is the Hair still parented to it? So if you go in to the character in Explorer do you still see it listed?

Yes, and when I click on the hair it’s like it’s invisible

We are in very different time zones, so the discussion is really slow.

So we know that the hair is present in the character model.
Did you resize the hair before you Parented it to the character. If done after .Parent, then yes it will probably break the weld.
So theoretically this should work:

local NewHair = Hairs["Hair"..HairNumber.Value]:Clone()
NewHair.Size = Vector3.new(NewHair.Size.X * Scale, NewHair.Size.Y * Scale, NewHair.Size.Z * Scale)
NewHair.Parent = Character

But, not all hair is equal. After playing about with this I have found that some Hair is a MeshPart as the Handle whci can be scaled suing the above. Others can be a plain part as the Handle, then a SpecialMesh as a child. This second type is more difficult to scale as you will also need to offset the CFrame probably to cater for the scale change

Try using Humanoid:AddAcessory()

https://developer.roblox.com/en-us/api-reference/function/Humanoid/AddAccessory

Yes, we are in very different time zones, because I’m from Brazil, now it’s 10:00 AM. Well I have two different scripts, one for customization and one for transformation, Do you indicate to remove the accessory and put this in the transformation script?

(as it is also used to customize other accessories besides hair I put a “StringValue” called “Type” which has its types: hair, BackAcessory, Front Accessory etc.)

Example:

for i,v in pairs(Character:GetChildren()) do
    if v:FindFirstChild("Type") ~= nil and v:FindFirstChild("Type").Value == "Hair" then
     v:Remove()
    end
end

local NewHair = Hairs["Hair"..HairNumber.Value]:Clone()
NewHair.Size = Vector3.new(NewHair.Size.X * Scale, NewHair.Size.Y * Scale, NewHair.Size.Z * Scale)
NewHair.Parent = Character