This repository has been archived by the owner on Jun 10, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
105 lines (105 loc) · 3.75 KB
/
index.html
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
<!DOCTYPE html>
<html lang="en">
<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">
<script src="https://cdn.jsdelivr.net/npm/typed.js@2.0.12"></script>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Noto+Sans+TC:wght@300;400;900&display=swap" rel="stylesheet">
<link rel="stylesheet" href="https://pro.fontawesome.com/releases/v5.10.0/css/all.css" integrity="sha384-AYmEC3Yw5cVb3ZcuHtOA93w35dYTsvhLPVnYs9eStHfGJvOvKxVfELGroGkvsg+p" crossorigin="anonymous"/>
<title>Ping Pong Game</title>
<style>
* {
padding: 0;
margin: 0;
overflow: hidden;
font-family: 'Noto Sans TC', sans-serif;
}
body {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
height: 100vh;
width: 100vw;
}
body div {
margin-bottom: 30px;
}
#pingpongTitle {
font-size: 3em;
font-weight: 900;
color: #fff;
background-color: #000;
padding: 0.5em;
width: 100%;
display: flex;
justify-content: center;
align-items: center;
}
#rule {
font-size: 1.5em;
font-weight: 900;
background-color: rgb(255, 251, 214);
border-radius: 15px;
width: 60%;
height: 150px;
padding: 15px;
}
button {
font-size: 1.5em;
font-weight: 900;
background-color: #000;
border-radius: 15px;
width: 200px;
height: 80px;
padding: 5px;
color: #fff;
border: none;
cursor: pointer;
}
#socialOption {
display: flex;
justify-content: center;
align-items: center;
width: 100%;
height: 2.1em;
}
#socialOption a {
margin-right: 10px;
font-size: 2em;
}
a {
text-decoration: none;
color: unset;
}
</style>
</head>
<body>
<div id="pingpongTitle">
<span id="pingTT"></span>
</div>
<div id="rule">
<p>
這是一個簡單的 連線乒乓球 遊戲,這個遊戲的規則<span style="color: green">很簡單</span>,玩家能操控其中一邊的板子(上跟下),想辦法將球<span style="color: green">擊回</span>,只要一方<span style="color: brown">失誤</span> (碰到其中一方的邊界),<span style="color: red">遊戲結束</span>。
</p>
</div>
<div id="playButton">
<button id="playButton" onclick="location.href = '/multipingpong'">Play</button>
</div>
<div id="socialOption">
<a href="https://github.com/000hen/pingponggame"><i class="fab fa-github"></i></a>
</div>
</body>
<script>
var typed = new Typed('#pingTT', {
strings: ["Ping Pong Game", "乒乓球遊戲"],
typeSpeed: 50,
backDelay: 2500,
backSpeed: 50,
loop: true
});
</script>
</html>