& &80
& &eighty
--------------------------------------------------------------------------------
& &78
& &seventy-eight
------------------------------------------------------------------------------
& MAIL
& BB
& Bulletin Board
& @mail

  Rather than using the built-in @mail system, this MUSH uses Talvo's +Mail
  and BB system. Please see HELP MAIL CREDITS for information about who wrote
  or contributed to the system.

  The system allows you to send messages to players and to Bulletin Boards.

  To send a message, you must first start it (see HELP MAIL STARTING). Then
  you can write your message (HELP MAIL WRITING) and check for and fix any
  errors (HELP MAIL PROOFING), before sending it (HELP MAIL SENDING).

  For a full list of commands, see HELP MAIL COMMANDS.

  For a description of what a '<message range>' is, see HELP MAIL RANGES.

  You may be able to download your +mail via POP3. See HELP POP3 for info.

& MAIL RANGES
& MESSAGE RANGES

  Anywhere a command takes a <message range> as an argument, you can use
  any combination of the syntaxes below to specify which messages you mean.
  If no range is given, it defaults to '-', all messages.

  These strings can be used in a message range:
  * A number, which refers to the Nth message in the inbox
  * A range of numbers, in the form X-Y, which refer to all the messages
    in the inbox between X and Y, inclusive. If X is omitted, it defaults
    to 1. If Y is omitted, it defaults to the last message in the inbox.

  Continued in HELP MAIL RANGES2

& MAIL RANGES2

  * The string "author=<player>", in which case only messages written
    by <player> are returned.
  * The string "mark=<status>" or "status=<status>", in which case only
    messages with that status are returned. For BBs and players, the
    <status> can be "read" or "new", or any abbreviation of them. For
    players, "deleted" (or an abbreviation) is also valid.
  * The string "subject=<subject>", in which case only messages whose
    subjects match <subject> are returned. An underscore (_) should be
    used to represent a space, and the '*' wildcard can be used.
  * The string "date=[<>]<number>". If a '<' or '>' is given, only
    messages written before or after <number> - which is a secs()
    count - are returned. Otherwise, only messages written at
    <number> are returned.

  Continued in HELP MAIL RANGES3

& MAIL RANGES3

  Any number of these can be combined, in which case all must be true. For
  example:

  > +skim mark=read 1-20 author=fred

  will +skim only messages which are in the first 20 in your inbox, if Fred
  wrote them, and they're marked as read.

  Now, just to complicate things a little more, you can |-separate these
  message ranges, in which case any one will apply. For example:

  > +skim mark=read 1-20 author=fred | author=george subject=*foobar*

  will +skim all the messages from before, but it will also include any and
  all messages from George which have the word 'foobar' in the subject.

  This allows for some very powerful processing. The main uses, however,
  are for '+READ MARK=NEW' to read your new messages, or '+SKIM AUTHOR=BOB'
  if you're looking for a certain message from the player Bob.

& &80
& &eighty
--------------------------------------------------------------------------------

& @mailfailure

  @mailfailure <object>[=<message>]

  This command sets a MAILFAILURE attribute on <object> (or clears it, if no
  <message> is given). This attribute only has any relevance for players - 
  when someone attempts to +mail a player, and fails to because of the 
  player's MAIL @lock, they will be shown this message.

  Example:
  > @mailfailure me=On vacation. Please email me instead!

& MAIL BLOCKING
& MAIL LOCKING

  If you wish to stop somebody from sending you +mail, you just need to set
  a MAIL @lock on yourself. HELP @LOCK explains how locks work in detail,
  but here are a couple of brief examples:

  This stops everyone from sending you mail:
  @lock/mail me=#false

  This stops Ben and Fred from mailing you:
  @lock/mail me=!=*ben&!=*fred

  And this lets only Eve and Karen mail you:
  @lock/mail me==*eve|=*karen

  You can also set an @mailfailure attribute on yourself, which will be
  shown to anyone who fails to +mail you because of your mail @lock. See
  HELP @MAILFAILURE for more information.

& MAIL COMMANDS

  For writing, editing, and sending a message:
    +MAIL, +REPLY, +FORWARD, +INCLUDE, +INCLUDES, +WRITE, +PROOF, +ADDRESS,
    +CC, +SUBJECT, +EDIT, +ERASE, +TOSS and +SEND

  For listing, reading, and deleting your messages:
    +SKIM, +READ, +UNREAD, +DELETE, +UNDELETE, +CLEAR, +OUTBOX

  For working specifically with Bulletin Boards:
    +BBLIST, +BBSCAN, +BBINFO, +BBIGNORE

  For game admins:
    +BBCREATE, +BBDELETE, +BBDESC, +BBHEADER, +BBLOCK, +BBTIMEOUT, +BBINFO,
    +MGROUP, +MAIL/BAN, +MAIL/UNBAN, +MAIL/BANNED, +MAIL/CONFIG, +MAIL/PURGE

  For more info on any of these commands, type HELP <command>
  See also: @mailsignature, @mailfailure, MAIL RANGES, MAIL LOCKING,
            +MAIL/VERSION, BB SETUP

& BB SETUP
  Use these commands for setting up a newly created BB:
  Type...                     To....
  --------------------------  ------------------------------------------------
  +BBINFO <bb>                See how the BB is currently set up
  +BBLOCK/READ <bb>=<func>    Set who can read the BB
  +BBLOCK/WRITE <bb>=<func>   Set who can post to the BB
  +BBLOCK/NOTIFY <bb>=<func>  Set the player's notified when the BB is
                              posted to
  +BBDESC <bb>=<description>  Set a description explaining the BB's use
  +BBADMIN <bb>=<func>        Set who is an admin for the BB
  +BBTIMEOUT <bb>=<timeout>   Change how old messages must be to be deleted
                              from the BB
  +BBHEADER <bb>=<text>       Set the header shown at the top of +bbscan <bb>

  When a board is first created, noone can post to or read from it, so it's
  vital that you set those to make the board useful.

  See also: +bbinfo, +bblock, +bbdesc, +bbadmin, +bbtimeout, +bbheader

