Example code: Single file examples: audio.lua: Can't see rendered text instructions

The single file example audio.lua in the SDK examples, has the following code:

playdate.graphics.drawText("Press A or B to play sounds", 95, 100)

which confused me, because when I ran it you just get a blank screen.

It's a minor issue, but got me running around trying to understand what was going wrong.

I added the following code to fix it:

function playdate.update() end  -- prevents main.lua from rendering text 
-- draws a black background
playdate.graphics.fillRect(0, 0, 400, 240)

Low priority, but maybe update the example so someone else doesn't get confused. Although arguably that confusion made me understand things better... so maybe it's working as intended :smiley:

Thanks for the report! We'll get this fixed.

1 Like