Activation doesn’t fire at all. I’m confused what’s going on:
--Important button hovers
HoverInfo = TweenInfo.new(.25,Enum.EasingStyle.Circular,Enum.EasingDirection.Out,0,false,0)
function HoverAction(button,response)
if response == true then
TweenService:Create(button.Parent,HoverInfo,{Size = UDim2.new(1.1,0,1.1,0)}):Play()
else
TweenService:Create(button.Parent,HoverInfo,{Size = UDim2.new(1,0,1,0)}):Play()
end
end
--Button activation (for frames and menu)
MenuInfo = TweenInfo.new(.125,Enum.EasingStyle.Circular,Enum.EasingDirection.Out,0,false,0)
function ButtonActivation(button,frame)
print("test")
end
--Collect all important buttons for the menu
for index,object in pairs(Interface:GetDescendants()) do
if object:IsA("ImageButton") and object.Name == "ButtonOpen" then
object.MouseEnter:Connect(function()
HoverAction(object,true)
end)
object.MouseLeave:Connect(function()
HoverAction(object,false)
end)
object.Activated:Connect(ButtonActivation,object,object.Parent.Parent)
end
end
I also tried to replace it with:
object.Activated:Connect(function()
ButtonActivation(object,object.Parent.Parent)
This did nothing either. No error pops up. In the Activation function, nothing prints out.
I’m clueless.