loki-47-6F-64 / sunshine

Host for Moonlight Streaming Client
GNU General Public License v3.0
1.77k stars 152 forks source link

Sunshine causes a game to freeze when vibrations should happen - Linux regression #255

Open JacekJagosz opened 2 years ago

JacekJagosz commented 2 years ago

This is a thing introduced in 0.11.1, I tested back an forth with 0.10.1 and it works correctly in the older version. The problematic game is Art of Rally, and problem occurs with both Moonlight for PS Vita and Moonlight for Android (neither having vibrations). Everything seems to be working alright with newest Sunshine, controller works in the menu, and in the game. But the moment you press the accelerator and the car starts moving, the game just freezes. I suppose this is because that is the moment the vibrations should start. The game stays frozen, until you exit the Moonlight app on the client, and unfreezes immediately when I do that. Unfortunately neither Sunshine nor the game post any errors. I am maintaining Sunshine for Solus, so maybe I did something wrong during packaging, but I don't expect so. Every packaging step is the same for old and new version. I will try to test more games and clients and see if I can get closer to the cause, but I would love if anybody could give me some help with troubleshooting. Edit: I just tested it with Moonlight on Linux with controller supporting vibrations. And the game freezes the same. My guess is that when you fixed support for multiple controllers, the rewrite of the code for vibrations introduced compatibility problems when using vibrations? I guess the problematic commit is 1f7bdb1b2a19444b5f9394f237a191cb6cd4dc6f, or maybe this one 91a6e55f7487509168960ac960e637739a7182bb? But I still don't get why, I don't see anything bad with it.

Slayer5934 commented 2 years ago

And here I was thinking Mortal Kombat 11 was at fault here.. Can confirm, actually I can't because I already got rid of the game but I'll try again using steam streaming instead =D If I remember to I'll come back here.

kunver400 commented 2 years ago

Can confirm this, happens with every game when using DS4 controller on android, games work fine without controller connected.

Slayer5934 commented 2 years ago

Hello I'm back =D Actually while trying to emulate a game via Yuzu and a vibration happens it does actually freeze until I disconnect the controller, so thats interesting.. I turned off vibrations in Yuzu and it did not freeze anymore.

esistgut commented 2 years ago

Can confirm this on Dualsense too.

jkms commented 2 years ago

Confirming in Hades. If I punch something, the game freezes for ~45 seconds.

h0m3 commented 2 years ago

Confirming in GTA V. I was getting desesperated not knowing what was wrong. Your post saved me, disabled rumble on game solves the issue but you get no rumble.

Host: OS: Arch Linux KERNEL: 5.16.15-zen1-1-zen CPU: AMD Ryzen 9 5950X 16-Core GPU: NVIDIA GeForce RTX 3080 GPU DRIVER: NVIDIA 510.54 RAM: 64 GB

Guest: Apple TV 4K A2169 Xbox Series X Controller or DualShock 4 Controller

Reproductible games:

JacekJagosz commented 2 years ago

@h0m3 I just stayed on 0.10.1 until this gets fixed. Very unfortunate, but what can you do.

lq95v5 commented 2 years ago

same issue

Slayer5934 commented 2 years ago

Everyone should go to this repo instead: https://github.com/LizardByte/Sunshine/releases This one is dead, the issue is fixed there.