From 8bda83838cb16e2ecfb6787008e3dc58b66d3e46 Mon Sep 17 00:00:00 2001 From: pascald Date: Sat, 3 May 2025 00:49:48 +0200 Subject: [PATCH] final changes for better touch function --- main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index 561e538..158f037 100644 --- a/main.py +++ b/main.py @@ -708,10 +708,10 @@ async def main(): running = False elif event.type == pygame.KEYDOWN or event.type == pygame.JOYBUTTONDOWN or event.type == pygame.JOYHATMOTION or event.type == pygame.FINGERDOWN or touch_start or (event.type == pygame.MOUSEBUTTONDOWN and event.button == 1): if state == 1: # PLAYING + result = None if pygame.FINGERUP and touch_start: result = touch(event) - else: - result = None + if is_LEFT_event(event) or result == "ontop": can_tip = current_case.length_units * UNIT_HEIGHT <= TRAILER_HEIGHT if current_case and current_case.allow_snap and can_use_tilt and can_tip: