Hello! So I am using a rotate block script, and when I click to rotate it unanchored, it works perfectly, but then once I anchor it the script completely breaks and I do not even know why this happens and I was wondering if its a problem with the script. If you could just take a quick look at the script, and see if there is something wrong that would be amazing appreciated!
1 | script.Parent.ClickDetector.MouseClick:connect( function () |
2 | print ( "Rotating" ) |
3 | script.Parent.RotVelocity = Vector 3. new( 0 , script.Parent.RotVelocity.y + 2 , 0 ) --Change this to your desired velocity. |
4 | end ) |
RotVelocity changes the velocity, not the actual rotation when a part is anchored it cannot move, velocity just makes it into a conveyor belt. Using rotation or CFrame would be able to fix this by changing the actual rotation instead of just rotation speed.
just desactive the contraints + Collisions you should be able to move it without unanchor it
Oh and you should have use Orientation
1 | script.Parent.ClickDetector.MouseClick:connect( function () |
2 | print ( "Rotating" ) |
3 | script.Parent.Orientation = Vector 3. new( 0 , script.Parent.Orientation.y + 2 , 0 ) --Change this to your desired velocity. |
4 | end ) |