#Can someone help me on my menu

1 messages · Page 1 of 1 (latest)

south owl
#

when i click the shop button it should make ButtonFrame visable = true and the Shop visable = true this is the code inside the button

local shopButton = script.Parent -- The 'ShopButton' frame
local mainGui = shopButton.Parent.Parent.Parent.Parent -- The 'Main' ScreenGui

-- Locating the target frames using your exact names
local mainFrame = mainGui:WaitForChild("MainFrame")
local buttonFrame = mainFrame:WaitForChild("ButtonFrame") -- No 's' at the end
local shopPage = buttonFrame:WaitForChild("Shop") -- Shop is directly in ButtonFrame

shopButton.InputBegan:Connect(function(input)
-- Detects mouse click or mobile touch
if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then

    -- 1. Make the container and shop visible
    buttonFrame.Visible = true
    shopPage.Visible = true

    -- 2. Hide the 4-button selection grid so it doesn't overlap
    shopButton.Parent.Parent.Visible = false

    print("Shop is now visible!")
end

end)

south owl
#

how can i fix it

summer plaza
#

are you trying to learn scripting or no

south owl
#

bcs when i manualy do it it still dont work

south owl
summer plaza
#

so

#

define the frame and the button

#

then do button.MouseButton1Click:Connect(function()

end)

#

and in that function put

#

frame.Visible = not frame.Visible

#

thats all

#

5 lines

south owl
#

for the button?

summer plaza
south owl
#

its still not working

summer plaza
#

whyd u add those other 4 lines

#

in the function

#

remove them

#

only keep frame.Visible = not frame.Visible

#

yo wtf is this setup

#

what are u trying to do

#

u do shopPage.Visible = not shopPage.Visible

south owl
#

so del 11/14?

summer plaza
#

yes and change buttonframe to shopframe

#

what is buttonframe bro

south owl
#

ButtonFrames

#

is a frame

summer plaza
#

i mean u defined it wrong

#

u defined it as ButtonFrame but its name is ButtonFrames

#

DUDE WTF IS THIS SETUP

#

WHY DO U HAVE FRAMES INSIDE FRAMES INSIDE FRAMES

#

im actually crashing out

south owl
#

to make it organised

summer plaza
#

that is NOT organized

south owl
#

its kinda hard being the only dev working on a basketball game

summer plaza
#

i think the issue is that you have 0 idea how to use roblox studio

south owl
summer plaza
#

yeah i understand but this is so fucked

#

maybe dont work on such a big project yet

#

basketballs are very difficult to script

#

and if youre just gonna copy paste code from ai or a youtube tutorial, then whats the point

south owl
summer plaza
#

then how do u have no idea how to use studio

#

you mustve learned something

#

why is the buttonframes a frame

south owl
#

i know how to code my effects its just this ui is buggin ive made an ui before and scripted it its just like for this ui im using a like mini menu

summer plaza
#

its supposed to he a screengui

#

but u dont need to put them in the same folder at all

summer plaza
#

uh

#

why are alot of the uis in a frame (buttonframes)

#

a frame isnt a folder

#

i mean itd work if the buttonframes frame was visible but transparency 1 by default and u only edit the visibility of the frames inside it

#

but its like pointless and not organizing and messy and confusing

south owl
#

iam just remove the ButtonsFrames

#

so it will become easier

#

i spelled that wrong

#

💀

summer plaza
#

yeah

south owl
#

@summer plaza

#

i just coded it

summer plaza
#

ok

south owl
#

local Button = script.Parent
local shopFrame = script.Parent.Parent.ShopFrame

Button.MouseButton1Click:Connect(function()
shopFrame.Visible = not shopFrame.Visible
end)

#

thats the code

#

@summer plaza no ai

summer plaza
#

sick

#

im proud

south owl
#

w

south owl
#

@summer plaza

#

i have 1 last issue

summer plaza
#

what

south owl
#

and its not ui

summer plaza
#

what

south owl
#

so when the player gets close to the mid why do the OnButton not show up so if i click the on button when i get close to the HomeHitBox it should Teleport my player to the mid

#

@summer plaza i have the teleport thing down its just the ui is not showing up

summer plaza
#

what are the video and pictures showing

#

im so confused

south owl
#

the pad system

summer plaza
south owl
#

no if player gets near the hitbox

summer plaza
#

show script

south owl
#

local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local ShowExitUI = ReplicatedStorage:WaitForChild("ShowExitUI")

local padsFolder = workspace.Court2.Main.Pads
local homeHitbox = padsFolder.Home.HomeHitbox
local awayHitbox = padsFolder.Away.AwayHitbox

local homeMid = padsFolder.Home.a:WaitForChild("mid")
local awayMid = padsFolder.Away.a:WaitForChild("mid")

