как сделать гуи кнопку, прислать другу
https://www.donationalerts.com/r/donabb script\ local frame = script.Parent.Parent. Background -- the background frame script.Parent.MouseButton1Click:Connect(function() -- when the button is clicked if frame.Visible == true then -- Checks if the frame is already open frame.Visible = false -- if it is, "close" it else -- if the frame is closed frame.Visible = true -- open the frame end end) script 2\ local button = script.Parent local SocialService = game:GetService("SocialService") local player = game.Players.LocalPlayer function onButtonPressed() local success, result = pcall( function() return SocialService:CanSendGameInviteAsync(player) end ) if result == true then SocialService:PromptGameInvite(player) end end button.MouseButton1Click:Connect(onButtonPressed) button.TouchTap:Connect(onButtonPressed)
https://www.donationalerts.com/r/donabb script\ local frame = script.Parent.Parent. Background -- the background frame script.Parent.MouseButton1Click:Connect(function() -- when the button is clicked if frame.Visible == true then -- Checks if the frame is already open frame.Visible = false -- if it is, "close" it else -- if the frame is closed frame.Visible = true -- open the frame end end) script 2\ local button = script.Parent local SocialService = game:GetService("SocialService") local player = game.Players.LocalPlayer function onButtonPressed() local success, result = pcall( function() return SocialService:CanSendGameInviteAsync(player) end ) if result == true then SocialService:PromptGameInvite(player) end end button.MouseButton1Click:Connect(onButtonPressed) button.TouchTap:Connect(onButtonPressed)
