loveframes OnClick not working
Posted: Mon Dec 14, 2015 9:23 am
Hey guys! I was recently using loveframes and found out that the OnClick function does not work is there a fix?
It works when i do OnMouseEnter but not OnClick which i find weird please help!
-Note this is not the complete script I just sliced it to add the important bits
-I have already added all the loveframes. functions including mousepressed and mousereleased
Code: Select all
loveframes = require("assets.Source")
StartP = 0
loveframes.SetState("Menu")
local button = loveframes.Create("button")
button:SetState("Menu")
button:SetSize(love.window.getWidth() / 8, love.window.getHeight() / 27)
button:SetText("Play!")
button:Center()
button.OnClick = function(object)
StartP = 1
end
-Note this is not the complete script I just sliced it to add the important bits
-I have already added all the loveframes. functions including mousepressed and mousereleased