im making animation gui gampass and when i open and close the scale is not workng well and the position change. please help me i tried everything.
script:
local GamepassId = 21177189 -- example
local frameToShow = script.Parent -- example
local player = game.Players.LocalPlayer
repeat wait() until player.Character -- waits for player to load in
local PlayerGui = player:WaitForChild("PlayerGui"):WaitForChild("ScreenGui")
-- quote me if im wrong, but that should work
local MarketplaceService = game:GetService("MarketplaceService")
if MarketplaceService:UserOwnsGamePassAsync(player.UserId, GamepassId) then
frameToShow.Visible = true
end
local button = script.Parent
local frame = script.Parent.Parent.AnimationsBG
local debounce = false
button.MouseButton1Up:Connect(function()
script.Parent.ClickSound:Play()
if debounce == false then
debounce = true
frame.Visible = true
elseif debounce == true then
debounce = false
frame.Visible = false
end
end)
animation gui model: Animation Gui - Roblox