On the first parameter of TweenInfo “.3”
yes like that, it should be the timer and tween preferences since you said there’s none of the other script interrupting.
This is what im getting: (My file is bigger than 10 mb)
How can I make it so it goes from large to small when a player clicks out of it?
show all scripts in UI [limit]
Ok it actually plays but i feel like your other scripts are setting it since i see the tween play at the end but your whole shop GUI disappears before that plays.
so it wasn’t about the timer but rather how your script manages it, also i see there’s 2 another script in the pic there so def checking out if there’s smth connected to that button???
Never mind, I just changed the easingstyle to Sine, and it looks fine, I just want to know how I can add an animation when a player clicks out of the shop, going from large to small. Here is a rec of what I got:
Plus the script im using:
local TweenService = game:GetService(“TweenService”)
local UIScale = script.Parent.Parent.ShopFrame.UIScale
local Enabled = false
local Animations = {
ScaleEnable = TweenService:Create(UIScale, TweenInfo.new(.1, Enum.EasingStyle.Sine, Enum.EasingDirection.Out), {
Scale = 1
}),
ScaleDisable = TweenService:Create(UIScale, TweenInfo.new(.1, Enum.EasingStyle.Sine, Enum.EasingDirection.In), {
Scale = 0
})
}
script.Parent.MouseButton1Click:Connect(function()
if not Enabled then
Enabled = true
Animations.ScaleEnable:Play()
else
Enabled = false
Animations.ScaleDisable:Play()
end
end)
It’s not about the animation, but about your scripts. As I understand it, you use free models from Toolbox, so you don’t know how to properly configure their script? Find the Visible parameter in your scripts and remove it so that it does not interact with the frame.
set enable to false in this script (try to disable or comment this script)
Its not working, I unenabled the script and the whole thing just broke
I dont think it has anything to do with that script
it’s because visible of frame is false by default (change it to true)
Alright im going to try that out
yeah that’s where things go wrong, those script are connecting an event to the button and still setting the visibility when running the game (you have 2 connections to it which is why they’re invisible after you press the button twice) you should delete the function “toggleShopFrame” and that event below it.
set the visibility on the tween script instead after the tween finishes playing.
I changed unenabled the script and changed the visibility of the frame to true, and nothing really changed. Im not getting the animation when I click out of the shop
Delete this
Anything else I need to do after deleting it?
no ---------------------------------------------d
Alright it works, thanks a ton which reply do I put as solution