How to change the height on an R6 Character

So I want to make a script were players are able to change there height in R6. But I don’t know how to script something like that. Cause I could only do it in R15

2 Likes

I haven’t done this myself, but I know a few people who use applyhumanoiddescription, I’d suggest looking into that here

Hope this helps!

2 Likes

You can just scale the body parts and then rejoint them.

A Free Model by hunxrepair

Sample code:

local Percentage = 0.3 -- 1 = normal, 0.5 = half your normal size, 2 = double your normal size
local LastGrowth = 0

script.Parent.Touched:Connect(function(Hit)
	if time() - LastGrowth > 1 then
		LastGrowth = time()

	local Player = game.Players:GetPlayerFromCharacter(Hit.Parent)
	
	if Player and Player.Character:FindFirstChild("AppliedGrowth") == nil then
		local Motors = {}
		local NewMotors = {}
		local NewVal = Instance.new("BoolValue")
		NewVal.Name = "AppliedGrowth"
		NewVal.Parent = Player.Character
		
		
		for i,v in pairs(Player.Character.Torso:GetChildren()) do
			if v:IsA("Motor6D") then
				table.insert(Motors, v)
			end
		end
		table.insert(Motors, Player.Character.HumanoidRootPart.RootJoint)
		
		for i,v in pairs(Motors) do

			local X, Y, Z, R00, R01, R02, R10, R11, R12, R20, R21, R22 = v.C0:components()
			X = X * Percentage
			Y = Y * Percentage
			Z = Z * Percentage
			R00 = R00 * Percentage
			R01 = R01 * Percentage
			R02 = R02 * Percentage
			R10 = R10 * Percentage
			R11 = R11 * Percentage
			R12 = R12 * Percentage
			R20 = R20 * Percentage
			R21 = R21 * Percentage
			R22 = R22 * Percentage
			v.C0 = CFrame.new(X, Y, Z, R00, R01, R02, R10, R11, R12, R20, R21, R22)
			
			local X, Y, Z, R00, R01, R02, R10, R11, R12, R20, R21, R22 = v.C1:components()
			X = X * Percentage
			Y = Y * Percentage
			Z = Z * Percentage
			R00 = R00 * Percentage
			R01 = R01 * Percentage
			R02 = R02 * Percentage
			R10 = R10 * Percentage
			R11 = R11 * Percentage
			R12 = R12 * Percentage
			R20 = R20 * Percentage
			R21 = R21 * Percentage
			R22 = R22 * Percentage
			v.C1 = CFrame.new(X, Y, Z, R00, R01, R02, R10, R11, R12, R20, R21, R22)
			
			table.insert(NewMotors, {v:Clone(), v.Parent})
			v:Destroy()
		end
		
		for i,v in pairs(Player.Character:GetChildren()) do
			if v:IsA("BasePart") then
				v.Size = v.Size * Percentage
			end
		end
		
		for i,v in pairs(NewMotors) do
			v[1].Parent = v[2]
		end
	end
   end
end)
4 Likes

Will it resize the character items too?

You can try it, i haven’t tested it so idk.

The problem with that is just it will increase the players whole size in general. I wanna know how to make it so like Only the height changes. Cause I could try increasing the length on the limbs

4 Likes