local function teleportAndFreeze(hit, targetPart)
local character = hit.Parent
local player = Players:GetPlayerFromCharacter(character)
local rootPart = character:FindFirstChild("HumanoidRootPart")
local humanoid = character:FindFirstChildOfClass("Humanoid")

if player and rootPart and humanoid and not rootPart.Anchored then

    
    rootPart.AssemblyLinearVelocity = Vector3.new(0, 0, 0)
    rootPart.AssemblyAngularVelocity = Vector3.new(0, 0, 0)
    humanoid.WalkSpeed = 0 

    
    rootPart.CFrame = targetPart.CFrame * CFrame.new(0, 3, 0)
    rootPart.Anchored = true

    
    humanoid.PlatformStand = true -- Forces a neutral state

    
    local animateScript = character:FindFirstChild("Animate")
    if animateScript then 
        animateScript.Disabled = true 
    end

    
    local animator = humanoid:FindFirstChildOfClass("Animator")
    if animator then
        for _, track in pairs(animator:GetPlayingAnimationTracks()) do
            track:Stop(0) -- Instant stop
        end
    end

    
    ShowExitUI:FireClient(player)
end

end

-- Connecting the hitboxes
homeHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, homeMid) end)
awayHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, awayMid) end)

summer plaza
#

can u send it using lua formatting

south owl
#

its located in the serverscript servive

summer plaza
#

with ```lua

south owl
#

wym

summer plaza
#

the one above tab

#

so before the script type 3 of the quotation things above tab and lua next to it

#

and in the end put 3 of the things above tab again

#

i cant im on phone

south owl
#
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local ShowExitUI = ReplicatedStorage:WaitForChild("ShowExitUI")


local padsFolder = workspace.Court2.Main.Pads
local homeHitbox = padsFolder.Home.HomeHitbox
local awayHitbox = padsFolder.Away.AwayHitbox


local homeMid = padsFolder.Home.a:WaitForChild("mid")
local awayMid = padsFolder.Away.a:WaitForChild("mid")

local function teleportAndFreeze(hit, targetPart)
    local character = hit.Parent
    local player = Players:GetPlayerFromCharacter(character)
    local rootPart = character:FindFirstChild("HumanoidRootPart")
    local humanoid = character:FindFirstChildOfClass("Humanoid")

    
    if player and rootPart and humanoid and not rootPart.Anchored then

        
        rootPart.AssemblyLinearVelocity = Vector3.new(0, 0, 0)
        rootPart.AssemblyAngularVelocity = Vector3.new(0, 0, 0)
        humanoid.WalkSpeed = 0 

        
        rootPart.CFrame = targetPart.CFrame * CFrame.new(0, 3, 0)
        rootPart.Anchored = true

        
        humanoid.PlatformStand = true -- Forces a neutral state

        
        local animateScript = character:FindFirstChild("Animate")
        if animateScript then 
            animateScript.Disabled = true 
        end

        
        local animator = humanoid:FindFirstChildOfClass("Animator")
        if animator then
            for _, track in pairs(animator:GetPlayingAnimationTracks()) do
                track:Stop(0) -- Instant stop
            end
        end

        
        ShowExitUI:FireClient(player)
    end
end

-- Connecting the hitboxes
homeHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, homeMid) end)
awayHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, awayMid) end)```
summer plaza
#

ye but do ‘’’lua at the beginning

#

not just ‘’’

south owl
#

oh

#
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local ShowExitUI = ReplicatedStorage:WaitForChild("ShowExitUI")


local padsFolder = workspace.Court2.Main.Pads
local homeHitbox = padsFolder.Home.HomeHitbox
local awayHitbox = padsFolder.Away.AwayHitbox


local homeMid = padsFolder.Home.a:WaitForChild("mid")
local awayMid = padsFolder.Away.a:WaitForChild("mid")

local function teleportAndFreeze(hit, targetPart)
    local character = hit.Parent
    local player = Players:GetPlayerFromCharacter(character)
    local rootPart = character:FindFirstChild("HumanoidRootPart")
    local humanoid = character:FindFirstChildOfClass("Humanoid")

    
    if player and rootPart and humanoid and not rootPart.Anchored then

        
        rootPart.AssemblyLinearVelocity = Vector3.new(0, 0, 0)
        rootPart.AssemblyAngularVelocity = Vector3.new(0, 0, 0)
        humanoid.WalkSpeed = 0 

        
        rootPart.CFrame = targetPart.CFrame * CFrame.new(0, 3, 0)
        rootPart.Anchored = true

        
        humanoid.PlatformStand = true -- Forces a neutral state

        
        local animateScript = character:FindFirstChild("Animate")
        if animateScript then 
            animateScript.Disabled = true 
        end

        
        local animator = humanoid:FindFirstChildOfClass("Animator")
        if animator then
            for _, track in pairs(animator:GetPlayingAnimationTracks()) do
                track:Stop(0) -- Instant stop
            end
        end

        
        ShowExitUI:FireClient(player)
    end
