-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
258 lines (248 loc) · 9.21 KB
/
index.html
File metadata and controls
258 lines (248 loc) · 9.21 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
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
<!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>Simulator</title>
<!-- 引入样式 -->
<link rel="stylesheet" href="style.css" />
<link
href="https://cdn.bootcdn.net/ajax/libs/element-plus/1.0.2-beta.53/theme-chalk/index.css"
rel="stylesheet"
/>
<!-- 引入组件库 -->
<script src="lib/lodash.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/vue/3.1.2/vue.global.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/element-plus/1.0.2-beta.53/index.full.min.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/element-plus/1.0.2-beta.53/umd/locale/es.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/dayjs/1.10.5/locale/zh-cn.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/p5.js/1.4.0/p5.min.js"></script>
</head>
<body>
<div id="app">
<el-container class="main">
<el-header>
<h1>众生之门 模拟器</h1>
</el-header>
<el-container>
<el-container>
<el-main>
<el-card shadow="hover">
<template #header>
<div class="card-header">
<span>模型参数设置</span>
<el-button
class="button"
type="text"
icon="el-icon-question"
@click="helpVisible = true"
>使用帮助</el-button
>
</div>
</template>
<el-row>
<el-col :span="8">
<el-form :model="settings" label-width="100px">
<el-form-item
label="玩家数量"
prop="maxPlayer"
:rules="[
{ required: true, message: '不能为空'},
{ type: 'number', message: '必须为数字值'}
]"
>
<el-input
v-model.number="settings.maxPlayer"
autocomplete="off"
>
</el-input>
</el-form-item>
<el-form-item
label="地图大小"
prop="mapSize"
:rules="[
{ required: true, message: '不能为空'},
{ type: 'number', message: '必须为数字值'}
]"
>
<el-input
v-model.number="settings.mapSize"
autocomplete="off"
></el-input>
</el-form-item>
</el-form>
</el-col>
<el-col :span="8">
<el-form :model="settings" label-width="100px">
<el-form-item
label="运行回合"
prop="targetTurns"
:rules="[
{ required: true, message: '不能为空'},
{ type: 'number', message: '必须为数字值'}
]"
>
<el-input
v-model.number="settings.targetTurns"
autocomplete="off"
></el-input>
</el-form-item>
</el-form>
</el-col>
</el-row>
<el-row justify="center">
<el-button
@click="update"
type="warning"
plain
icon="el-icon-upload2"
>更新参数</el-button
>
<el-button
@click="init"
type="primary"
plain
icon="el-icon-refresh"
>初始化模型</el-button
>
<el-button
@click="start"
type="danger"
plain
icon="el-icon-video-play"
>运行模型</el-button
>
<el-button
@click="step"
type="danger"
plain
icon="el-icon-caret-right"
>步进</el-button
>
<el-tooltip content="假的,还没做好" placement="top"
><el-button
@click="pause"
type="danger"
plain
icon="el-icon-video-pause"
>暂停</el-button
></el-tooltip
>
</el-row>
</el-card>
<el-divider></el-divider>
<el-card shadow="hover">
<el-empty
image="img/bg.jpg"
description="未初始化模型"
v-show="showResult"
></el-empty>
<transition>
<el-descriptions title="模型信息" border v-show="!showResult">
<el-descriptions-item label="玩家数"
>{{modelPlayerAmount}}</el-descriptions-item
>
<el-descriptions-item label="经验总和"
>{{modelTotalExp}}</el-descriptions-item
>
<el-descriptions-item label="死亡玩家数"
>{{modelDeadPlayer}}</el-descriptions-item
>
<el-descriptions-item label="当前运行回合"
>{{modelTotalRun}}</el-descriptions-item
>
<el-descriptions-item label="最高经验记录">
Lv.{{modelHighestExp[0]}}
<el-progress
:percentage="modelHighestExp[1]/(modelHighestExp[0]+1)*100"
><span
>{{modelHighestExp[1]}}/{{modelHighestExp[0]+1}}</span
></el-progress
>
</el-descriptions-item>
</el-descriptions>
</transition>
</el-card>
</el-main>
<el-footer>
<el-row
><el-alert
title="建议使用IE6以上系列浏览器、1024*768以上分辨率访问本网站"
type="success"
:closable="false"
center
>
</el-alert>
</el-row>
<el-row>
ALC Simulator 由
<el-link
type="primary"
target="_blank"
href="https://mail.qq.com/cgi-bin/qm_share?t=qm_mailme&email=-pe_hoqfjITQnZA"
>
XTARZ
</el-link>
使用
<el-link
type="primary"
target="_blank"
href="https://v3.cn.vuejs.org/"
>Vue3</el-link
>+<el-link
type="primary"
target="_blank"
href="https://element-plus.gitee.io/"
>Element Plus</el-link
>
构建
<el-divider direction="vertical"></el-divider>灵感来自于 YeFeng
Miao
</el-row>
<el-row>
项目源代码托管在
<el-link
type="primary"
target="_blank"
href="https://github.com/FallenXtar/alc-exp-simulator"
>Github</el-link
>
和
<el-link
type="primary"
target="_blank"
href="https://gitee.com/xtar/alc-exp-simulator"
>Gitee</el-link
>.
</el-row></el-footer
></el-container
><el-aside>
<el-table :data="tableData" style="width: 100%" height="800px">
<el-table-column prop="id" label="ID" width="100">
</el-table-column>
<el-table-column prop="location" label="位置" width="100">
</el-table-column>
<el-table-column prop="status" label="状态" width="100">
</el-table-column>
</el-table> </el-aside
></el-container>
</el-container>
<el-dialog
title="使用说明"
v-model="helpVisible"
width="30%"
destroy-on-close
>
<ol>
<li>输入参数</li>
<li>点击[更新参数]</li>
<li>点击[初始化模型]</li>
<li>运行模型</li>
</ol>
</el-dialog>
</div>
<script src="main.js"></script>
<script src="app.js"></script>
</body>
</html>