function goHistorique(delta)
{  history.go(delta);}

function leretour()
{document.write('<a href="javascript:goHistorique(-1)">');
document.write('Retour');
document.write('</a><br><br>');}

function revien()
{window.top.location.href = "z.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;}

function retouretat()
{document.write('<a href="javascript:revien()">');
document.write('Retour');
document.write('</a><br><br>');}

function isayno()
{alert("Internet Eplorer is  not currently my default browser. It will never be.
 For if it was really a good browser they would not ask each time.");}

function lanouv()
{url = "lesnouvelx.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;
	window.top.location.href =  url;}
		
function home()
{if(langue==6){lhome = "index_fr.htm"; }  
	if(langue==5){lhome = "index_es.htm"; }
	if(langue==4){lhome = "index_en.htm"; }   
	if(langue==3){lhome = "index_de.htm"; }   
	if(langue==1){lhome = "index_br.htm"; }   
	window.top.location.href =  lhome;}

function homez()
{lhome = "lesnouvelx.htm?" + 9 + langue + story + etat + jeux + num + perso;
	window.top.location.href = lhome;}
	
function visages()  
{var url = "listepersos.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;
	window.top.location.href =  url;}

function clafin()  
{var url = "sup.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;
	window.top.location.href =  url;}
	
function designer()
{var url = "designe.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;
	window.top.location.href =  url;}

function etatlieux()
{var url = "constat.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;
	window.top.location.href =  url;}
	
function alumcourant(nb)
{ for (i = 2; i < 10; i++) 	
     rempdifimage(i);
	supimage(nb);}

function Nbaleat(valeur1,valeur2)
{ if (valeur2-valeur1 < 0) return 0;
	chiffre = Math.random();
	chiffre = (chiffre * (valeur2 - valeur1)) + valeur1;
	chiffre = Math.round(chiffre);
	return chiffre;}

var secret = Nbaleat(1,8);

function supid(i)
   {  if (i>2) document.images[i-1].src = "image/" + story +  "/" + perso + "92.gif";  }
	
function supall(i)
    {  if (i>2) document.images[i-1].src = "image/" + story +  "/" + perso + "9" + i + ".gif";  }

function supimage(nombre)
{
if (nombre==2) document.jeu.image2.src="image/" + story +  "/" + perso + "92.gif";
else if (perso==13)	supall(nombre);// substituer images différentes
else if (perso==9)	supall(nombre);
else if (perso==7)	supall(nombre);
else if (perso==4)	supall(nombre);
else if (perso==0)	supall(nombre);
else supid(nombre);}

function rempimage(i)
{  if (i>2) document.images[i-1].src = "image/" + story +  "/" + perso  + "2.gif";  }

function rempdifimage(i)
{  if (i>2) document.images[i-1].src = "image/" + story +  "/" + perso  + i + ".gif";  }


function sesjeux()
{window.top.location.href = "u.htm?u" + lenoeud + langue + story + etat + jeux + num + perso;}
	
function noeud()
{window.top.location.href = "lirelestitresx.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;}	

function noeudb()
{window.top.location.href = "partnovelx.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;}	

function Lireletout()
{window.top.location.href = "alanovelx.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;}

function pagex()
{window.top.location.href = "x.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;}

function pagez()
{window.top.location.href = "lesnouvelx.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;}

function pagey()
{window.top.location.href = "y.htm?"+ fich + lenoeud + langue + story + "9999999999999999" + num + perso;}

function pagezy()
{window.top.location.href = "lirelestitresy.htm?"+ fich + lenoeud + langue + story + etat + jeux + num + perso;}

function aide() 
{lenoeud=0;
	perso=99;
	var url = "alapagex.htm?" + 0 + langue + story + "1111111111111111" + "199";
	affichetoi(url);} 
