网页打砖块

博主在学习Unity过程中感到困难,转向制作了一个Python版的打砖块游戏,并分享了游戏截图和代码,表示将带来详细注释版。
摘要由CSDN通过智能技术生成

失踪人口回归啦!

兄弟们,我回来啦!呜呜呜!Unity好难学
今天搞了个打砖块
截图:
在这里插入图片描述
就这个,好难啊!
好了,不多哔哔。
啊!哈哈哈哈,代码来咯:

<!DOCTYPE html>
<html lang = "en">
<head>
<meta charset = "UTF-8">
<meta name = "viewport" content = "width = device-width, initial-scale = 1.0">
<title>打砖块游戏</title>
	// 搭建画布
	<style>
     #box {
   
      width: 600px;
      height: 650px;
      border: 5px solid rgb(168, 139, 8);
      position: relative;
      left: 500px;
      background: linear-gradient(rgb(19, 192, 120), rgb(47, 32, 114));
     }
     #ball {
   
      width: 20px;
      height: 20px;
      border-radius: 10px;
      background-color: white;
      position: absolute;
      top: 560px;
      box-shadow: 0px 0px 3px 3px aqua;
     }
     #btn {
   
      width: 150px;
      height: 90px;
      position: fixed;
      left: 730px;
      top: 350px;
      border-radius: 10px;
      font-size: 24px;
      cursor: pointer;
     }
     #slide {
   
      width: 120px;
      height: 20px;
      background-color: rgb(168, 139, 8);
      position: absolute;
      top: 585px;
      border-radius: 10px;
      box-shadow: 0px 0px 2px 2px red;
      cursor: pointer;
     }
     #brick div {
   
      width: 98px;
      height: 20px;
      float: left;
      border: 1px solid black;
     }
     #tip {
   
      width: 280px;
      position: fixed;
      top: 100px;
      left: 150px;
      border: 1px solid black;
      text-indent: 2em;
      padding: 10px;
      border-radius: 20px;
     }
     #grade {
   
      width: 180px;
      position: fixed;
      top: 100px;
      left: 1150px;
      border: 1px solid black;
      text-indent: 2em;
      padding: 10px;
      border-radius: 20px;
     }
     #grade h3 {
   
      font-weight: 500;
     }
	</style>
</head>
<body>

	// 规则与难度
	<div id = "box">
		
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值