Hello, I am trying to make an rc car game. So I have a tool that opens up a gui for the car. It works in StarterGUI, but for some weird reason the gui doesn't work when I use my tool. Can somebody help? Tool open gui script (local):
local menuClone
script.Parent.Equipped:Connect(function()
if not game:GetService("Players").LocalPlayer.PlayerGui:FindFirstChild("OreoMenu") then
menuClone = script.Parent.OreoMenu:Clone()
menuClone.Parent = game:GetService("Players").LocalPlayer.PlayerGui
end
end)
script.Parent.Unequipped:Connect(function()
pcall(function()
menuClone:Destroy()
end)
end)
GUI button script (server):
script.Parent.MouseButton1Click:Connect(function()
workspace.OreoCar.Shell.Velocity = workspace.OreoCar.Shell.CFrame.LookVector * -100
end)
I placed my gui in the tool

1 comment
No, the problem is that the GUI shows up, but the buttons don't work. They work when I place it in StarterGUI though.