Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Sword is not animating well and is turning inside out?

So I got some things from the internet that I should rotate my sword using grip, which I did, but it is not really doing what I want it to do. When I click (I used a click function) it turns inside out and it doesn't go back to it's original idle positon (the position that it is before I click). It's either I do some complex scripting, which will probably take a long time, or I could get some advice from you guys on what I should do to help my sword. Anyways here is my code, I hope you read this.

script.Parent.Activated:Connect(function()
 if NEXTB == true then
       doubleclicked = true 
    wait(0.1)
    doubleclicked = false
    -- your function
script.Parent.GripForward = Vector3.new(0, 1, 0)
script.Parent.GripPos = Vector3.new(0, 0, 0)
script.Parent.GripRight = Vector3.new(0, 0, -1)
script.Parent.GripUp = Vector3.new(1, 0, 0)
wait(1)
script.Parent.GripForward = Vector3.new(0, 0, -1)
script.Parent.GripPos = Vector3.new(0, 0, 0)
script.Parent.GripRight = Vector3.new(1, 0, 0)
script.Parent.GripUp = Vector3.new(0, 1, 0)
        end
end)

1 answer

you should save the old grip positions as variables and when you need to reset, set the grips to the corresponding variables

1 comment

0

Wait, how do you set variables like 1, 1, 1 are those tables? I forgot

This discussion is preserved as it was. New answers, comments, and votes are closed.