Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Linux] Touchscreen issue, cursor jumping after movement #172

Open
hippydave opened this issue May 5, 2024 · 6 comments
Open

[Linux] Touchscreen issue, cursor jumping after movement #172

hippydave opened this issue May 5, 2024 · 6 comments

Comments

@hippydave
Copy link

I know the readme only talks about touchscreen controls for Android/iOS, but it appears to be active in the Linux build too. I'm trying to run the game on L4T Ubuntu on my Nintendo Switch (using the Linux x64 build, via box64 to run on the Switch's AArch64 architecture). It seems to run totally fine, except when I get to the main menu I'm having an issue controlling the mouse cursor with the touchscreen.

While I move my finger on the screen, the cursor moves as expected, doing the same relative movements. But when I lift my finger from the screen, the cursor does a sudden jump. If I've just moved in one direction, the cursor will jump in the same direction, and the further I've moved, the further it jumps. If I've moved in multiple directions in the same touch, then the jump seems to be in the final direction I was moving, but a jump size related to the total distance moved.

One- and two-finger taps for left and right mouse button seem to work as expected, so the cursor jumping after movement is the only thing keeping me from playing. Does anyone have any suggestions please? Many thanks!

@theofficialgman
Copy link

It should be possible to build this from source rather than use the provided x64 Linux builds with box64. You will get better performance and less power draw.

@hippydave
Copy link
Author

It should be possible to build this from source rather than use the provided x64 Linux builds with box64. You will get better performance and less power draw.

Yep was thinking about it, but I don't currently have a Linux build environment set up, and there's not much spare space on my Switch's Linux partition. Unless I could build it on my Raspberry Pi maybe?

Haven't spent much time in game yet because of the aforementioned issue, but it seems like performance is ample anyway for this 1997 game. Would be nice to have it running native tho.

@hippydave
Copy link
Author

It should be possible to build this from source rather than use the provided x64 Linux builds with box64. You will get better performance and less power draw.

Well I built it on my Switch, forgot the necessary build stuff was already on there. It runs great except the playback of video files is fucky, covered in flickery squares. Will check other issues for clues. Then maybe I can start messing with mouse movement code.

@hippydave
Copy link
Author

hippydave commented May 7, 2024

Not the focus of this issue, but for the glitchy videos, I tried this commit which says it fixes it, but didn't work for me so I tried rolling back this previous fix which apparently introduced the regression and they're playing fine now. I know this isn't an ideal solution as the latter was fixing an existing issue, but it'll do me until a fixed fix is in.

@hippydave
Copy link
Author

I identified the issue causing the cursor jumps, and made a pull request with a potential fix.

@Norfolc
Copy link

Norfolc commented Jun 2, 2024

The same issue reproduces also on Windows laptop with touch screen. The proposed fix #176 resolves the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants