Skip to content
This repository has been archived by the owner on Oct 13, 2023. It is now read-only.

Commit

Permalink
调试,添加文档,准备发布第一版
Browse files Browse the repository at this point in the history
  • Loading branch information
xxzl0130 committed Feb 5, 2020
1 parent 01a8546 commit ad245c8
Show file tree
Hide file tree
Showing 17 changed files with 80 additions and 18 deletions.
6 changes: 3 additions & 3 deletions ChipDataWindow/GetChipWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ GetChipWindow::~GetChipWindow()

void GetChipWindow::init()
{
this->ui->netProxyRadioButton->setChecked(true);
this->ui->localProxyRadioButton->setChecked(true);
request_->setHeader(QNetworkRequest::ContentTypeHeader, "application/x-www-form-urlencoded; charset=UTF-8");

QSslConfiguration config = request_->sslConfiguration();
Expand All @@ -54,8 +54,8 @@ void GetChipWindow::init()
void GetChipWindow::startLocalProxy()
{
killProcess();
process_->start(QIODevice::ReadOnly);
this->ui->startLocalPushButton->setEnabled(false);
process_->start(QIODevice::ReadOnly);
}

void GetChipWindow::closeEvent(QCloseEvent* e)
Expand Down Expand Up @@ -160,6 +160,7 @@ void GetChipWindow::processError(QProcess::ProcessError error)
localProxyPort_ = "";
if (this->ui->netProxyRadioButton->isChecked())
return;
this->ui->startLocalPushButton->setEnabled(true);
switch (error)
{
case QProcess::FailedToStart:
Expand All @@ -181,7 +182,6 @@ void GetChipWindow::processError(QProcess::ProcessError error)
QMessageBox::warning(this, trUtf8(u8"错误"), trUtf8(u8"程序未知错误!"));
break;
}
this->ui->startLocalPushButton->setEnabled(true);
}

void GetChipWindow::processDataReady()
Expand Down
4 changes: 2 additions & 2 deletions ChipDataWindow/GetChipWindow.ui
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
<item>
<widget class="QLineEdit" name="uidLineEdit">
<property name="text">
<string>1563276</string>
<string/>
</property>
</widget>
</item>
Expand All @@ -65,7 +65,7 @@
<string/>
</property>
<property name="text">
<string>轩轩醉了</string>
<string/>
</property>
</widget>
</item>
Expand Down
Binary file added CodeX/GF_Tool_Server.exe
Binary file not shown.
27 changes: 14 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
# CodeX
少女前线芯片计算器CodeX
少女前线芯片计算器CodeX
[使用说明](./doc/使用说明.md)

