Hello, I realy need help. I want to get the Touch Position from a Button (or something else, the main thing is to get the position). It should work on mobile devices and on computer (for testing, because exporting takes too long). Ive searched the documentation for InputEventScreenTouch, classic Buttons and Touch Screen Buttons but found no help.

I need for my game for the user to place and remove tiles in a 2d tilemap, place furniture, plants etc. I also need it for another Game so its very important to me

(Sorry for my bad English. If you have any questions about my text, feel free to ask me)

Topic was stuck in moderation queue. Check your email for a confirmation link and if you don't find it also check your spam filter.

You can use the _input function to get the touch events.

func _input(event):
	if event is InputEventScreenTouch and event.is_pressed():
		var x = event.position.x
		var y = event.position.y
		// do something with position here
2 years later