So, in the editor, the animation is perfectly smooth. But here’s what it looks like in-game:
robloxapp-20220814-1453452.wmv (489.7 KB)
Why is it getting cut in the middle then smooth at the end??? Help!
Here’s the script btw
repeat wait() until game.Players.LocalPlayer
local UIS = game:GetService("UserInputService")
local RS = game:GetService("ReplicatedStorage")
local TS = game:GetService("TweenService")
local Character = game.Players.LocalPlayer.Character
local IsOn, DashLength, Cooldown = nil, .3, 1
local DashAnimation = Character.Humanoid:LoadAnimation(script:WaitForChild("Dash"))
DashAnimation.Priority = Enum.AnimationPriority.Action
local DefaultView = 70
local DashSpeed = 10
local TrashTable = {}
UIS.InputBegan:Connect(function(Input,IsTyping)
if IsTyping then return end
if Input.KeyCode == Enum.KeyCode.Q then
if IsOn then return end
IsOn = true
local BV = Instance.new("BodyVelocity", Character.Torso)
BV.MaxForce = Vector3.new(100000,200,100000)
BV.Velocity = Character.HumanoidRootPart.CFrame.LookVector * DashSpeed
TrashTable[Character] = BV
DashAnimation:Play()
local Infomation = TweenInfo.new(DashLength, Enum.EasingStyle.Linear,Enum.EasingDirection.InOut,0,true,0)
TS:Create(game.Workspace.CurrentCamera,Infomation, {FieldOfView = DefaultView + 0}):Play()
task.wait(DashLength)
TrashTable[Character]:Destroy()
TrashTable[Character] = nil
task.wait(Cooldown)
IsOn = nil
end
end)