Keybind
Last updated
Was this helpful?
Last updated
Was this helpful?
Section:Keybind({
Name <string>
Default <enum>
Blacklist <table: <... enum>>
Callback <function(): enum>
onBinded <function(): enum>
onBindHeld <function(): boolean, enum>
}, <string or nil> Flag)
Functions
:UpdateName(<string>)
:SetVisiblity(<boolean>)
:Unbind()
:Bind(<enum>)
:GetBind(: enum)
.Bind : enum
.IgnoreConfig <boolean>
.Settings : table -- Not everything may be updated, but Callback should be correct.
Example
sections.MainSection1:Keybind({
Name = "Reset Inventory",
Callback = function(binded)
Window:Notify({
Title = "Kuzu Hub",
Description = "Successfully Reset Inventory",
Lifetime = 3
})
end,
onBinded = function(bind)
Window:Notify({
Title = "Kuzu Hub",
Description = "Rebinded Reset Inventory to "..tostring(bind.Name),
Lifetime = 3
})
end,
}, "ResetInventoryBind")