DAILY GEMS v2026.10.31.2
by Alex Corris alexcorris@outlook.com @bbswordle for BlueSky
======================================================================

Columns, one board a day.  A column of three gems drops into a well six
wide and thirteen deep.  Slide it, cycle its gems, drop it.  Three or
more of one colour in a line - across, down, or on either diagonal -
shatter, everything above falls, and anything that lines up as it lands
goes too: a chain, worth more at every step.

Every caller gets exactly the same columns, in the same order, in the
same starting well, and one try at it.  Best score wins the day; scores
add up over the month and all-time.  Missed days can be made up from the
calendar while they are still open, and late in each month the rest of
that month can be played ahead.  It is a sister door to Daily Blocks and
works the same way everywhere outside the well: same menus, calendar,
scoreboards, keys screen, make-ups, play-ahead and InterBBS league.

BBSes can play each other: point the door at the daily league server
(dbserver, 2026.10.28.1 or later) and every BBS in the league gets the
same boards and one shared set of scoreboards.  See INTERBBS LEAGUES.


THE GAME
----------------------------------------------------------------------
The well      6 wide, 13 deep.  A new column comes in at the top of the
              third column, sliding in a gem at a time.  If the mouth of
              the well is blocked, or anything is left sticking out of
              the top once the gems have settled, the well is full and
              the board is over.

The gems      Six of them.  Each has its own colour AND its own mark, so
              they can be told apart without colour too:

                Ruby        red      square cut   (a white square)
                Topaz       yellow   star         *
                Emerald     green    step cut     (three bars)
                Sapphire    blue     oval         (an O with a bar)
                Amethyst    purple   cross        +
                Aquamarine  cyan     x            x

              A gem is three characters: a bright rim each side (half
              blocks) round a dark stone with a white mark.  Only
              characters from 128 up and plain ASCII are used - the low
              CP437 symbols (hearts, diamonds) are control codes to
              some terminals.

Matching      3 or more of one colour in a row, column or diagonal.
              Lines of more than three, and lines that cross, all go at
              once.

Chains        When gems fall into place and line up again, that is the
              next step of a chain.  Step 2 scores double, step 3 triple,
              and so on.

Magic Jewel   Every so often (about one column in twenty-five, never in
              the first dozen) a flashing column comes down instead.
              It takes every gem of the colour it lands on, wherever it
              is in the well, then vanishes.  On the bare floor it takes
              nothing.  Everyone gets it at the same point on the same
              day.

Levels        Every 30 gems cleared is a level.  The gems fall faster,
              and every gem is worth more.  Level 15 is the top.

Scoring       Each gem: 30 x level x step of the chain
              Soft drop 1 a row, hard drop 2 a row
              Well emptied (from a well that had gems in it): +2,000
              Flash gem cleared (Flash days): +3,000
              Every column dropped: +1,000, plus 50 per empty row left

Day types (SpecialBoards=1; roughly how often)
              Classic   40%   an empty well
              Debris    22%   3-6 gems deep, ragged, on the floor
              Flash     15%   5-8 rows of gems, with a flashing gem on
                              the floor: dig down and clear it for a
                              3,000 bonus (as in Flash Columns)
              Rush      12%   the fast day: an empty well, but the gems
                              start at level 7 - falling at 350 ms a
                              row and scoring 7 x from the first one
              Canyon    11%   walls of gems up both sides, a gap down the
                              middle
              A starting well never has three in a line ready-made.

Rush days score a lot more than the others.  Everybody gets the same
Rush days, so it is fair; it just means a Rush day weighs more in the
monthly totals, the way a Tetris-heavy day does in Daily Blocks.


FILES
----------------------------------------------------------------------

dgems          Linux 64
dgemsPI	       Raspberry Pi/Arm
dgemsWin32.exe Windows 32
dgemsWin64.exe Windows 64

RUNNING
----------------------------------------------------------------------
Exactly like Daily Blocks:

  dgems -D<path>DOOR32.SYS          (or DOOR.SYS, DORINFOx.DEF, BBSDEV.DRP)
  dgems -N<node> -S<socket>
  dgems -L                          local mode, asks for a name

  -U           local mode on Linux: send UTF-8 instead of CP437
  -PName       local mode: log in as Name without the prompt (_ = space)
  -TYYYYMMDD   pretend today is that date - for testing only

