Skip to content

Hide rich presence during sleep and track real playtime (#11) - #12

Merged
llsc12 merged 3 commits into
llsc12:mainfrom
Jonathan8520:fix/sleep-elapsed-reset
Jul 19, 2026
Merged

Hide rich presence during sleep and track real playtime (#11)#12
llsc12 merged 3 commits into
llsc12:mainfrom
Jonathan8520:fix/sleep-elapsed-reset

Conversation

@Jonathan8520

@Jonathan8520 Jonathan8520 commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

Fixes #11.

The elapsed timer used to keep running the whole time the console was asleep. Now the presence is hidden during sleep and comes back on wake, and the timer tracks real playtime; it resumes where it left off (sleep excluded, like you suggested) instead of resetting to 0. Sleep/wake is detected via PSC, since the sysmodule is frozen during sleep and no clock works there.

Also fixed a few things I ran into along the way: a double free that crashed at startup, logout not actually stopping the presence, and sessions stacking up when switching game.

Tested on hardware :)

@llsc12

llsc12 commented Jul 19, 2026

Copy link
Copy Markdown
Owner

no idea why the workflow failed

@llsc12
llsc12 merged commit ab5603a into llsc12:main Jul 19, 2026
1 check failed
@Jonathan8520

Copy link
Copy Markdown
Contributor Author

I don't think it's the code! Devkitpro's server just blocks the GitHub runners sometimes, so it fails while installing the packages before it even builds anything. Seems pretty random too, one of your older builds failed then worked fine on a re-run, so just re-running it should do the trick :)
Builds fine locally on my side

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Force the stop

2 participants