Click on game object

Right now I’m doing like this:

`function on_input(self, action_id, action)
 if action_id == input_mouse and action.pressed then
 
 	local spritePos = go.get_world_position("myGo") 	-- getting my go position
 	local mouseX = action.x  -- getting mouse position
 	local mouseY = action.y
 	local rightBoundary = spritePos.x - 200   --200 is half the width of my go
 	local leftBoundary = spritePos.x + 200
 	local upperBoundary = spritePos.y + 200
 	local downBoundary = spritePos.y - 200
 	
 	if mouseX >= rightBoundary and mouseX <= leftBoundary and mouseY >= downBoundary and mouseY <= upperBoundary then
 		print("clicked")
 	else
 		print("outside")
 	end
 
 end
end `

This works for right now since I don’t have a moving camera and don’t need to worry about worldspace coordinates. Just wish that there would be something like in action script:
mySprite.addEventListener(MouseEvent.CLICK, myFunction);