It might be worth looking through that to see how it's done.
Fps sidetalk code#
Google's WebGL based Quake uses java for the server, and the source code is found here. TF2's server is written using C/C++, and thus, is going to be faster than node.js (which if I remember correctly, uses Javascript interpreted in Java) Are there other tricks in this realm I can try, which focus on minimizing the cost of my broadcast operation? This would decrease both the number of people who care about data, and also the amount of data sent to interested parties. The first most obvious improvement is line of sight checking. So I clearly need to do some optimization here. But with only 5 users, broadcasting takes around 0.5 ms.
Fps sidetalk full#
On a 20 user load, I cut my broadcast time 90%, from 24ms down to just over 2ms by sending only "" instead of the full data. Further testing showed that this time is dependent on both the number of clients and the size of the data, but more so the latter. I quickly wrapped some timing functions around my code (thanks, FP!) and discovered what I never expected: the act of broadcasting the data to clients accounts for nearly all of the execution time. Profiling really is the only mantra I've ever found that's absolutely infallible.
Fps sidetalk update#
So what are the other tricks of the industry to do only the minimum required on the server but still have a flawless game experience? There's a big conflict between "defer to client to save cpu time" and "don't trust the client", so maybe it helps to know where the line is drawn in various situations? Update Is it all in the server configuration magic?.I've considered the unfortunate possibility that node.js is just way slower than whatever TF2 is using, and may not be suited for this kind of high intensity task.
ended up spending the rest of the night watching and rewatching everything. it was so funny i decided to check out the whole channel. while in the middle of writing them for some reason i wandered over to youtube, and saw the Purim episode in my recommendations. i got home and turned on my computer to write goodbye emails. everything was crashing down and i legit felt like the people in my life would be better off without me. Around 6 months ago i went to the hardware store and bought rope to hang myself.