Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local module = require(script.CustomHotbar)
- local hotbar = module.new(script.Parent:WaitForChild("Hotbar"),script:WaitForChild("Template"))
- local tweens = game:GetService("TweenService")
- local sizes = {
- normal = UDim2.fromScale(0.08,0.8),
- goal = UDim2.fromScale(0.1,1)
- }
- hotbar.Equipped:Connect(function(tool,frame)
- local info = TweenInfo.new(.3,Enum.EasingStyle.Bounce)
- tweens:Create(frame,info,{Size = sizes.goal, BackgroundTransparency = 0}):Play()
- end)
- hotbar.Unequipped:Connect(function(tool,frame)
- local info = TweenInfo.new(.3,Enum.EasingStyle.Bounce)
- tweens:Create(frame,info,{Size = sizes.normal, BackgroundTransparency = .5}):Play()
- end)
Advertisement
Add Comment
Please, Sign In to add comment