speed up animations slider troll fe
Key RequiredUniversal

speed up animations slider troll fe

Universal Scriptgentgent 7.3K views 239 executesUpdated Mar 11, 2025
5.0/ 5(1 votes)
10100% Positive
Lua Script•112 lines (3561 chars)
local Players = game:GetService("Players")
local UserInputService = game:GetService("UserInputService")
local RunService = game:GetService("RunService")
local player = Players.LocalPlayer

local ScreenGui = Instance.new("ScreenGui")
ScreenGui.ResetOnSpawn = false
ScreenGui.Parent = player:WaitForChild("PlayerGui")

local Frame = Instance.new("Frame")
Frame.Size = UDim2.new(0.3, 0, 0.15, 0)
Frame.Position = UDim2.new(0.35, 0, 0, 10)
Frame.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
Frame.BorderSizePixel = 2
Frame.Parent = ScreenGui

local Slider = Instance.new("Frame")
Slider.Size = UDim2.new(0.9, 0, 0.3, 0)
Slider.Position = UDim2.new(0.05, 0, 0.5, 0)
Slider.BackgroundColor3 = Color3.fromRGB(100, 100, 100)
Slider.BorderSizePixel = 1
Slider.Parent = Frame

local Knob = Instance.new("Frame")
Knob.Size = UDim2.new(0.05, 0, 1, 0)
Knob.Position = UDim2.new(0.5, 0, 0, 0)
Knob.BackgroundColor3 = Color3.fromRGB(200, 200, 200)
Knob.BorderSizePixel = 1
Knob.Parent = Slider

local Label = Instance.new("TextLabel")
Label.Size = UDim2.new(1, 0, 0.3, 0)
Label.Position = UDim2.new(0, 0, 0.1, 0)
Label.BackgroundTransparency = 1
Label.TextColor3 = Color3.fromRGB(255, 255, 255)
Label.TextScaled = true
Label.Text = "Speed: 1"
Label.Parent = Frame

local TextBox = Instance.new("TextBox")
TextBox.Size = UDim2.new(0.9, 0, 0.3, 0)
TextBox.Position = UDim2.new(0.05, 0, 0.8, 0)
TextBox.BackgroundColor3 = Color3.fromRGB(150, 150, 150)
TextBox.TextScaled = true
TextBox.Text = "1"
TextBox.Parent = Frame

local minSpeed, maxSpeed, defaultSpeed = 0.1, 15, 1
local dragging = false
local currentSpeed = defaultSpeed
local manualOverride = false

local function updateSpeed(xPos)
    if manualOverride then return end
    local relativePos = math.clamp((xPos - Slider.AbsolutePosition.X) / Slider.AbsoluteSize.X, 0, 1)
    currentSpeed = minSpeed + (maxSpeed - minSpeed) * relativePos
    currentSpeed = math.round(currentSpeed * 10) / 10
    Knob.Position = UDim2.new(relativePos, 0, 0, 0)
    Label.Text = "Speed: " .. tostring(currentSpeed)
    TextBox.Text = tostring(currentSpeed)
end

Knob.InputBegan:Connect(function(input)
    if input.UserInputType == Enum.UserInputType.MouseButton1 then
        dragging = true
        manualOverride = false
    end
end)

UserInputService.InputChanged:Connect(function(input)
    if dragging and input.UserInputType == Enum.UserInputType.MouseMovement then
        updateSpeed(input.Position.X)
    end
end)

UserInputService.InputEnded:Connect(function(input)
    if input.UserInputType == Enum.UserInputType.MouseButton1 then
        dragging = false
    end
end)

TextBox.FocusLost:Connect(function()
    local enteredSpeed = tonumber(TextBox.Text)
    if enteredSpeed then
        currentSpeed = enteredSpeed
        Label.Text = "Speed: " .. tostring(currentSpeed)
        manualOverride = true
    else
        TextBox.Text = tostring(currentSpeed)
    end
end)

local function applyAnimationSpeed()
    local character = player.Character
    if character then
        local humanoid = character:FindFirstChildOfClass("Humanoid") or character:FindFirstChildOfClass("AnimationController")
        if humanoid then
            for _, track in ipairs(humanoid:GetPlayingAnimationTracks()) do
                track:AdjustSpeed(currentSpeed)
            end
        end
    end
end

RunService.Heartbeat:Connect(applyAnimationSpeed)

player.CharacterAdded:Connect(function()
    wait(1) -- Ensure character is loaded
    applyAnimationSpeed()
end)

updateSpeed(Slider.AbsolutePosition.X + (Slider.AbsoluteSize.X * 0.5))

Features & Information

speed up animations a slider textbox to get certain values

Community Comments (1)

CK5c00lkiddCK5c00lkiddAug 9, 2025

fire

More Scripts for Universal Scripts