Im just really confused why it does this:
local guiWordTable = {
["guikey"] = Skillslot1
}
Slot1.MouseButton1Click:Connect(function()
guiWordTable["guikey"] = Skillslot1
end)
Slot2.MouseButton1Click:Connect(function()
guiWordTable["guikey"] = Skillslot2
end)
local cooldown = script.Parent.Values.Cooldown.Value
local last = tick() - cooldown
if last > cooldown then last = cooldown end
detroit.OnClientEvent:Connect(function()
local change = 1 - (last/cooldown)
guiWordTable["guikey"]:TweenSize(UDim2.new(1,0,change,0),"In","Linear",0.3)
wait(cooldown)