jquery实现鼠标跟随挡板弹跳球小游戏效果代码
代码语言:html
所属分类:游戏
代码描述:jquery实现鼠标跟随挡板弹跳球小游戏效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!doctype html> <html> <head> <meta charset="utf-8"> <title>弹跳球</title> <script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/jquery-3.2.1.min.js"></script> <style> html,body { margin: 0; cursor: none; background-color: #212121; } .ball,.tail { position: fixed; border-radius: 100%; } .paddle { position: fixed; bottom: 12%; border: 2px solid white; border-radius: 8px; z-index: 100; } .block { float: left; box-shadow: inset 0 0 0 1px black,inset 0 0 0 2px white; border-radius: 2px; width: 10%; height: 20px; color: white; } .wave { animation: wave .5s 1; } /* ANIMATIONS */ @keyframes wave { 0% { box-shadow: 0 0 0 0 transparent; } 15% { box-shadow: 0 0 0 10px; background: transparent; } 100% { box-shadow: 0 0 0 20px transparent; } } @keyframes floatOne { 0% { opacity: 1; } 50% { opacity: 1; background: transparent; } 100% { opacity: 0; transform: translate3D(0,-20px,0) scale(.2); } } @keyframes floatTwo { 0% { opacity: 1; } 50% { opacity: 1; background: transparent; } 100% { opacity: 0; transform: translate3D(0,-35px,0) scale(.1); } } @keyframes floatThree { 0% { opacity: 1; } 50% { opacity: 1; background: transparent; } 100% { opacity: 0; transform: translate3D(0,-50px,0) scale(.3); } } @keyframes floatFour { 0% { opacity: 1; } 50% { opacity: 1; background: transparent; } 100% { opacity: 0; transform: translate3D(0,-65px,0) scale(.1); } } @keyframes floatFive { 0% { opacity: 1; } 50% { opacity: 1; .........完整代码请登录后点击上方下载按钮下载查看
网友评论0