My mechanical LED Roccat Ryos has been doing similar to this for years - there's a whole API to hang events from. You can link in game events to LEDs doing stuff eg health bar length, to Function key lights F1 = nearly dead, F1 to F12 lit = full health
See also real time spectrum analyser...