var g = new Array(12);

g[0]="games/jammer/jammer";
g[1]="games/million/million";
g[2]="games/ogre/ogre";
g[3]="games/cell/cell";
g[4]="games/fif/fif";
g[5]="games/tgp/tpg";
g[6]="games/bh/bh";
g[7]="games/ba/ba";
g[8]="games/a61/a61";
g[9]="games/drun/drun";
g[10]="games/rally/rally";
g[11]="games/agm/agm";

var n = new Array(12);
n[0]="Planet Jammer";
n[1]="Million Dollar Island";
n[2]="O.G.R.E.";
n[3]="Cell Division";
n[4]="Forged in Fire";
n[5]="Target Practice";
n[6]="Dan's Dead Bug";
n[7]="Little Man - Big Axe";
n[8]="Area 61";
n[9]="Diamond Runner";
n[10]="Rally Race";
n[11]="Against the Machines";

var down=new Array(12);
down[0] = '<div align="center"><p><a href="http://www.mediafire.com/?swqjsc2mc1s">Download Planet Jammer via MediaFire</a></p></div><div align="center"><p><a href="http://files.filefront.com/PJSetupexe/;9826958;/fileinfo.html" title="PJSetup.exe">Download Planet Jammer via File Front</a></p></div>';
down[1] = '<div align="center"><p><a href="http://www.mediafire.com/?tmn4jgqnizt">Download Million Dollar Island via MediaFire</p></div><div align="center"><p><a href="http://files.filefront.com/MISetupexe/;9826847;/fileinfo.html" title="MISetup.exe">Download Million Dollar Island via File Front</a></p></div>';
down[2] = '<div align="center"><p><a href="http://www.mediafire.com/?2nz1tm3dnzp">Download O.G.R.E via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Offensive+Ground+Roving+Exoskeleton/;9827010;/fileinfo.html" title="Offensive Ground Roving Exoskeleton">Download O.G.R.E via File Front</a></p></div>';
down[3] = '<div align="center"><p><a href="http://www.mediafire.com/?d1zmlmndsod">Download Cell Division via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Cell+Division/;10016678;/fileinfo.html" title="Cell Division">Download Cell Division via File Front</a></p></div>';
down[4] = '<div align="center"><p><a href="http://www.mediafire.com/?9zx2bwjgmst">Download Forged In Fire via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Forged+In+Fire/;10079330;/fileinfo.html" title="Forged In Fire">Download Forged In Fire via File Front</a></p></div>';
down[5] = '<div align="center"><p><a href="http://www.mediafire.com/?mxwmbjgzj1f">Download Target Practice via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Target+Practice/;10111990;/fileinfo.html" title="Target Practice">Download Target Practice Via File Front</a></p></div>';
down[6] = '<div align="center"><p><a href="http://www.mediafire.com/?kumnev9mgiu">Download Dans Dead Bug via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Dans+Dead+Bug/;10216302;/fileinfo.html" title="Dan`s Dead Bug">Download Dan`s Dead Bug via FileFront</a></p></div>';
down[7] = '<div align="center"><p><a href="http://www.mediafire.com/?gzvyjct2cjj">Download Little Man - Big Axe via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Little+Man+Big+Axe/;10529208;/fileinfo.html" title="Little Man - Big Axe">Download Little Man - Big Axe Free via FileFront</a></p></div>';
down[8] = '<div align="center"><p><a href="http://www.mediafire.com/?xz4z30cj4zz">Download Area 61 via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Area+61/;10852786;/fileinfo.html" title="Area 61">Area 61 via File Front</a></p></div>';
down[9] = '<div align="center"><p><a href="http://www.mediafire.com/?iymydzxmeit">Download Diamond Runner via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Diamond+Runner/;11053753;/fileinfo.html" title="Diamond Runner">Download Diamond Runner via File Front</a></p></div>';
down[10] = '<div align="center"><p><a href="http://www.mediafire.com/?0jzch8ctodp">Download Rally Racer via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Rally+Race/;11418106;/fileinfo.html" title="Rally Race">Download Rally Race From File Front</a></p></div>';
down[11] = '<div align="center"><p><a href="http://www.mediafire.com/?rkzsd225brc">Download Against the Machines via MediaFire</p></div><div align="center"><a href="http://files.filefront.com/Against+The+Machines/;11616161;/fileinfo.html" title="Download Against The Machines via File Front">Download Against The Machines via File Front</a></p></div>';

var cheat=new Array(12);
cheat[0]='<p class="tl">Game Cheats</p> <p>Go to the Load Level Menu and type GDMODE. This will give the player unlimited health and ammo.</p><p class="tl">Level Passwords:</p><p> Level 2 = XEWRTY. Level 3 = ARFVIL. Level 4 = PNSDRT. </p>';
cheat[1]='<p class="tl">Game Cheats</p> <p>Hold Space for 5 seconds while looking at the map to show your position.</p>';
cheat[2]='<p class="tl">Game Cheats</p> <p>Go to the Difficulty Select Menu and press 0. This will give the player unlimited health.</p>';
cheat[3]='<p class="tl">Game Cheats</p> <p>No Cheats!</p>';
cheat[4]='<p class="tl">Game Cheats</p> <p>No Cheats!</p>';
cheat[5]='<p class="tl">Game Cheats</p> <p>No Cheats!</p>';
cheat[6]='<p class="tl">Game Cheats</p> <p>Unlimited ammo always.</p>';
cheat[7]='<p class="tl">Game Cheats</p> <p>At the main menu type health. This will give the player unlimited health.</p>';
cheat[8]='<p class="tl">Game Cheats</p> <p>No Cheats!</p>';
cheat[9]='<p class="tl">Game Cheats</p> <p>No Cheats!</p>';
cheat[10]='<p class="tl">Game Cheats</p> <p>No Cheats!</p>';
cheat[11]='<p class="tl">Game Cheats</p> <p>Hold SPACE for 5 seconds to restore health.</p>';

