Sliders

I might fix how slider's hitbox is so small.

To create a slider, use this.

local Slider = Tabs.Main:AddSlider("Slider", 
{
    Title = "Slider",
    Description = "This is a slider",
    Default = 2,
    Min = 0,
    Max = 5,
    Rounding = 1,
    Callback = function(Value)
        print("Slider was changed:", Value)
    end
})
circle-exclamation

Change local Slider to a different variable name every time. It can be anything.

Slider (name of slider) is saved in the Options variable.

You can try to remove it, but I've never tried to.

You can get the value anywhere simply by using this: (Put your variable name)

Or, whatever you put as the name of the toggle.

Functions

You can check when the slider is changed, but Callback does the same thing.

To set the value of a slider, use this.

circle-exclamation

Last updated