end

-- Connecting the hitboxes
homeHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, homeMid) end)
awayHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, awayMid) end)```
summer plaza
#
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local ShowExitUI = ReplicatedStorage:WaitForChild("ShowExitUI")


local padsFolder = workspace.Court2.Main.Pads
local homeHitbox = padsFolder.Home.HomeHitbox
local awayHitbox = padsFolder.Away.AwayHitbox


local homeMid = padsFolder.Home.a:WaitForChild("mid")
local awayMid = padsFolder.Away.a:WaitForChild("mid")

local function teleportAndFreeze(hit, targetPart)
    local character = hit.Parent
    local player = Players:GetPlayerFromCharacter(character)
    local rootPart = character:FindFirstChild("HumanoidRootPart")
    local humanoid = character:FindFirstChildOfClass("Humanoid")

    
    if player and rootPart and humanoid and not rootPart.Anchored then

        
        rootPart.AssemblyLinearVelocity = Vector3.new(0, 0, 0)
        rootPart.AssemblyAngularVelocity = Vector3.new(0, 0, 0)
        humanoid.WalkSpeed = 0 

        
        rootPart.CFrame = targetPart.CFrame * CFrame.new(0, 3, 0)
        rootPart.Anchored = true

        
        humanoid.PlatformStand = true -- Forces a neutral state

        
        local animateScript = character:FindFirstChild("Animate")
        if animateScript then 
            animateScript.Disabled = true 
        end

        
        local animator = humanoid:FindFirstChildOfClass("Animator")
        if animator then
            for _, track in pairs(animator:GetPlayingAnimationTracks()) do
                track:Stop(0) -- Instant stop
            end
        end

        
        ShowExitUI:FireClient(player)
    end
end

-- Connecting the hitboxes
homeHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, homeMid) end)
awayHitbox.Touched:Connect(function(hit) teleportAndFreeze(hit, awayMid) end)```
summer plaza
#

that youre trying to open a ui for a player from a serverscript

south owl
#

do it need to be a local script?

floral cypressBOT
#

studio** You are now Level 4! **studio

south owl
#

or how should i fix this problem @summer plaza

summer plaza
#

show the clientscript

#

its firing a remoteevent to the client

#

send the clientscript that listens for that remote

#

afk i gotta brush my teeth

south owl
#

oh

#

found it

#

this is the local sript for it in starterplayerscripts

#
local player = game.Players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")

-- Paths to your objects
local mainGui = playerGui:WaitForChild("Main")
local onButton = mainGui:WaitForChild("Buttons"):WaitForChild("OnButton")
local hitbox = workspace:WaitForChild("Court2").Main.Pads.Home:WaitForChild("HomeHitbox")

local DISTANCE_LIMIT = 10 -- Adjust this to how close you want to be

RunService.Heartbeat:Connect(function()
    local char = player.Character
    local root = char and char:FindFirstChild("HumanoidRootPart")

    if root then
        -- Calculate distance between player and hitbox
        local distance = (root.Position - hitbox.Position).Magnitude

        if distance <= DISTANCE_LIMIT then
            onButton.Visible = true -- Button appears on screen
        else
            onButton.Visible = false -- Button vanishes when walking away
        end
    end
end)```
summer plaza
#

umm

#

so what is the first script supposed to do

south owl
#

but it dont'

summer plaza
#

whats the fireclient for

#

does it do anything

south owl
#

no

summer plaza
#

@south owl is the onButton under any frame or screengui

#

and are you sure you are going near the correct hitbox

south owl
#

and idk why but when i do get teleported to mid the player is still walking idk why that is

#

thats why i did a vid

summer plaza
#

and the buttons gui is enabled??

south owl
summer plaza
#

where is the script and is it a localscript

#

do u get any errors in the output

south owl
south owl
summer plaza
#

up the distance limit to 20 rq

#

to test

#

to be honest the script looks good so it must be something with the onbutton

#

or the hitbox

south owl
#

i changed it to 20

#

and when i get teleported to the mid i am still walking idk why'

#

unless this is the reason


-- Configuration
local COURT_PADS_FOLDER = workspace:WaitForChild("Court2"):WaitForChild("Pads")

local function onPadTouch(hit, midPart)
    local character = hit.Parent
    local player = Players:GetPlayerFromCharacter(character)
    local humanoid = character:FindFirstChildOfClass("Humanoid")
    local rootPart = character:FindFirstChild("HumanoidRootPart")

    -- Check if it's a valid player who isn't already locked
    if player and rootPart and humanoid and not rootPart:FindFirstChild("LockedOnPad") then

        -- 1. Teleport to the "mid" part position
        -- We add 3 studs to Y so the character doesn't get stuck in the floor
        rootPart.CFrame = midPart.CFrame * CFrame.new(0, 3, 0)

        -- 2. Freeze the character
        rootPart.Anchored = true

        -- 3. Add a tag so the script knows they are already on a pad
        local tag = Instance.new("BoolValue")
        tag.Name = "LockedOnPad"
        tag.Parent = rootPart

        print(player.Name .. " is now waiting on the court.")
    end
end

-- Loop through all pads (Away and Home) to set up the touch events
for _, teamFolder in pairs(COURT_PADS_FOLDER:GetChildren()) do
    for _, padModel in pairs(teamFolder:GetChildren()) do
        local triggerPad = padModel:FindFirstChild("a") -- The pad you walk on
        local targetMid = padModel:FindFirstChild("mid") -- The part you teleport to

        if triggerPad and targetMid then
            triggerPad.Touched:Connect(function(hit)
                onPadTouch(hit, targetMid)
            end)
        end
    end
end```
#

