bbs-scene.org onelinerz for Synchronet Bulletin Board Systems
echicken@bbs.electronicchicken.com
October 12, 2010

echttp.js v1.1
onelinerz.js v2.1
randomoneliner.js v1.0
wonelinerz.ssjs v1.6

What's New
----------

A "rumors" style mod to print out a random oneliner on the console (easily adapted for use
on your Synchronet BBS' website.)

INI based configuration.  Previous versions required editing of variables at the top of each
script, but as the number of mods I make for bbs-scene.org grows, I figured we'd all benefit
from a centralized configuration file.


What's Included
---------------

bbs-scene.ini		- Contains info about your bbs-scene.org account
echttp.js		- My library of HTTP functions
onelinerz.ans		- The onelinerz header graphic by phlash
onelinerz.js		- The main onelinerz script, for the console
randomoneliner.js	- A "rumors"-like mod to print out a single oneliner on the console
readme.txt		- You're reading it, foo!
wonelinerz.ssjs		- A semi-useful onelinerz script for the web

Installation
------------

- Back up your shit before you follow any of the installation & configuration steps
  described in this file and before you run any of these scripts.

- Copy bbs-scene.ini to your sbbs/ctrl/ directory.
- Edit bbs-scene.ini to your liking;
  Change "username" and "password" to match your account;
  Details on the rest of the keys in bbs-scene.ini come later in this file.

- Copy echttp.js, onelinerz.js, and randomoneliner.js to your sbbs/mods/ directory.
  Call onelinerz.js from within another javascript with 'bbs.exec("?onelinerz");' or
  from within a Baja module with 'exec "?onelinerz"'.  These same instructions apply
  to randomonelinerz.js.

- Copy onelinerz.ans to your sbbs/text/menu/ directory.

- Copy wonelinerz.ssjs to somewhere in your sbbs/web/root/ directory, or wherever your
  web document root is.
  Call wonelinerz.ssjs from within another ssjs with 'load("wonelinerz.ssjs");'

Upgrading
---------

- Back up your shit before you follow any of the installation & configuration steps
  described in this file and before you run any of these scripts.

- Copy bbs-scene.ini to your sbbs/ctrl/ directory.
- Edit bbs-scene.ini to your liking;
  Change "username" and "password" to match your account;
  Details on the rest of the keys in bbs-scene.ini come later in this file.

- Copy echttp.js, onelinerz.js, and randomoneliner.js to your sbbs/mods/ directory,
  overwriting any existing copies of these files.

- Copy wonelinerz.ssjs to wherever you put your copy of the previous version, if you're
  using it at all.  Overwrite the existing file if prompted.

Configuration
-------------

Your configuration is stored in sbbs/ctrl/bbs-scene.ini, and the keys therein are as follows:

[Account]		- This section contains settings related to your user account and
			  your connection to bbs-scene.org.

username		- Your bbs-scene.org username.  Typically the email address that you
			  supplied when signing up.

password		- Your bbs-scene.org password.

server			- The IP or FQDN of the server hosting the BBS Scene API.  You probably
			  don't need to edit this, but if somebody decides to host a fully
			  compatible service somewhere else, or if Netsurge has to move the site
			  to another domain someday, all you'll need to do is edit this setting
			  to reflect the change.

port			- The default is port 80.  It's even less likely that you'll ever need
			  to change this setting.

timeout			- How many seconds to wait for a response from the server. 2 is usually
			  plenty, but increasing this can sometimes be a useful troubleshooting
			  step.

apiPath			- The path to the API resources on the server. You'll likely never need
			  to change this unless Netsurge moves the API.

[onelinerz]		- This section contains settings related to the style and formatting of
			  the onelinerz.

BBSName			- The shortest possible form of your BBS' name (this needs to fit on a
			  line with each user alias and oneliner that get printed to the screen.)

displayFile		- This is the name of a file within your sbbs/text/menu/ directory that is
			  displayed as a header graphic when onelinerz.js is run.  Change this if
			  you've drawn your own graphic to replace the stock header by phlash.

limit			- This is how many oneliners the console (onelinerz.js) script will print.
			  With the default header graphic and layout, 14 oneliners make the best
			  use of available screen area in an 80x24 console.

webLimit		- This is how many oneliners the web (wonelinerz.ssjs) script will print.

oneLinerLength		- In the console script, the text input box and printed oneliners will be
			  limited to this length.  The default setting is 58.

aliasLength		- In the console script, user aliases will be truncated to this length
			  before being printed to the screen.  The default setting is 8.

BBSNameLength		- In the console script, BBS names will be truncated to this length before
			  being printed to the screen.  The default setting is 10.
			  Note: oneLinerLength + aliasLength + BBSNameLength + 4 should not exceed
			  the width of your console.

ansiColour		- The ansiColour settings specify an ANSI escape sequence to apply to each
			  portion of the oneliner (alias, bbsname, oneliner) that the console script
			  (onelinerz.js) prints out. Example: [1;37;40m is bright white text on a
			  black background.  For more info, go do some Googling.

ansiColourRandom	- Same as above, but for the randomonelinerz.js rumors script.

bannedUsers		- A comma-delimited list of names of users who are banned from posting
			  oneliners.  These can be real names or aliases.  spidy is only listed as
			  an example; feel free to take his name off of the list.