SteelSeries / gamesense-sdk

472 stars 146 forks source link

Won't react to other event #121

Closed Hely0n closed 2 years ago

Hely0n commented 2 years ago

I have two bound events for the oled screen. Everything works as it should. Event A gets send and the screen reacts. Now I send event B, and the screen changes accordingly, and reacts to all event B. But now it doesn't react to event A anymore until re-binding the events.

Sometimes, it works but only once or twice, and it seems like in random situations.

Hely0n commented 2 years ago

Well, I just found the problem. It won't react to events with unchanged values. Had to do some workarounds against it.

ToadKing commented 2 years ago

The correct way to always handle events even if the value doesn't change is to use the value_optional property when registering the event. See the bottom of the sending game events documentation.

Hely0n commented 2 years ago

Oh I see, thank you!