I am currently working on a radial menu for my game. But the labels overlap each other so buttons would not work. I tried writing a custom function for it which looks like.
function click(input, gameProcessed)
local pos = input.Position
local guisAtPosition = game.Players.LocalPlayer.PlayerGui:GetGuiObjectsAtPosition(pos.X, pos.Y)
for i,v in pairs(guisAtPosition) do
if cannames[v.Name] then
local tool = script.Parent.Tools:FindFirstChild(v.Name)
if tool then
game.Players.LocalPlayer.Character.Humanoid:EquipTool(tool:Clone())
end
return
end
end
end
but it still yeilds the same results. If i click between the two buttons here
It shows that it clicked both buttons
How can i make it more accurate?