dolphin icon indicating copy to clipboard operation
dolphin copied to clipboard

Handle Pausing in AchievementManager

Open LillyJadeKatrin opened this issue 1 year ago • 8 comments

There are two pieces of functionality to be added here. One, we want to disallow pausing too frequently, as it may be used as an artificial slowdown. This is handled within the client, which can tell us if a pause is allowed. Two, we want to call rc_client_idle on a periodic basis so the connection with the server can be maintained even while the emulator is paused.

LillyJadeKatrin avatar Jun 14 '24 00:06 LillyJadeKatrin

You should also audit all calls to EnableStepping. For instance, right now I don't think there's anything stopping the GDB stub from pausing emulation.

I looked over EnableStepping and the GDB stub does appear to be the only outlier. I'll disable that in hardcore mode in a separate PR.

LillyJadeKatrin avatar Jun 15 '24 16:06 LillyJadeKatrin

I don't think I can see any issues anymore, but I would like @AdmiralCurtiss to take a look at this too.

JosJuice avatar Jun 21 '24 17:06 JosJuice

And I got an assert failure because apparently do_idle is processing rich presence despite that not actually updating at all while paused. Looking into it.

LillyJadeKatrin avatar Jun 25 '24 03:06 LillyJadeKatrin

Why not just have this thread periodically call Core::QueueHostJob? That would ensure it gets used constantly can idle can end up doing memory reads just fine (and it's probably better to touch cheevo stuff on the host thread rather)

CasualPokePlayer avatar Jun 25 '24 18:06 CasualPokePlayer

Still evaluating but ran out of time this morning so here's what it looks like so far.

LillyJadeKatrin avatar Jun 26 '24 12:06 LillyJadeKatrin

So are you done with this now?

AdmiralCurtiss avatar Jun 27 '24 18:06 AdmiralCurtiss

I'm not finding anything wrong with it yet, I think I might have this locked in.

LillyJadeKatrin avatar Jun 28 '24 01:06 LillyJadeKatrin

Okay, I'll give this another test then. I still think the unsynchronized thread is fundamentally flawed, but whatever, we can go with it for now.

AdmiralCurtiss avatar Jun 28 '24 14:06 AdmiralCurtiss

I'm still not 100% happy with this but I think we can go with this for now...

AdmiralCurtiss avatar Jul 04 '24 20:07 AdmiralCurtiss

DO NOT USE THIS VERSION OF THE APP! It has a flaw which thinks every game is banned.

DevanWolf avatar Jul 06 '24 08:07 DevanWolf

DO NOT USE THIS VERSION OF THE APP! It has a flaw which thinks every game is banned.

where does it say that? Are you sure that's what you mean and not that there are no achievements?

kira1000 avatar Jul 06 '24 11:07 kira1000

DO NOT USE THIS VERSION OF THE APP! It has a flaw which thinks every game is banned.

where does it say that? Are you sure that's what you mean and not that there are no achievements?

No, the version is broken, launch any game and it crashes.

DevanWolf avatar Jul 09 '24 23:07 DevanWolf

DO NOT USE THIS VERSION OF THE APP! It has a flaw which thinks every game is banned.

where does it say that? Are you sure that's what you mean and not that there are no achievements?

No, the version is broken, launch any game and it crashes.

We have a team of people actively testing and verifying this integration and the only thing remotely similar to the behavior you describe is a bug on the Android version which has since been fixed. I invite you to join the Dolphin Discord server if you continue to have issues but here is a terrible place to discuss them.

LillyJadeKatrin avatar Jul 09 '24 23:07 LillyJadeKatrin

Or the forums, or the IRC channel, or the issue tracker.

JosJuice avatar Jul 10 '24 07:07 JosJuice