Computing: Free Pascal Programming

Logic number puzzle: Lightbulbs.


Download Lightbulbs desktop application (Windows 64bit) Download Lightbulbs source code (Lazarus/Free Pascal)

Description: Puzzle game with numbered grid fields to be colored. The rules of the game are as follows:
    1. Color the gray fields in the grid white or black.
    2. At least one field must be white.
    3. The number in a white field indicates how many of its neighbor-fields (including itself) are white.
    4. The number in a black field must NOT indicate how many of its neighbor-fields are white.
The game is a typical logic game: In order to find the correct solution of the puzzle, you have to explore the numbers given and the fields already colored, and by logical thinking (concluding from what you know, that color a given field must be, or on the contrary, mustn't be), determine, which fields have to have which color.
To play the game, click the field, that you want to color; this toggles the field color from gray (not yet colored) to white, then to black and finally to gray again.

Possible extension: In the actual version some puzzles are more than easily to resolve, whereas others need serious thinking and try-out. Adding difficulty levels would be nice.

Free Pascal features: Changing the color of shapes during execution. Handling mouse clicks. Two-dimensional arrays (classic Pascal).

Screenshot:

Lightbulbs - a free logic game for PC

If you like this application, please, support me and this website by signing my guestbook.