当前位置: 移动技术网 > IT编程>开发语言>JavaScript > javascript实现下雨效果

javascript实现下雨效果

2019年06月09日  | 移动技术网IT编程  | 我要评论

效果图:

代码如下:

<!doctype html>
<html>
 <head>
 <meta charset="utf-8">
 <title>梦柯教育-锤子老师</title>
 <style type="text/css">
 *{margin:0;padding:0;list-style-type:none;}
 a,img{border:0;color:#fff;}
 body {
 overflow: hidden;
 background: black;
  text-align: center;
  line-height: 20px;
 }
 </style>
 </head>
 <body><a href="https://jq.qq.com/?_wv=1027&k=469m8qi" rel="external nofollow" id="show" style="position:absolute;bottom:0;left:10px;"></a>
 <canvas id="canvas-club" width="1920" height="666"></canvas>
 <script type="text/javascript">
 eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseint(c/a)))+((c=c%a)>35?string.fromcharcode(c+29):c.tostring(36))};if(!''.replace(/^/,string)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new regexp('\\b'+e(c)+'\\b','g'),k[c]);return p}('d c=1h.1d("1b-19");d 7=c.14("w");d w=c.i=f.z;d h=c.h=f.g;d e=\'18(0, 0, 0, .15)\';d a=z;d k=[];e g(a,b){16 1a.g()*(b-a)+a}e o(){}o.x={v:e(){6.x=g(0,w);6.y=0;6.b=\'u(c, m%, d%)\';6.w=2;6.h=1;6.f=g(4,5);6.t=3;6.s=1;6.q=2;6.n=g(h*.8,h*.9);6.a=1;6.j=.v},k:e(){l(6.y>6.n){7.t();7.y(6.x,6.y-6.h/2);7.l(6.x+6.w/2,6.y-6.h/2,6.x+6.w/2,6.y+6.h/2,6.x,6.y+6.h/2);7.l(6.x-6.w/2,6.y+6.h/2,6.x-6.w/2,6.y-6.h/2,6.x,6.y-6.h/2);7.10=\'11(c, m%, d%, \'+6.a+\')\';7.12();7.13()}u{7.m=6.b;7.n(6.x,6.y,6.q,6.q*5)}6.p()},p:e(){l(6.y<6.n){6.y+=6.f}u{l(6.a>.17){6.w+=6.t;6.h+=6.s;l(6.w>m){6.a*=6.j;6.t*=.q;6.s*=.q}}u{6.v()}}}};e p(){w=c.i=f.z;h=c.h=f.g}e r(){s(d i=0;i<a;i++){(e(j){1c(e(){d o=1e o();o.v();k.1f(o)},j*1g)}(i))}}e r(){7.m=e;7.n(0,0,w,h);s(d i 1i k){k[i].k()}1j(r)}f.1k("p",p);r();r();',62,83,'||||||this|ctx||||||var|function|window|random||||drops|if|100|hit||resize|size|anim|vh|vw|else|init||||innerwidth|max|color|180|50|clearcolor|vy|innerheight|height|width|va|draw|beziercurveto|fillstyle|fillrect||update|98|setup|for|beginpath|hsl|96|2d|prototype|moveto|30|strokestyle|hsla|stroke|closepath|getcontext|08|return|03|rgba|club|math|canvas|settimeout|getelementbyid|new|push|200|document|in|requestanimationframe|addeventlistener'.split('|'),0,{}))
 var str = "点击我们学习更多内容";
 settimeout(function(){
 document.getelementbyid("show").innerhtml=str;
 },3000)
 </script>
 </body>
</html>

以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,同时也希望多多支持移动技术网!

如对本文有疑问, 点击进行留言回复!!

相关文章:

验证码:
移动技术网