Create a variable called direction.
1. Create a direction first. If the player swipe right , the direction will be right ,same with left , up , down etc.
2. For every tick - create a sub event and add these logic:
if direction is right - simulate control right
if direction is left - simulate control left
You get the point