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

wall fling velocity wont add velocity?

Asked by 2 years ago
Edited 2 years ago

For context, i just want to fling a wall with the click of a GUI button, this is a script in serverscript service specifically reserved for Events For some reason, all it does is unanchor the peice and disable its script, nothing else happens. it also prints the text too which is weird, i also get no errors

local ReplicatedStorage = game:GetService("ReplicatedStorage")

ReplicatedStorage.FlingGroupWall.OnServerEvent:Connect(function(player)
    local Wall = game.Workspace.GroupInWall

    Wall.Anchored = false
    Wall.Script.Disabled = true
    wait(0.1)
    print("Wall Flinging")
    Wall.Attachment.LinearVelocity.VectorVelocity = Vector3.new(1000, 1000, 1000)
    wait(3)
    Wall.Attachment.LinearVelocity.VectorVelocity = Vector3.new(0, 0, 0)
    print("Wall Flung")
end)

Answer this question