未验证 提交 e992734c 编辑于 作者: Diving-Fish's avatar Diving-Fish 提交者: GitHub
浏览文件

Merge pull request #3 from yuudi/develop

Develop
{
"stable": {
"version": 3444,
"url": "http://img.yobot.xyz/yobot/yobot3444.zip"
"version": 3458,
"url": "http://img.yobot.xyz/yobot/yobot3458.zip"
}
}
\ No newline at end of file
......@@ -65,6 +65,10 @@ yobot 提供了群聊、web 页面两套用户交互方式,具有操作便捷
<https://github.com/yuudi/yobot>
## 贡献者
[项目贡献者](./project/contributors.md)
## 开源协议
本工具使用了[这些](./project/open-source.md)开源软件和工具
......
......@@ -10,8 +10,10 @@ yobot 的编写出于学习目的,很高兴此工具能为大家提供帮助
QQ群:
770947581(满)
1044314369(满)
1067699252
1067699252(满)
774394459
[项目贡献者](./project/contributors.md)
[更新日志](./project/changelog.md)
[待办事项](./project/todo.md)
[开源许可](./project/open-source.md)
......@@ -54,7 +54,7 @@
| 关键词 | 说明 |
| --------------------------------- | -------------- |
| jjc查询(+5个角色名空格分隔) | 查找竞技场解法 |
| jjc查询 +5个角色名空格分隔 | 查找竞技场解法,指定区服可改用“jjc国服/jjc台服/jjc日服” |
| (自动:新闻推送) | 推送最新的新闻 |
| 日程(今日/明日/x月x日)(可自动) | 查看活动日程 |
| 日程表 | 查看一周日程 |
......
......@@ -41,7 +41,7 @@ yobot 三代基于酷Q机器人和 httpapi 插件实现
### Windows系统
[点击下载便携版](http://tools.yobot.win/fetch-latest/)
[点击下载便携版](https://yobot.lanzous.com/b00nlr3ni)
下载yobot便携版,创建一个文件夹解压,启动 yobot.exe 即可。如需更改端口,请启动一次后修改 yobot_config.json 中的 port 字段并重启。
......
......@@ -28,7 +28,7 @@
### 第二步
点击下载[yobot便携版](http://tools.yobot.win/fetch-latest/)
点击下载[yobot便携版](https://yobot.lanzous.com/b00nlr3ni)
解压后双击“yobot.exe”启动服务,双方通信成功后出现如下的提示
......
# 更新日志
## 3.6.1
- 竞技场查询支持pcrdfans
- 更多的统计图表([#85](https://github.com/yuudi/yobot/pull/85)
- 统计:多维度分析([#82](https://github.com/yuudi/yobot/pull/82)
## 3.6.0
- 公会战数据多存档
- 开放统计api与数据下载
- 统计1:出刀顺序表([#75](https://github.com/yuudi/yobot/pull/75)
- 统计2:出刀统计图([#77](https://github.com/yuudi/yobot/pull/77)
- 统计:出刀顺序表([#75](https://github.com/yuudi/yobot/pull/75)
- 统计:出刀统计图([#77](https://github.com/yuudi/yobot/pull/77)[#79](https://github.com/yuudi/yobot/pull/79)
- 自动更新时有反馈
- 允许删除公会
- 优化在线十连
- 修复[#69](https://github.com/yuudi/yobot/issues/69)[#66](https://github.com/yuudi/yobot/issues/66)[#55](https://github.com/yuudi/yobot/issues/55)
## 3.5
......
# 项目贡献者
## Code
[@yuudi](https://github.com/yuudi)
[@winrey](https://github.com/winrey)
[@Tan90Qian](https://github.com/Tan90Qian)
[@Diving-Fish](https://github.com/Diving-Fish)
[@Ai-Himmel](https://github.com/Ai-Himmel)
[@Windylh](https://github.com/Windylh)
[@myisjt](https://github.com/myisjt)
[@otz](https://github.com/otz)
[@Lancercmd](https://github.com/Lancercmd)
[@xhl6666](https://github.com/xhl6666)
## Platform Support
[@winrey](https://github.com/winrey)
[@yyuueexxiinngg](https://github.com/yyuueexxiinngg)
## Bug Report
[@sugar-zero](https://github.com/sugar-zero)
[@WenyiDong](https://github.com/WenyiDong)
[@Syntacticlosure](https://github.com/Syntacticlosure)
[@Hieuzest](https://github.com/Hieuzest)
[@tomorrowlong](https://github.com/tomorrowlong)
[@OVERDRIVEZhi](https://github.com/OVERDRIVEZhi)
[@KB-learning-01](https://github.com/KB-learning-01)
[@Ryunkun](https://github.com/Ryunkun)
[@wrysfz](https://github.com/wrysfz)
[@HsuJv](https://github.com/HsuJv)
[@Kelcoin](https://github.com/Kelcoin)
[@guch8017](https://github.com/guch8017)
......@@ -11,6 +11,7 @@
- peewee: <https://github.com/coleifer/peewee>
- requests: <https://pypi.org/project/requests>
- aiohttp: <https://github.com/aio-libs/aiohttp>
- echart: <https://github.com/apache/incubator-echarts>
- axios: <https://github.com/axios/axios>
- beautifulsoup4: <http://www.crummy.com/software/BeautifulSoup/>
- APscheduler: <https://github.com/agronholm/apscheduler>
......
......@@ -50,6 +50,10 @@
`gacha_private_on` 开启私聊抽卡功能,默认值 `false`
`jjc_search` 竞技场查询,可选`nomae.net` `pcrdfans.com` `off`,默认值`nomae.net`
`jjc_auth_key` pcrdfans.com 提供的查询授权码
`news_jp_official` 开启日服官网新闻推送,默认值 `true`
`news_jp_twitter` 开启日服推特新闻推送,默认值 `true`
......
......@@ -16,7 +16,8 @@ Bot 只是辅助作用,与成员多沟通才能提高分数
1. 在群聊中发送`创建日服公会`(日、韩、台、国)
1. 所有公会战成员在群聊中发送`加入公会`,或者由群管理员发送`加入全部成员`
1. 成员向 bot 私聊发送`登录``重置密码`,进入后台确认,同时修改登录密码
1. 成员进入公会战面板,并将网页地址保存到桌面快捷方式(手机、电脑均可)
1. 成员进入公会战面板,并将网页地址保存到桌面快捷方式(手机、电脑均可),以便使用网页报刀和查看数据
1. 管理员在公会设置中,新建一个空白档案用来存放公会战数据
## 进行中:成员
......
......@@ -17,7 +17,8 @@
"show_jjc_solution": "url",
"gacha_on": false,
"gacha_private_on": false,
"jjc_consult": true,
"jjc_search": "nomae.net",
"jjc_auth_key": "",
"news_jp_official": true,
"news_jp_twitter": true,
"news_tw_official": true,
......
......@@ -2,12 +2,17 @@
* TODO:
* 公会伤害成长曲线
* 公会成员成长曲线合图
* 公会成员总伤害对比表
* 公会成员刀平均伤害对比表
* 公会成员各Boss刀数统计
* 各个玩家与BOSS均伤偏差值百分比统计
*/
const numberFormatter = num => {
if (num < 10000)
return `${num.toLocaleString()}`
if (num < 100000000)
return `${(num / 10000).toLocaleString()} W`
return `${(num / 100000000).toLocaleString()} E`
}
if (!Object.defineProperty) {
alert('浏览器版本过低');
}
......@@ -82,6 +87,7 @@ var vm = new Vue({
boss_hit_chart: null,
personal_progress_chart: null,
personal_time_chart: null,
total_damage_chart: null,
is_loading: true,
selecting_tab: "table",
selecting_qqid: parseInt(qqid)
......@@ -97,6 +103,7 @@ var vm = new Vue({
this.boss_hit_chart = echarts.init(document.getElementById("boss_hit_chart"));
this.personal_progress_chart = echarts.init(document.getElementById("personal_progress_chart"));
this.personal_time_chart = echarts.init(document.getElementById("personal_time_chart"));
this.total_damage_chart = echarts.init(document.getElementById("total_damage_chart"));
this.selecting_tab = "total";
this.refresh_data();
},
......@@ -184,7 +191,11 @@ var vm = new Vue({
xAxis: {
data: temp[0],
},
yAxis: {},
yAxis: {
axisLabel: {
formatter: numberFormatter
}
},
series: [{
name: '伤害',
type: 'bar',
......@@ -226,9 +237,13 @@ var vm = new Vue({
data: ['伤害']
},
xAxis: {
data: temp3[0],
data: temp3[0]
},
yAxis: {
axisLabel: {
formatter: numberFormatter
}
},
yAxis: {},
series: [{
name: '伤害',
type: 'bar',
......@@ -350,7 +365,7 @@ var vm = new Vue({
yAxis: {
type: 'value',
axisLabel: {
formatter: v => `${v / 10000} W`
formatter: numberFormatter
},
axisPointer: {
snap: true
......@@ -430,7 +445,6 @@ var vm = new Vue({
series: {
name: '刀数',
type: 'bar',
animation: true,
lineStyle: {
width: 2
......@@ -488,6 +502,76 @@ var vm = new Vue({
}
}]
};
let temp9 = this.members_damage_for_chart(this.global_table_data);
let option9 = {
title: {
text: '成员伤害统计'
},
tooltip: {
trigger: 'axis',
axisPointer: {
type: 'cross',
crossStyle: {
color: '#999'
}
}
},
toolbox: {
feature: {
dataView: {show: true, readOnly: false},
magicType: {show: true, type: ['line', 'bar']},
restore: {show: true},
saveAsImage: {show: true}
}
},
legend: {
data: ['总伤害', '刀均伤害']
},
xAxis: [
{
type: 'category',
data: temp9[0],
axisPointer: {
type: 'shadow'
},
axisLabel: {
interval: 0,
rotate: 45
},
boundaryGap: true,
}
],
yAxis: [
{
type: 'value',
name: '总伤害',
axisLabel: {
formatter: numberFormatter
}
},
{
type: 'value',
name: '刀均伤害',
axisLabel: {
formatter: numberFormatter
}
}
],
series: [
{
name: '总伤害',
type: 'bar',
data: temp9[1]
},
{
name: '刀均伤害',
type: 'bar',
yAxisIndex: 1,
data: temp9[2]
}
]
};
this.boss_dmg_chart.setOption(option);
this.challenge_chart.setOption(option2);
......@@ -497,6 +581,7 @@ var vm = new Vue({
this.boss_blood_chart.setOption(option6);
this.total_time_chart.setOption(option7);
this.boss_hit_chart.setOption(option8);
this.total_damage_chart.setOption(option9);
},
resizeAll: function() {
......@@ -508,6 +593,7 @@ var vm = new Vue({
this.personal_progress_chart.resize();
this.personal_time_chart.resize();
this.boss_hit_chart.resize();
this.total_damage_chart.resize();
},
init_player_data: function() {
......@@ -521,7 +607,7 @@ var vm = new Vue({
if (clist[i].health_ramain != 0) {
damage = clist[i].damage;
}
else if (clist[i+1].is_continue) {
else if (clist[i+1]?.is_continue) {
damage = clist[i].damage + clist[i+1].damage
i++;
}
......@@ -602,6 +688,9 @@ var vm = new Vue({
yAxis: {
type: 'value',
scale: true,
axisLabel: {
formatter: numberFormatter
}
},
tooltip: {
trigger: 'axis',
......@@ -870,6 +959,14 @@ var vm = new Vue({
);
},
members_damage_for_chart: function(global_table_data) {
const data = global_table_data.sort((a, b) => b.sum_dmg - a.sum_dmg);
const full = data.map(elem => elem.sum_dmg);
const average = data.map(elem => elem.avg_dmg);
const names = data.map(elem => elem.nickname);
return [names, full, average];
},
average_damage: function(damage, contain_tail_and_continue) {
let sum = this.sum(damage.normal_damage);
let count = damage.count;
......@@ -895,7 +992,7 @@ var vm = new Vue({
},
get_player: function(qqid) {
return this.members.find(o => o.qqid === qqid);
return this.members.find(o => o.qqid === qqid) ?? {nickname:'未加入',qqid:qqid,sl:null};
},
player_damage: function(player_qqid) {
......
......@@ -9,6 +9,7 @@ var experience = {
"star1": 0,
"diamond": 0,
};
var progress = false;
(function () {
var h = localStorage['gacha_experience'];
if (h) {
......@@ -52,7 +53,12 @@ async function reload() {
experience.diamond += 1500;
}
async function gacha() {
if (progress) {
return;
}
progress = true;
await reload();
document.getElementById('result').innerHTML = `★3: ${experience.star3}<br>★2: ${experience.star2}<br>★1: ${experience.star1}<br>总耗钻: ${experience.diamond}`;
localStorage['gacha_experience'] = [experience.star3, experience.star2, experience.star1, experience.diamond].join(',');
progress = false;
}
\ No newline at end of file
......@@ -26,7 +26,7 @@
联系邮箱:<a href="mailto:yobot@pcrbot.com">yobot@pcrbot.com</a>
</p>
<p>
交流群:<br>770947581(满)<br>1044314369(满)<br>1067699252
交流群:<br>770947581(满)<br>1044314369(满)<br>1067699252(满)<br>774394459
</p>
<h2>
其他
......
......@@ -163,7 +163,19 @@
<el-checkbox v-model="setting.gacha_private_on">允许私聊抽卡</el-checkbox>
</p>
<p>
<el-checkbox v-model="setting.jjc_consult">允许竞技场查询</el-checkbox>
竞技场查询
<el-select v-model="setting.jjc_search">
<el-option label="关闭" value="off"></el-option>
<el-option label="nomae.net" value="nomae.net"></el-option>
<el-option label="pcrdfans.com" value="pcrdfans.com"></el-option>
</el-select>
</p>
<p :hidden="setting.jjc_search!='pcrdfans.com'">
<el-col :span="4">pcrdfans.com apikey</el-col>
<el-col :span="20">
<el-input v-model="setting.jjc_auth_key" placeholder="如果您没有apikey,请更换其他查询方式">
</el-input>
</el-col>
</p>
<p>
新闻推送:
......
......@@ -209,6 +209,9 @@
</el-main>
</el-container>
</div>
<footer style="text-align: center">
powered by <a href="https://github.com/yuudi/yobot">yobot</a>
</footer>
</body>
<script>var csrf_token = "{{ session['csrf_token'] }}";</script>
<script src="{{ url_for('yobot_static', filename='clan/panel.js') }}"></script>
......
......@@ -154,6 +154,9 @@
没有记录
</template>
</div>
<footer style="text-align: center">
powered by <a href="https://github.com/yuudi/yobot">yobot</a>
</footer>
</body>
<script>var csrf_token = "{{ session['csrf_token'] }}";</script>
<script src="{{ url_for('yobot_static', filename='clan/progress.js') }}"></script>
......
......@@ -81,6 +81,9 @@
</el-form-item>
</el-form>
</div>
<footer style="text-align: center">
powered by <a href="https://github.com/yuudi/yobot">yobot</a>
</footer>
</body>
<script>var csrf_token = "{{ session['csrf_token'] }}";</script>
<script src="{{ url_for('yobot_static', filename='clan/setting.js') }}"></script>
......
......@@ -6,14 +6,10 @@
<body>
<p><a href="../">返回</a></p>
<h1>建设中</h1>
<p><a href="./1/">统计1:出刀顺序表</a> by <a href="https://github.com/Ai-Himmel">@Ai-Himmel</a></p>
<p><a href="./2/">统计2:数据图表</a> by <a href="https://github.com/Diving-Fish">@Diving-Fish & @Winrey</a></p>
<!--
不知道统计改怎么写,所以我就没写了
但还是有大佬写出来了有用的分析,感谢这些大佬的贡献
更多统计等待大佬们出主意,欢迎PR,可以内置到yobot里,也可以外部调用api进行分析
-->
<h1>数据分析</h1>
<p><a href="./1/">统计:出刀顺序表</a> by <a href="https://github.com/Ai-Himmel">@Ai-Himmel</a></p>
<p><a href="./2/">统计:数据图表</a> by <a href="https://github.com/Diving-Fish">@Diving-Fish</a> & <a href="https://github.com/winrey">@Winrey</a></p>
<p><a href="#" target="_blank" id="pcrd-yobot-fe">统计:多维度分析</a>(需要开启api访问) by <a href="https://github.com/Tan90Qian">@Tan90Qian</a></p>
<p>
原始数据(json格式)<br>
<a href="./api/">查看本轮</a> <a href="./api/" download>下载本轮</a><br>
......@@ -46,7 +42,9 @@
<script>
var apikey = "{{ apikey }}";
document.getElementById("apiurl").value = window.location.href + "api/?apikey=" + apikey;
var apiurl = window.location.href + "api/?apikey=" + apikey
document.getElementById("apiurl").value = apiurl;
document.getElementById("pcrd-yobot-fe").href = "http://tools.yobot.win/pcrd-yobot-fe/#" + encodeURIComponent(apiurl);
document.getElementById("copy").addEventListener("click", e => {
document.getElementById("apiurl").select();
document.execCommand("Copy");
......
支持 Markdown
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册