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

Why is the movement choppy?

Asked by 8 years ago

Alright, so I've been working on a 3rd person script, and it works, kinda. There are no errors, but the movement is very choppy. What I mean, is that when the player moves the mouse, the player's body does move in the right direction, however it looks rather odd for some reason. Yes, I am using RenderStepped.

game:GetService("RunService").RenderStepped:connect(function()
    bounceRate = (bounceRate or 0) + math.rad(speed)
    bounce = bounce + math.sin(bounceRate)
    local camera = workspace.CurrentCamera.CoordinateFrame.lookVector
    local angle = CFrame.Angles(0,math.atan2(camera.X,camera.Z)+math.rad(180),0)
    game.Players.LocalPlayer.Character:SetPrimaryPartCFrame(CFrame.new(game.Players.LocalPlayer.Character.PrimaryPart       .CFrame.p)*angle)
    game.Players.LocalPlayer.Character.Humanoid.CameraOffset = offset*Vector3.new(1,(bounce/(100))+1,1)
    for _,part in pairs(parts) do
        if part:IsA("BasePart") then
            part.LocalTransparencyModifier = 0
        end
    end
end)

There's the main code. If you want to see what I mean, here's the place: http://www.roblox.com/games/301680604/Waffloids-Place-Number-12808

0
It's not choppy at all? Validark 1580 — 8y
0
Really? It is for me.. Waffloid 15 — 8y

1 answer

Log in to vote
0
Answered by 8 years ago

You could be experiencing this due to the fact that your graphic quality is set too high, try to turn it down a bit, I like to use 2, every game runs smooth for me that way. You can find it if you press Esc and go to settings while in your game. The issue is anyways with you. Your other option is to update your video player, such as Java.

Ad

Answer this question