Tool for gamers: Control your Yeelights with CS:GO and Dota 2 in-game events


#1

Hey guys,

another small script for your Yeelights right here, check out this demo:
https://www.youtube.com/watch?v=fe1lsKPRyoE

If there are some gamers around here, this script works for CS:GO & Dota 2: https://github.com/davidramiro/yeelight-valve-gsi

Let me know what you think!

Cheers,
David

Edit: Dota is now fully supported too :slight_smile:


#2

I watched the video you post, that’s cool :thumbsup:

I have a question how do you get the event from the game cs or dota?


#4

Glad you like it!

Dota and CS:GO have an API for that, it’s called Gamestate Integration. You just enable it in a config file. There are many values you can use, health, ammo, timers, items, abilities and much more.

If anybody wants to read more about this, here are the Dota values and here are the CS:GO values. There are many example scripts on github and other sites, you can just combine them with the Yeelight API.

Edit: added links


#5

great work, i have no idea what I did wrong but it made my CS:GO installation drop from 200 fps to about 18 and then grind too a halt… i had to remove my whole config directory and recreate it… I really want to give this a go again though. the GSI works fine with my steel series mouse.


#6

Can’t waiting for your new script for Dota and LOL.


#7

That’s really weird, didn’t encounter anything like this. Generally you would just have to delete the gamestate_integration_yeelight.cfg and it would be back to default.


#8

Hi David,

I download CS:GO to try with script from https://github.com/davidramiro/yeelight-gsi, but the lamp doesn’t change any color. I think I can’t receive any game state from CS:GO, cause there’s no other log print here:

I see you write copy the file of gamestate_integration_yeelight.cfg to gamedir/csgo/cfg, but there’s no folder of csgo/cfg, so I create it and copy the file into it. So I want to know if there’s a switch to enable game state of CS:GO, or if there’s something wrong i did.

And another question, how could i use the script in Linux? Cause CS:GO is only available on Windows.

Thanks,
Andy


#9

Hello Andy,

thanks for trying out my script. So since it’s not putting out an error message, the script is now waiting for gamestate to send commands. If it receives commands, it prints them out in the gsi-csgo window, so in your case, the gamestate integration seems to not work.

What is weird is that you had to create the csgo/cfg folder. In the normal steam version, this one is always there and it stores all of your config files. I suppose you are running the Chinese Perfect World version? I didn’t find anything on Google about where the PW client saves its configs. Maybe you try and look on Baidu or some Chinese CS:GO forum.

And another question, how could i use the script in Linux? Cause CS:GO is only available on Windows.

On Steam, CS:GO for Linux got released a few years ago. It was released for SteamOS (Linux-based) but it works on other distributions aswell.


#10

Yes, I think so. I am running the Chinese Perfect World version.

I will try CSGO from steam to see if it works.


#11

Ok. Hope it works.

Make sure to download the newest version (new URL: https://github.com/davidramiro/yeelight-valve-gsi), it has better colors and some bugs fixed.


#12

I tried CSGo from steam, but the same result. The script is waiting for gamestate to send commands, but there’s no data received.

This time there’s directories of csgo/sfg, and I put the cfg file into it. However I can’t play it online cause of matchmaking unavailable, I choose mode of offline with bots. I don’t know if this is the reason.

I also find the page from Value, https://developer.valvesoftware.com/wiki/Counter-Strike:_Global_Offensive_Game_State_Integration, I don’t find other settings need to set :joy:

Do i miss something?

BTW, I also tried the new version you post, the same result…
Thanks,
Andy


#13

I think you have set it up correctly, if the cfg is in the correct folder it should work…
I don’t know why it’s not working. Should also work on bot game, doesn’t need to be online.

Maybe you can try another script that uses game state integration to test if that works. Something like this for example. If that doesn’t work too, your game is somehow not sending commands… If it works, I made a mistake on my script.


#14

Finally it works, I download steam app first and then add CS:GO in it.

Sometimes delay is a bit long, I will have a look at it. Thanks!