@summer plaza

summer plaza
#

humanoid:ChangeState(Enum.HumanoidStateType.Frozen)

#

replace walkspeed = 0 with this

south owl
#

what line @summer plaza

#

and which script

summer plaza
#

i meant replace rootpart.anchored with that

floral cypressBOT
#

studio** You are now Level 11! **studio

south owl
summer plaza
#

i mean does it work

south owl
#

no

uneven ginkgo
#

why is this chat so long

south owl
uneven ginkgo
#

anyways

#

im supposed to help now

south owl
uneven ginkgo
summer plaza
summer plaza
uneven ginkgo
#

to

summer plaza
#

lol oknfine gn

south owl
uneven ginkgo
#

just give me a sec to read through all this

south owl
floral cypressBOT
#

studio** You are now Level 5! **studio

south owl
#

i figured it out

uneven ginkgo
#

oh gj

#

i dont need to do anything

#

hooray

south owl
#

wwwwwwwwwwww

#

right

south owl
#

@uneven ginkgo

#

i need u rq

uneven ginkgo
#

with what

south owl
# uneven ginkgo with what

so like it shows the button when player gets close to the part its just when button clicked it dont teleport them to mid

uneven ginkgo
#

none of the teleport code would be in here

south owl
#

where do i put the teleport code

uneven ginkgo
#

do you have code that loooks like

Event.OnServerEvent:Connect(function()
-- stuff
end)

#

or like
TeleportRequest.OnServerEvent:Connect(function()
-- stuff
end)

#

ok then

uneven ginkgo
#

one sec

south owl
#

okay

uneven ginkgo
#

where do you want it to teleport too

south owl
uneven ginkgo
#
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local TeleportRequest = ReplicatedStorage.TeleportRequest

TeleportRequest.OnServerEvent:Connect(function(player)
    local character = player.Character
    
    local hrp = character:FindFirstChild("HumanoidRootPart")
    hrp.Position = Vector3.new(-- position you want to teleport to)
end)
uneven ginkgo
# south owl

i would need to know a parts name there or the position

south owl
#

mid

uneven ginkgo
#

you could add an invisable part named TeleportArea

#

make it a bit easier for you

south owl
#

should i just rename mid

#

to TeleportArea

uneven ginkgo
#

ok can

#

which part is mid

south owl
#

look in the ss

#

i just renamed it to TeleportArea

#

@uneven ginkgo

uneven ginkgo
#

ok

#
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local TeleportRequest = ReplicatedStorage.TeleportRequest

TeleportRequest.OnServerEvent:Connect(function(player)
    local character = player.Character
    
    local hrp = character:FindFirstChild("HumanoidRootPart")
    hrp.Position = workspace.TeleportArea.Position + Vector3.new(0, 4, 0)
end)

south owl
#

what do i replace that with?

#

@uneven ginkgo

uneven ginkgo
#

just put it in a server script

south owl
uneven ginkgo
south owl
#

when i click the button it still dosent teleport the player to mid

#

should i remove the teleport from the button code or no?

urban pivot
#

@uneven ginkgo are u on 24/7

uneven ginkgo
uneven ginkgo
uneven ginkgo
south owl
uneven ginkgo
south owl
#

it says its waiting for an remote event lemme fix that

#

okay so there is no errors but when i click the button a few times it dissapear but it dosent teleport the player to the TeleportArea

#

@uneven ginkgo

uneven ginkgo
#

some of the paths are prob wrong

#

just send the rbxl

#

its just faster

south owl
#

file?

uneven ginkgo
#

yeah

south owl
#

@uneven ginkgo its the first pad

uneven ginkgo
# south owl <@1383293550032322630> its the first pad
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local TeleportRequest = ReplicatedStorage.TeleportRequest

TeleportRequest.OnServerEvent:Connect(function(player)
    local character = player.Character

    local hrp = character:FindFirstChild("HumanoidRootPart")
    hrp.Position = workspace.Court2.Main.Pds.Home.A.TeleportRequest.Position + Vector3.new(0, 4, 0)
end)
#

