gsap实现点状机器人吃星星游戏代码

代码语言:html

所属分类:游戏

代码描述:gsap实现点状机器人吃星星游戏代码,按住键盘上下左右键吃掉星星闯关升级。

代码标签: gsap 点状 机器人 星星 游戏

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="en" >

<head>

  <meta charset="UTF-8">
  

  
<style>
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@700&display=swap');

html, body {
  width:100%;
  height:100%;
  overflow:hidden;
  display: flex;
  flex-direction:column;
  align-items: center;
  justify-content: center;
  background:#000;
  font-family: 'Roboto', sans-serif;
  font-weight:900;
  font-size:12px;
}

#game {
  width:80%;
  height:80%;
  overflow:visible;
}
</style>


</head>

<body  >
  <svg id="game" viewBox="0 0 100 100" style="opacity:0">
  <g id="grid" fill="#fff"></g>
  <g id="bot" stroke="#fff">
<!--     <path d="M5,2L5,-2"/>
    <circle cx="5" cy="-2" r="0.7"/> -->
    <rect x="-0.5
" y="4" width="11" height="2" rx="0.5"/>
    <rect x="1
" y="1" width="8" height="8&qu.........完整代码请登录后点击上方下载按钮下载查看

网友评论0