& MAIL CREDITS

  Talvo's +Mail and BB System was written by Talvo@ElendorMUSH/Mike@M*U*S*H 
  (who can be emailed at mike@keyboardzombie.com). It's based heavily on the 
  ElendorMUSH +mail system, which was written by Lukthil@ElendorMUSH. The 
  following people made significant contributions to the code:

  * Benigo@ElendorMUSH helped with large portions of the SQL code, made
    suggestions for additonal functionality, and also provided a MUSH
    for testing the system on. It wouldn't have happened without him.
  * Cheetah@M*U*S*H wrote the extremely nifty regexp used by FUN.PARSEARGS,
    which makes the syntax a lot more natural.
  * Walker@M*U*S*H wrote the regexp code used by +EDIT/REGEXP, greatly
    improving its power.
  * Many, many bug reports/suggestions came from the folks at Blood
    of Dragons MUSH (http://www.westeros.org/BoD/).

  See HELP MAIL CHANGES for the current version, and a list of changes
  from previous versions. If you would like to contribute anything to
  this system - bug reports, code fixes, suggestions, etc - please email
  Talvo (Mike Griffiths), at mike@keyboardzombie.com

& +MAIL/VERSION

  +MAIL/VERSION

  This command shows some information on the +Mail system, including the
  current version, an email address to send bug reports/feature requests,
  and the website where you can download the latest version of the code.

  The file HELP MAIL CHANGES lists changes in the different versions,
  going all the way back to the first release, and HELP MAIL CREDITS lists
  some of the people who have made significant contributions to the code.

& MAIL CHANGES
& MAIL VERSION
& MAIL 2.3

  Version 2.3 - November 22 2007

  * Elusive bug in purge routine fixed. Many thanks to Nymeria and
    Balerion at Blood of Dragons for their help.
  * After two +reply's, message subjects are now "Re (X): <original>",
    where X is the number of replies, to avoid messages with dozens of
    "Re:"s at the start. This removes the re_subject +mail/config
    option with the reply_subject message on %vc. Suggested by Balerion.
  * Mail sent via sendmail() didn't pass the subject to the "new mail"
    message. Reported by Balerion.

& MAIL 2.2

  Version 2.2 - October 28 2007

  * Typo in the +delete messages fixed by Balerion.
  * Help for +delete/+expunge re-written, hopefully making it clearer.
    Suggested by Balerion.
  * Bug in +delete with messages marked as 'new' fixed.
  * The subject of a new mail message can now be included in the message
    shown to recipients. Suggested by Nymeria.
  * New +bbauthor command, lets you change the way an author's name
    appears on BB posts, allowing for "anonymous" BBs and suchlike.
    Suggested by Nymeria.
  * A couple of bugs in +bbheader fixed.

& MAIL 2.1

  Version 2.1 - July 20 2007

  * +BBREAD now works the same as in Myrrdin's system. See HELP +BBREAD.
    Suggested by Balerion.
  * +BBIGNORE now clears the bbignore attr, rather than setting it empty,
    when no boards are being ignored. By Balerion.

& MAIL 2.0

  Version 2.0 - July 8 2007

               *** NOW REQUIRES PENNMUSH 1.8.1p9 OR HIGHER ***

  * +BBLOCK showed a lot of junk debug output at the end, which should have
    been removed. Fixed now. Reported by Balerion@M*U*S*H.
  * +BBLOCK didn't work without a switch. It now defaults to /read, like
    it's supposed to.
  * +BBLOCK/POST is now an alias for +BBLOCK/WRITE.
  * When an Admin lock isn't set for a BB, the 'Admin Lock' line is omitted
    from +BBINFO, instead of being shown as being empty.
  * The +BBREAD command only worked with BB names, not numbers. Fixed now.
  * It's now possible to stop messages on a BB from timing out, by setting
    the timeout to zero (0). Messages on those boards will never time out,
    and will need to be manually deleted with +expunge.
  * Any command which takes an amount of time in seconds (+mail/config and
    +bbtimeout) can now accept any value which is valid for stringsecs().
  * The llocks() function was used incorrectly in the code, making it
    impossible for anyone to ever pass a BB's locks. Fixed by Balerion.
  * The +BBSCAN command listed all BBs with new posts, regardless of whether
    or not you could actually read that BB. Fixed now.
  * Some minor code changes to take advantage of new features in PennMUSH,
    and lower the number of function calls used in some places.
  * Assorted help-file updates and changes.
  * The default maximum length for BB names is now 14 characters instead of
    15, to improve formatting for BB commands.
  * The code for the +BBHEADER command was missing from the code file. It's
    now included, and the header for a BB is shown on +bbinfo.
  * Bug in +bblist/all which prevented skins from working has been fixed.
  * Some bugs in fun.range for BBs fixed.
  * Instead of storing BB names in the MySQL database, we now store their
    id number. This fixes possible errors which could occur if you delete
    a bb and then create a new one with the same name (as well as saving a
    small amount of space in your db). Current posts will not be effected.
  * Players passing the %vb/see_all @lock can now use the @<alt> syntax
    of more commands to view things as mortals, including +skim, +outbox
    and +bbscan. This requires a change to %vb/FUN.ISALT - see the code
    for details.
  * Even when connect_bb is turned on, we don't show the 'No new messages'
    error. The aconnect now lists BBs with new posts if there are any, and
    stays quiet otherwise, to cut down on spam.
  * The aconnect now informs you if you're writing a message.
  * +SKIM sometimes listed messages in the wrong order. Fixed by Balerion.
  * Typo in purge routine fixed.
  * +EXPUNGE no longer works if no message range is given. To expunge all
    messages, use the message range '-'.
  * +WRITE didn't work when the text written included %r. Reported by Alkar.
  * When you +EDIT a message, the changes are shown with ansi hilight. This
    was previously only done for regexp edits.


& MAIL 1.8b

  Version 1.8b - May 4 2006

  * +BBDESC actually deleted a BB (just like +BBDELETE) instead of changing
    it's description, because of two very stupid typos. Fixed.
  * +BBLIST now shows the tag when there are no BBs you can read.
  * Fix to +BBLOCK which stopped it working correctly since 1.8.
  * Error message for +BBLOCK with an invalid switch listed the valid switches
    incorrectly. Fixed now.
  * +MAIL and +MGROUP no longer ignore trailing ='s, as the bug which made
    that necessary is fixed in Penn 1.8.1p8. (It was actually implemented
    incorrectly for +mgroup anyway, and so only worked for +mail.)
  * The +MAIL command can now accept BB numbers when checking mail with the
    '+mail [@<alt>] <bb>' syntax. A new argument parsing routine is used
    for this, %vb/fun.parseargs-noargs, which checks for an alt and a BB, but
    does not check for a message range (allowing numbers to be parsed as BBs).
  * You can no longer add a BB whose name is a number; given that BBs can now
    be referenced by both name and ID number, that would be extremely nasty.
  * Cosmetic fixes to some help-files.
  * Added HELP BB SETUP, which lists all the commands used to set up a newly
    created BB. (This file was already referenced by the +BBCREATE command,
    even though it didn't exist.)

& MAIL 1.8

  Version 1.8 - Apr 30 2006

  * The Command and Function objects are set with the new LOUD flag, to make
    sure they can always pemit to players.
  * Fix to the @command/add's, which were being done incorrectly.
  * Some commands are @command/add'd with the /eqsplit switch, so they
    evaluate the right-hand side properly.
  * There is now a 1 second pause after you connect, before the mail system
    aconnect runs +mail/+bbscan for you.
  * The help for sendmail() is now aliased to mailsend(), which is the name
    of the PennMUSH @mail function which does the same job.
  * +BBINFO for a board now also shows how it's Admin lock (+bbadmin) is set.
  * +BBADMIN can now actually take the documented /noeval switch.
  * +BBLOCK can now take a /noeval switch.
  * Added some error-checking for +bblock/+bbadmin so that '+bblock <bb>'
    and '+bblock <bb>=' won't clear a lock; you must now set it to 0 instead.
  * The +mail and +mgroup commands ignores the last character typed, if it's
    an '='. This is a temporary fix to work around a minor bug in PennMUSH
    1.8.1p7's matching when using @command/add/eqsplit.
  * Extra checks in the lock-checking functions, to make sure they fail if
    the lock is set incorrectly or the BB does not exist.

& MAIL 1.7

  Version 1.7 - Mar 3 2006

  * The address-parsing code was altered so that BBs could be referred to
    by number, as well as by name (the same as Myrddin's system allows).
    Suggested by Kali@M*U*S*H.
  * Change to +bbinfo, so that it could accept BBs by number as well as
    name. The command also includes the BB's number for all players;
    previously, only those with see_all were shown them.
  * The default display of +bbscan and +bbinfo have been altered to include
    the BB's number.
  * Changes to help files and code comments - the /noeval switches should
    all work, in Penn 1.8.1p6 and higher, now. (Thanks, Javelin!)
  * The attributes used for +BBLIST and +BBSCAN have been altered to allow
    skinning - that is, you can now set a custom look for those +mail
    commands without having to touch any of the preset attributes. (The
    attrs are SKIN`BBLIST and SKIN`BBSCAN). The same should happen for
    +skim and +read/+proof soon. Suggested by Kali@M*U*S*H.
  * Added a new +BBIGNORE command. See HELP +BBIGNORE. This also adds a
    new standard attribute named BBIGNORE. Similar to Myrddin's +bbleave.
  * Fixed a typo in %vb/config`db_prefix`onchange which would have caused
    an error, if you tried to change the db_prefix with +mail/config.
  * Fixed a bug in fun.range which made it impossible to use the 'status='
    argument in message ranges for BBs.
  * Added a +BBREAD <bb>/<range> command, for added compatability with
    Myrrdin's BB system. This is usually the same as +read <bb> <range>,
    but see HELP +BBREAD for more.
  * You can now force a BB in commands that take <bb> <range> by prefixing
    the <bb> arg with 'BB:'. This allows you to use a BB's number without
    that number being interpreted as a part of the <range>, as in
    '+skim bb:4 3-6 mark=new'.
  * BB names may no longer contain colon (:) characters.
  * New command +BBCATCHUP which works as an alias for +read/mark. See
    HELP +BBCATCHUP for more.
  * Added an optional /noeval switch to +MGROUP/ADD.

& MAIL v1.6

  Version 1.6b - Feb 25 2006

  * A bug appeared in +BBSCAN in Penn 1.8.0p10 / 1.8.1p5 due to a change
    in the way SQL() treats it's <delimiter> args, when they're given as
    an empty string (previously they used a space). We now force a space
    in these cases. (This also effects dozens of other commands/functions
    in the code, but I think they've all been fixed now.) Original report
    by Matthew Stockfleth.
  * The unknown-mail-switch message attribute was set on the wrong object.
  * Added descriptions to %va (command object) and %vb (function object),
    which show the contents of the %vb/info** attributes (code name,
    version, etc), as several people had said this info was hard to find.
  * New +MAIL/VERSION command, which shows the same info as the @descs
    mentioned above.
  * Fixed a typo in a config option which may have made it impossible to
    change the option with +mail/config. A couple of typos in the install
    script's comments/docs were also fixed.
  * Help (and code comments) updated to reflect the fact that commands are
    not yet @command/add'd (since it's not possible after all, yet), which
    also means that /noeval switches don't work, etc.
  * A reference to @mail in HELP @MAILFAILURE has been changed to +mail.

& MAIL v1.5

  Version 1.5 - Dec 12 2005

  * Fixed a typo in the +DELETE code, when deleting your own mail. Fixed
    by Balerion@M*U*S*H.
  * The +EXPUNGE command was missed from the list of commands which were
    @command/add'ed and @hook'd. Added in, now.
  * The +EXPUNGE command was also pathetically broken, due to several
    typos and a lack of testing. Fixed now. Reported by Balerion@M*U*S*H.

& MAIL v1.4

  Version 1.4 - Dec 2 2005

  * The MailBot character created is no longer set WIZARD - which was
    now both unnecessary and unwise. Instead, we set a bunch of @powers
    on him to give him only the powers he needs, and move all the wizard
    things onto the Function Object, which is already a Wizard. Some other
    flags are also set (like QUIET and NO_WARN).
  * Set several new attributes, on the Function Object (%vb) and the MailBot
    character, to allow the POP3 server to function.
  * Commands are now made global, via @command/add and @hook/override.
    This works only if you're running PennMUSH 1.8.1p4 or higher. (The short
    forms for writing and sending, -<msg> and --, are still not global,
    because it can't be done through softcode.)
  * Initial release of the POP3 Server for use with the mail system.
  * Fixes to +BBCREATE, and several other BB commands which did stupid things.
  * You can now delete mail from a BB via the +DELETE/FORCE command. To do
    this, you must be a BB Admin. Suggested by Balerion@M*U*S*H.
  * Addition of +BBADMIN command, to set the Admins for a given BB. See above.
  * Fixed a typo in fun.range which caused it to accept invalid ranges.
  * +PROOF/EXAMINE is aliased as +DRAFT, and +DELETE/FORCE is aliased as
    +EXPUNGE, both for compatability with ElendorMUSH's +mail system.
  * The connect_[mail|bb] config options where actually being set as
    startup_[mail|bb] by mistake.

& MAIL v1.3

  Version 1.3 - Nov 27 2005 (again!)

  * Fixed many stupid bugs:
    - +CC and +ADDRESS both checked incorrectly to see if you were writing a
      message, which meant they showed success messages even when you weren't
      writing.
    - When the tables were created, they did not use the new DB_PREFIX option,
      which broke just about everything. Woops.
    - Around a half-dozen sql() calls didn't use DB_PREFIX, or were using it
      incorrectly (by calling %qp instead of %vp).
    - The @attribute commands used /add, when they meant /access. Thanks to
      Nymeria@M*U*S*H for spotting it! 

& MAIL v1.2

  Version 1.2 - Nov 27 2005

  * New config option DB_PREFIX lets you specify a prefix for the tables
    in the MySQL DB. The default is 'mm_' - if you have an install which
    doesn't use this, you'll want to set it to an empty string. Suggested
    by Linda Antonsson.
  * All MUSHcode used by the POP3 server is now included in the code, and
    is not commented out. This adds a WIZARD player used as a bot to the MUSH.
  * POP3 help-files released. Note that you should edit these to show the
    correct host names in HELP POP3 and HELP POP3 OE6, and to show which
    configuration you're using in HELP MAILSERVERS2.
  * A new @ACONNECT on the command object can show connecting players both
    the number of +mail messages they have (as per '+mail'), and which BBs
    have unread messages (as per '+bbscan'). This introduces two new config
    options, connect_mail and connect_bb, which control what's shown.
  * Dozens of help-file corrections, mostly typos.

& MAIL v1.1

  Version 1.1 - Sep 19 2005

  * Fix to +BBCREATE (%vb/fun.bbcreate) which was failing to set an
    attribute later used by the other bb commands
  * Added a note about safer_ufun in the installation file
  * Fixed a mistake in the installation file's comments about how
    FUN.ISALT works, which broke the error messages for commands when
    a player was given who was not your alt via the +command @alt syntax

& MAIL v1.0

  Version 1.0 - Sep 12 2005

  Talvo's +Mail System is currently at version 1.0. This is the initial
  release, so there are no changes to report.

& MAIL STARTING

  There are three ways you can begin a +mail message: by starting a new
  message from scratch, by forwarding a message to another player, or by
  replying to a message. This file covers starting a new message - for
  replies and forwards, see HELP +REPLY and HELP +FORWARD, respectively.

  To start the message, you use the +mail command, and type:
    +mail <address>=<subject>
  The <address> can be any combination of Players, Bulletin Boards and
  Mail Groups. If a player/BB/MG have the same name, you can make sure
  the right one is used by using PLAYER:<name>, BB:<name> or MG:<name>.
  For instance:

    +mail Fred Player:Test MG:Test BB:Public=Hello!

  would start a new messages to the players Fred and Test, the BB
  Public, and everyone in the Mail Group Test, called "Hello!".

  When you've started your message, you need to write it. This is
  explained in HELP MAIL WRITING.

& MAIL WRITING

  When you've started a message, you can write in it by using the +WRITE
  command. A hypen (-) is the abbreviation for +WRITE, so:
    +write Hello everyone!
  is the same as
    -Hello everyone!

  To move to the next line in your message, type '%r'. For example:
    -Hello everyone!%rI'm testing how to write!%rTalvo

  You can write as many times as you like; the new text will be added onto
  the end of the message.

  When you've finished writing your message, you should check it over and
  fix any mistakes you see. HELP MAIL PROOFING explains how.

  For people trying to place code into mail messages, HELP MAIL EVALUATION
  will provide some helpful information.

& MAIL PROOFING

  When you've written your message, you can read it over to see how it will
  look by typing +PROOF. If you see any mistakes, you should use one of the
  commands below to fix it, depending on where the mistake is:

  +EDIT will edit the actual text in your message.
  +CC and +ADDRESS will edit the list of recipients.
  +SUBJECT will change the subject of your message.
  +INCLUDE lets you include the text from another message inside your current
    message.
  +ERASE will delete the text from your message, if you want to start over.
  +UNDO will undo your last change to the message (not the subject/address).
  
  When your message is finished you can send it, as explained in HELP MAIL
  SENDING.

& MAIL SENDING

  To send your message, use the +SEND command. You can also use two hyphens
  (--) as an abbreviation for +SEND.

  When you send your +mail, all the recipients will receive a message, telling
  them they have new mail. You will then be told that your message is sent,
  and given it's ID number:

    [+MAIL] Message sent (#12345).

  You can use this number later to get the message back, if you need to, with
  the +UNMAIL command. Don't worry about remembering the ID number, though -
  you can get the IDs of all the messages you've sent by typing +OUTBOX.

  And that's it - your message is sent. There are some more complex things
  you can do, too, which aren't mentioned in this introduction - read the
  help-files for the specific +mail commands to find out what they are.

& +MAIL

  +MAIL [@<alt>] [<bb>]
  +MAIL <address>=<subject>

  (Note: this is the help for the +MAIL command. For help on Talvo's +Mail and
  BB System in general, see HELP MAIL.)

  The first form of this command simply tells you how many messages you have,
  and how many are new (unread), read, and marked for deletion. If an <alt>
  is given, that player's messages will be checked instead. If a <bb> is
  given, the messages on that bulletin board are checked.

  The second form of the command starts a new message, addressed to everyone
  in <address> who you're allowed to mail, entitled <subject>.

  See also: MAIL, +forward, +reply, sendmail()

& SENDMAIL()
& MAILSEND()

  SENDMAIL(<author>,<address>,<subject>,<message>[,<silent?>])

  This function is a part of Talvo's +Mail system, and can be used to send
  mail instantly from coded systems. The first argument should be the name,
  dbref or objid of the player the mail is from - if omitted, or if it's not
  a valid player, #1 will be used instead. <address> should be an address list
  in the form used by other +Mail commands, and specifies who the mail will be
  sent to. <subject> is the mail's +subject, and <message> is the content of
  the message. If <silent?> is true, the normal notifications which tell
  players they have received mail will not be sent.

  This function can only be used by Wizards. It returns 1 on success, and 0 on
  failure. ('Success' is when the mail is successfully sent to at least one
  recipient. Any members of the <address> which are not matched are
  silently ignored.)

  Example:
  > @open Join Game;jg
  > @success jg=You join the game![null(sendmail(%#,BB:Public,New Player!,
         %n has just joined [mudname()]. Please welcome %o!%r%rThe Staff.,0))]

  (When a player walks through the exit "Join Game", a mail will be sent to
  the Public BB welcoming them to the game.)

& +FORWARD

  +FORWARD [@<alt>] [<bb>] [<message range>]=<address>

  This command starts a new +mail message addressed to <address>, and
  automatically includes the contents of the messages in <message range>
  at the end of your message. If an <alt> is given, the message range is
  matched against his mail. If a <bb> is given, the messages are taken from
  that bulletin board. This command is basically just an alias for:

    +mail <address>=Forwarded Messages
    +include [@<alt>] [<bb>] <message range>

  See also: MAIL, +include, +mail, +reply

& +REPLY

  +REPLY [@<alt>] [<bb>] [<message range>]

  This command starts a new +mail message, addressed to the author and
  recipients of the message which matches the range <message range>. If the
  range matches more than one message, an error occurs. The subject will be
  "Re: <original subject>", though the contents of the original message
  will not be included (though you can include it with +include, if you wish).

  See also: MAIL, +mail, +include

& +INCLUDE
& +INCLUDES

  +INCLUDE [@<alt>] [<bb>] [<message range>]
  +INCLUDES
  +INCLUDE/REMOVE <ids>

  The first form of this command will include the text of any messages which
  match the <message range> into the message you are currently writing. This
  is similar to +forward, except that +forward starts a new message, whereas
  +include puts the messages into a message you're already writing.

  The second form, +includes, lists the message IDs of all the messages
  currently included (via +include or +forward) in your message.

  The final form of the command takes a list of message ids, as show by
  +includes, and removes them from your message.

  See also: MAIL, +forward

& +SUBJECT

  +subject <subject>

  This command changes the subject for the +mail message which you are
  currently writing to <subject>.

  See also: MAIL, +mail

& +CC
& +ADDRESS

  +CC <address>
  +CC/REMOVE <address>
  +ADDRESS <address>

  The +CC command will add everyone in <address> into the list of recipients
  for the +mail you're writing. +CC/remove does the opposite, removing all
  those in <address> from your current recipient list.

  The +ADDRESS command sets your recipient list to <address>, deleting all the
  people already in the list.

  See also: MAIL, +mail

& -
& +WRITE

  +WRITE[/nospace][/noeval] <text>
  -<text>

  These commands write some text into your current +mail message. The '-'
  command is the same as +WRITE with no switches, and adds a single space
  followed by <text> onto the end of your message.

  If the /nospace switch is given to +WRITE, no space is added before <text>.
  If the /noeval switch is given, <text> is not evaluated.

  See also: MAIL, MAIL EVALUATION

& MAIL EVALUATION

  By default, +mail messages are evaluated twice: Once when you write the
  message, and once when you read it. This is done so that code can be
  placed inside a message. For example, assuming the object #100 is called
  "Talvo's Wagon", and is in a room named "Market Place", if you use:

  +write Visit [name(#100)] at [name(loc(#100))] now!

  You will write: Visit Talvo's Wagon at Market Place now!

  Continued in HELP MAIL EVAULATION2

& MAIL EVALUATION2

  But what happens if the wagon moves? Your message will still tell people
  to look for it at it's old location. So, instead, you could use:

  +write Visit [name(#100)] at \[name(loc(#100))] now!

  In which case, your message will now say:
  Visit Talvo's Wagon at [name(loc(#100))] now!

  When someone reads that, it will be evaluated again, and they'll see:
  Visit Talvo's Wagon at Market Place now!

  If you then move the wagon into a room called "Main Road", and re-read
  the +mail message, you'll now see:
  Visit Talvo's Wagon at Main Road now!

  Continued in MAIL EVALUATION3

& MAIL EVALUATION3

  It's very simple to prevent this extra evaluation, if you want to. To stop
  your message being evaluated when you write it, simply put a ']' before the
  command. For example:

  ]+write Visit [name(#100)] at [name(loc(#100))] now!

  To prevent the message being evaluated when you read it, simply use the
  +read/examine command.

  Note: If you read a mail message which was written by a player who is no
  longer on the game (someone who has been purged), the message will not be
  evaluated again when you read it.

& +UNDO

  +UNDO

  This command is a part of the +mail system, and undoes the last change made
  to the body of the message, via +write, +edit, etc. It does -not- reverse
  changes made to the address or subject of a message.

  See also: MAIL, +write, +edit

& +SEND
& --

  +SEND[/nosig][/loud]
  --

  These commands send your current +mail message, notifying all the
  recipients that they have received mail. The '--' command is the same
  as +SEND with no switches. By default, if your MAILSIGNATURE attribute is
  set, and evaluates to a non-empty string, a newline character followed by
  the contents of that attribute is added to the end of your message. If the
  /nosig switch is given to +SEND, however, that does not happen.

  If you are hidden (via @hide) when you send the message, players who cannot
  see you in the WHO list will not be notified that they have received
  mail from you, unless the /loud switch is given.

  See also: MAIL, @mailsignature

& @mailsignature

  @mailsignature <object>[=<signature>]

  This command sets a MAILSIGNATURE attribute onto <object>, if <signature>
  is given, otherwise it clears the attribute. The MAILSIGNATURE attribute
  only has meaning for players - when set, it is evaluated and added
  onto the end of all +mail messages the player sends.

  Example:
  @mailsig me=Eagles may soar, but weasels don't get sucked into jet engines.

& +PROOF
& +DRAFT

  +PROOF[/examine]
  +DRAFT

  The +PROOF command shows you the contents of the +mail message you're
  currently writing. If the /examine switch is given, the message will not
  be evaluated. Otherwise, the message appears exactly as it will after
  it's been sent.

  +draft is an alias for +proof/examine.

  See also: MAIL, +read

& +READ
& +READ/MARK
& +READ/SENT
& +READ/EXAMINE

  +READ[/mark|/examine] [@<alt>] [<bb>] [<message range>]
  +READ/SENT[/examine] <id>

  This message is used to read +mail messages. If the /mark switch is given,
  you will not actually see the content of the message, but it will still be
  marked as having been read.

  The second form of the command allows you to read messages which have
  been sent, but aren't currently in your inbox. You can only read a message
  if you were the original author or a recipient. The <id>s of messages
  you sent can be seen via the +OUTBOX command.

  If the /examine switch is given, the message will not be evaluated.

  See also: MAIL, +proof, +outbox, +bbread

& +BBREAD

  +BBREAD [<bb>[/<message range>]]

  This is a compatability command for Myrddin's BB system. With no arguments,
  it does the same thing as +bblist/all. With a <bb>, it works the same as
  '+skim bb:<bb>'.

  If a <message range> is given as well, the command works the same as
  '+read bb:<bb> <message range>', with one exception: if <message range> is
  'u', the command will show all unread (new) messages on <bb>, the same as
  '+read bb:<bb> mark=new'.

  See also: MAIL, +read, MAIL RANGES

& +BBCATCHUP

  +BBCATCHUP <bb> [<message range>]

  This command marks all messages on <bb> which are in the <message range>
  as read. It's just an alias for
    +read/mark BB:<bb> <message range>
  and was added for compatability with Myrrdin's BB system. If no
  <message range> is given, all messages are marked as read.

& +SKIM

  +SKIM [@<alt>] [<bb>] [<message range>]

  This command lists the messages in your inbox (or the inbox of <alt> or
  <bb>, if given) which match <message range>. It tells you the number the
  message has in your inbox, it's author, subject, the date it was sent,
  and it's status (read, marked for deletion, etc).

  See also: MAIL, +read

& +DELETE
& +DELETED
& +DELETE/FORCE
& +EXPUNGE

  +DELETE <message range>
  +EXPUNGE [<bb>] <message range>
  +DELETED

  The +DELETE command marks all messages in the <message range> for deletion
  (but does not actually delete them). Any messages in that range marked as
  New (unread) will not be changed. 

  The +EXPUNGE command is similar, but will also mark new (unread) messages
  as deleted. You can also use +EXPUNGE to delete messages from a bulletin
  board. Messages from a BB are deleted INSTANTLY, and it can't be undone, so
  use it carefully!

  The +DELETED command tells you which messages are marked for deletion. These
  messages are not deleted completely until you use the +clear command.

  Please delete messages whenever you've finished with them to help us
  save database space. Thank you.

  +DELETE/FORCE is an alias for +EXPUNGE.

  See also: MAIL, +clear, +undelete, POP3

& +CLEAR

  +CLEAR

  This command deletes all messages in your inbox which are marked for
  deletion with +delete. The messages will not actually be deleted until you
  use this command.

  See also: MAIL, +delete

& +UNDELETE
& +UNREAD

  +UNREAD [<bb>] <message range>
  +UNDELETE <message range>

  These commands edit all the messages in your inbox (or that of <bb>) and
  change their status, either from Read to New (unread), or from Marked for
  Deletion to Read, respectively.

  See also: MAIL, +read, +delete, +bbcatchup

& +OUTBOX

  +OUTBOX[/id] [@<alt>]

  This command lists all the messages you (or <alt>) have sent, along with
  a little bit of info about each message. Part of this info is the ID number
  of the message, which you can use to +unmail the message, or to read it
  via +read/sent.

  By default, the messages are sorted in date order (as they are in +skim
  and other commands). If the /id switch is given, however, the messages
  will be sorted in numerical order by ID number.

  See also: MAIL, +unmail, +read

& +UNMAIL

  +UNMAIL <id>

  This command unmails the +mail message <id>. It removes it from the inboxes
  of all the recipients, and places it back in front of you to edit and resend
  (or +toss) as you wish. You cannot unmail if you are already writing a
  message, however. If players have already read the message, you will be
  notified when you unmail it. All players who have the message in their
  inbox will be notified that you have taken it back.

  See also: MAIL, +outbox

& +ERASE

  +ERASE[/all]

  This command erases the body of your current message. If the /all switch is
  given, the subject is erased, too, and set to the default.

  See also: MAIL, +subject, +toss, +undo

& +TOSS

  +TOSS

  This command totally destroys the message you are currently writing, 
  allowing you to start a new message. It cannot be undone.

  See also: MAIL, +erase

& +EDIT
& +EDIT/DELIM
& +EDIT/REGEXP
& +EDIT/REGEXPI
& +EDIT/REGEXPALL
& +EDIT/REGEXPALLI

  +EDIT[/noeval] <old>/<new>
  +EDIT/DELIM[/noeval] <delim> <old><delim><new>
  +EDIT/REGEXP[all][i][/noeval] <delim> <pattern><delim><replacement>

  These commands can be used to edit the body of your current +mail message.
  The first two commands replace all occurances of <old> with <new>, with
  two exceptions: if <old> is a caret (^), <new> will be added to the start
  of your message. If <old> is a dollar-sign ($), <new> is added to the end
  of your message (exactly like +write/nospace <new>). The main use for
  +edit/delim is if you need to edit a '/' character, as you can specify
  a different string to separate <old> and <new>.

  The third command uses regular expression matching to edit your message.
  By default, only the first match is replaced, but this can be changed by
  giving the 'all' part of the switch. The match is case-sensitive, unless the
  'i' part of the switch is given. Strings in your message which match the
  regular expression pattern <pattern> will be replaced with <replacement>.
  In <replacement>, $0 refers to the entire string matched, $1 to the first
  matching sub-pattern, $2 to the second, and so on to $9, similar to the
  regedit[all][i]() functions.

  There are a few examples in HELP +EDIT2.

  See also: MAIL, +erase, +write, regedit()

& +EDIT2

  If your message read "This is a test / abc, 123" then...

  > +edit is/
  Th  a test / abc, 123

  > +edit/delim FOO / abcFOO- ABC
  This is a test - ABC, 123

  > +edit/regexp/noeval _ (\S+)s(\S*)_$1S$2
  ThiS iS a teSt / abc, 123

  (To prevent the MUSH from evaluating the \'s in the regular expression,
  it's a good idea to use the /noeval switch with +edit/regexp.)

& +BBSCAN

  +BBSCAN [@<alt>]

  This command lists all the bulletin boards in the game which you can read,
  and which have messages which you have not read. If an <alt> is given, it
  checks to see which boards he can read, and which messages he has not read.
  It also tells you how many unread messages there are, in parenthesis after
  the board's name. Bulletin boards which you are ignoring (via +bbignore) are
  also excluded from the list.

  See also: MAIL, +mail, +bblist, +bbignore

& +BBIGNORE
& +BBLEAVE

  +BBIGNORE [<bb>]

  This command causes you to 'ignore' the bulletin board <bb>, so that it no
  longer shows up on a +bbscan. (It will still show up on +bblist, however.) 
  This is useful if there is a BB you don't read which often has new posts.

  If no <bb> is given, the command shows which BBs you are currently ignoring.
  If you are already ignoring <bb>, you will stop ignoring it.

  +bbleave is an alias for +bbignore, for compatability with Myrrdin's BB.
& bbignore

  The BBIGNORE attribute is used by Talvo's +Mail System, to store a list
  of BBs which you are currently ignoring. See HELP +BBIGNORE. This attribute
  can only be seen or altered by Wizards, though there should be no need for
  it to be changed manually at any time.

& +BBLIST

  +BBLIST[/all] [@<alt>]

  This command lists all the BBs on the game which you (or <alt>, if given)
  can read, and tells you how many messages are posted on the board.

  If the /all switch is given, all BBs are shown, though you will only see
  the number of posts for boards which you can read.

  See also: MAIL, +mail, +bbscan

& +BBINFO

  +BBINFO <bb>

  This command shows certain information about the bulletin board <bb>,
  including it's proper name, the header shown at the top of the board when
  you +skim it, how long a message posted to the board will stay before it
  times out, and the functions which you must pass in order to read from or
  write to the BB. It also shows a ufun which you must pass in order to be
  notified of new posts. If one is set, a description of the board's
  purpose will be shown. And finally, if you can read from the board, you
  will be told how many messages are posted.
  
& +BBCREATE
& +BBDELETE

  +BBCREATE <bb>
  +BBDELETE <bb>

  These admin-only commands create a new Bulletin Board, and destroy an
  existing BB, respectively. By default when a new BB is made, noone can
  post messages on it or read from it - these locks must be edited with
  the +BBLOCK command.

  Deleting a BB cannot be undone, so please be careful when doing so.

  See also: +bbtimeout, +bblock, +bbdesc, +bbheader

& +BBAUTHOR

  +BBAUTHOR[/noeval] <bb>[=<function>]

  If a <function> is given, this command overrides the way a message author's
  name is shown for messages posted to <bb>. Instead, <function> will be
  evaluated (with the author's objid passed as %0), and the result will be
  displayed in place of his name. The dbref of the person reading the message
  is passed as %1.

  If no <function> is given, the author is reset, and the default is used.

  Examples:
  > +bbauthor Gossip=Anonymous
    (makes all posts to the 'Gossip' BB from 'Anonymous')
  > +bbauthor/noeval Discussion=switch(0,t(pmatch(%0)),<Purged>,orflags(%0,Wr),
                 name(%0),ansi(rh,name(%0)))
    (shows <Purged> for purged players, the name in red for staff, or the name
     with no ansi for non-staff)

& +BBADMIN

  +BBADMIN[/noeval] <bb>=<function>

  This command sets the function which determines who is an admin for <bb>.
  BB Admins can delete posts from the BB (via +delete/force). The player being
  checked is passed to this function as %# (and %:, %n, etc), and the player
  is considered to pass the admin lock if the function returns 1. Wizards and
  Royals are always admins for all BBs. <function> will be evaluated, unless
  the /noeval switch is given.

  Example:
  > +bbadmin/noeval mybb=cor(member(get(#123/admin_list),%:),
                             hasflag(%:,EDITOR))

& +BBTIMEOUT

  +BBTIMEOUT <bb>=<timestring>

  This admin-only command changes the time it takes for a message posted
  on <bb> to time out and be purged to <timestring>. <timestring> should
  be a combination of numbers followed by d, h, m or s (for days, hours,
  minutes or seconds). Note that messages may stay on the board slightly
  longer than this amount of time, as the purging routine is only run
  once a day.

  If <timestring> is 0 (zero), messages will not time out, and will remain
  until they're deleted with +expunge.

  Examples:
   > +bbtimeout Public=604800
   (sets the timeout for the Public board to 604800 seconds, or 1 week)
   > +bbtimeout News=30d
   (sets the timeout for the News board to 2592000 seconds, or 30 days)
   > +bbtimeout Archive=0
   (removes the timeout from the Archive board)

  See also: +bbcreate, +bbdelete, +bblock, +bbdesc, +bbheader

& +BBLOCK

  +BBLOCK[/read|/write|/notify][/noeval] <bb>=<ufun>

  This admin-only command changes who can read from <bb>, post to <bb>, or who
  will be notified of new posts to <bb> to <ufun>. <ufun> should be a function
  where %# is the player being checked against. The <ufun> must return 1 if
  the player should be able to pass the lock. If no switch is given, /read is
  the default.

  Note that <ufun> will be evaluated, which may not be desirable. Use the
  /noeval switch to prevent evaluation of the <ufun>.

  Example:
  > +bbcreate Admin
  > +bblock/read/noeval Admin=orflags(%#,Wr)
  > +bblock/write Admin=1
  > +bblock/notify/noeval Admin=orflags(%#,Wr)

  In this example, anyone can post to the Admin BB, but only Wizards and
  Royalty can read the messages, and only Wiz/Roy will be notified about new
  messages posted to the board.

  See also: +bbcreate, +bbdelete, +bbtimeout, +bbdesc, +bbheader

& +BBDESC

  +BBDESC <bb>=<desc>

  This admin-only command sets the description for the bulletin board <bb> to
  <desc>. This description is shown in +BBINFO, and advises players as to the
  intended purpose of a particular board. If <desc> is an empty string, then
  no description will be shown for <bb>.

  Example:
  > +bbdesc Admin=If you have a question or comment for the game staff, please
                  post it here.

  See also: +bbcreate, +bbdelete, +bbtimeout, +bblock, +bbheader

& +BBHEADER

  +BBHEADER <bb>=<header>

  This admin-only command sets the header for the bulletin board <bb>. The
  header is the string show at the top of +BBINFO, and of +SKIM, for the
  given <bb>. Often some kind of ASCII art is used. Please note that the
  header is evaluated each time it's needed, so you'll probably want to escape
  out your <header>.

  Example:
  > ]+bbheader Public=center(ansi(h,PUBLIC!),78)

  See also: +bbcreate, +bbdelete, +bbtimeout, +bblock, +bbdesc

& +MAIL/BAN
& +MAIL/UNBAN
& +MAIL/BANNED
& MAILBAN

  +MAIL/BAN <player>
  +MAIL/UNBAN <player>
  +MAIL/BANNED

  These admin-only commands stop a player from sending mail, and allow him to
  do so again, respectively. The last lists all players currently banned.
  The banning is done internally via the use of a MAILBAN flag.

& +MAIL/CONFIG

  +MAIL/CONFIG [<option>]
  +MAIL/CONFIG <option>=<value>

  The first form of this command is used to list the config options for the
  mail system, or to view the setting of a specific option. It can be used
  by anyone.

  The second command is Wiz-only, and changes a config option.

& +MGROUP

  +MGROUP[/list] [<mailgroup>]
  +MGROUP/EX <mailgroup>
  +MGROUP/ADD[/noeval] <mailgroup>=<function>
  +MGROUP/REMOVE <mailgroup>

  These commands are a part of the +mail system, and are used for managing
  Mailgroups. (For info on what a Mailgroup is, see HELP MAILGROUPS.) The
  first two commands can be used by anybody. With no <mailgroup> given,
  +MGROUP shows a list of all mailgroups on the game. If a <mailgroup> is
  given, it will show who is in that mailgroup. If the /EX switch is given, it
  will instead show the function which determines who is in the group.

  The last two commands are admin-only. +MGROUP/ADD will add a new mailgroup
  called <mailgroup>, where <function> evaluates to a list of players to
  be mailed. %# is the player sending the mail, in this function.

  +MGROUP/REMOVE deletes a mailgroup.

  For examples of +MGROUP/ADD, see HELP +MGROUP2

& +MGROUP2

  +MGROUP/ADD/NOVEVAL myadmins=switch(1,haspower(%#,GUEST),BB:ADMINS),
                                 hasflag(%#,UNREGISTERED),BB:APPLICATIONS,
                                 #4 #5 #6)
  When a Guest player sends mail to 'myadmins', it will be sent to the Admins
  BB. Players set 'Unregistered' who mail 'myadmins' will actually mail the
  Applications BB. All other players will mail the players with the dbrefs
  #4, #5 and #6.

  ]+MGROUP/ADD builders=BB:BuildBB [lsearch(all,powers,builder)]
  When someone mails 'builders', the mail will go to the 'BuildBB' BB, and to
  any players on the game who have the Builder @power.

& MAILGROUPS

  Mailgroups in Talvo's +Mail System are very similar to the Mail Aliases
  (as per @malias) in PennMUSH's @mail system. They provide a convenient way
  to send mail to groups of people, particularly when those groups may change
  over time, or when the groups include bulletin boards.

  The Mailgroup is set to a ufun, which returns a list of players and BBs (it
  cannot contain other mailgroups). So, for instance, you can get() a list
  of dbrefs from another object, or lsearch() for all the players with a 
  certain flag or power.

  See also: MAIL, +mgroup


& &80
& &eighty
--------------------------------------------------------------------------------

& +MAIL/PURGE

  +MAIL/PURGE

  This admin-only command will run the +mail system's internal purging code.

  This does several things. First of all, it removes messages from bulletin
  boards which have expired (have been on the board for longer than that
  board's timeout).

  It then deletes all messages from the database which are no longer in use,
  and are old enough not to be considered important. A message is no longer
  in use when it is in no player's inbox, is not posted to any BB, and is
  not being used as a +forward for another message. How old a message must
  be to not be considered important is defined by the purge_time config
  option - see +MAIL/CONFIG PURGE_TIME for how long that is.

