Network request permissions-access UI is broken

,

Hi!

Was just testing out some network capability on the playdate to familiarize myself with the tooling. Upon seeing the permissions screen, I was surprised to see the following:

playdate-20251126-111703

At first I thought it was a Z-Index issue with the sprites in-game, but after running "playdate.graphics.sprite.removeAll()" prior to the invocation, I found the same issue:

playdate-20251126-112241

(Clearly there is at least one sprite being added back again.)

So it seems the issue is with the pop-up itself. I don't see any specifics in the documentation about it, nor do I think it would be secure to allow for customization past the "reason" message, as the current state could allow adding in a fake pop-up misleading the player to press "OK" without a clear idea of what's going on. Similarly, the "Deny" option is missing from the pop-up in its current state.

Probably worth fixing! :stuck_out_tongue:

1 Like

nice catch! I think the problem is (or at least, one way to reproduce this is) that there's a clip rect set when requestAccess() is called. We need to reset the clip rect before drawing the dialog, and I'll bet there are other graphics states that mess up the alert too. We probably just need to push a new graphics context for the modal dialog. I'll get a fix in for the next update!

1 Like

haha oh geez. I am saving and restoring the game's drawing state, so I was clearly aware this would be a problem.. I just forgot to clear the state while the dialog is active. At least it's an easy fix!

1 Like

At least it didn't mess up everything else in-game while the dialog is active, then! :smiley: Thank you for the update and hopefully see the fix soon!