<!--
// The Central Randomizer 1.3 (C) 1997 by Paul Houle (houle@msc.cornell.edu)
// See:  http://www.msc.cornell.edu/~houle/javascript/randomizer.html

rnd.today=new Date();
rnd.seed=rnd.today.getTime();

function rnd() {
        rnd.seed = (rnd.seed*9301+49297) % 233280;
        return rnd.seed/(233280.0);
};

function rand(number) {
        return Math.ceil(rnd()*number);
};

// end central randomizer. -->

// function to resize docs window
function on_load()
{
	if (top != self) top.document.title = document.title;

  if (top.name != 'woc_doc')
  {
    new_win = window.open(top.location.href,'woc_doc','menubar=0,location=0,toolbar=0,personalbar=0,status=0,scrollbars=1,titlebar=no,width=484,height=600,screenX=0,screenY=0');
    if (!new_win)
    {
      window.resizeTo(484,600);
    }
    else
    {
      window.location.href = '../closepage.htm';
      new_win.focus();
    }
  }
  else
	{
		window.focus();

		// If the document window is in the top frame, nest it within the frameset instead.
		if (top == self)
		{
			top.location.href = "../woc_frameset.htm?" + top.location.href;
		}
		else
		{
			// Have the banner ad refresh
			top.woc_banner.location.href = "http://warofconquest.com/woc_banner.htm";
		}
	}
}

function on_resize()
{
  window.resizeTo(484,600)
}

function launch_doc(_url)
{
  new_win = window.open(_url,'woc_doc','menubar=0,location=0,toolbar=0,personalbar=0,status=0,scrollbars=1,titlebar=no,width=484,height=600,screenX=0,screenY=0');
  new_win.focus();
}

function launch_browser(_url)
{
  new_win = window.open(_url,'woc_win');
  new_win.focus();
}

function produce_ad()
{
	switch (rand(4))
	{
		case 1:
			document.write("<SCRIPT LANGUAGE=\"javascript\" src=\"http://www.qksz.net/1e-632y\"> </\SCRIPT>");
			break;
		case 2:
			document.write("<SCRIPT LANGUAGE=\"javascript\" src=\"http://www.qksz.net/1e-6330\"> </\SCRIPT>");
			break;
		case 3:
			document.write("<SCRIPT LANGUAGE=\"javascript\" src=\"http://www.qksz.net/1e-6332\"> </\SCRIPT>");
			break;
		case 4:
			document.write("<SCRIPT LANGUAGE=\"javascript\" src=\"http://www.qksz.net/1e-63a8\"> </\SCRIPT>");
			break;
		default:
			document.write("<!-- VC active -->\n" +
				"<SCRIPT LANGUAGE=\"JavaScript\">\n" +
				"<!--\n" +
				"// ValueParameters\n" +
				"ValueHost = \"hs0259038\";\n" +
				"ValueLoaded = false;\n" +
				"ValueID = \"valueid\";\n" +
				"ValueVersion = \"1.1\";\n" +
				"ValueWidth = 468;\n" +
				"ValueHeight = 60;\n" +
				"//-->\n" +
				"</SCRIPT>\n" +
				"<SCRIPT LANGUAGE=\"Javascript\" SRC=\"http://oz.valueclick.com/jsmaster\"></SCRIPT>\n" +
				"<SCRIPT LANGUAGE=\"JavaScript\">\n" +
				"<!--\n" +
				"if (ValueLoaded) ValueShowAd();\n" +
				"//-->\n" +
				"</SCRIPT>\n" +
				"<NOSCRIPT>\n" +
				"</NOSCRIPT>\n" +
				"<!-- vc active -->\n");
			break;
	}
}
