-
Notifications
You must be signed in to change notification settings - Fork 0
/
game.html
110 lines (99 loc) · 2.69 KB
/
game.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
106
107
108
109
110
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<title>测试</title>
<style>
* {
margin: 0;
padding: 0;
user-select: none;
box-sizing: border-box;
}
html,
body {
display: flex;
justify-content: center;
align-items: center;
width: 100%;
max-width: 1300px;
min-width: 1200px;
min-height: 650px;
background: #423939;
}
.box {
width: 85%;
background: #827979;
position: relative;
margin: 20px 20px 20px 20px;
padding: 10px 10px 10px 10px;
box-shadow: 2px 2px 20px 2px rgba(0, 0, 0, 0.2);
border-radius: 2px;
}
.gamebox {
min-height: 600px;
min-width: 800px;
background: black;
}
.box_title {
font-size: 35px;
color: white;
}
.box_context {
font-size: 20px;
color: white;
}
</style>
<script type="text/javascript">
document.addEventListener('plusready', function() {
//console.log("所有plus api都应该在此事件发生后调用,否则会出现plus is undefined。")
});
</script>
</head>
<body>
<div class="box">
<iframe src="index.html" frameBorder="0" scrolling="no" class="gamebox">
</iframe>
</div>
<div style="min-width:400px;">
<div class="box">
<span class="box_title">666</span><br>
<span class="box_context">简介</span><br>
</div>
<div class="box">
<span class="box_title">操作方法</span><br>
<span class="box_context">鼠标:点击游戏画面操作</span><br>
<span class="box_context">键盘:“上下左右”键盘移动</span><br>
<span class="box_context">-------“Shift”奔跑/取消奔跑</span><br>
<span class="box_context">-------“Enter/空格”确定</span><br>
<span class="box_context">-------“Esc”取消</span><br>
</div>
</div>
<script>
function IsPC() {
var userAgentInfo = navigator.userAgent;
var Agents = new Array("Android", "iPhone", "SymbianOS", "Windows Phone", "iPad", "iPod");
var flag = true;
for (var v = 0; v < Agents.length; v++) {
if (userAgentInfo.indexOf(Agents[v]) > 0) {
flag = false;
break;
}
}
return flag;
}
console.log(IsPC())
var presentPC = IsPC()
if (presentPC) {
break;
} else {
if (confirm("系统检测到您为移动端,是否转至全屏模式?")) {
window.location.href = 'https://endless.rpgca.tk/'
} else {
break;
}
}
</script>
</body>
</html>