there was errors in the output

south owl
#

oh

#

is that the error code @uneven ginkgo

uneven ginkgo
south owl
uneven ginkgo
# south owl when i click the button it still dont teleport
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local TeleportRequest = ReplicatedStorage.TeleportRequest

TeleportRequest.OnServerEvent:Connect(function(player)
    local character = player.Character

    local hrp = character:FindFirstChild("HumanoidRootPart")
    hrp.Position = workspace.Court2.Main.Pads.Home.a.TeleportArea.Position + Vector3.new(0, 4, 0)
end)
south owl
#

w so i have to make it so player freezes

#

in place

south owl
#

@uneven ginkgo the Exit button isnt working this is the code for it
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local button = script.Parent
local exitRequest = ReplicatedStorage:WaitForChild("ExitRequest")

button.MouseButton1Click:Connect(function()

exitRequest:FireServer()


button.Visible = false

end)

uneven ginkgo
#

just change the paths

#

change the remote event

#

and the place you go

south owl
#

okay so i did it and it work but it just dont freeze character when character is on TeleportArea and it unfreeze character when player is on ExitArea

#

@uneven ginkgo

#

i fixed it

#

ima need more help on sum give me a sec tho

#

@uneven ginkgo one more thing

floral cypressBOT
#

studio** You are now Level 6! **studio

south owl
#

please

fair moss
#

Fr ai sucks

south owl
#

arl so i made a working intro but

#

it dont unfreeze player when intro done and it dont make the buttons dissapear

summer plaza
south owl
summer plaza
#

what function

#

like did u just change the walkspeed

#

or

south owl
#

i just used the serverside script that u made me

local ReplicatedStorage = game:GetService("ReplicatedStorage")
local TeleportRequest = ReplicatedStorage:WaitForChild("TeleportRequest")

local targetMid = workspace.Court2.Main.Pads.Home.a:WaitForChild("TeleportArea")

TeleportRequest.OnServerEvent:Connect(function(player)
local character = player.Character
local humanoid = character and character:FindFirstChildOfClass("Humanoid")
local hrp = character and character:FindFirstChild("HumanoidRootPart")

if hrp and humanoid then
    
    hrp.AssemblyLinearVelocity = Vector3.new(0, 0, 0)

    
    hrp.CFrame = targetMid.CFrame * CFrame.new(0, 3, 0)

    
    humanoid.WalkSpeed = 0
    hrp.Anchored = true

    
    local animate = character:FindFirstChild("Animate")
    if animate then
        animate.Disabled = true
    end

    
    local playerGui = player:WaitForChild("PlayerGui")
    local buttons = playerGui:FindFirstChild("Buttons")
    if buttons then
        buttons.OnButton.Visible = false
        buttons.ExitButton.Visible = true
    end

    print(player.Name .. " has been frozen on the spot.")
end

end)

#

@summer plaza

#

thats for courtpad1

summer plaza
#

i didnt make that

#

so whats the issue

south owl
#

i can send a vid rq

summer plaza
#

the current script?

south owl
#

this is the server side script

summer plaza
#

ok give me like 10 mins

#

im on phone in bed

#

i cant check it

#

let me get up

south owl
#

no no its okay u dont have to rush

#

@summer plaza

summer plaza
#

nah its good

#

its 2pm

#

i should wake up anyway

south owl
summer plaza
#

alr

#

im on pc now

#
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local PlayIntro = ReplicatedStorage:WaitForChild("PlayIntro")

local Values = workspace.Court2.Main.Values
local homeValue = Values:WaitForChild("Home")
local awayValue = Values:WaitForChild("Away")

local homeCourtPos = workspace.Court2.Main.Positions.Home.a
local awayCourtPos = workspace.Court2.Main.Positions.Away.a

local gameStarted = false

local function startGame()
    if gameStarted then return end
    gameStarted = true

    task.wait(5) 

    local playerHome = game.Players:FindFirstChild(homeValue.Value)
    local playerAway = game.Players:FindFirstChild(awayValue.Value)

    if playerHome and playerAway then
        
        if playerHome.Character and playerHome.Character:FindFirstChild("HumanoidRootPart") then
            playerHome.Character.HumanoidRootPart.CFrame = homeCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerHome.Character.HumanoidRootPart.Anchored = false
            playerHome.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed
        end

        -- Teleport Away Player
        if playerAway.Character and playerAway.Character:FindFirstChild("HumanoidRootPart") then
            playerAway.Character.HumanoidRootPart.CFrame = awayCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerAway.Character.HumanoidRootPart.Anchored = false
            playerAway.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed
        end

        
        local matchPlayers = {playerHome, playerAway}
        for _, p in pairs(matchPlayers) do
            local pGui = p:FindFirstChild("PlayerGui")
            if pGui then
                local buttons = pGui:FindFirstChild("Buttons")
                if buttons then
                    
                    if buttons:FindFirstChild("ExitButton") then buttons.ExitButton.Visible = false end
                    if buttons:FindFirstChild("OnButton") then buttons.OnButton.Visible = false end

                    
                    if buttons:FindFirstChild("AwayButton") then 
                        buttons.AwayButton.Visible = false 
                    end
                end
            end
        end

        PlayIntro:FireAllClients()
    else
        
        gameStarted = false
    end
end

homeValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)

awayValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)
south owl
#

should i just copy+paste @summer plaza

summer plaza
#

no

#

no

#

thats not ready

#

wait

#

where is the character or player or humanoid variable

#

nvm

south owl
#

oh

#

it checks if a player is on the pad and if player is on the pad then get gets the humanoid from there

summer plaza
#

whats the default walkspeed value called in starterplayer

#

u just dont make the walkspeed 16 again

#

but

#

im not on studio rn

#

can u check

south owl
#

CharacterWalkSpeed

summer plaza
#

try now

#
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local PlayIntro = ReplicatedStorage:WaitForChild("PlayIntro")

local Values = workspace.Court2.Main.Values
local homeValue = Values:WaitForChild("Home")
local awayValue = Values:WaitForChild("Away")

local homeCourtPos = workspace.Court2.Main.Positions.Home.a
local awayCourtPos = workspace.Court2.Main.Positions.Away.a

local gameStarted = false

local function startGame()
    if gameStarted then return end
    gameStarted = true

    task.wait(5) 

    local playerHome = game.Players:FindFirstChild(homeValue.Value)
    local playerAway = game.Players:FindFirstChild(awayValue.Value)

    if playerHome and playerAway then
        
        if playerHome.Character and playerHome.Character:FindFirstChild("HumanoidRootPart") then
            playerHome.Character.HumanoidRootPart.CFrame = homeCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerHome.Character.HumanoidRootPart.Anchored = false
            playerHome.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed
        end

        -- Teleport Away Player
        if playerAway.Character and playerAway.Character:FindFirstChild("HumanoidRootPart") then
            playerAway.Character.HumanoidRootPart.CFrame = awayCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerAway.Character.HumanoidRootPart.Anchored = false
            playerAway.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed
        end

        
        local matchPlayers = {playerHome, playerAway}
        for _, p in pairs(matchPlayers) do
            local pGui = p:FindFirstChild("PlayerGui")
            if pGui then
                local buttons = pGui:FindFirstChild("Buttons")
                if buttons then
                    
                    if buttons:FindFirstChild("ExitButton") then buttons.ExitButton.Visible = false end
                    if buttons:FindFirstChild("OnButton") then buttons.OnButton.Visible = false end

                    
                    if buttons:FindFirstChild("AwayButton") then 
                        buttons.AwayButton.Visible = false 
                    end
                end
            end
        end

        PlayIntro:FireAllClients()
    else
        
        gameStarted = false
    end
end

homeValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)

awayValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)
south owl
#

copy+Paste?

summer plaza
#

ye

#
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local PlayIntro = ReplicatedStorage:WaitForChild("PlayIntro")

local Values = workspace.Court2.Main.Values
local homeValue = Values:WaitForChild("Home")
local awayValue = Values:WaitForChild("Away")

local homeCourtPos = workspace.Court2.Main.Positions.Home.a
local awayCourtPos = workspace.Court2.Main.Positions.Away.a

local gameStarted = false

local function startGame()
    if gameStarted then return end
    gameStarted = true

    task.wait(5) 

    local playerHome = game.Players:FindFirstChild(homeValue.Value)
    local playerAway = game.Players:FindFirstChild(awayValue.Value)

    if playerHome and playerAway then
        
        if playerHome.Character and playerHome.Character:FindFirstChild("HumanoidRootPart") then
            playerHome.Character.HumanoidRootPart.CFrame = homeCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerHome.Character.HumanoidRootPart.Anchored = false
            playerHome.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed

            local animate = playerHome.Character:FindFirstChild("Animate")
            if not animate then
              animate.Disabled = false
            end
        end

        -- Teleport Away Player
        if playerAway.Character and playerAway.Character:FindFirstChild("HumanoidRootPart") then
            playerAway.Character.HumanoidRootPart.CFrame = awayCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerAway.Character.HumanoidRootPart.Anchored = false
            playerAway.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed

            local animate = playerAway.Character:FindFirstChild("Animate")
            if not animate then
              animate.Disabled = false
            end
        end

        
        local matchPlayers = {playerHome, playerAway}
        for _, p in pairs(matchPlayers) do
            local pGui = p:FindFirstChild("PlayerGui")
            if pGui then
                local buttons = pGui:FindFirstChild("Buttons")
                if buttons then
                    
                    if buttons:FindFirstChild("ExitButton") then buttons.ExitButton.Visible = false end
                    if buttons:FindFirstChild("OnButton") then buttons.OnButton.Visible = false end

                    
                    if buttons:FindFirstChild("AwayButton") then 
                        buttons.AwayButton.Visible = false 
                    end
                end
            end
        end

        PlayIntro:FireAllClients()
    else
        
        gameStarted = false
    end
end

homeValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)

awayValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)
#

@south owl u want them to be unfrozen right after they get teleported?

summer plaza
#

where is the intro..?

#

i dont see that in this script

south owl
#

the script i sent u is the intro script

#

ima send a vid again

summer plaza
#

ohi see where

#

PlayIntro:FireAllClients()

south owl
summer plaza
#

how long is the intro?

south owl
#

ima add animations later in game

#

i have them animated ima just add them to script

#

@summer plaza

#

so u see how it resets camera

#

after the cameras like reset i want the players to be able to move and idk why but the exitButton isnt doing visable = false when intro

summer plaza
#
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local PlayIntro = ReplicatedStorage:WaitForChild("PlayIntro")
local StarterPlayer = game:GetService("StarterPlayer")

local Values = workspace.Court2.Main.Values
local homeValue = Values:WaitForChild("Home")
local awayValue = Values:WaitForChild("Away")

local homeCourtPos = workspace.Court2.Main.Positions.Home.a
local awayCourtPos = workspace.Court2.Main.Positions.Away.a

local gameStarted = false

local function startGame()
    if gameStarted then return end
    gameStarted = true

    task.wait(5) 

    local playerHome = game.Players:FindFirstChild(homeValue.Value)
    local playerAway = game.Players:FindFirstChild(awayValue.Value)

    if playerHome and playerAway then
        
        if playerHome.Character and playerHome.Character:FindFirstChild("HumanoidRootPart") then
            playerHome.Character.HumanoidRootPart.CFrame = homeCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerHome.Character.HumanoidRootPart.Anchored = false
            playerHome.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed

            local animate = playerHome.Character:FindFirstChild("Animate")
            if not animate then
              animate.Disabled = false
            end
        end

        -- Teleport Away Player
        if playerAway.Character and playerAway.Character:FindFirstChild("HumanoidRootPart") then
            playerAway.Character.HumanoidRootPart.CFrame = awayCourtPos.CFrame * CFrame.new(0, 3, 0)
            playerAway.Character.HumanoidRootPart.Anchored = false
            playerAway.Character:FindFirstChildOfClass("Humanoid").WalkSpeed = StarterPlayer.CharacterWalkSpeed

            local animate = playerAway.Character:FindFirstChild("Animate")
            if not animate then
              animate.Disabled = false
            end
        end

        
        local matchPlayers = {playerHome, playerAway}
        for _, p in pairs(matchPlayers) do
            local pGui = p:FindFirstChild("PlayerGui")
            if pGui then
                local buttons = pGui:FindFirstChild("Buttons")
                if buttons then
                    
                    if buttons:FindFirstChild("ExitButton") then buttons.ExitButton.Visible = false end
                    if buttons:FindFirstChild("OnButton") then buttons.OnButton.Visible = false end

                    
                    if buttons:FindFirstChild("AwayButton") then 
                        buttons.AwayButton.Visible = false 
                    end
                end
            end
        end

        PlayIntro:FireAllClients()
    else
        
        gameStarted = false
    end
end

homeValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)

awayValue.Changed:Connect(function()
    if homeValue.Value ~= "" and awayValue.Value ~= "" then startGame() end
end)
#

see if it lets u move now

south owl
#

im fixing the button

summer plaza
#

wait

#

now

summer plaza
south owl
#

this is the only error

summer plaza
#

im not sure if that has to do with this script

#

it doesnt

summer plaza
south owl
#

ik i would have to difine it

south owl
#

rq

summer plaza
#

bro

#

i want to know if there are any errors after you teleport

#

thats the important part

south owl
summer plaza
#

check the output

#

now

south owl
#

these are the errors

summer plaza
#

send rbxl

south owl
#

@summer plaza

summer plaza
#

which one is home and which one is away

#

cause one of the buttons does disappear

#

and i think i know why

south owl
#

the one in the half circle is home

#

the other is away

summer plaza
#

ok

south owl
summer plaza
#

why do u have 2 exit buttons?

south owl
summer plaza
#

well right now u only turned exitbutton invisible but not exitbutton2

#

now i gotta figure out the not moving part

#

i mean i fixed the movement part

floral cypressBOT
#

studio** You are now Level 12! **studio

south owl
#

what abt the button

summer plaza
#

you have some duplicate logic between the scripts

#

so idk which one to edit

south owl
summer plaza
#

both the scripts do the same thing

#

