How to move and rotate a Model using pivot?

im working with this but doesn’t seem to rotate, it is just at 0,0,0

local x = result.Position.X
		local y = result.Position.Y + _PLACEHOLDER:GetExtentsSize().Y/2
		local z = result.Position.Z
		local pos = CFrame.new(x,y,z)
		_PLACEHOLDER:PivotTo(pos,  _PLACEHOLDER:GetPivot() * CFrame.Angles(math.rad(33), math.rad(60), 0))		
1 Like

models themselves dont have a position, so you need to get the position of the primary part of the model

Result is the raycast position, im talking about the model rotation, when i set the pos the rotation doesnt set

PivotTo takes a single argument which is the CFrame, position and rotation included. So this is essentially how you would do that:

_PLACEHOLDER:PivotTo(pos *  CFrame.Angles(math.rad(33), math.rad(60), 0))	
1 Like

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