var howplay=new Array(12);
howplay[0]='<p class="tl">How To Play</p><p>The objective for each level is to plant seven explosive charges at strategic points in the level. These points are marked by purple circles on the map. Press 4 on the keyboard or joystick to plant the charge. When the first charge is planted it will begin a 10 minute countdown. Plant all the charges and get back to the ship before that time. In the top right corner is a compass. The green dot represents the ship and the red dot is the center of your target area. The red and blue lines at the top center of the screen are the player health and armor. Returning to the ship replenishes ammo and armor.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Fire. Right Mouse Button = Change Weapon. X = Zoom In. Z = Zoom Out. ESC = Menu.</p>';
howplay[1]='<p class="tl">How To Play</p><p>The objective is to locate the Robot Chopper, the keys for it, the fuel and the one million dollars, before the hour is up. All the while avoiding the giant spiders. Collect the items and then make it to the Chopper.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Fire. Right Mouse Button = Change Weapon. ESC = Menu. SPACE = Show Map.</p>';
howplay[2]='<p class="tl">How To Play</p><p>The objective for each level is outlined at the beginning of each level. The center HUD display can be changed to show the level map, a scope, a compass or ammo remaining.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Fire. Right Mouse Button = Change HUD. M = Music Off. ESC = Menu. 1 - 4 = Select Weapon.</p>';
howplay[3]='<p class="tl">How To Play</p><p>The objective for each level is to locate and terminate the specified number of mutants before the time runs out. After the mutants, you must hack the transport panel to finish the level.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Fire. M = Music Off. ESC = Menu.</p>';
howplay[4]='<p class="tl">How To Play</p><p>Locate the eight fires of Rakka, while fighting off skeleton warriors.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Attack. ESC = Menu.</p>';
howplay[5]='<p class="tl">How To Play</p><p>Target practice is a simple game that challenges you to beat your time and increase your accuracy.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Attack. ESC = Menu.</p>';
howplay[6]='<p class="tl">How To Play</p><p>Use the Geo Sensor to track down and terminate the giant aliens protecting the area.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Attack. ESC = Menu.</p>';
howplay[7]='<p class="tl">How To Play</p><p>Free each village from the Golem and collect the items needed to destroy the final wizard.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Attack. ESC = Menu.</p>';
howplay[8]='<p class="tl">How To Play</p><p>Hunt down 30 aliens and disable the flying saucer.</p><p>W = Move Forward. A = Strafe Left. S = Move Back. D = Strafe Right. Left Mouse Button = Attack. ESC = Menu.</p>';
howplay[9]='<p class="tl">How To Play</p><p>Get to the diamonds and deliver them before the time runs out.</p><p>W = Move Forward. A = Tuen Left. S = Brake/Reverse. D = Turn Right. ESC = Menu.</p>';
howplay[10]='<p class="tl">How To Play</p><p>Make the Check Points before the time runs out.</p><p>W = Move Forward. A = Turn Left. S = Brake/Reverse. D = Turn Right. ESC = Menu.</p>'
howplay[11]='<p class="tl">How To Play</p><p>Fight machines and sewer monsters to make it to the time portal.</p><p>W = Move Forward. A = Strafe Left S = Back D = Strafe Right. ESC = Menu.</p>'

function randomPic()
{
	var game = Math.floor(Math.random()*11.9);
	var pic = Math.floor(Math.random()*4.9)+1;
	document.write('<img src = "' + g[game] + pic + 'small.jpg" width="120">');
}

function showpictures(p)
{
	
	var num = p.split("=");
	var v=num[1];
	v=v-1;
	var pic1 = '<a href="gamepic.html?pic=' + g[v] + '1large" target="_BLANK"><img src="' + g[v] + '1small.jpg" width="200" border="0"></a>';
	var pic2 = '<a href="gamepic.html?pic=' + g[v] + '2large" target="_BLANK"><img src="' + g[v] + '2small.jpg" width="200" border="0"></a><br>';
	var pic3 = '<a href="gamepic.html?pic=' + g[v] + '3large" target="_BLANK"><img src="' + g[v] + '3small.jpg" width="200" border="0"></a>';
	var pic4 = '<a href="gamepic.html?pic=' + g[v] + '4large" target="_BLANK"><img src="' + g[v] + '4small.jpg" width="200" border="0"></a><br>';
	var pic5 = '<a href="gamepic.html?pic=' + g[v] + '5large" target="_BLANK"><img src="' + g[v] + '5small.jpg" width="200" border="0"></a>';
	var pic6 = '<a href="gamepic.html?pic=' + g[v] + '6large" target="_BLANK"><img src="' + g[v] + '6small.jpg" width="200" border="0"></a><br>';
	
	document.write('<h2>' + n[v] + '</h2>');
	document.write('<hr>');
	document.write(pic1);
	document.write(pic2);
	document.write(pic3);
	document.write(pic4);
	document.write(pic5);
	document.write(pic6);
	document.write('<hr>');
	document.write(down[v]);
	document.write('<hr>');
	document.write('<div align="center">');
	document.write(howplay[v]);
	document.write('</div>');
	
}

function showcheats(p)
{
	var num = p.split("=");
	var v=num[1];
	v=v-1;
	document.write(cheat[v]);	
	
}

function drawpic(p)
{
	var num = p.split("=");
	var v=num[1];
	var pic1 = '<img src="' + v + '.jpg">';
	document.write(pic1);
}