-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
206 lines (179 loc) · 6.35 KB
/
index.html
File metadata and controls
206 lines (179 loc) · 6.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>dfgg服务器官方中文网站-一周年</title>
<style>
* {
margin:0;
padding:0;
}
body {
color: #FFF;
font-size:14px;
overflow: hidden;
}
h1,h2,h3,h4,h5,h6 {
font-weight: 500;
}
#background {
position: fixed;
top:0;
z-index: -1;
background-image: url(./newblack.jpg);
opacity: .8;
width: 100%;
height: 100%;
}
.content {
font-weight: 500;
text-align: center;
margin-top:100px;
}
.joinus {
display: inline-block;
margin-top:30px;
padding:20px;
color:#FFF;
font-size:20px;
border:3px solid #000;
text-decoration: none;
border-radius: 15px;
transition: all .5s;
}
.joinus:hover {
background-color: #fff;
color:#000;
}
</style>
<embed src="mp3/minecraft.mp3" hidden="true" autostart="true" loop="true">
</head>
<body>
<h3>dfggMC Minecraft 服务器</h3>
<hr />
<div id="background">
<canvas id="canvas"></canvas>
</div>
<main>
<div class="content">
<h1>dfgg服务器</h1>
<h2 class="title">dfgg服务器一周年,感谢有你!</h2>
<h2 class="title">一个我的世界生存服务器</h2>
<a href="https://dfggmc.cn.eu.org/join.html"joinus" target="_blank">
加入我们
<br />
<a href="https://dfggmc.cn.eu.org/jh.html"joinus" target="_blank">
我们的计划
<br />
<a href="https://dfggmc.cn.eu.org/world.html"joinus" target="_blank">
地图回顾
<br />
<a href="https://dfggmc.cn.eu.org/zzmd.html"joinus" target="_blank">
peg195的精神支柱
</a>
<section style="margin-top:100px;">
<h1>联系我们</h1>
邮箱:<ADDRESS>dfgg@aliyun.com</ADDRESS>
<h1> </h1>
<section style="margin-top:200px;">
<hr>
<h3>友情链接</h3>
<section style="margin-top:10px;">
<a href="http://zl.cn.eu.org/">ZL服务器</a>
</section>
<p style="text-align: center;margin-top:100px;">©2023 <a href="http://dfggmc.cn.eu.org/">dfggMC Minecraft服务器 2022-2023</a></p>
<a href="https://icp.gov.moe/?keyword=20230195" target="_blank">萌ICP备20230195号</a>
<section style="margin-top:50px;">
</div>
</main>
<!-- <script>
// 设置div背景的宽高
background = document.getElementById("background")
background.style.width = innerWidth + 'px'
background.style.height = innerHeight + 'px'
// 获取canvas对象
var canvas = document.getElementById("canvas")
// 获取画笔
var ctx = canvas.getContext("2d")
// 设置canvas宽高
canvas.height = innerHeight
canvas.width = innerWidth
// 定义一个粒子数组
var particlesArray = []
// 定义页面内粒子的数量
var count = parseInt(canvas.width / 80 * canvas.height / 80)
// 定义粒子类
class Particle {
constructor(x, y) {
this.x = x
this.y = y
// x,y轴的移动速度 -0.5 -- 0.5
this.directionX = Math.random() - 0.5
this.directionY = Math.random() - 0.5
}
// 更新点的坐标
update() {
this.x += this.directionX
this.y += this.directionY
}
// 绘制粒子
draw() {
ctx.beginPath()
ctx.arc(this.x, this.y, 2, 0, Math.PI * 2)
ctx.closePath()
ctx.fillStyle = "white"
ctx.fill()
}
}
// 创建粒子
function createParticle() {
// 生成一个点的随机坐标
var x = Math.random() * innerWidth
var y = Math.random() * innerHeight
particlesArray.push(new Particle(x, y))
}
// 处理粒子
// 先更新坐标,再绘制出来
function handleParticle() {
for(var i = 0; i < particlesArray.length; i++) {
var particle = particlesArray[i]
particle.update()
particle.draw()
// 超出范围就将这个粒子删除
if(particle.x < 0 || particle.x > canvas.width || particle.y < 0 || particle.y > canvas.height) {
particlesArray.splice(i, 1)
}
// 绘制两个点之间的连线
for(var j = i + 1; j < particlesArray.length; j++) {
dx = particlesArray[j].x - particlesArray[i].x
dy = particlesArray[j].y - particlesArray[i].y
dist = Math.sqrt(Math.pow(dx, 2) + Math.pow(dy, 2))
if(dist < 100) {
ctx.beginPath()
ctx.strokeStyle = "rgba(255, 255, 255, " + (1 - dist / 100)
ctx.moveTo(particlesArray[i].x, particlesArray[i].y)
ctx.lineTo(particlesArray[j].x, particlesArray[j].y)
ctx.closePath()
ctx.lineWidth = 1
ctx.stroke()
}
}
}
}
function draw() {
// 首先清空画布
ctx.clearRect(0, 0, canvas.width, canvas.height)
// 如果粒子数量小于规定数量,就生成新的粒子
if(particlesArray.length < count) {
createParticle()
}
// 处理粒子
handleParticle()
}
// 设置定时器
setInterval(draw, 10)
</script> -->
</body>
</html>