for N,R in ipairs(buttons)do R.MouseEnter:Connect(function()onButtonEnter(R)end)R.MouseLeave:Connect(function()onButtonLeave(R)end)end
-- Set up the event handlers for each button
for _, button in ipairs(buttons) do
	button.MouseEnter:Connect(function()
		onButtonEnter(button)
	end)
	button.MouseLeave:Connect(function()
		onButtonLeave(button)
	end)
end
