Pocket Lights 1.0


I just wanted to share some general info on the initial development of Pocket Lights.

The 1.0 version of Pocket Lights took me almost 2 months to get ready start-to-finish, but I was only working on this sporadically.

Development was done in the evenings (generally I'd have about 2-3 hours to work on this on the nights I could find time) Based on my git history, I spent about 20 evenings working on this, so somewhere from 40-60 hours development time total. Not all of this was programming! It took me a couple days to re-familiarize myself with Lua and the Playdate SDK in general. This 1.0 version borrows heavily from Worddate (which is evident in the main menu and puzzle/daily archive pages), so there was time to re-understand that as well. A fair amount of time was also spent just sourcing and inputting puzzles, and several evenings were spent generating title card and animation screens too.

The initial version of the app was just the board, and two modes - the normal "+" light toggling gameplay that exists now, and a single-square toggle as well. From there, I built a mechanism to load premade puzzles, and export a board hand drawn by me (via the single-square draw mode). Once this was in place, I could switch off between working on actually making the game and building puzzles via this mode (eventually I found an archive of existing puzzles online, and borrowed a bunch from there).

How does the board import/export work? Great question! Because a square can either be on or off, we can treat a row of squares as a 5-digit binary number. For example, [ON]-[OFF]-[ON]-[OFF]-[ON] is 10101, or 21 in base-10. All the puzzles in Puzzle mode are stored as simple strings of 5 base-10 numbers. For example:

Puzzle-string: "16-8-4-2-1"
Binary representation: 10000
01000
00100
00010
00001 This is Puzzle 2 - "Slice"

My debug export tool was an additional System Menu button that would log the base10 puzzle string to the console.

(As I work to build in 3-state light games, I'll have to re-think how the import/export process works for those puzzles.)

After this initial implementation, I proceeded to adding the puzzle, archive, and daily game modes themselves (which each just load a different puzzle string depending on which mode is used), plus their corresponding menu screens. 

Save data handling (for finished puzzle/daily games) was a couple of days.

The "how to play" and "about" pages were pretty quick - both of those happened in a day.

A couple days were spent on tweaking the UI and polishing things (fixing some bugs with menus and whatnot).

The last few days were spent collecting and inputting puzzles, and writing some additional code to draw different screens that ended up being used for the app launch image animation. Thats it!

So what's next? I have 3-state lights working (Lights Out: 2000 anyone?), and am pondering how to toggle between game modes (2 lights, 3 lights, maybe different toggle patterns). Hopefully I'll have another update soon!

Files

pocket-lights-1.0.0.pdx.zip 114 kB
Feb 27, 2023

Get Pocket Lights

Download NowName your own price

Leave a comment

Log in with itch.io to leave a comment.