var object=new Array();
object['home_link']      = new objectdata(500,500,"/site_images/menu_frame_home_lit.jpg","/site_images/menu_frame_home.jpg","home");
object['galleries_link'] = new objectdata(500,500,"/site_images/menu_frame_galleries_lit.jpg","/site_images/menu_frame_galleries.jpg","galleries");
object['extras_link']    = new objectdata(500,500,"/site_images/menu_frame_extras_lit.jpg","/site_images/menu_frame_extras.jpg","extras");
object['bio_link']       = new objectdata(500,500,"/site_images/menu_frame_bio_lit.jpg","/site_images/menu_frame_bio.jpg","bio");
object['contact_link']   = new objectdata(500,500,"/site_images/menu_frame_contact_lit.jpg","/site_images/menu_frame_contact.jpg","content");
object['links_link']     = new objectdata(500,500,"/site_images/menu_frame_links_lit.jpg","/site_images/menu_frame_links.jpg","links");


function go_to_gallery(prefix) {
  var address = '/html/' + prefix + '_gallery_page_1.html';
  window.location = address;
  return;
}


function go_to_gallery_page(gal,page,scriptpath) {
  window.location=scriptpath + 'open_gallery.php?galleryname=' + gal + '&pageselection=' + page;
  return;
 }


//============================
//
// Go to home page
//
function jump_to_home() {
  parent.location = '/';
  return;
}


function objectdata(hsize,vsize,replaceimg,restoreimg,mess) {
  this.mess=mess;
  this.simg=new Image(hsize,vsize);
  this.simg.src=replaceimg;
  this.rimg=new Image(hsize,vsize);
  this.rimg.src=restoreimg; 											 
}

function ReplaceOrig(name) {
  window.status=object[name].mess;
  document[name].src=object[name].simg.src;
} 

function RestoreOrig(name) {
  window.status="";
  document[name].src=object[name].rimg.src;
} 

//===========================================
//
// Open Pop-Up Window and display image
//


function open_image(name, width, height) {
	
  var isIE = navigator.appName.indexOf("Microsoft") != -1;
  if(isIE) { width = width + 25; height = height + 25; }
  height = height + 50;
   Shadowbox.open({
        content:    "/scripts/gallery_popup.php?name=" + name,
        player:     "iframe",
        title:      "",
        height:     height,
        width:     	width
    }); 
   
}




//=======================
//
// Play A Sound File
//
function play_sound_file(file) {
  window.location = file;
}


//=======================
//
// Play Achiania Sound File
//

function play_achania() {  
  var awindow = window.open("","achania_pronounciation_window",
                            "toolbar=no,height=50,width=200,screenX=100,screenY=50,alwaysRaised=yes,location=no,directories=no,status=no,scrollbars=yes,resizable=yes, menubar=no");
  var html_code = "<html><head><script src='/scripts/scripts.js'></script></head><body onload='javascript:play_sound_file(\"/site_images/achania.mp3\")'></body></html>";
  awindow.document.open();
  awindow.document.write(html_code);
  awindow.document.close();
}

//=======================
//
// Achania Description Pop-Up
//
function what_is_achania() {
  var achania_window = window.open("","acha_win",
                                   "toolbar=no,height=575,width=500,screenX=100,screenY=100,alwaysRaised=yes,location=no,directories=no,status=no,scrollbars=yes,resizable=yes, menubar=no");
  achania_window.document.open();
  
  var html_code =  "<html>\n" +
    "  <head>\n" +
    "    <title>What is Achania?</title>\n" +	
    "    <LINK REL='stylesheet' TYPE='text/css' HREF='/css/styles.css'>\n" +
    "    <script src='/scripts/scripts.js'></script>\n" +
    "  </head>\n" +
    "  <body bgcolor='#000000'>\n" +
    "    <p align=right>\n" +
    "      <a href='javascript:window.close()'><FONT color='#00FF00'>Close</FONT></a>\n" +
    "    </p>\n" +
    //   "    <FONT size=-1 color='#FFFFFF' align=justify>\n" +
    "    <table cellpadding=0 cellborder=0 width=100%>\n" +
    "      <tr>\n" +
    "        <td class='text_entry'>\n" +
    "<a href='javascript:play_achania();'>Achania (Ah-cha'-nee-ah)</a> is an unpublished home-brew setting based on Joy's massive amount of writing\n" +
    "and years of role-play.\n" +
    "One way to think of Achania is that it is almost a sister-world to Krynn of the Dragonlance setting.\n" +
    "After the end of the Chaos War on Krynn, the Gods were without a world. Did they sit on their\n" +
    "backsides and mope? Did they only try looking for Krynn? Or did they go to other places?<br>\n" +
    "<br>\n" +
    "Included in the setting of Achania is the thought maybe the three moons tried to rebuild their\n" +
    "Orders of magic on a different world, away from the other Krynnish gods. Also included is the concept\n" +
    "that maybe they tried to do things differently. Instead of a single Wizards' Conclave of 21, \n" +
    "what if they had a Mages' Council of nine per each of the four Towers they discovered on this\n" +
    "world. (And there is a reason why 'Towers' is capitalized.)<br>\n" +
    "<br>\n" +
    "In the end, things didn't turn out too well. In fact saying it went <i>badly</i> would had been the understatement\n" +
    "of the century. It also gave a much harsher meaning to Lunitari's words to Dalamar in 'Dragons\n" +
    "of a Vanished Moon' on the subject of losing everything.<br>\n" +
    "<br>\n" +
    "\"Perhaps, we understand better than you think.\"<br>\n" +
    "<br>\n" +
    "If a lot of the setting of Dragonlance is about how lost and ancient mysteries can be rediscovered and brought anew,\n" +
    "then Achania is about how most old and ancient secrets are best left buried and forgotten.\n" +
    "<hr>\n" +
    "'Dragons of a Vanished Moon' by Margaret Weis and Tracy Hickman and 'Dragonlance'\n" +
    "are copyright by Wizards of the Coast.<br>\n" +
    "<br>\n" +
    "'Achania' is an unofficial fan setting using some of the 'Dragonlance' elements. Its existence is not recognized in\n" +
    "ANY official capacity.\n" +
	"<br />\n" +
	"<hr>\n" +
	"<br />\n" +
	"Update: We are currently working at removing the Dragonlance-specific elements from our Achania notes\n" +
	"and are designing Achania to be a stand-alone setting. Hopefully in the end there may be a few elements\n" +
	"<i>inspired</i> by the setting but nothing infringing on copyright or ownership. Progress may be noted\n" +
	"in the future.\n" +
	"           </td>\n" +
	"        </tr>\n" +
    "     </table>\n" +
    //    "    </FONT>\n" +
    "  </body>\n" +
    "</html>\n";
  
  achania_window.document.write(html_code);
  
  achania_window.document.close();
}
