Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How to rotate it?

I'm asking this part because I can't rotate this part,I tried with .Rotation but it didn't work so I gave a chance to cframe.angles()

	local x = Instance.new("Part")
			x.Shape = "Block"
			x.CanCollide = true
			x.TopSurface = "Smooth"
			x.BottomSurface = "Smooth"
			x.Parent = Workspace
			x.Transparency = 0
			x.Size = Player.Character["Right Arm"].Size
			x.BrickColor = Player.Character["Right Arm"].BrickColor
			x.Name = "Bara Punch"
			x.CFrame = Player.Character["Right Arm"].CFrame*CFrame.new(0, 0, -3)* CFrame.Angles(0,90,0)
			x.CFrame = CFrame.new(x.Position,mouse.Hit.p)
			y = Instance.new("BodyVelocity")
			y.maxForce = Vector3.new(math.huge, math.huge, math.huge)
			y.velocity = x.CFrame.lookVector*75
			y.Parent = x
			b = Instance.new("BoolValue", x)
			b.Value = true
			game.Debris:AddItem(x, 2)

1 answer

CFrame.Angles uses radians, and you gave it 90. Either change it to math.pi/2 or to math.rad(90)

2 comments

0

Not working.

0

You're overwriting its CFrame on line 12.

This discussion is preserved as it was. New answers, comments, and votes are closed.