Eklablog Tous les blogs Top blogs Mode, Art & Design Tous les blogs Mode, Art & Design
Editer l'article Suivre ce blog Administration + Créer mon blog
MENU

Venez visiter ma malle aux trésors ..Vous y trouverez pleins de surprises...

Publicité

Père Noël du net

<script language=JavaScript1.2> //3D Starfield - by Mikhail Ansolis, based on Flying planes - by John Ely //Modified from: Autumn leaves script- by Kurt Grigg (kurt.grigg@virgin.net) //Visit http://www.dynamicdrive.com for this script //Pre-load your image below! //CHANGE 2 to the number of images listed below grphcs=new Array(3) //PRELOAD the involved images (extend or contract variables according to # of images used) Image0=new Image(); Image0.src=grphcs[0]=" http://img65.imageshack.us/img65/1286/etoile1kv8.gif" Image1=new Image(); Image1.src=grphcs[1]=" http://img179.imageshack.us/img179/5199/etoile2wm7.gif" Image2=new Image(); Image2.src=grphcs[2]=" http://img163.imageshack.us/img163/6697/etoile5zu3.gif " Image3=new Image(); Image3.src=grphcs[3]=" http://img179.imageshack.us/img179/8894/etoile3xk1.gif" Image4=new Image(); Image4.src=grphcs[4]=" http://img129.imageshack.us/img129/7026/etoile4cq6.gif" //SPECIFY number of images to randomly display concurrently from list above. Less the more efficient Amount=20; Ypos=new Array(); Xpos=new Array(); Zpos=new Array(); //SpeedX=new Array(); //SpeedY=new Array(); ScrXpos=new Array(); ScrYpos=new Array(); Speed=new Array(); Size=new Array(); Step=new Array(); ns=(document.layers)?1:0; ie=document.all&&navigator.userAgent.indexOf("Opera")==-1 if (ns){ for (i = 0; i < Amount; i++){ var P=Math.floor(Math.random()*grphcs.length); rndPic=grphcs[P]; document.write("<layer NAME='sn"+i+"' LEFT=0 TOP=0></layer>"); } //end for } //end if else if (ie){ //IE document.write('
'); for (i = 0; i < Amount; i++){ document.write(''); } document.write('
'); } //initialize star properties if (ie||ns){ WinHeight=(ns)?window.innerHeight-20:window.document.body.clientHeight; WinWidth=(ns)?window.innerWidth-70:window.document.body.clientWidth; for (i=0; i < Amount; i++){ Speed[i]=(i+1)*6/Amount+4; //speed range from 4 to 10 Xpos[i] = (Math.random()*WinWidth-WinWidth/2)*(Amount-i/3)/Amount; Ypos[i] = (Math.random()*WinHeight-WinHeight/2)*(Amount-i/3)/Amount; Zpos[i] = Math.random()*900*(Amount-i/3)/Amount+100; } } function fly(){ var WinHeight=(ns)?window.innerHeight-20:window.document.body.clientHeight; var WinWidth=(ns)?window.innerWidth-70:window.document.body.clientWidth; var hscrll=(ns)?window.pageYOffset:document.body.scrollTop; for (i=0; i < Amount; i++){ Zpos[i]-=Speed[i]; if (ScrXpos[i]>WinWidth || ScrXpos[i]<0 || ScrYpos[i]>WinHeight || ScrYpos[i]<0 || Zpos[i]<=0) { //generate new stars Speed[i]=(i+1)*6/Amount+4; //speed range from 4 to 10 Xpos[i] = (Math.random()*WinWidth-WinWidth/2)*(Amount-i/3)/Amount; Ypos[i] = (Math.random()*WinHeight-WinHeight/2)*(Amount-i/3)/Amount; Zpos[i] = Math.random()*900*(Amount-i/3)/Amount+100; } ScrXpos[i]=Xpos[i]/Zpos[i]*100 + WinWidth/2; ScrYpos[i]=Ypos[i]/Zpos[i]*100 + WinHeight/2; if (ns){ document.layers['sn'+i].left=ScrXpos[i]; document.layers['sn'+i].top=ScrYpos[i]+hscrll; } else{ //IE eval("document.all.si"+i).style.left=ScrXpos[i]; eval("document.all.si"+i).style.top=ScrYpos[i]+hscrll; } } //end for setTimeout('fly()',20); } //end fly if (ie||ns) window.onload=fly //--> </script> <script language=JAVASCRIPT> </script>

 

Que serais Noêl sans père Noêl ......

Publicité
Retour à l'accueil
Partager cet article
Repost0
Pour être informé des derniers articles, inscrivez vous :
Commenter cet article