why do u have 2 scripts with duplicate reasoning

#

introhelper and handlegame

#

they do the same thing

#

and its confusing as fuck and hard to debug

#

im gonna delete one of the scripts

south owl
summer plaza
#

@south owl wyd

south owl
summer plaza
south owl
summer plaza
#

just to turn a button invisible

south owl
#

@summer plaza we getting somewhere

summer plaza
#

Ws

#

what time is it for u lmao

south owl
#

8:00 AM

#

havent slept at all

summer plaza
#

holy wshit

south owl
#

btw

#

yeah

summer plaza
#

i went to sleep at 5am and thought thats bad

south owl
#

grind dont stop

summer plaza
south owl
#

wdh

floral cypressBOT
#

studio** You are now Level 7! **studio

summer plaza
#

DUDE WHY DO U HAVE SO MANY SCRIPTS

south owl
#

1569 lines of code 💀

summer plaza
#

THAT DO THE SAME THING

south owl
summer plaza
#

what is happening

south owl
summer plaza
#

howd u make turning a button invisible this difficult broo 😭

summer plaza
#

did u script all this yourself?

#

im sorry bro idk anymore 😭

south owl
summer plaza
#

also to fix movement u just have to reset the WalkSpeed to the CharacterWalkSpeed in starterplayer

summer plaza
summer plaza
#

u forgot to define starterplayer in introhelper @south owl

south owl
drowsy osprey
#

what's this slop ahh

#

what's you're problem

summer plaza
drowsy osprey
#

no he is a problem too

summer plaza
#

lmao

#

he wants to make a basketball game

#

where if 2 players go up to 2 pads

drowsy osprey
#

ok

summer plaza
#

and click the buttons to hop on the game

#

they tp to the field in 5 seconds

#

and an animation plays

drowsy osprey
#

shit is easy as hell

summer plaza
#

and theres also exit buttons which are supposed to go invisible but one doesnt

#

and also movement doesnt revert to normal

south owl
summer plaza
#

i fixed the movement one but i forgot how cause i restarted cause i got mad

drowsy osprey
#

😭

summer plaza
#

he has like duplicate scripts fucking everywhere

#

not like literal copy pastes

#

but scripts that have things in them that do the same thing as things in other scripts

#

so its actually difficult as fuck

drowsy osprey
#

just delete it all

south owl
#

i fixed errors

#

i have 1

#

left

summer plaza
#

and um

#

i dont think he is

south owl
#

bruh

#

got no rest for this

summer plaza
#

@drowsy osprey also its like almost 9am for him and he hasnt slept

drowsy osprey
#

well go sleep

#

send me your place i'll finish your work rq

#

if i feel like it

south owl
drowsy osprey
#

but if the code is a total mess i won't do anything

#

yes you do

south owl
#

i just wanna get this fucking beta out

#

were like almost done bru

drowsy osprey
#

add me

summer plaza
drowsy osprey
#

add me as collab

#

on your studio

south owl
#

beaming links

summer plaza
south owl
#

alriiii

drowsy osprey
#

you want fixed or not

summer plaza
drowsy osprey
#

it's a profile link

summer plaza
#

holy

#

read the link

languid hazelBOT
south owl
#

i was finna say

summer plaza
south owl
#

ik

summer plaza
#

if youre logged out after clicking a link just dont log in

south owl
#

u get hacked if u put ur info in

summer plaza
#

add him bum

south owl
summer plaza
drowsy osprey
#

if i was hacking people i wouldn't send a link

summer plaza
#

YOURE PISSING ME OFF RN

drowsy osprey
summer plaza
#

I WASTED LIKE 4 HOURS TO TRY AND HELP YOU

summer plaza
south owl
drowsy osprey
#

added

#

add me to the studio

south owl
drowsy osprey
#

you can

south owl
#

idk why but nametag buggin and its pissing me off

#

@summer plaza why did u get mad at me?

summer plaza
drowsy osprey
#

i won't upload the game on my account

#

too lazy to do that

#

this break your game entirely

summer plaza
drowsy osprey
#

i can't make it work

summer plaza
#

i mean

summer plaza
#

how would that be affected

#

i fixed the movement without publishing

south owl
summer plaza
#

@south owl js add him to the game

south owl
#

oh

summer plaza
south owl
#

no i only send file

summer plaza
#

cause it has to be published to roblox

#

and hes too lazy to do that

south owl
#

no thank you

summer plaza
#

ok

south owl
#

i will not be adding him to studio

#

so he can just delete everything

drowsy osprey
#

what's that

drowsy osprey
#

but ok

#

i respect that

south owl
#

is that why u cant fix it?

drowsy osprey
south owl
#

no no chill its my game

drowsy osprey
#

check the comments

south owl
#

its from my acc i lost access to but i can access it in studio

drowsy osprey
#

your game is a decompiled game

summer plaza
#

damn