How to detect slide from anywhere on the screen?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Szaronko

Hello! In my mobile game I have menu with a couple pages (something like in youtube app there is home, library and other pages.) I also have transition between those pages. It goes left and right. I can controll it through buttons but I really want to be able to slide my finger left or right anywhere on the screen and then menu goes left or right. I already have function for menu to go left or right. I only need some way to detect this slide.

I also have a lot of butons in those pages and i still want to just tap them so they work.

Thank you for any help!

:bust_in_silhouette: Reply From: Szaronko

Okay I found this video https://www.youtube.com/watch?v=7XlMqjikI9A&feature=emb_title)&ab_channel=GDQuest

i didn’t think to search for “how to swipe”