Advertisement
AbdulMuttaqin

Rain Text JS

Jul 19th, 2018
374
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <html>
  2.  
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=windows-1256">
  5. <meta http-equiv="Content-Language" content="en-us">
  6. <meta name="GENERATOR" content="Microsoft FrontPage 5.0">
  7. <meta name="ProgId" content="FrontPage.Editor.Document">
  8. <title></title>
  9. </head>
  10.  
  11. <body>
  12.  
  13. <p>
  14. <script language="JavaScript1.2">
  15.  
  16.  
  17. //specify path to cursor image
  18. var cursorpath="http://www.javascriptfreecode.com/images/fly2.gif"
  19.  
  20. if (document.layers)
  21. {document.write("<LAYER NAME='PoInTeRs' LEFT=800 TOP=10><img src='"+cursorpath+"' width=17 height=22></LAYER>")}
  22. else if (document.all){document.write("<div id='pOiNtErS' style='position:absolute;top:10px;left:10px;width:17px;height:22px;z-index:50'><img src='"+cursorpath+"' width=40 height=40></div>")}
  23.  
  24. count=-1;                                                    
  25. move=1;
  26.  
  27. function Curve(){
  28. abc=new Array(0,1,1,1,2,3,4,0,6,-1,-1,-1,-2,-3,-4,0,-6)
  29. for (i=0; i < abc.length; i++)
  30. {var C=Math.round(Math.random()*[i])}
  31. howbend=abc[C];
  32. setTimeout('Curve()',1900);
  33. return howbend;
  34. }
  35. ypos=100;
  36. xpos=100;
  37.  
  38. degree = 600;
  39. function MoveRandom(){
  40. PathBend=degree+=howbend;//ok!
  41. y = 4*Math.sin(PathBend*Math.PI/180);
  42. x = 6*Math.cos(PathBend*Math.PI/180);
  43. if (document.layers){
  44. ypos+=y;
  45. xpos+=x;
  46. document.PoInTeRs.top=ypos+window.pageYOffset;
  47. document.PoInTeRs.left=xpos+window.pageXOffset;
  48. }
  49. else if (document.all){
  50. ypos+=y;
  51. xpos+=x;
  52. document.all.pOiNtErS.style.top=ypos+docu
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement