Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to make a block rotate forever?

Asked by 10 years ago

I want to make a block rotate forever. The RotatingSign is the model so I don't lose track of things.

local r = game.Workspace.RotatingSign.Part
repeat
    wait()
    r = r + 0.1
until r == 9999999999999999999 
0
XD I totally forgot about the rotation part in the local... raystriker6707 30 — 10y

1 answer

Log in to vote
1
Answered by
RedCombee 585 Moderation Voter
10 years ago

To me, it looks like you want a brick to rotate on the Y axis. In your first line of code, why are you receiving a part? Don't you need the rotation? In your repeat loop, part is an instance, not a number value.

local r = Workspace.RotatingSign.Part.Rotation -- Get the rotation of the brick instead of the brick
while wait() do -- The loop
r = r + Vector3.new(0,0.1,0) -- Making the brick rotate on the Y axis
end

I believe this is what you are looking for.

Ad

Answer this question