Tap to start game play unreal enine 4

I want to start game when user tap on anywhere of screen not the button to start how to do that in unreal engine 4.

Touch in wherever you’re handling the input? Player Controller would be the best, I guess.

313845-screenshot-2020-09-16-182751.jpg

As on game load i show widget with tap to play text. I want to remove widget after user tap on screen . My player automatically run forward on event tick.

You have 2 options here:

  • make the widget Not Hit-Testable (so it’s just for show and cannot be interacted with) and implement the Touch in the Player Controller as seen above
  • or override the appropriate event in the widget instead:

313864-screenshot-2020-09-16-191840.jpg

Both should work fine here.

sorry but i do not getting you point. I am new to ue4. thats why i do not know much about it.

When you create the widget, set it to Not Hit-Testable so it’s not in the way of the touch:

And then have the Touch in the Player Controller. That’s really it.

If in doubt, show us how you’ve implemented both the widget and the touch.

i just have text on widget nothing else.in game mode begin play i load that widget and in player touch1 event i want to remove that widget. but there is option for remove all widgets but i want to remove that text only. And after touch the screen player start run forward like endless runner. I set the timer on touch1 event that not run the player.
alt text

If you want to keep the widget and remove the text only, use OnTouchStarted as suggested above. Flag the text block asVariable, and set its Visiblity to hidden.

The widget needs to be in focus for this to work and has a Visible element to tap on. A fully transparent border could work, or even a simple canvas if you’re using one.