// The styling information for UGModules is formatted as a JSON array and the
// modules get their styling from two sources.  When the script first runs, it
// checks to see if the user has certain cookies with the styling information.
// If those cookies are not found, it looks for variables incoming through .js
// files.  The following variable can be altered to provide custom colors.

var UGMpreferences = {
	"colorStyles": [{"title":"Blue Lighted  Glass","pbUGMcol":"55BBFF","sbUGMcol":"CCCCCC","obUGMcol":"000055","lpUGMcol":"55BBFF","lsUGMcol":"FFFFFF","ltUGMcol":"000055","txUGMcol":"000000","dtUGMcol":"FFFFFF","mtUGMcol":"55BBFF","bgUGMcol":"FFFFFF","UGMcolSeq":"1"},
	{"title":"Red Lighted Glass","pbUGMcol":"FF0000","sbUGMcol":"990000","obUGMcol":"550000","lpUGMcol":"990000","lsUGMcol":"FFDCDC","ltUGMcol":"320109","txUGMcol":"320109","dtUGMcol":"FFDCDC","mtUGMcol":"FA362D","bgUGMcol":"FFEEDD","UGMcolSeq":"2"},
	{"title":"Gold Lighted Glass","pbUGMcol":"FFD700","sbUGMcol":"DAA520","obUGMcol":"320109","lpUGMcol":"B8860B","lsUGMcol":"FAE781","ltUGMcol":"520006","txUGMcol":"000000","dtUGMcol":"FFFFFF","mtUGMcol":"FFD700","bgUGMcol":"FFFFFF","UGMcolSeq":"3"},
	{"title":"Green Lighted Glass","pbUGMcol":"00FF00","sbUGMcol":"228B22","obUGMcol":"0A3C00","lpUGMcol":"00FF00","lsUGMcol":"FCE488","ltUGMcol":"055800","txUGMcol":"003300","dtUGMcol":"FFFFFF","mtUGMcol":"7FFF00","bgUGMcol":"FFFFFF","UGMcolSeq":"4"},
	{"title":"All of the Rainbow","pbUGMcol":"55BBFF","sbUGMcol":"0038FF","obUGMcol":"0000AA","lpUGMcol":"19FF15","lsUGMcol":"FF0069","ltUGMcol":"FFFFFF","txUGMcol":"000000","dtUGMcol":"FAEC54","mtUGMcol":"55BBFF","bgUGMcol":"FFFFFF","UGMcolSeq":""},
	{"title":"Fire and Ice","pbUGMcol":"FCB52F","sbUGMcol":"F40A20","obUGMcol":"880000","lpUGMcol":"1241FC","lsUGMcol":"B6E7FA","ltUGMcol":"FFFFFF","txUGMcol":"000000","dtUGMcol":"FFFFFF","mtUGMcol":"55BBFF","bgUGMcol":"FFFFFF","UGMcolSeq":""},
	{"title":"Green and Gold","pbUGMcol":"FFD700","sbUGMcol":"228B22","obUGMcol":"003400","lpUGMcol":"006400","lsUGMcol":"DAA520","ltUGMcol":"FFFFFF","txUGMcol":"000000","dtUGMcol":"FFFFFF","mtUGMcol":"FFD700","bgUGMcol":"FFFFFF","UGMcolSeq":""},
	{"title":"Blues at Midnight","pbUGMcol":"55BBFF","sbUGMcol":"CCCCCC","obUGMcol":"000055","lpUGMcol":"55BBFF","lsUGMcol":"FFFFFF","ltUGMcol":"000055","txUGMcol":"FFFFFF","dtUGMcol":"000000","mtUGMcol":"000000","bgUGMcol":"000000","UGMcolSeq":""},
	{"title":"Black & White Formal","pbUGMcol":"DCDCDC","sbUGMcol":"686868","obUGMcol":"000000","lpUGMcol":"000000","lsUGMcol":"E6E6E6","ltUGMcol":"FFFFFF","txUGMcol":"000000","dtUGMcol":"FFFFFF","mtUGMcol":"CCCCCC","bgUGMcol":"FFFFFF","UGMcolSeq":""}
	]};


// The following variables allow developer to specify certain initial operating 
// parameters, such as the maximum number of frames per second to perform color
// changes when multi-color controller is turned on.  Some of these variables
// can be changed by the user, at which time their new setting is stored in a
// cookie and then reused whenever they return to the site.

var multiColorFps=20; // max frames per second on color changes (best at 10-20)
var multiColorMinS=1; // minimum seconds to cycle through all selected colors
var multiColorMaxS=300; // maximum seconds to cycle through all selected colors


// Following array gets stored as cookie to retain users choices, but developer
// can determine initial settings.  "colorStyle" is index number of initial
// color style from "UGMpreferences" array above, and "0" indicates the first
// colorstyle, which is "Blue Lighted Glass" by default. "tintAutoAdj" values
// can be 1 or 'on' to enable "Auto Adjust" on the tinting, or 0 or 'off' to
// set tinting to "Fixed".  "multicolor" set to 1=on, 0=off.  "multicolorspeed"
// defines initial multi-color change speed, where it can be any number between
// 0 and 35 with highest numbers producing fastest changes.  The actual change
// speed is also dependent on values set above for "MinS" and "MaxS" values,
// so each step here is 1/36 of the range set by those variables.

var UGModMulCol=new Array({"colorStyle":0, "modTint":100, "tintAutoAdj":1, "multicolor":1, "multicolorspeed":33}); //important! for col chg speed


// Because the UGModules are designed to drag over each other, the script is
// automatically bringing the most recently selected module to the front.  This
// is performed by incrementing the 'z-index" value of each module when it is
// clicked anywhere within it.  By default, the initial z-index range begins
// begins at 10001 as indicated below.  Developers can increase or decrease this
// starting range as needed for compatibility with other objects on their page.
// This index value is not stored and begins anew when a new session is started.

var UGMcurIndex=10001 // The starting point for z-index on modules


var cookieSaveDays=30 // This variable is a mystery unless you can figure it out


var UGModMulCol=new Array({"colorStyle":0, "modTint":100, "tintAutoAdj":1, "multicolor":0, "multicolorspeed":33}); //important! for col chg speed