## 施工中
目前进度
- [x] 与代理服务器通讯
- [x] 芯片基础类
- [x] 芯片拼图方案
- [x] 用户数据解析
- [x] 重装方案解析与用户配置 80%
- [x] 分析用户现有芯片配置
- [ ] 算法求解线程(已有算法在[GFChipToolX](https://github.com/xxzl0130/GFChipToolX)中,需要移植) 70%
- [x] 芯片列表展示(ChipDataWindow)
- [ ] 芯片方案展示(在主界面) 20%
- [x] ~~使用SQLite~~保存数据、用户配置、芯片方案
## 第一版
目前功能
* 从本地代理/网络代理获取芯片数据
* 配置各小队参数
* 为各小队配置不同的芯片组合方案(例如用不用5格)
* 按格数筛选方案
* 在方案列表中直接对各属性排序

TODO:
- [ ] 保存为各小队选择的配置
- [ ] 在计算中排除已经选择的配置中的芯片
- [ ] 计算并显示当前各小队的满强化属性

## 依赖
[zlib](https://github.com/madler/zlib)
Expand Down
Binary file added doc/img/1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/10.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/4.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/7.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/8.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/9.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/firewall.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/group.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
61 changes: 61 additions & 0 deletions doc/使用说明.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# CodeX 重装芯片计算器使用说明
主程序为“CodeX.exe”。目录下会附带有其他支持文件以及“GF_Tool_Server.exe”,该程序来自于这个[芯片提取工具](https://bbs.nga.cn/read.php?tid=19277807),也可单独使用。
以下为详细使用步骤:
## 1. 打开主程序
双击“CodeX.exe”,将进入主界面如下:
![主界面](./img/1.png)
## 2. 获取芯片数据
单击右上角的“芯片”按钮,打开芯片数据窗口。
![芯片数据](./img/2.png)
这里已经有了读取好的芯片,如果没有,可以单击“获取芯片数据”打开新的窗口。
![获取芯片数据窗口](./img/3.png)
这里可以看到“本地代理”和“网络代理”两个选项,其中本地代理将启动附带的“GF_Tool_Server.exe”程序进行代理,而网络代理则将使用网络服务器进行代理。
本地代理适合于部分没有自动代理的手机(ViVo),而本地代理出错或者没有WiFi的时候可以用网络代理。

### 2.1. 使用网络代理
选择网络代理时,下方的文本框会显示自动代理地址,地址为:
`http://static.xuanxuan.tech/GF/GF.pac`
需要将该地址设置到手机中。以下说明以安卓手机为例:
打开手机,连接任意WiFi,长按选择修改网络,打开高级选项,代理模式为“自动”或“自动配置”,将该地址填入,例如:
![自动代理图](./img/4.jpg)
然后保存设置。
随后完全退出游戏并重新进入。为了避免滥用服务器,此时进入游戏后将卡死在基地界面无法操作,出现此情况也代表着代理设置正确。
此时在“获取芯片数据”窗口中,准确填写UID和昵称信息,单击“获取数据”,即可读取到芯片数据。如弹出错误请按错误说明重试。

### 2.2. 使用本地代理
选择本地代理时,“启动”按钮将亮起:
![“启动”按钮](./img/5.png)
单击“启动”按钮,程序启动时,防火墙可能会弹出提示,此时请选择允许其通信,注意勾选“专用网络”。
![防火墙](./img/firewall.png)
启动成功后将弹出成功提示,同时文本框会提示代理地址与端口:
![手动代理](./img/6.png)
例如,这里显示的代理地址为`192.168.3.31`,端口为`8081`。需要将该地址设置到手机中。以下说明以安卓手机为例:
打开手机,连接与电脑同一局域网的WiFi,长按选择修改网络,打开高级选项,选择代理模式为“手动”,将地址和端口分别填入,例如:
![手动代理图](./img/7.jpg)
然后保存设置。
随后完全退出游戏并重新进入。进入基地界面后,即可在“获取芯片数据”窗口中,准确填写UID和昵称信息,单击“获取数据”,即可读取到芯片数据。如弹出错误请按错误说明重试。

## 3. 设置重装小队参数
在主界面右上角,可以选择不同的重装小队以及对应的方案,例如AT4有“只用6格”和“使用5格”两种方案:
![AT4](./img/8.png)
另外也可以勾选“使用已锁定”按钮来在计算过程中使用游戏中锁定的芯片,而勾选“使用已装备”按钮会在计算过程中使用游戏中已经装备到重装小队上的芯片。
单击主界面右上角“设置”按钮,可以打开设置窗口。这里可以设置各个重装的目标属性格数以及要求解的方案数量。重装属性默认为公认的最优解,单击“重置”按钮可以恢复。
“自由”一栏表示最终方案允许的格数偏差值。
![设置](./img/9.png)
设置完成后,单击“开始计算”即可执行计算过程。

## 4. 查看方案
计算完成后,主界面将显示芯片方案如下:
![方案](./img/10.png)
单击左侧任意方案,会在右侧显示拼法图解以及所用到的芯片。
在左侧的方案列表中,四项属性是当前方案所有芯片满强化后的总属性,而括号中的数值是与属性上限的差值,如果溢出则为0。总偏差也是计算的所有不足的属性之和,溢出部分不计入。
也就是说,括号中的数值越大越好,总偏差越大(绝对值越小)越好。
总等级一列是该方案中所有芯片的强化等级,以供参考当前方案能节省多少强化资源。
校准券一列提供了当前方案需要消耗的校准券的参考值。可能存在误差。
单击表头可以按各列属性分别排序。

# 联系我
[GitHub](https://github.com/xxzl0130/CodeX)
[NGA](https://bbs.nga.cn/nuke.php?func=ucp&uid=41490180)
或者加入QQ群1042332676:
![QQ群](./img/group.png)

0 comments on commit ad245c8

Please sign in to comment.