Can I make the marble roll but keep the player standing up?

  1. What do you want to achieve? hi, I have this marble system where the player is inside of the marble, and when he moves, the marble rolls. But the player rolls, too, and I want him to stand. How can I do that?

  2. What is the issue? the player rolls with the ball.

  3. What solutions have you tried so far? everything.

This is my code:

game.Players.PlayerAdded:Connect(function(player)
	player.CharacterAdded:Connect(function(char)
		local HRP = char:WaitForChild("HumanoidRootPart")
		local marble = Instance.new("Part")
		marble.Size = Vector3.new(8,8,8)
		marble.BrickColor = BrickColor.Random()
		marble.Transparency = .5
		marble.Shape = Enum.PartType.Ball
		marble.Parent = char
		marble.Material = Enum.Material.SmoothPlastic
		local Velocity = Instance.new("BodyAngularVelocity")
		Velocity.Parent = marble
		local Hum = char:WaitForChild("Humanoid")
		local Weld = Instance.new("Weld")
		Weld.Parent = marble
		Weld.Part0 = HRP
		Weld.Part1 = marble
		Hum.PlatformStand = true

		while true do
			wait()
			marble.BodyAngularVelocity.AngularVelocity = Vector3.new(char.Humanoid.MoveDirection.z * 32,0,char.Humanoid.MoveDirection.x * -32)
			marble.BodyAngularVelocity.MaxTorque = Vector3.new(10000,10000,10000)
			if char.Humanoid.MoveDirection == Vector3.new(0,0,0) then
				marble.BodyAngularVelocity.MaxTorque = Vector3.new(0,0,0)
			end
		end
	end)
end)

I hope somebody can help. Have a nice day!

2 Likes

Could you show an example of what you currently have? Like a video of the actual rolling?

I don’t know why but the dev forum won’t load my video :(, anyways if you copy and paste the script I shared in server script service you will have my same result

1 Like

Make this a BallSocketConstraint instead and it will work just fine.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.