Open ghost opened 5 years ago
Hey ! I'm quite interested, would you mind opening a PR so I can review that properly?
I haven't used github since college so I might be doing this wrong, but it looks like I need write access to upload the new branch.
nvm, figured it out. I made the pull request #49
It looks like visual studio's auto formatting messed with the spacing on the lines though so it isnt as easy to compare.
i tried to make it easier to compare. i'm really just messing around at this point
that should show you the oppose of the changes. red is green and green is red
edit: nvm, this comparison thing broke.
I forked your branch and I'm taking time to thinks this over properly. This change, semantically speaking, is a breaking change (change in behavior). So I want to fix this once and for all, for everyone.
My current idea is the following: Poke the API with an incremental delay (15s,30s,1m,2m,5m,15m,30m,1h,2h). If activity is detected then reset the delay. If no activity is detected after reaching the max delay, then start a final countdown of 24hrs. In the mean time, keep poking the API every MAX_DELAY (2hrs I'd say) If the player is playing on PC (membershipType===4), on destiny 2 exe launch(and only on launch, i.e. first detection), reset the final countdown and the delay. If the player quit the app (process not detected anymore), I'll certainly try to bust the cache (sorry Bungie!), now that I know it's possible. Thus allowing us to return to the routine (poke the api, increment timer and monitor process)
Update, this one is almost next on my hit list. Sorry for the long wait, security and privacy were my upmost priorities
It looks like everyone is doing a great job but I need to know what is happening?
Yes good job
I'm not sure to understand your question @Robinhubbard31
for reference: #31
I felt like this should be fixed so I found a way to fix it. It's fixed under the assumption that you're running discord, destiny, and this script on the same computer. I say for the most part because there isn't anything you can do when someone is starting up the game. The script sees the game running so it goes to the API to get their status (which is wrong). If they shut down the game or start the script before they launch destiny, it does not claim they are on destiny.
Changes:
Example output:
Code is here: https://apx.gg/files/discord-ghost-src.zip
disclaimer - i'm a very experienced c# dev who has only dabbled in node.js. i do not know what i am doing, but i can make things work.