Ad
Log in to vote
0

How do you rotate a part, is my script incorrect in some way?

Asked by 11 months ago

I'm trying to rotate a part in a model 90", how would I go about doing this?

I'm trying to use this script right now, but it's not working:

function onClicked()
game.Workspace.SeatFC_.BedFC.SeatFC__.Orientation = 90, 0, 0

What am I doing wrong?

2 answers

Log in to vote
0
Answered by 11 months ago

You need to call the function so you would do this

script.Parent.MouseButton1Click:connect(function)
    game.Workspace.SeatFC_.BedFC.SeatFC__.Orientation = 90, 0, 0
end

If this helped you, dont forget to accept it as the answer.

0
I forgot to add the end to the end when I typed it in on the forum. xPhysicsFire -7 — 11mo
0
This is my full script: function onClicked() game.Workspace.SeatFC_.BedFC.Union1.Transparency = 0 game.Workspace.SeatFC_.BedFC.Union2.Transparency = 0 game.Workspace.SeatFC_.BedFC.Union3.Transparency = 0 game.Workspace.SeatFC_.BedFC.Union4.Transparency = 0 game.Workspace.SeatFC_.BedFC.SeatFC__.Configuration["Arms Angle"].Value = -90 game.Workspace.SeatFC_.BedFC.SeatFC__.Configuration["Head xPhysicsFire -7 — 11mo
0
Yeah, dont juse do functionOnClicked(), do script.Parent.MouseButton1Click:connect(function) KennySfromTitan 106 — 11mo
Ad
Log in to vote
0
Answered by 11 months ago
Edited 11 months ago

You need a CFrame value. Like this.

workspace.Part.CFrame =  CFrame.Angles(90, 0, 0)

Sorry I can't explain much because I'm on a phone.

0
Responding to you and Kenny, adding the MouseButton1Click made my button no longer work, and the vector3 didn't fix anything. Are there any other issues..? xPhysicsFire -7 — 11mo
0
Maybe try my edit. hiimgoodpack 1824 — 11mo
0
Do you have discord, so we can troubleshoot this over dm? xPhysicsFire -7 — 11mo
0
no hiimgoodpack 1824 — 11mo

Answer this question