ANSI and an 80x24 screen.  Players are identified by alias (real name if
the drop file has no alias).  All data lives next to the executable.


DGEMS.INI
----------------------------------------------------------------------
  PiecesPerDay=60     columns of gems in each board (20-500)
  MakeupDays=30       how many days back a missed board stays open
  PlayAheadDay=22     from this day of each month, the rest of that
                      month can be played ahead (0 = never)
  SpecialBoards=1     1 = Debris, Flash, Rush and Canyon days; 0 = every
                      day Classic
  BoardSeed=<number>  this BBS's own number; picked at random on first run
  StartDate=YYYYMMDD  first day of play; set automatically on first run

  InterBBS=0          1 = take part in an InterBBS league
  LeagueServer=       the league server: host, or host:port
  BBSName=            your BBS's name as the other boards will see it

PiecesPerDay, SpecialBoards and BoardSeed change the boards themselves:
decide once and leave them alone.  Every caller on your BBS gets the
same board each day; another BBS has a different BoardSeed and so
different boards, so nobody can practise today's board elsewhere.  60
columns is a game of about five minutes.

Playing ahead and sealed scores work exactly as in Daily Blocks: a
score played ahead stays off every scoreboard until its own day.


INTERBBS LEAGUES
----------------------------------------------------------------------
Exactly as for Daily Blocks - three lines in dgems.ini:

  InterBBS=1
  LeagueServer=their.address.example        (add :port if they say so)
  BBSName=Your BBS Name

You can put bbswordle.com in here as long as we are going!

The league server is the same dbserver that runs the Daily Blocks,
Daily Yacht and Daily Pig leagues, on the same port.  It keeps a Daily
Gems league of its own (gems.ini, gems.dat, gems.bbs) that never touches
the others.  The server hands the door the league's boards - its own
BoardSeed, PiecesPerDay and SpecialBoards - and its make-up and
play-ahead rules, and the door writes them into dgems.ini by itself.

A server older than 2026.10.28.1 cannot hand out Daily Gems boards; the
door then says "that league server needs updating for Daily Gems" on
the home screen, keeps playing locally, and posts nothing.

Everything else - when league boards start on a BBS, what callers see,
L for local scores, B for BBS vs BBS, BBS names that do not fit, the
server being down, when scores move - is as described in Daily Blocks'
README.  A tie on a day goes to the quicker game, as in Daily Blocks.


KEYS
----------------------------------------------------------------------
Default keys are Daily Blocks' own, so the hands find the same places:

           Left/Right (A D, 4 6) move     Up (W X, 5) cycle the gems
           Z cycle back                   Down (S, 2) soft drop
           Space (8) hard drop            G ghost on/off
           P pause                        Q or Esc quit the board

Cycle moves every gem down one, the bottom one to the top; cycle back
goes the other way.  The ghost marks where the column will land.  Each
caller can change any of the nine from "Keys & Controls" (up to four
keys each, saved in dgems.key).  ESC always quits a board.


RULES WORTH KNOWING
----------------------------------------------------------------------
* One try per board.  The board is claimed the moment the gems start
  falling and the score is written to disk after EVERY column.  Quit,
  hang up, time out or get killed: the score stands, the day is used.
* Pausing (and the quit prompt) hides the well and the next columns.
* Make-ups count in full.  A day's winner can change until its make-up
  window closes.
* Hitting Play when today is done offers your open make-up and
  play-ahead days, or tells you to come back tomorrow.


SCOREBOARDS
----------------------------------------------------------------------
  1 Day        ranking for any single board (gems, columns, best chain)
  2 Winners    who won each day of a month
  3 Month      monthly standings
  4 Champs     the champion of every month
  5 All-Time   lifetime standings
  6 Top Days   the 50 highest single boards of one type: , and . step
               through Classic, Debris, Flash, Rush and Canyon.  There
               is no list of every type together - a Rush day starts
               at level 7 and would fill it.
  7 Records    , and . step through All, Classic, Debris, Flash, Rush
               and Canyon.  All: highest day, most gems in a day,
               biggest clear (the most gems one dropped column cleared,
               chains and Magic Jewel included), longest chain, longest
               streak, most wins, best average, biggest month - and the
               caller's own numbers.  One type: that type's highest
               day, most gems, biggest clear, longest chain, most wins,
               best average (3+ boards), most played (and on Flash,
               most Flash gems) - and the caller's own numbers on it.
