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

How do i make a brick to spin around?

Asked by 10 years ago

Im new to scripting how do i make the spin to touch people and they died from touching it.

1 answer

Log in to vote
0
Answered by 10 years ago

Ok Basically This website is for scripting problems and not for asking people to make stuff for you but since I have nothing better to be doing I will just answer it anyway. Ok so set the rotvelocity of the part to whatever amount you are happy with then do this

function Touched (h)
    if h:FindFirstChild("humanoid") then
        if h.Parent.Humanoid.Health ~= 0 then -- kinda a debounce
            h.Parent.Humanoid.Health = 0
        end
    end
end

Game.Workspace.Part.Touched:connect(Touched)

This should work if not then sorry.

Ad

Answer this question