three星际穿越旅行机器人操作飞船动画效果代码
代码语言:html
所属分类:动画
代码描述:three星际穿越旅行机器人操作飞船动画效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en" > <head> <meta charset="UTF-8"> <style> body { width: 100vw; height: 100vh; margin: 0; background: #34496a; overflow: hidden; display: flex; justify-content: center; align-items: center; } #webgl { width: 800px; height: 600px; position: absolute; z-index: -1; } #webgl2 { position: absolute; top: 0; left: 0; outline: none; z-index: 2; } #bg-box { width: 802px; height: 602px; position: absolute; z-index: -1; } .svg-box { width: 800px; height: 600px; position: absolute; z-index: 1; } .svg-box #robot { cursor: pointer; } </style> </head> <body> <div id="webgl"></div> <div id="bg-box"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 600"> <path fill="#34496a" d="M0 0v600h800V0zm405.6 458.4C217 458.4 64.1 360.6 64.1 240S217 21.5 405.6 21.5 747.3 119.3 747.3 240s-153 218.4-341.6 218.4z" /> </svg> </div> <div class="svg-box"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 600"> <defs /> <defs> <clipPath id="clip-path"> <rect id="graph-line-mask" width="105.2" height="66.7" x="439.5" y="186.6" fill="none" /> </clipPath> <clipPath id="clip-path-2"> <path id="body-mask" fill="none" d="M490.4 368.3c0 63.7-38 140-84.7 140s-84.8-76.3-84.8-140 38-90.6 84.8-90.6 84.7 26.9 84.7 90.6z" /> </clipPath> </defs> <g id="Ship"> <g id="mid-display"> <rect width="320.3" height="207" x="248.8" y="116.3" fill="#282e39" stroke="#0ff" stroke-miterlimit="10" stroke-width="5" opacity=".8" rx="18.4" /> <g id="graph-btm"> <path id="graph-left" fill="#0ff" d="M439.7 292.1s4.5-19.4 8.7-19c3.6.3 4.6 9.2 7.3 9 3.4-.2 4-14 7.3-14.3 3-.2 4.7 10 8.3 10 4 0 5.1-12.6 8.8-12.8 4.1-.2 7.2 27.1 7.2 27.1z" /> <path id="graph-morph1" fill="none" d="M439.7 292.1s2.2-10.8 6.5-10.4c3.5.3 8.3-18.9 11-19 3.4-.3 5.6 9 9 8.7 3-.3 3.5-3.2 7-3.2 4 0 5.9 10.6 9.5 10.4 4.2-.2 4.7 13.5 4.7 13.5z" /> <path id="graph-right" fill="#34496a" d="M502.6 292.1s4.5-19.4 8.8-19c3.5.3 4.6 9.2 7.3 9 3.4-.2 3.9-14 7.3-14.3 3-.2 4.7 10 8.3 10 4 0 5-12.6 8.7-12.8 4.2-.2 7.3 27.1 7.3 27.1z" /> <path id="graph-morph2" fill="none" d="M502.6 292.1s4.5-9.8 8.8-9.4c3.5.3 4.6-6.8 7.3-7 3.4-.2 3.9 6.6 7.3 6.4 3-.3 4.7-17.9 8.3-17.9 4 0 5 16.5 8.7 16.3 4.2-.2 7.3 11.6 7.3 11.6z" /> </g> <g id="planet"> <circle id="planet-base" cx="332.2" cy="207.8" r="37.3" fill="#34496a" /> <ellipse id="planet-circle" cx="331.5" cy="207.8" fill="none" stroke="#0ff" stroke-miterlimit="10" stroke-width="5" rx="61.8" ry="12.7" /> <path id="planet-top" fill="#34496a" d="M294.9 207.8a37.3 37.3 0 0174.6 0z" /> </g> <g class="graph-circle-lb" id="graph-cir-left"> <circle cx="290.4" cy="287.5" r="20.8" fill="#34496a" /> <path fill="#0ff" d="M290.4 287.5l5.3-20.1a20.8 20.8 0 0115.5 20z" /> </g> <g class="graph-circle-lb" id="graph-cir-mid"> <circle cx="345.4" cy="287.5" r="20.8" fill="#34496a" /> <path fill="#0ff" d="M345.4 287.5l5.2-20.1a20.8 20.8 0 0115.5 20z" /> </g> <g id="graph-cir"> <circle cx="396.4" cy="292.1" r="16.4" fill="none" stroke="#34496a" stroke-miterlimit="10" stroke-width="2" /> <circle cx="396.4" cy="292.1" r="20.8" fill="none" stroke="#34496a" stroke-miterlimit="10" stroke-width="2" /> <circle cx="396.4" cy="292.1" r="11.6" fill="none" stroke="#34496a" stroke-miterlimit="10" stroke-width="2" /> <circle id="graph-cir-1" cx="408" cy="292.1" r="2.3" fill="#0ff" /> <circle id="graph-cir-2" cx="396.4" cy="275.7" r="2.3" fill="#0ff" /> <circle id="graph-cir-3" cx="417.2" cy="292.1" r="2.3" fill="#0ff" /> <circle id="graph-cir-mid-2" cx="396.4" cy="292.1" r="2.3" fill="#0ff" data-name="graph-cir-mid" /> </g> <g id="graph-big" clip-path="url(#clip-path)"> <path id="graph-line" fill="none" stroke="#0ff" stroke-miterlimit="10" stroke-width="5&q.........完整代码请登录后点击上方下载按钮下载查看
网友评论0