请滑至最后查看该说明文档的个人翻译版!
Please scroll to the bottom of the page to check out the translated version of README!
以下说明仅适用于本分支。其它说明详见原存储库的main分支下的说明文档。
The following explanations only apply to the current branch. For other details (installation and prospects), please visit the README in the main branch of the original repository.
本程序集仅供学习和个人娱乐,不得用于其它盈利用途!
本程序集支持创建自定义房间(包括5v5训练模式)、检查可用电脑玩家和游戏模式以及其它探索性功能的开发。
克隆本存储库,需要本地至少有37 GB的存储空间。如果仅使用发行版中的压缩包,请保证本地至少有2 GB的存储空间。
关于自定义房间创建之外的脚本,请参阅第6点注意事项。
- 本程序集提供所有模式与电脑玩家难度设置和路线选择的整合版。
- 整合版采用的电脑玩家数据为主目录下的
available-bots.xlsx文件。因此请勿移动任何离线版文件和该xlsx文件。 - 整合简化版文件提供以下功能:
- 自定义游戏模式选择
- 电脑玩家自动随机生成
- 整合版文件提供以下功能:
- 队列房间循环创建
- 自定义房间游戏模式选择
- 游戏类型选择
- 游戏地图选择
- 允许观战策略选择
- 对局名设置
- 队伍规模选择
- 密码(可选)设置
- 电脑玩家路线和难度选择
在该文件中可以选择是否设定电脑玩家难度一致。 - 电脑玩家数量设置
- 模拟客户端行为
- 电脑玩家添加脚本允许用户在已经创建好的房间内添加电脑玩家而不覆盖原房间。仅此文件允许访问非官方电脑玩家数据。
- 整合版采用的电脑玩家数据为主目录下的
- 本程序集中的
check_available_gameMode.py提供检查可用游戏模式的功能。- 请勿在程序运行过程中创建自定义房间,否则可能输出实际不可创建的房间信息。
- 国服艾欧尼亚大区可创建自定义房间参数(游戏模式,地图序号):
- ("CLASSIC", 11)
- ("CLASSIC", 12)
- ("CLASSIC", 21)
- ("CLASSIC", 22)
- ("ARAM", 12)
- ("PRACTICETOOL", 11)
- ("TUTORIAL", 11)
- ("TUTORIAL", 12)
- ("TUTORIAL", 21)
- ("TUTORIAL", 22)
- ("GAMEMODEX", 11)
- ("GAMEMODEX", 12)
- ("GAMEMODEX", 21)
- ("GAMEMODEX", 22)
- 国服艾欧尼亚大区可创建自定义房间参数(游戏模式,地图序号):
- 本程序设置了默认的检测上下限。如有需要,请自行修改上下限。
- 请勿在程序运行过程中创建自定义房间,否则可能输出实际不可创建的房间信息。
- 本程序集中的
get_lobby_information.py提供反复获取房间信息的功能。 - 本程序集提供了离线数据资源,用于降低资源获取时间。
- 离线数据资源包含CommunityDragon数据库的latest和pbe文件夹下的所有文本文档和DataDragon数据库的dragontail存档压缩包的data文件夹下的所有中文和英文文件。
- CommunityDragon数据库的数据资源将跟随美测服的每一次调整而更新,更新周期以天计;DataDragon数据库的数据资源将跟随正式服的每一次停机更新而更新,更新周期以半个月计。
- 离线数据文件夹下的
自动更新离线数据脚本可简化离线数据资源更新过程。- 该脚本仅供开发者用于更新离线数据资源,感兴趣的用户可自行下载体验。
- 该脚本可用于更新CommunityDragon和DataDragon数据库的数据资源。
- 在更新CommunityDragon数据库的资源时,程序提供了2种模式。
- 【按修改时间更新】用于反映本地数据资源和在线数据资源的变化。
- 如果本地数据资源文件的修改时间晚于在线数据资源文件,而本地数据资源文件的内容实际上早于在线数据资源文件,那么这些数据资源文件不会更新。
- 该模式在存储库中被设置为默认模式。输入空字符串即采用默认模式。
- 【按程序需求更新】用于快速更新为程序所需要的数据资源。
- 该模式在发行版中被设置为默认模式。输入空字符串即采用默认模式。
- 【按修改时间更新】用于反映本地数据资源和在线数据资源的变化。
- 在更新DataDragon数据库的资源时,用户需要按照程序提示,先下载DataDragon数据库的最新压缩包,然后解压,并提供解压的目录。
- 在更新DataDragon数据库的资源时,程序提供了2种模式。
- 【全局扫描】可将本地存储库中的数据资源与下载到本地的最新DataDragon存档压缩包中的数据资源进行全面对比,实现数据资源的同步。
- 该模式在存储库中被设置为默认模式。输入空字符串即采用默认模式。
- 【按程序需求更新】用于快速更新为程序所需要的数据资源。
- 该模式在发行版中被设置为默认模式。输入空字符串即采用默认模式。
- 【全局扫描】可将本地存储库中的数据资源与下载到本地的最新DataDragon存档压缩包中的数据资源进行全面对比,实现数据资源的同步。
- 对于联网更新的资源,使用适当的代理可能加速数据资源的获取。
- 在更新CommunityDragon数据库的资源时,程序提供了2种模式。
- 由于每次更新可能涉及的数据资源较多,GitHub无法加载变化内容。以下推荐两种查看变化内容的方式:
- 访问英雄联盟版本更新存储库以在线查看主要更新内容。
- 将本仓库克隆到本地,并查看标题为“离线数据资源更新”的提交,以离线查看完整更新内容。
- 克隆该存储库需要占用大约37 GB的本地空间。请保证您的磁盘有足够的空间。
- 对于包含较多数据资源的更新的提交,本地加载仍然需要几分钟时间,请耐心等待。
- 离线数据资源包含CommunityDragon数据库的latest和pbe文件夹下的所有文本文档和DataDragon数据库的dragontail存档压缩包的data文件夹下的所有中文和英文文件。
- 本程序集起源于主目录下的
create_custom_lobby.py。
- 本程序集全部为Python程序,需要从Python官网中下载最新版本的Python。(不是最新版本也可,但不要太古早~)
- 初次安装Python,切记勾选
Add Python to PATH选项。 - 如果因为某些原因,系统环境变量PATH中没有Python的工作目录,可以按照如下步骤添加环境变量。
- 在Windows搜索框中输入
path,单击编辑系统环境变量,弹出系统属性窗口。 - 单击
环境变量(N),弹出环境变量窗口。 - 在
用户变量中,找到Path变量。双击,进入编辑环境变量对话框。 - 通过点击
新建(N)按钮,添加3个地址。这些地址是Python的工作目录。如果已存在类似的地址,就没有必要再加了。
C:\Users\[用户名]\AppData\Local\Programs\Python\Launcher\
C:\Users\[用户名]\AppData\Local\Programs\Python\Python[版本号]\
C:\Users\[用户名]\AppData\Local\Programs\Python\Python[版本号]\Scripts
如我的用户名是19250,使用的Python版本是3.13.3,则PATH中包含:
C:\Users\19250\AppData\Local\Programs\Python\Launcher\
C:\Users\19250\AppData\Local\Programs\Python\Python312\
C:\Users\19250\AppData\Local\Programs\Python\Python312\Scripts\ - 保险起见,可以在
系统变量的Path中也添加这三个地址。 - 重启已经打开的命令提示符或终端,即可正常使用Python工具。如pip。
- 在Windows搜索框中输入
- 安装完成并配置好环境变量后,需要使用
pip install [库名]命令安装本程序集所需的一些Python库。在科学上网的网络环境或者指定镜像的情况下,下载Python库应当会比国内环境快很多。本程序集所需的Python库有:- lcu_driver
- 本人复刻了[lcu_driver库]文件(https://github.com/WordlessMeteor/lcu-driver/tree/master/lcu_driver),以便相应的拉取请求在经过lcu_driver库的作者同意合并之前,或者被作者拒绝时,用户仍然可以下载体验本存储库的lcu_driver库文件。
- 本人只负责根据本程序集需要对该存储库中的库文件进行修改,没有义务将其它GitHub用户对库文件的修改与本人对库文件的修改进行合并。不过,欢迎任何用户基于本程序集的更新对库文件更新提出意见和建议👏
- 如果需要使用本人修改的lcu_driver库,请按照如下步骤进行。
- 打开本人的lcu-driver存储库主页。
- 单击绿色Code按钮,再单击DownloadZIP,下载本存储库的源代码。
- 将下载好的压缩包【解压到当前文件夹】。
- 不用担心解压完成之后会不会有一大堆文件分散在文件夹里面。从GitHub上下载的源代码应该已经放在了一个文件夹里面。
- 打开Python存储库的目录。
- 一般位于
C:\Users\[用户名]\AppData\Local\Programs\Python\Python[版本号]\Lib\site-packages。- 如我的用户名是
19250,使用的Python版本是3.13.3,则应打开
C:\Users\19250\AppData\Local\Programs\Python\Python312\Lib\site-packages。
- 如我的用户名是
- 如果上一条方法行不通,请先在命令行中输入
pip install lcu_driver以安装lcu_driver库,再使用Everything软件搜索lcu_driver关键字,从而定位到Python存储库的位置。
- 一般位于
- 在解压好的文件中找到
lcu_driver文件夹,将其复制到上面的目录中。如果提示文件已存在,请选择覆盖。 - 若要恢复原始lcu_driver库文件,请先在命令行中输入
pip uninstall lcu_driver,再输入pip install lcu_driver重新安装。
- openpyxl
- pandas
- requests
- pyperclip
- pickle
- urllib
- wcwidth
- bs4
- lcu_driver
- 初次安装Python,切记勾选
- 为提高响应速度,请在命令行环境中,而不是Python IDLE中使用本程序集。
- 为方便查看程序的返回信息,避免命令行一闪而过,建议先打开命令提示符(或终端),使用cd命令切换到程序集所在目录,再输入命令
python [文件名]或python -W ignore [文件名]以使用某个程序。
- 为方便查看程序的返回信息,避免命令行一闪而过,建议先打开命令提示符(或终端),使用cd命令切换到程序集所在目录,再输入命令
- 所有程序必须在登录英雄联盟客户端后运行。
- 本程序集所有打开的py文件均可通过Ctrl + C提前结束进程。一次不行来十次!
- 本程序集提供了一些自定义房间创建之外的功能,仅供娱乐。欢迎各位志同道合的小伙伴补充完善!
- 声明:请按照顺序为后来添加的脚本命名,格式为
Customized Program [数字] - [功能].py。 - 自定义脚本1返回通过lcu_driver库获取到的连接信息。
- 自定义脚本2参考了Mario开发的图形化界面的LeagueLobby中根据Json创建房间按钮的功能。使用时,需要先在文本编辑器中修改该文件中create_custom_lobby函数中的各参数的值,保存后再双击该文件以尝试创建房间。
- 若要查看创建房间后的返回信息,请选择先打开命令提示符或终端再输入
python [文件名]或python -W ignore [文件名]。
- 若要查看创建房间后的返回信息,请选择先打开命令提示符或终端再输入
- 自定义脚本3为探索LCU API提供了一个基础工具,将格式化的返回结果输出到同目录下的
temporary data.txt,并将变量以二进制的形式保存到同目录下的temporary data.pkl中。该程序中列出了一些参考的网络请求命令。所有可用API来自LCU Explorer。- 请参考示例输入。不合法的输入会导致程序直接退出。合法的输入格式有以下要求:
- 包含一或两个空格。
- 包含两个空格时,用户可以传入请求主体。
- 地址(输入字符串以空格作为分隔符分隔而成的列表的第二个字符串元素)以斜杠开头。
- 包含一或两个空格。
- 要在网页端而不是软件端查看所有LCU API,请访问Swagger或LCU Swagger UI。(如在浏览器中使用Ctrl + F以搜索API。)
- 请参考示例输入。不合法的输入会导致程序直接退出。合法的输入格式有以下要求:
- 自定义脚本4用于更新主目录下的
available-bots.xlsx文件。- 该工作簿包含3个工作表:
- Sheet1为训练模式中官方允许添加的电脑玩家信息。
- Sheet2为训练模式中可以添加到房间内的电脑玩家信息。
- 相比Sheet1,Sheet2中包含一般级难度的人机对战中的所有电脑玩家信息。
- Sheet3为英雄联盟全英雄信息。
- 一般情况下不需要用户自行更新英雄数据。我会保持更新。每次更新的依据是新英雄的发布。
- 该程序允许在客户端未运行时使用。此时只能获取全英雄信息。
- 该程序涉及以下数据资源:
- 该工作簿包含3个工作表:
- 自定义脚本5(☆)用于查询和导出召唤师战绩。
- 该脚本支持通过召唤师名称和玩家通用唯一识别码查询。
- 由于使用的是LCU API,在国服环境下,即使召唤师生涯不可见,仍然能够查询到该召唤师的全部对局记录和段位信息。
- 该脚本设置了一些命令行参数。通过
python [文件名] -h命令以查看这些参数。命令行参数 行为类型 描述 取值 -r
--reserve赋值为真 在对局不包含主玩家的情况下仍然加载该对局 无 -rt
--reserve_text赋值为真 在对局不包含主玩家的情况下仍然保存该对局 无 - 该脚本生成的文件位于主目录下的“召唤师信息(Summoner Information)”文件夹下。
- 该脚本所依赖的数据资源主要来自CommunityDragon数据库,支持离线获取。发行版中已经包含所有自定义脚本依赖的最新数据资源文件。如果没有这些文件,在离线获取时,请按照程序提示,在主目录下新建文件夹
离线数据(Offline Data),打开相应资源的网页,将相应的json文件下载到该文件夹下。 - 从13.22版本开始,美测服采用拳头ID来替代召唤师名称。因此,如果通过召唤师名称无法查询一名召唤师的信息,请尝试在玩家昵称后加上一个“#”,再加上昵称编号。
- 提示:在客户端中打开一个召唤师的生涯界面,将鼠标悬停在玩家昵称上,即可看到完整的带有昵称编号的拳头ID。单击即可复制。粘贴到生涯界面右上方的搜索栏即可搜索该玩家。
- 该脚本支持以下保存模式:
注:【扫描保存】和【扫描加载】统称【扫描模式】或【本地重查】。保存模式 定义 适用产品 实现步骤 完全保存 保存所有的对局信息和时间轴文本文档,并导出所有对局工作表 英雄联盟
云顶之弈英雄联盟:
1. “是否查询英雄联盟对局记录”,输入任意非空字符串以选择是
2. 输入“3”以批量查询全部对局
3. 输入任意非空字符串以自行指定对局索引上下限
4. 在设置需要查询的对局索引上下界时直接按回车
5. 直接按回车以输出每场对局的文本文档
6. 在计算每场对局要保存的工作表数量后,输入任意非空字符串以导出所有对局工作表
云顶之弈:
1. “是否查询云顶之弈对局记录”,输入任意非空字符串以选择是
2. 直接按回车以输出每场对局的文本文档
3. 输入任意非空字符串以重新保存所有对局的文本文档
4. 在计算每场对局要保存的工作表数量后,输入任意非空字符串以导出所有对局工作表完全加载 在不保存任何对局信息和时间轴文本文档的情况下,导出所有对局工作表 英雄联盟
云顶之弈英雄联盟:
5. 输入任意非空字符串以不输出每场对局的文本文档
其余步骤与【完全保存】相同
云顶之弈:
1. “是否查询云顶之弈对局记录”,输入任意非空字符串以选择是
2. 输入任意非空字符串以不输出每场对局的文本文档
3. 在计算每场对局要保存的工作表数量后,输入任意非空字符串以导出所有对局工作表批量保存 保存指定的上下界范围内的API中记录的对局信息和时间轴文本文档,并导出所有对局工作表 英雄联盟 英雄联盟:
1. “是否查询英雄联盟对局记录”,输入任意非空字符串以选择是
2. 输入“3”以批量查询全部对局
3. 输入任意非空字符串以自行指定对局索引上下限
4. 在设置需要查询的对局索引上下界时输入空格分隔的两个自然数
5. 直接按回车以输出每场对局的文本文档
6. 在计算每场对局要保存的工作表数量后,输入任意非空字符串以导出所有对局工作表批量加载 在不保存指定的上下界范围内的API中记录的对局信息和时间轴文本文档的情况下,导出所有对局工作表 英雄联盟 英雄联盟:
5. 输入任意非空字符串以不输出每场对局的文本文档
其余步骤与【批量保存】相同增补保存 保存本地未保存文本文档的对局的信息和时间轴文本文档,并导出这些对局的工作表 英雄联盟
云顶之弈英雄联盟:
1. “是否查询英雄联盟对局记录”,输入任意非空字符串以选择是
2. 输入“3”以批量查询全部对局
3. 直接按回车以只查询未保存过文本文档的对局
4. 直接按回车以输出每场对局的文本文档
5. 在计算每场对局要保存的工作表数量后,输入任意非空字符串以导出所有对局工作表
云顶之弈:
3. 直接按回车以只保存尚未保存过文本文档的对局
其余步骤与【完全保存】相同增补加载 在不保存任何本地未保存文本文档的对局的信息和时间轴文本文档的情况下,导出这些对局的工作表 英雄联盟 4. 输入任意非空字符串以输出每场对局的文本文档
其余步骤与【增补保存】相同列表保存 按照一个对局序号列表保存对局信息和时间轴文本文档,并导出这些对局的工作表 英雄联盟 1. “是否查询英雄联盟对局记录”,输入任意非空字符串以选择是
2. 输入一个由中括号包围、由半角逗号分隔的正整数列表作为对局序号列表
3. 直接按回车以输出每场对局的文本文档
4. 在计算每场对局要保存的工作表数量后,输入任意非空字符串以导出所有对局工作表列表加载 在不保存某个给定对局序号列表中的任何对局的信息和时间轴文本文档的情况下,导出这些对局的工作表 英雄联盟 3. 输入任意非空字符串以不输出每场对局的文本文档
其余步骤与【列表保存】相同扫描保存 扫描本地已保存的所有对局,重新查询这些对局的信息和时间轴,保存其文本文档并导出其工作表 英雄联盟 1. “是否查询英雄联盟对局记录”,输入任意非空字符串以选择是
2. 输入隐藏代码“scan”以扫描本地文件,获取对局序号
3. 直接按回车以开始对局记录重查,或者输入任意非空字符串以返回第2步
4. 直接按回车以输出每场对局的文本文档
5. 在计算每场对局要保存的工作表数量后,输入任意非空字符串以导出所有对局工作表扫描加载 扫描本地已保存的所有对局,重新查询这些对局的信息和时间轴,在不保存其文本文档情况下,导出其工作表 英雄联盟 4. 输入任意非空字符串以不输出每场对局的文本文档
其余步骤与【扫描保存】相同 - 在选择【完全保存】模式的情况下,生成的Excel文件中包含五大部分:
- 人物简介(单工作表)
- 排位信息(单工作表)
- 战区天梯(单工作表)
- 英雄成就(单工作表)
- 对局记录(五工作表)
- 近期一起玩过的英雄联盟玩家
- 近期一起玩过的云顶之弈玩家
- 英雄联盟对局记录
- 本地重查对局记录
- 云顶之弈对局记录
- 各对局详细信息(至多三工作表/对局)
- 对局信息
- 对局时间轴
- 对局事件
- 扫描模式(【本地重查】)说明:(要查看一些名词的含义,请看相应的提交记录描述。)
- 不建议使用该程序导出超过1600场正常对局(或5000场斗魂竞技场对局)的信息。
- 在运行扫描模式之前,先删除工作簿(到回收站)或重命名工作簿,这样防止原有文件较大而导致程序读取文件和导出工作表的时间过长。
- 【本地重查】目前只支持英雄联盟对局。
- 每次导出一名召唤师的战绩后,如果后续有自行整理的需求,请修改相应的对局记录工作表名,以防程序下次运行时会覆盖工作表导致数据丢失。例如在工作表名后添加“ - Manual”。
- 如果原工作簿较大,建议先备份原工作簿,再导出数据,以免导出过程因意外中断导致工作簿损坏。
- 该程序涉及以下数据资源:
- https://ddragon.leagueoflegends.com/api/versions.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/summoner-spells.json
- https://raw.communitydragon.org/{版本}/cdragon/tft/{语言}.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/champion-summary.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/cherry-augments.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/items.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/perks.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/perkstyles.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/tftchampions.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/tftitems.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/companions.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/tfttraits.json
- 该程序需要依据实际遇到的报错来更新异常修复部分的代码。欢迎各位开发者分享爬取过程中遇到的报错问题👏
- 自定义脚本6用于在美测服一键开启云顶之弈发条鸟的试炼模式,以获取3000点券。双击即可。
- 从2023年8月27日开始,云顶之弈1V0模式不再可用。
- 自定义脚本7用于获取商店中上架的商品信息和主召唤师的藏品信息。
- 该程序将商品和藏品信息输出到主召唤师文件夹下的
Store and Collections - {召唤师名称}.xlsx中。 - 商品信息中的缩略图路径是与LCU API相关的网址,需要在英雄联盟客户端启动的情况下才能打开。初次打开网站需要输入用户名和密码,请在该脚本的输出的最开始部分找到带有“riot”的一行,用户名为“riot”,密码为“riot”后面的一串字符串。
- 缩略图路径标为default.png的商品的缩略图尚未找到。
- 该程序涉及以下数据资源:
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/companions.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/skins.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/statstones.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/summoner-emotes.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/summoner-icons.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/tftdamageskins.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/tftmapskins.json
- https://raw.communitydragon.org/{版本}/plugins/rcp-be-lol-game-data/global/{语言}/v1/ward-skins.json
- 该程序将商品和藏品信息输出到主召唤师文件夹下的
- 自定义脚本8从来没有被寄予统计一个服务器上所有召唤师的数量的厚望。(因为人实在是太多了,并且遍历是最盲目的!)
- 自定义脚本9用于查询和导出当前服务器存在的游戏模式。
- 尝试在多个服务器上运行此程序,并比较开放的游戏模式。兴许你会发现自己可以在国测服玩到卡莎打一般难度的1v1人机的云顶之弈1v0狂暴模式。
- 自定义脚本10用于搜索指定召唤师进行过的对局。可以与自定义脚本5联动。
- 自定义脚本11用于查询与指定召唤师最近玩过的召唤师。
- 该脚本的大部分代码继承自自定义脚本5,包括扫描模式。但是该脚本只涉及结果的输出,不会修改自定义脚本5生成的任何中间文件(文本文档和json文件)。
- 该脚本设置了一些命令行参数。通过
python [文件名] -h命令以查看这些参数。命令行参数 行为类型 描述 取值 -r
--reserve赋值为真 在对局不包含主玩家的情况下仍然加载该对局 无 -ss
--save_self赋值为真 在对局包含主玩家的情况下仍然保存其数据 无 - 该脚本设置了【生成模式】和【检测模式】。
- 【生成模式】用于将某召唤师最近若干场对局中遇到的玩家保存到本地文件。将保存到前缀为“Summoner Profile”的工作簿的“Recently Player Summoners”工作表中,并导出8张关于玩家的游戏时长和对局数的柱状图。
- 【检测模式】用于查询玩家是否在以前的对局中遇到过。该脚本考虑了6种检测场景。不同场景的主体代码类似。
- 房间内/英雄选择阶段/游戏中
- 该场景返回主召唤师在房间内、英雄选择阶段和游戏中遇到的召唤师在历史对局中的信息。格式参考了自定义脚本5生成的对局信息的每一条记录。
- 该场景目前支持查询用户自己和英雄选择阶段、游戏中遇到的其它玩家的近期一起玩过的玩家。
- 注意:云顶之弈对局也是有英雄选择阶段的!只不过持续时间太短了。
- 由于英雄选择阶段和游戏中具有临时性,因此在该模式下,程序只会在主目录生成一个临时文件。
- 该场景在主目录下产生临时文件“Recently Played Summoners in Match {platformId}-{gameId}.xlsx”,{platformId}代表服务器代号,{gameId}代表对局序号。
- 好友列表
- 该场景返回好友在历史对局中的信息。
- 该场景在主目录下产生临时文件“Recently Played Summoners in Friend List of {current_summonerName} - {platformId}.xlsx”,{current_summonerName}代表主召唤师名,{platformId}代表服务器代号。
- 好友请求
- 该场景返回用户想要添加为好友的玩家和想要添加用户为好友的玩家在历史对局中的信息。
- 该场景在主目录下产生临时文件“Recently Played Summoners in Friend Requests of {current_summonerName} - {platformId}.xlsx”,{current_summonerName}代表主召唤师名,{platformId}代表服务器代号。
- 相比其它场景,该场景的工作表名中包含了好友关系方向的信息。其中,in表示该玩家想要加用户为好友。out则相反。
- 组队邀请
- 该场景返回向用户发起组队邀请者和用户发起组队邀请的对象在历史对局中的信息。
- 该场景在主目录下产生临时文件“Recently Played Summoners in Invitations to and from {current_summonerName} - {platformId}.xlsx”,{current_summonerName}代表主召唤师名,{platformId}代表服务器代号。
- 相比其它场景,该场景的工作表名中包含了邀请方向的信息。其中,in表示该玩家向用户发起组队邀请。out则相反。
- 聊天黑名单
- 该场景返回被用户拉黑的玩家在历史对局中的信息。
- 该场景在主目录下产生临时文件“Recently Played Summoners in Block List of {current_summonerName} - {platformId}.xlsx”,{current_summonerName}代表主召唤师名,{platformId}代表服务器代号。
- 任意玩家列表
- 该场景返回用户输入的玩家列表中的所有玩家在历史对局中的信息。
- 玩家列表的每个元素可以是召唤师名或者玩家通用唯一识别码。
- 该场景在主目录下产生临时文件“Recently Played Summoners in Specified Player List.xlsx”。
- 该场景返回用户输入的玩家列表中的所有玩家在历史对局中的信息。
- 房间内/英雄选择阶段/游戏中
- 在【检测模式】下,该脚本支持启用【小号模式】,允许用户添加同一个服务器上的其它账号。
- 和查战绩脚本相同,该脚本的扫描模式只适用于查询英雄联盟对局。
- 如果用户在英雄选择阶段因为某些原因(如命令行一闪而过、历史记录无法正常获取等)未能通过【检测模式】获取队友是否曾遇到过的信息,那么在游戏中还可以通过【单独查询】手动输入对局中的召唤师名称来检查曾经遇到过的玩家。
- 自美测服13.22版本,对于拳头代理的服务器上的玩家,只输入玩家昵称无法正常查询其信息。由于加载资源界面只呈现玩家昵称,这时可以等待游戏开始后在计分板中查看玩家昵称及其昵称编号。
- 该程序涉及的数据资源与查战绩脚本相同。
- 自定义脚本12用于整理战利品信息。
- 该脚本的最终结果是一个包含部分字段的二维表,保存在工作簿中。工作簿的生成路径参照查战绩脚本。
- 该脚本仅作数据的转换和整理,不作任何数据分析。如有需要,请自行使用Excel软件进行分析。
- 自定义脚本13用于爬取当前服务器的所有天梯数据。
- 该脚本生成的文件位于主目录下的“顶尖排位玩家(Ranked Apex)”文件夹下。
- 该脚本生成的Excel文件中包含两大部分:
- 赛季信息(双工作表)
- 赛季信息
- 赛季奖励进度追踪
- 天梯信息
- 胜点系列天梯元数据(单工作表)
- 天梯数据
- 胜点系列天梯数据
- 单人/双人
- 灵活 5v5
- 云顶之弈
- 双人作战(beta测试)
- 排名分系列天梯数据
- 狂暴模式
- 斗魂竞技场
- 胜点系列天梯数据
- 赛季信息(双工作表)
- 自定义脚本14用于秒进好友小队。
- 程序已添加使用限制。请勿滥用和篡改代码。
- 这个脚本可能并没有想象中那么好用。如果你实在想上车,建议运行脚本的同时鼠标也狂点“加入小队”按钮即将出现的地方。
- 自定义脚本15用于玩家在自定义对局中选择相同的英雄。该问题目前已被修复,因此你可以无视这个脚本。
- 自定义脚本16用于模拟英雄联盟客户端中与聊天服务相关的行为。
- 目前该脚本提供以下功能:
- 导出好友数据
- 管理好友分组
- 聊天
- 导出聊天记录
- 管理好友列表
- 发送组队邀请
- 管理组队邀请
- 观战
- 管理小队语音
- 管理黑名单
- 黑名单操作中植入了自定义无限火力专用模式,用于群成员管理。该模式作为隐藏功能。
- 目前该脚本提供以下功能:
- 自定义脚本17用于整理所有游戏类型信息。主要用于自定义房间创建请求的参数设置。
- 自定义脚本18用于梳理所有任务信息。
- 你可以用这个脚本来查看美测服点券任务。
- 自定义脚本19用于模拟客户端中符文配置和符文页操作。
- 目前该脚本提供以下功能:
- 查看所有符文信息
- 查看不同英雄、分路和地图的推荐符文
- 符文页管理
- 导出所有符文页
- 单符文页查看、编辑和导出
- 切换活动符文页
- 排序符文页
- 删除符文页
- 目前该脚本提供以下功能:
- 自定义脚本20用于批量汇总玩家战绩。
- 该脚本综合了查战绩脚本的查询功能和自定义脚本11的游戏状态检测功能,汇总了以下场景的玩家战绩:
- 英雄选择阶段信息可见的队友
- 游戏内的所有玩家
- 已经结束的对局内的所有玩家
- 该脚本在输出基本数据的同时,也会输出一些统计指标,参考了以下内容:
- 掌上英雄联盟的雷达图指标
- 电子竞技常用指标(战损比、参团率、分均经济、分均补刀、伤害转化率等)
- 该脚本为特定格式的数据添加了条件格式,以提升直观性。
- 战损比按照一位小数格式输出。
- 部分电子竞技统计指标按照三位小数格式输出。
- 占比数据按照两位小数的百分比格式输出。
- 位次数据设置了三色刻度。
- 胜负结果通过公式确定着色。“胜利”设置为绿色,“失败”设置为红色。
- 为了简化使用步骤,该脚本设置了一些命令行参数。通过
python [文件名] -h命令以查看这些参数。命令行参数 行为类型 描述 取值 -e
--save_early赋值为真 只导出早于查询对局的对局 无 -l
--locale存储变量 设置程序内定义的常量字典的语言。目前仅支持简体中文和美式英语 zh_CN(默认)
en_US-os
--open_after_save赋值为真 在成功保存文件后打开文件,不需要程序询问 无 --verbose 赋值为真 输出详细的对局加载进度和异常处理过程性提示 无 --nonverbose 赋值为真 只输出关键信息 无
- 该脚本综合了查战绩脚本的查询功能和自定义脚本11的游戏状态检测功能,汇总了以下场景的玩家战绩:
- 自定义脚本21用于模拟客户端中各个游戏状态下的操作。旨在解决客户端无法正常响应时的燃眉之急。
- 声明:该脚本不涉及任何自动化操作。
- 该脚本融合了前20个脚本的部分核心行为。如果想要体验完整功能,请确保自定义脚本19也在同目录下。
- 该脚本支持未登录、无状态、房间内、队列中、就位确认、英雄选择阶段、游戏内、重连状态、等待数据、赛后预结算和赛后结算阶段等状态的行为模拟。调试功能以外的所有支持的操作如下:(多次出现的操作只在第一次出现时展开其下级操作。)
- 未登录
- 调试客户端接口
- 客户端任务管理
- 窗口管理
- 显示窗口
- 最小化窗口
- 显示高亮通知
- 设置窗口尺寸
- 进程管理
- 启动用户体验界面
- 暂时关闭窗口
- 重新加载窗口
- 结束进程(!)
- 窗口管理
- 无状态
- 调试客户端接口
- 创建房间
- 创建小队
- 创建自定义房间
- 通过json创建
- 处理邀请
- 加入小队或自定义房间
- 小队
- 自定义房间
- 冠军杯赛
- 观战
- 聊天
- 客户端任务管理
- 房间内
- 调试客户端接口
- 管理小队
- 入队准备
- 选择位置(仅排位赛和极限闪击)
- 设置快速模式英雄选择(仅快速模式)
- 设置子阵营(仅斗魂竞技场)
- 切换就绪状态
- 云顶之弈赛前配置(仅云顶之弈)
- 查看社交排行榜
- 改变小队公开性
- 让小队仅能通过邀请来进入
- 将小队公开给好友
- 更换模式
- 创建小队
- 创建自定义房间
- 通过json创建
- 寻找对局
- 入队准备
- 管理自定义房间
- 添加电脑玩家
- 移除电脑玩家
- 交换队伍
- 切换观战状态(!)
- 更换模式
- 开始游戏
- 邀请玩家
- 聊天
- 成员管理
- 晋升为小队拥有者
- 将玩家移出小队
- 更改邀请权限
- 提供邀请权限
- 撤回邀请权限
- 输出房间信息
- 处理邀请
- 加入小队或自定义房间
- 退出房间
- 客户端任务管理
- 队列中
- 调试客户端接口
- 输出寻找对局信息
- 聊天
- 处理邀请
- 加入小队或自定义房间
- 退出队列
- 客户端任务管理
- 就位确认
- 接受
- 拒绝
- 输出就位确认阶段信息
- 客户端任务管理
- 英雄选择阶段
- 调试客户端接口
- 交换
- 选用顺序
- 查看
- 发送
- 分路
- 查看
- 发送
- 队友英雄
- 查看
- 发送
- 可用英雄池(替补席)
- 查看
- 发送
- 选用顺序
- 英雄选择
- 声明(不可用)
- 禁用
- 选择
- 重随
- 准备赛前配置
- 符文(需要自定义脚本19支持)
- 召唤师技能
- 皮肤
- 守卫(眼)皮肤
- 表情
- 召唤师图标
- 水晶枢纽终结特效
- 旗帜
- 徽章
- 冠军杯赛奖杯
- 静音玩家
- 聊天
- 其它
- 解锁全员战斗加成
- 设置最爱的分路英雄
- 清空静音玩家
- 退出英雄选择阶段
- 输出英雄选择会话
- 客户端任务管理
- 游戏中
- 聊天
- 客户端任务管理
- 重连
- 等待数据结算
- 赛后预结算阶段
- 调试客户端接口
- 赞誉其他玩家
- 查看票数
- 这次不行
- 输出荣誉投票信息
- 输出当前事件
- 聊天
- 客户端任务管理
- 赛后结算阶段
- 调试客户端接口
- 查看英雄成就点数更新情况
- 查看计分板数据
- 英雄联盟
- 云顶之弈
- 聊天
- 再来一局
- 离开
- 唤起荣誉投票界面
- 客户端任务管理
- 其它
- 未登录
- 在没有明确说明的情况下,输入“0”以返回上一层。
- 该脚本会在“cache”文件夹下创建缓存,以加快数据资源加载速度。
- 本地缓存有24小时的有效期。
- 用户可以重新加载数据资源以手动更新本地缓存。
- 读取缓存预计能节省10~30秒数据资源加载时间。
清除临时文件.bat用于清除自定义脚本产生的临时文件。目前可以清除自定义脚本03、05、10、11、17、19、20和21产生的临时文件。召唤师信息文件格式转换.bat用于将自定义脚本5产生的数据文档在txt和json格式之间重命名。- 大量数据文档的重命名可能导致文件资源管理器卡顿,因此请谨慎使用本脚本。
- 由于本脚本涉及中文字符,因此请先在命令行中使用
chcp 65001以切换代码活动页,再运行本脚本。 - 如果正常运行,命令行中会不断提示“1 file(s) moved”。可以使用Everything软件以查看“召唤师信息(Summoner Information)”文件夹中的txt文件数量。
- 尝试在Everything的搜索框中输入
"{文件夹路径}" .txt以查看某个文件夹下的txt文件列表,在窗口左下角即可看到符合条件的文件数量。- “{文件夹地址}”示例:
C:\Users\19250\Desktop\英雄联盟自定义房间创建\召唤师信息(Summoner Information)。
- “{文件夹地址}”示例:
- 尝试在Everything的搜索框中输入
- 装备脚本用于生成各版本的装备信息表。
- 该脚本的数据来源是DataDragon数据库和CommunityDragon数据库。
- 该脚本支持所有《英雄联盟》支持的语言。
- 该脚本支持两个数据库收录的所有版本。
- 该脚本生成的表格主要分为5个部分:
- 元数据
- 装备分类
- 游戏内详细信息
- 地图可用性(CommunityDragon收录的装备数据中无此类数据)
- 基础属性
- 如果想要批量冻结窗格和启用筛选,可以通过编写宏来一次性对所有表格固定表头。下面以Microsoft Excel为例进行示范。
- 在Excel中,依次单击“文件”—“选项”—“自定义功能区”,在右侧的“自定义功能区”中勾选“开发工具”。单击“确定”。
- 单击“开发工具”选项卡,再单击“Visual Basic”,打开VBA编辑器。
- 在新窗口的“工程 - VBAProject”子窗口中,右键单击“VBAProject ({工作簿名称})”,依次单击“插入”—“模块”。
- 在新的模块子窗口粘贴以下宏代码:
注:上面的宏对所有工作表都生效。如果只想对部分工作表生效,需要在for语句下方添加对工作表属性的判断语句,并将后续操作代码的缩进后移一层。 5. 关闭VBA编辑器,回到Excel窗口,单击“开发工具”选项卡中的“宏”。 6. 选择“FreezeTopRowsAndSelectA1”,然后点击“执行”。 7. 如果想要在保存更改的同时保存该宏,请另存为“.xlsm”格式。Sub FreezeAndFilterTopRowsAndColumns() Dim ws As Worksheet Dim lastCol As Long For Each ws In ThisWorkbook.Worksheets ws.Activate ' 选中该工作表 If ws.AutoFilterMode Then ws.AutoFilterMode = False ' 取消已经存在的筛选 ActiveWindow.FreezePanes = False ' 取消当前冻结窗格效果 ActiveWindow.SplitColumn = 0 ' 取消任何可能的列拆分 ActiveWindow.SplitRow = 0 ' 取消任何可能的行拆分 ws.Range("E3").Select ' 冻结前两行和前四列 ActiveWindow.FreezePanes = True ' 冻结窗格 ws.Range("A2").Select ' 移动光标到A2 lastCol = ws.Cells(2, ws.Columns.Count).End(xlToLeft).Column ' 确定第二行最后一个有内容的单元格的列数 ws.Range(ws.Cells(2, 1), ws.Cells(2, lastCol)).Select ' 选中从A2到最后一个有内容的单元格 Selection.AutoFilter ' 对选中范围应用筛选 ws.Range("A1").Select ' 光标初始化——选中A1单元格 Next ws End Sub
- 下面另外提供一些宏代码。
- 清除格式
Sub ClearFormat() Dim ws As Worksheet Dim lastCol As Long For Each ws In ThisWorkbook.Worksheets If InStr(ws.Name, "cdragon") > 0 Or ws.Name = "pbe" Or ws.Name = "latest" Then ' 筛选所有由CommunityDragon数据库产生的工作表 ws.Activate If ws.AutoFilterMode Then ws.AutoFilterMode = False ActiveWindow.FreezePanes = False ActiveWindow.SplitColumn = 0 ActiveWindow.SplitRow = 0 ws.Range("A1").Select End If Next ws End Sub
- 为方便查阅英雄联盟中的官方术语,在主目录中添加了一个翻译库脚本
trans.py。- 该脚本每次运行可以选择汇总和保存一种语言的翻译数据资源,并允许同时下载所有语言的翻译数据资源。
- 由于该脚本仅用于校正术语,其涉及的数据资源仅用于开发程序,而不适用于发行版。因此建议用户在存储库,而不是由发行版压缩包解压得到的文件夹中运行该脚本。
- 自定义脚本05、11、13、16、19、20和21在运行过程中可以将终端呈现的内容保存到本地日志中。见主目录下的“日志(Logs)”文件夹。
- 为方便理解自定义脚本中一些大型数据框的结构,在主目录中添加了一个工作簿
Customized Program Main Dataframe Structure.xlsx,以解释其生成过程。- 下面对查战绩脚本和自定义脚本20中的
LoLGame_info_df、自定义脚本11和聊天服务脚本中的recent_LoLPlayers_df和自定义脚本20中的LoLGame_stat_header的结构进行说明,以便说明一些设定。一些设定在后续解释中不再赘述。- 工作表
05 - LoLGame_info_header、11 - LoLGame_info_header、16 - LoLGame_info_header和20 - LoLGame_stat_header共有6列,其中前3列是主要数据区域。Index代表LoLGame_info_data的键的索引。Key代表LoLGame_info_data的键。Value代表LoLGame_info_data的值。DirectlyImport?代表从LCU API中获取数据形成数据框时是否需要对数据进行加工。打勾表示直接引用。OutputOrder代表输出为工作表时各数据的排列顺序。DisplayOrder代表在网页中显示时各数据的排列顺序。只有在网页中显示的表格对应的表头工作表才有这一列。
- 在该工作表中,主要数据区域设置了9~10种颜色。
- 无填充代表
Key不作为LCU API中任何变量的索引。 - 浅绿色代表
Key可以作为LoLGame_info的索引。 - 浅蓝色代表
Key可以作为LoLGame_info["participantIdentities"][participantId]的索引。 - 深蓝色代表
Key可以作为LoLGame_info["participantIdentities"][participantId]["player"]的索引。 - 深绿色代表
Key可以作为LoLGame_info["participants"][participantId]的索引。 - 橙色代表
Key可以作为LoLGame_info["participants"][participantId]["stats"]的索引。 - 紫色代表
Key来自LoLGame_info["teams"][teamId]["bans"]的索引。- 注意到其中不包含任何可直接作为索引的键。
- 黄色代表
Key可以直接作为LoLGame_info["participants"][participantId]["timeline"]的索引。 - 粉色代表
Key不作为LCU API中任何变量的索引。- 目前粉红色区域只包含
ally?,表示查询的玩家是否是主玩家的队友。在导出的工作表中,打勾表示该玩家是主玩家的队友。
- 目前粉红色区域只包含
- 灰色代表
Key来自LoLGame_info["participants"][participantId]["stats"]的索引。- 该部分数据主要通过比较和计算得出。
- 无填充代表
- 一些键被标记为无填充。这样的键不作为LCU API中任何变量的索引,但仍来自其填充色所代表的变量的索引。如
gameModeName不曾出现在对局信息的json对象中,但是实际上来自LoLGame_info,对应的是键"gameMode"。 - 要获取各个呈现顺序列表,只需要将表格以
OutputOrder或DisplayOrder作升序排列,然后复制Index列的单元格内容即可。
- 工作表
- 下面对查英雄脚本和游戏状态管理脚本中的
LoLChampions_df的结构进行说明。- 工作表
04 - LoLChampions_header (LCU)和21 - LoLChampions_header的主要数据区域设置了8种颜色。- 无填充代表
Key可以直接作为LoLChampions[championId]的索引。 - 浅蓝色代表
Key来自LoLChampions[championId]["ownership"]的索引。 - 深蓝色代表
Key来自LoLChampions[championId]["ownership"]["rental"]的索引。 - 浅绿色代表
Key来自LoLChampions[championId]["roles"]的索引。 - 橙色代表
Key来自LoLChampions[championId]["tacticalInfo"]的索引。 - 粉色代表
Key来自LoLChampions[championId]["passive"]的索引。 - 深绿色代表
Key来自LoLChampions[championId]["spells"][spell_index]的索引。 - 黄色代表
Key来自/lol-perks/v1/recommended-champion-positions接口。
- 无填充代表
- 工作表
04 - LoLChampions_header (ddr)的主要数据区域设置了7种颜色。- 无填充代表
Key可以直接作为LoLChampions[championId]的索引。 - 浅蓝色代表
Key来自LoLChampions[championId]["image"]的索引。 - 浅绿色代表
Key来自LoLChampions[championId]["tags"]的索引。 - 深蓝色代表
Key来自LoLChampions[championId]["info"]的索引。 - 橙色代表
Key可以作为LoLChampions[championId]["stats"]的索引。 - 粉色代表
Key来自LoLChampions[championId]["spells"][spell_index]的索引。 - 深绿色代表
Key来自LoLChampions[championId]["passive"]的索引。
- 无填充代表
- 工作表
04 - LoLChampions_header (cdr)的主要数据区域设置了7种颜色。- 无填充代表
Key可以直接作为LoLChampions[championId]的索引。 - 浅蓝色代表
Key来自LoLChampions[championId]["tacticalInfo"]的索引。 - 浅绿色代表
Key来自LoLChampions[championId]["playStyleInfo"]的索引。 - 深蓝色代表
Key来自LoLChampions[championId]["championTagInfo"]的索引。 - 深绿色代表
Key来自LoLChampions[championId]["roles"]的索引。 - 橙色代表
Key来自LoLChampions[championId]["passive"]的索引。 - 粉色代表
Key来自LoLChampions[championId]["spells"][spell_index]的索引。
- 无填充代表
- 工作表
- 下面对查战绩脚本中的
mastery_df的结构进行说明。- 工作表
05 - mastery_header的主要数据区域设置了4种颜色。- 蓝色代表
Key可以直接作为mastery[champion_iter]的索引。- 白字只包含
champion和alias,分别表示英雄的称号和名字。LCU API只提供了英雄序号。
- 白字只包含
- 浅绿色代表
Key来自mastery[champion_iter]["nextSeasonMilestone"]的索引。 - 深紫色代表
Key来自mastery[champion_iter]["nextSeasonMilestone"]["rewardConfig"]的索引。
- 蓝色代表
- 工作表
- 下面对查战绩脚本中的
ranked_df的结构进行说明。- 工作表
05 - ranked_header的Key都可作为ranked["queues"][Id]的索引。 - 注意到
OutputOrder列存在重复数据。造成这个现象的根本原因是云顶之弈狂暴模式的段位和其它排位模式的段位被记录在两个变量中,但是输出表格时期望输出在一列中,所以有一些原键的输出顺序相同。
- 工作表
- 下面对查战绩脚本中的
ladders_df的结构进行说明:- 工作表
05 - ladders_header的主要数据区域设置了4种颜色。- 无填充代表
Key可以直接作为ladders[ladderId]的索引。 - 浅蓝色代表
Key可以作为ladders[ladderId]["divisions"][divisionId]["standings"][standingId]的索引。 - 浅绿色代表
Key可以作为/lol-summoner/v2/summoners/puuid/{puuid}接口的索引。 - 橙色代表
Key不作为LCU API中任何变量的索引。
- 无填充代表
- 工作表
- 下面对查战绩脚本和自定义脚本11中的
LoLHistory_df的结构进行说明:- 工作表
05 - LoLHistory_header和11 - LoLHistory_header的主要数据区域设置了6种颜色。- 无填充代表
Key不作为LCU API中任何变量的索引。 - 浅蓝色代表
Key可以作为LoLHistory["games"]["games"]的索引。 - 浅绿色代表
Key可以直接作为LoLHistory["games"]["games"]["participantIdentities"][0]["player"]的索引。 - 橙色代表
Key可以作为LoLHistory["games"]["games"]["participants"][0]的索引。 - 深绿色代表
Key可以作为LoLHistory["games"]["games"]["participants"][0]["stats"]的索引。 - 紫色代表
Key可以直接作为LoLHistory["games"]["games"]["participants"][0]["timeline"]的索引。
- 无填充代表
- 工作表
- 下面对查战绩脚本中的
LoLGame_leaderboard_df和TFTGame_leaderboard_df和自定义脚本20中的social_leaderboard_df的结构进行说明。- 工作表
05 - LoLGame_leaderboard_header、05 - TFTGame_leaderboard_header和20 - social_leaderboard_header的主要数据区域设置了2种颜色。- 蓝色代表
Key可以作为participantInfo的索引。 - 无填充代表
Key可以作为participant_leaderboard的索引。
- 蓝色代表
- 工作表
- 下面对查战绩脚本中的
LoLGame_timeline_df的结构进行说明。- 工作表
05 - LoLGame_timeline_header的主要数据区域设置了4种颜色。- 蓝色代表
Key可以作为frames[frameId]的索引。 - 灰色代表
Key对应的值是自动生成的,不依赖于LCU API。 - 绿色代表
Key来自LoLGame_info的一些信息。 - 橙色代表
Key可以作为frames[frameId]["participantFrames"][participantId]的索引。
- 蓝色代表
- 工作表
- 下面对查战绩脚本中的
LoLGame_event_df的结构进行说明。- 工作表
05 - LoLGame_event_header的主要数据区域设置为无填充。- 暗红色字代表
Key可以直接作为events[timestamp]的索引。 - 一些键被标记为无填充。这样的键不作为LCU API中任何变量的索引,但仍来自其填充色所代表的变量的索引。如
item不曾出现在对局时间轴的json对象中,但是实际上来自LoLGame_timeline["frames"]["events"][eventId],对应的是索引"itemId"。
- 暗红色字代表
- 工作表
- 下面对查战绩脚本中的
TFTHistory_df、自定义脚本11和聊天服务脚本中的recent_TFTPlayers_df和自定义脚本20中的TFTGame_stat_header的结构进行说明。- 工作表
05 - TFTHistory_header、11 - TFTHistory_header、16 - TFTHistory_header和20 - TFTGame_stat_header的主要数据区域设置了5种颜色。- 无填充代表
Key不作为LCU API中任何变量的索引。 - 天蓝色代表
Key可以作为TFTHistory[gameIndex]["json"]的索引。 - 绿色代表
Key可以作为TFTHistory[gameIndex]["json"]["participants"]的索引。 - 粉红色代表
Key的前半部分来自TFTHistory[gameIndex]["json"]["participants"][participantId]["traits"]的索引,后半部分可以直接作为TFTHistory[gameIndex]["json"]["participants"][participantId]["traits"][trait_index]的索引。 - 深蓝色代表
Key的第一部分来自TFTHistory[gameIndex]["json"]["participants"][participantId]["units"]的索引。- 129~183之间的键的第二部分可以直接作为
TFTHistory[gameIndex]["json"]["participants"][participantId]["units"][unit_index]的索引。 - 184及以后的键第二部分来自
TFTHistory[gameIndex]["json"]["participants"][participantId]["units"][unit_index]["items"]的索引,第三部分可以直接作为TFTHistory[gameIndex]["json"]["participants"][participantId]["units"][unit_index]["items"][item_index]的索引。
- 129~183之间的键的第二部分可以直接作为
- 无填充代表
- 相比之下,工作表
05 - TFTGame_info_header和工作表05 - TFTHistory_header只差了前面9行内容。
- 工作表
- 下面对商品藏品信息整理脚本中的
catalog_df的结构进行说明。- 工作表
07 - catalog_header的主要数据区域设置了3种颜色。item是catalogList中的任意一个元素。- 无填充代表
Key可以直接作为item的索引。 - 蓝色代表
Key来自item["prices"][priceId]的索引。 - 绿色代表
Key来自item["prices"][priceId]["sale"]的索引。
- 无填充代表
- 工作表
- 下面对商品藏品信息整理脚本中的
store_df的结构进行说明。- 工作表
07 - store_header的主要数据区域设置了5种颜色。item是store中的任意一个元素。- 无填充代表
Key可以直接作为item的索引。 - 蓝色代表
Key可以直接作为item["localizations"][locale]的索引。 - 绿色代表
Key的后半部分可以作为item["prices"][priceId]的索引。 - 黄色代表
Key的后半部分可以直接作为item["sale"]的索引。 - 紫色代表
Key的后半部分来自item["sales"]["prices"][priceId]的索引。
- 无填充代表
- 工作表
- 下面对商品藏品信息整理脚本和游戏状态管理脚本中的
collection_df的结构进行说明。- 工作表
07 - collection_header和21 - collection_header的主要数据区域设置了2种颜色。item是collection中的任意一个元素。- 无填充代表
Key可以直接作为item的索引。 - 蓝色代表
Key作为item["payload"]的索引。
- 无填充代表
- 工作表
- 下面对队列查询脚本和自定义脚本20中的
queues_df的结构进行说明。- 工作表
09 - queues_header和20 - queues_header的主要数据区域设置了4种颜色。- 绿色代表
Key可以直接作为queues[id]的索引。 - 橙色代表
Key可以作为queues[id]["gameTypeConfig"]的索引。 - 蓝色代表
Key可以作为queues[id]["queueRewards"]的索引。
- 绿色代表
- 工作表
- 下面对自定义脚本11中的
recent_players_metaDf的结构进行说明。- 工作表
11 - recent_players_metadata_he(11 - recent_players_metadata_header)的主要数据区域设置为无填充。Key可以直接作为recent_players_metadata_list的索引。
- 工作表
- 下面对整理战利品脚本中的
player_loot_df的结构进行说明。- 工作表
12 - player_loot_header的主要数据区域未设置颜色,因为这些键都可作为player_loot[i]的索引。
- 工作表
- 下面对查天梯脚本中的
splits_info_df的结构进行说明。- 工作表
13 - splits_info_header的主要数据区域设置了4种颜色。- 青绿色代表
Key可以作为splitsConfig["splits"][splitId]的索引。 - 浅绿色代表
Key来自splitsConfig["splits"][splitId]["victoriousSkinRewardGroup"]的索引。 - 橙色代表
Key来自splitsConfig["splits"][splitId]["victoriousSkinRewardGroup"]["splitPointsByHighestSeasonTier"]的索引。
- 青绿色代表
- 工作表
- 下面对查天梯脚本中的
rewardTrack_df的结构进行说明。- 工作表
13 - rewardTrack_header的主要数据区域设置了3种颜色。- 浅蓝色代表
Key可以直接作为splitsConfig["splits"][splitId]的索引。 - 橙色代表
Key对应的值是自动生成的,不依赖于LCU API。 - 浅绿色代表
Key可以作为splitsConfig["splits"][splitId]["rewardTrack"][rewardTrackId]["rewards"][rewardId]的索引。
- 浅蓝色代表
- 工作表
- 下面对查天梯脚本中的
challenger_ladders_metadata_df的结构进行说明。- 工作表
13 - challenger_ladders_metadat(13 - challenger_ladders_metadata_header)的主要数据区域设置了2种颜色。- 浅蓝色代表
Key可以作为ladders的索引。 - 浅绿色代表
Key可以作为ladders["divisions"][divisionId]的索引。
- 浅蓝色代表
- 工作表
- 下面对查天梯脚本中的
ladders_df["challenger_ladder"][queueType]的结构进行说明。- 工作表
13 - challenger_ladders_header的主要数据区域设置了2种颜色。- 无填充代表
Key可以作为ladders["divisions"][divisionId]["standings"][standingId]的索引。 - 浅蓝色代表
Key可以作为/lol-summoner/v2/summoners/puuid/{puuid}接口的索引。
- 无填充代表
- 工作表
- 下面对查天梯脚本中的
ladders_df["topRated_ladder"][queueType]的结构进行说明。- 工作表
13 - topRated_ladders_header的主要数据区域设置了2种颜色。- 无填充代表
Key可以直接作为ladders["standings"][standingId]的索引。 - 浅蓝色代表
Key可以作为/lol-summoner/v2/summoners/puuid/{puuid}接口的索引。
- 无填充代表
- 工作表
- 下面对聊天脚本中的
friend_hovercard_df的结构进行说明。- 工作表
16 - friend_hovercard_header的主要数据区域设置了4种颜色。friend是friends中的任意一个元素。- 蓝色代表
Key可以作为friend的索引。 - 浅绿色代表
Key可以作为friend["lol"]的索引。 - 橙色代表
Key的后半部分可以作为eval(friend["lol"]["pty"])的索引。 - 绿色代表
Key的后半部分可以作为eval(friend["lol"]["regalia"])的索引。
- 蓝色代表
- 工作表
- 下面对聊天脚本中的
friend_hovercard_df_simple的结构进行说明。- 工作表
16 - friend_hovercard_header_si(16 - friend_hovercard_header_simple)的主要数据区域设置为无填充。friend是friends中的任意一个元素。Key可以直接作为friend的索引。
- 工作表
- 下面对聊天脚本中的
friend_groups_df的结构进行说明。- 工作表
16 - friend_groups_header的主要数据区域设置为无填充。group是friend_groups中的任意一个元素。Key可以直接作为group的索引。
- 工作表
- 下面对聊天脚本和游戏状态管理脚本中的
conversation_df的结构进行说明。- 工作表
16 - conversation_header和21 - conversation_header的主要数据区域设置为无填充。conversation是conversations中的任意一个元素。Key可以直接作为conversation的索引。
- 工作表
- 下面对聊天脚本中的
message_df的结构进行说明。- 工作表
16 - message_header的主要数据区域设置为无填充。message是messages中的任意一个元素。Key可以作为message的索引。- 9之前的键可以直接作为
message的索引。 - 9及以后的键通过
get_info函数得到。
- 9之前的键可以直接作为
- 工作表
- 下面对聊天脚本中的
friend_request_df的结构进行说明。- 工作表
16 - friend_request_header的主要数据区域设置为无填充。friend_request是friend_requests中的任意一个元素。Key可以作为friend_request的索引。- 10之前的键可以直接作为
friend_request的索引。 - 10号键的后半部分可以直接作为
summonerIcons[friend_request["icon"]]的索引。
- 10之前的键可以直接作为
- 工作表
- 下面对聊天脚本中的
party_df的结构进行说明。- 工作表
16 - party_header的主要数据区域设置为4种颜色。party是parties中的任意一个元素。- 蓝色代表
Key可以直接作为party的索引。 - 浅绿色代表
Key的后半部分可以直接作为queues[party["queueId"]]的索引。 - 橙色代表
Key来自party的索引。 - 黄色代表
Key不作为LCU API中任何变量的索引。- 目前黄色区域只包含
full?,表示小队是否满员。在导出的工作表中,打勾表示小队已经满员。
- 目前黄色区域只包含
- 蓝色代表
- 工作表
- 下面对聊天脚本和游戏状态管理脚本中的
invid_df的结构进行说明。- 工作表
16 - invid_header和21 - invid_header的主要数据区域设置为3种颜色。invid是receivedInvitations中的任意一个元素。- 蓝色代表
Key可以作为invid的索引。 - 浅绿色代表
Key可以直接作为invid["gameConfig"]的索引。 - 橙色代表
Key的后半部分来自queues的索引。
- 蓝色代表
- 工作表
- 下面对聊天脚本中的
muted_player_df的结构进行说明。- 工作表
16 - player_mute_header的主要数据区域设置为无填充。muted_player是muted_players中的任意一个值。Key可以作为muted_player的索引。- 5之前的键可以直接作为
muted_player的索引。 - 5及以后的键通过
get_info函数得到。
- 5之前的键可以直接作为
- 工作表
- 下面对聊天脚本中的
champSelect_team_df和游戏状态管理脚本中的players_df的结构进行说明。- 工作表
16 - champSelect_team_header、20 - champSelect_players_header和21 - champSelect_players_header的主要数据区域设置为无填充。player是players中的任意一个值。Key可以作为player的索引。
- 工作表
- 下面对聊天脚本中的
captureDevices_df的结构进行说明。- 工作表
16 - captureDevices_header的主要数据区域设置为无填充。device是captureDevices中的任意一个值。Key可以直接作为device的索引。
- 工作表
- 下面对聊天脚本中的
voiceSettings_df的结构进行说明。- 工作表
16 - voiceSettings_header的主要数据区域设置为无填充。Key可以作为device的索引。- 12之前的键可以直接作为
device的索引。 - 12号键通过
captureDevices得到。
- 12之前的键可以直接作为
- 该数据框沿用了旧版数据框创建方式。见查战绩脚本的
info_data定义。
- 工作表
- 下面对聊天脚本中的
participant_record_df的结构进行说明。- 工作表
16 - participant_record_header的主要数据区域设置为无填充。participant是participant_records中的任意一个元素。Key可以作为participant的索引。- 8之前的键可以直接作为
participant的索引。 - 9和10号键通过
get_info函数得到。
- 8之前的键可以直接作为
- 工作表
- 下面对聊天脚本中的
blockList_df的结构进行说明。- 工作表
16 - blockList_header的主要数据区域设置为无填充。player是blockList中的任意一个元素。Key可以作为player的索引。- 8之前的键可以直接作为
player的索引。 - 8号键的后半部分可以作为键的前半部分所指数据资源的索引。
- 8之前的键可以直接作为
- 工作表
- 下面对游戏类型检查脚本中的
gametype_config_df的结构进行说明。- 工作表
17 - gametype_config_header的主要数据区域设置为无填充。config是gametype_config中的任意一个元素。Key可以直接作为config的索引。
- 工作表
- 下面对任务脚本中的
mission_df的结构进行说明。- 工作表
18 - mission_header的主要数据区域设置了6种颜色。mission是missions中的任意一个元素。- 无填充代表
Key可以作为mission的索引。 - 蓝色代表
Key的后半部分可以直接作为mission["display"]的索引。 - 浅绿色代表
Key来自mission["metadata"]的索引。 - 深绿色代表
Key的后半部分可以直接作为mission["rewardStrategy"]的索引。 - 橙色代表
Key来自mission["objective"][objectiveId]的索引。 - 紫色代表
Key的后半部分来自objective的索引。 - 蓝色、浅绿色、深绿色和橙色部分采用同一套代码框架。
- 无填充代表
- 工作表
- 下面对任务脚本中的
objective_group_df的结构进行说明。- 工作表
18 - objective_group_header的主要数据区域设置了2种颜色。objective是objectives中的任意一个元素。objectiveGroup是objective["objectives"]中的任意一个元素。- 无填充代表
Key可以作为objective的索引。 - 蓝色代表
Key的后半部分可以作为objectiveGroup的索引。
- 无填充代表
- 工作表
- 下面对符文脚本中的
perk_df的结构进行说明。- 工作表
19 - perk_header的主要数据区域设置为无填充。perk是perks中的任意一个元素。Key可以作为perk的索引。
- 工作表
- 下面对符文脚本中的
recommendedPage_df的结构进行说明。- 工作表
19 - recommendedPage_header的主要数据区域设置了3种颜色。page是recommendedPages中的任意一个元素。- 无填充代表
Key可以作为page的索引。 - 蓝色代表
Key的后半部分可以直接作为page["keystyone"]的索引。 - 绿色代表
Key来自page["perks"][perkId]的索引。
- 无填充代表
- 工作表
- 下面对符文脚本和游戏状态管理脚本中的
perkPage_df的结构进行说明。- 工作表
19 - perkPage_header和21 - perkPage_header的主要数据区域设置了3种颜色。page是perkPages中的任意一个元素。- 无填充代表
Key可以作为page的索引。 - 蓝色代表
Key的后半部分可以直接作为page["pageKeystone"]的索引。 - 绿色代表
Key来自page["uiPerks"][pageId]的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本20中的
inGame_players_df的结构进行说明。- 工作表
20 - inGame_players_header的主要数据区域设置了2种颜色。player是teamOne + teamTwo中的任意一个元素。loadout是player的赛前配置。- 无填充代表
Key可以作为player的索引。 - 蓝色代表
Key可以作为loadout的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本20中的
process_df的结构进行说明。- 工作表
20 - process_header的主要数据区域设置了2种颜色。- 无填充代表
Key不作为任何变量的索引。 - 蓝色代表
Key可以直接作为parent和child的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本21中的
swaps_df的结构进行说明。- 工作表
21 - swaps_header的主要数据区域设置为无填充。Key可以直接作为swap的索引。
- 工作表
- 下面对自定义脚本21中的
custom_game_df的结构进行说明。- 工作表
21 - custom_game_header的主要数据区域设置为无填充。lobby是custom_lobbies中的任意一个元素。Key可以作为lobby的索引。
- 工作表
- 下面对自定义脚本21中的
skins_df的结构进行说明。- 工作表
21 - skins_header的主要数据区域设置了6种颜色。skin是championSkins.values()中的任意一个元素。skin_flat是skins_flat.values()中的任意一个元素。- 无填充代表
Key可以直接作为skin的索引。 - 浅绿色代表
Key来自skin["emblems"]。- 29和30号键的后半部分可以直接作为
skin["emblems"]的索引。 - 31和32号键的后半部分可以直接作为
skin["emblems"][emblemIndex]["emblemPath"]的索引。
- 29和30号键的后半部分可以直接作为
- 深绿色代表
Key的后半部分可以直接作为skin["questSkinInfo"]的索引。 - 黄色代表
Key来自skin_flat。- 41~44号键可以直接作为
skin_flat的索引。 - 45~47号键的后半部分可以直接作为
LoLChampions[skin_flat["championId"]]的索引。
- 41~44号键可以直接作为
- 浅蓝色代表
Key的后半部分可以直接作为skin_flat["ownership"]的索引。 - 深蓝色代表
Key的第三部分可以作为skin_flat["ownership"]["rental"]的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本21中的
grid_champion_df的结构进行说明。- 工作表
21 - grid_champion_header的主要数据区域设置了2种颜色。champion是grid_champions中的任意一个元素。- 无填充代表
Key可以作为champion的索引。 - 蓝色代表
Key可以直接作为champion["selectionStatus"]的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本21中的
muted_player_df的结构进行说明。- 工作表
21 - muted_player_header的主要数据区域设置为无填充。player是muted_players中的任意一个元素。Key可以作为player的索引。- 0~3号键可以直接作为
player的索引。 - 4和5号键可以直接作为
player_info["body"]的索引。
- 0~3号键可以直接作为
- 工作表
- 下面对自定义脚本21中的
social_leaderboard_df的结构进行说明。- 工作表
21 - social_leaderboard_header的主要数据区域设置为无填充。player是social_leaderboard["rowData"]中的任意一个元素。Key可以作为player的索引。- 0~15号键可以直接作为
player的索引。 - 16和17号键的后半部分可以直接作为
summonerIcons[player["profileIconId"]]的索引。
- 0~15号键可以直接作为
- 工作表
- 下面对自定义脚本21中的
availableBot_df的结构进行说明。- 工作表
21 - availableBot_header的主要数据区域设置了2种颜色。bot是available_bots中的任意一个元素。- 无填充代表
Key可以直接作为bot的索引。 - 蓝色代表
Key可以直接作为LoLChampions[bot["id"]]的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本21中的
member_df的结构进行说明。- 工作表
21 - member_header的主要数据区域设置为无填充。member是members中的任意一个元素。Key可以作为member的索引。
- 工作表
- 下面对自定义脚本21中的
ballot_player_df的结构进行说明。- 工作表
21 - ballot_player_header的主要数据区域设置为无填充。player是honor_ballot["eligibleAllies"] + honor_ballot["eligibleOpponents"]中的任意一个元素。Key可以作为player的索引。
- 工作表
- 下面对自定义脚本21中的
eog_mastery_update_df的结构进行说明。- 工作表
21 - eog_mastery_update_header的主要数据区域设置为无填充。Key可以作为mastery_updates的索引。- 0~18号键可以直接作为
mastery_updates的索引。 - 19~21号键的后半部分可以直接作为
LoLChampions[mastery_updates["championId"]]的索引。 - 22和23号键的后半部分可以直接作为
player_info["body"]的索引。
- 0~18号键可以直接作为
- 工作表
- 下面对自定义脚本21中的
eog_stat_metaDf_lol的结构进行说明。- 工作表
21 - eog_stat_metadata_lol_head(21 - eog_stat_metadata_lol_header)的的主要数据区域设置了4种颜色。- 无填充代表
Key可以作为eog_stats_block的索引。 - 蓝色代表
Key的后半部分可以直接作为eog_stats_block["mucJwtDto"]的索引。 - 绿色代表
Key的后半部分可以直接作为eog_stats_block["rerollData"]的索引。 - 橙色代表
Key的后半部分可以作为eog_stats_block["teamBoost"]的索引。 - 蓝色、绿色和橙色部分采用同一套代码框架。
- 无填充代表
- 工作表
- 下面对自定义脚本21中的
eog_teamstat_df_lol的结构进行说明。- 工作表
21 - eog_teamstat_data_lol_head(21 - eog_teamstat_data_lol_header)的主要数据区域设置了2种颜色。team是eog_stats_block["teams"]中的任意一个元素。- 无填充代表
Key可以作为team的索引。 - 蓝色代表
Key的后半部分可以作为team["stats"]的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本21中的
eog_playerstat_df_lol的结构进行说明。- 工作表
21 - eog_playerstat_data_lol_he(21 - eog_playerstat_data_lol_header)的主要数据区域设置了2种颜色。team是eog_stats_block["teams"]中的任意一个元素。player是team["players"]中的任意一个元素。- 无填充代表
Key可以作为player的索引。 - 蓝色代表
Key的后半部分可以作为player["stats"]的索引。
- 无填充代表
- 工作表
- 下面对自定义脚本21中的
eog_stat_metaDf_tft的结构进行说明。- 工作表
21 - eog_stat_metadata_tft_head(21 - eog_stat_metadata_tft_header)的主要数据区域设置为无填充。Key可以作为tft_eog_stats的索引。
- 工作表
- 下面对自定义脚本21中的
eog_stat_df_tft的结构进行说明。- 工作表
21 - eog_playerstat_data_tft_he(21 - eog_playerstat_data_tft_header)的主要数据区域设置了7种颜色。player是tft_eog_stats["players"]中的任意一个元素。- 无填充代表
Key可以作为player的索引。- 0~14号键可以直接作为
player的索引。 - 15和16号键的后半部分可以直接作为
summonerIcons[player["iconId"]]的索引。
- 0~14号键可以直接作为
- 绿色代表
Key的后半部分可以直接作为player["augments"][augmentIndex]的索引。 - 橙色代表
Key的后半部分可以直接作为player["boardPieces"][unit_index]的索引。 - 蓝色代表
Key的第三部分可以直接作为player["boardPieces"][unit_index]["items"][item_index]的索引。 - 紫色代表
Key的后半部分可以直接作为player["companion"]的索引。 - 黄色代表
Key的后半部分可以直接作为player["customAugmentContainer"]的索引。 - 粉色代表
Key的后半部分可以直接作为player["playbook"]的索引。 - 紫色、黄色和粉色部分采用同一套代码框架。
- 无填充代表
- 工作表
- 下面对装备脚本中的
LoLItem_df的元数据进行说明。- 工作表
Item Program - base_header (ddr的主要数据区域设置了3种颜色。item是LoLItems_locale["data"]的键为i的值。item_default是LoLItems_default["data"]的键为i的值。- 无填充代表
Key不作为装备数据中的任何索引。 - 蓝色代表
Key可以作为item的索引。 - 绿色代表
Key来自item["gold"]的索引。
- 无填充代表
- 工作表
Item Program - base_header (ddr的主要数据区域设置为无填充。item是LoLItems_locale中的任意一个元素。item_default是LoLItems_default中的任意一个元素。Key可以作为item的索引。
- 工作表
- 下面对查战绩脚本和自定义脚本20中的
- 声明:请按照顺序为后来添加的脚本命名,格式为
- 一般情况下,本程序集生成的包含json数据的文本文档都是带缩进的。如果需要根据这些文件复现python运行环境中的字典变量,只需要向json库中的load函数传入一个由open函数创建的文件指针即可。如
fp = open("{文件名}.txt", "r", encoding = "utf-8")和d = json.load(fp)。- 若要在运行环境中将dumps函数生成的带缩进的json字符串转换成不带缩进的json字符串,只需要将dumps函数生成的字符串传入loads函数即可。如
formatted = json.dumps({字典变量}, indent = 8, ensure_ascii = False)和d = json.loads(formatted)。
- 若要在运行环境中将dumps函数生成的带缩进的json字符串转换成不带缩进的json字符串,只需要将dumps函数生成的字符串传入loads函数即可。如
作为初学者,我只学习到了Python的一些基本语法,还是在基于结构化程序设计的思想来实现每一个功能,而没有用到类和对象的概念,导致代码的整合程度不高,存在大量冗余的代码。例如查询召唤师战绩的脚本中,存在大量复制的现象。对于长字符串,我的处理方法是一行写到底,是基于缩减代码行数的考虑,可能不利于代码的浏览,还请见谅!另外,本程序集的注释尚不充足,还需要进一步完善。由于尚未学习图形化界面相关的知识(唯一学过的就是VB了😂),我只能设计这种通过命令行来实现功能的程序。(y1s1,现在并没有设计图形化界面的打算。)
整个程序集中的程序,除了参考知乎博主XHXIAIEIN的学习心得和拳头官方公布的接口,其实没有什么创新点,主要就是一个数据的爬取和整理。如果大家有什么好玩的想法,也欢迎复刻本存储库,并创建属于你自己的分支和提交拉取请求!
未来如果有机会,也许会根据查战绩脚本生成的对局信息数据框,结合WeGame或者OP.GG评分来回归得到现有对局表现评分机制。
(The following content is the English version of README.)
This program set only supports study use or personal entertainment. Any commercial use is forbidden!
This program set allows creating custom lobbies (including 5V5 Practice Tool), checking available bot players and game modes and development of other exploratory functions.
Cloning this repository requires about 37 GiB local storage. The compressed file in release takes up about 2 GiB local storage.
For details about customized programs that is beyond the scope of creating a custom lobby, please check the sixth instruction.
- This program set provides the consolidated version for all game modes and all levels and positions of bot difficulity.
- The consolidated version takes
available-bots.xlsxin the home directory as the bot player data. For its sake, please don't move any offline files (this file included). - The simplified consolidated version has the following features:
- Custom Game mode selection
- Random generation of bot players
- The consolidated version has the following features:
- Queue lobby over-creation
- Custom game mode selection
- Game mutator selection
- Game map selection
- Spectator policy selection
- Lobby name configuration
- Team size selection
- Password (optional) configuration
- Bot position and difficulty selection
By this file, the user may decide whether to set all bots' difficulty the same. - Bot number configuration
- Client action simulation
- The bot adding program allows users to add bot players to already created lobbies, instead of recreating another lobby and clearing all players. Only this file is allowed to visit unofficial bot player information.
- The consolidated version takes
- In this program set,
check_available_bots.pyandcheck_available_gameMode.pyprovide the functions of checking available bot players and game modes, respectively.- Please don't create any custom lobby while the program is running, in case unavailable lobbies may be output.
- Available custom lobby parameters on Chinese Ionia server (gameMode, mapId):
- ("CLASSIC", 11)
- ("CLASSIC", 12)
- ("CLASSIC", 21)
- ("CLASSIC", 22)
- ("ARAM", 12)
- ("PRACTICETOOL", 11)
- ("TUTORIAL", 11)
- ("TUTORIAL", 12)
- ("TUTORIAL", 21)
- ("TUTORIAL", 22)
- ("GAMEMODEX", 11)
- ("GAMEMODEX", 12)
- ("GAMEMODEX", 21)
- ("GAMEMODEX", 22)
- Available custom lobby parameters on Chinese Ionia server (gameMode, mapId):
- The detection range has been set to some values by default. For users' own requirements, please modify the ranges.
- Please don't create any custom lobby while the program is running, in case unavailable lobbies may be output.
- In this program set,
get_lobby_information.pyallows repeatedly getting lobby information. - This program set provides offline data resources to save the time of preparing data.
- The data resources include all text files under latest and pbe folders of CommunityDragon database and all Chinese and English files under data folder of the dragontail archived file of DataDragon database.
- The update of data resources in CommunityDragon database will follow each adjustment of PBE daily, and the update of data resources in DataDragon database will follow each patch mainteinance of live servers about every fortnight.
自动更新离线数据.pyunder the离线数据(Offline Data)folder simplifies the updating process of data resources.- This program is designed only for the developer to update offline data, but anyone interested is welcome to download and experience it.
- This program can be used to update data resources from both CommunityDragon and DataDragon databases.
- While updating CommunityDragon data resources, the program provides 4 updating modes.
- [Updating According to Modification Time] is meant to reflect the changes between online and local data resources.
- In a case where the modification times of some local data resources are later than those of the corresponding online data resources, whereas the actual content of these local data resources is earlier than that of their corresponding online data resources, running this mode won't update these local data resources.
- This mode is set as the default mode in the repository. Submit an empty string to adopt the default mode.
- [Updating According to Program Demands] is meant to quickly update the data resources only necessary for customized programs.
- This mode is set as the default mode in the releases. Submit an empty string to adopt the default mode.
- [Updating According to Modification Time] is meant to reflect the changes between online and local data resources.
- While updating DataDragon data resources, users need to follow the hint of the program: first download the latest compressed tarball of DataDragon database, then decompress it, and finally provide the decompression directory.
- While updating DataDragon data resources, the program provides 2 updating modes.
- [Global Scanning] performs an entire comparison on the data resources between the local repository and the latest DataDragon archive compressed file that has already been downloaded to local.
- This mode is set as the default mode in the repository. Submit an empty string to adopt the default mode.
- [Updating According to Program Demands] is meant to quickly update the data resources only necessary for customized programs.
- This mode is set as the default mode in the releases. Submit an empty string to adopt the default mode.
- [Global Scanning] performs an entire comparison on the data resources between the local repository and the latest DataDragon archive compressed file that has already been downloaded to local.
- For resources updated online, an appropriate proxy may accelerate the data capture process.
- While updating CommunityDragon data resources, the program provides 4 updating modes.
- Because a number of data resources might be involved in a commit, GitHub can't load the diff. Here two methods of checking the diff are recommended:
- Visit LoL-Patch-Change repository to look over the main update content online.
- Clone this repository to local and check the commit with header "Offline Data Resource Update" to look through the complete update content offline.
- Cloning this repository takes up approximately 37 GiB local space. Please ensure your disk has sufficient space for it.
- For those commits that involve a number of data resources, it still takes several minutes to load the diff locally. Please wait in patience.
- The data resources include all text files under latest and pbe folders of CommunityDragon database and all Chinese and English files under data folder of the dragontail archived file of DataDragon database.
- The program set is adapted from
create_custom_lobby.pyin the home directory.
- The whole program set is made of Python programs. Users are highly suggested to download the latest version of Python from Python official website. (A version that isn't latest is also OK, but please make sure it's not too early, either [xD])
- For this first time of installation of Python, please tick on
Add Python to PATHoption. - If the working directories of Python aren't present in the environment variable Path, the following steps can be adopted to add Python to Path.
- Type in
pathin Windows search bar and click编辑系统环境变量.系统属性window will pop up. - Click
环境变量(N)button and the环境变量window will occur. - In
用户变量, Find the variablePathand double-click it to enter the编辑环境变量dialog box. - Add 3 addresses by clicking the
新建(N)button. These addresses are working directories of Python. If some similar addresses already exist, there's no need to add them.
C:\Users\[Username]\AppData\Local\Programs\Python\Launcher\
C:\Users\[Username]\AppData\Local\Programs\Python\Python[Version]\
C:\Users\[Username]\AppData\Local\Programs\Python\Python[Version]\Scripts
For example, my username is19250, and my Python version is 3.13.3. Then the updated PATH should include
C:\Users\19250\AppData\Local\Programs\Python\Launcher\
C:\Users\19250\AppData\Local\Programs\Python\Python312\
C:\Users\19250\AppData\Local\Programs\Python\Python312\Scripts\ - Basically, adding the three addresses to
Pathin系统变量is of no harm. - Restart Command Prompt or Terminal. In that case, Python tools, e.g. pip, can be used as normal.
- Type in
- After installation and environment variable configuration of Python, use
pip install [LibraryName]command to install required libraries for this program set. For Chinese mainland users, using a proxy or setting a mirror should accelerate the downloading stage of Python libraries. Required libraries for this program set are:- lcu_driver
- I've forked lcu_driver library , so that the user can still pxperience library files in the forked repository if the corresponding pull request hasn't been accepted to merge into the official version, or has been rejected to merge, by the original author.
- I'm only reponsible for modifying the library files in the forked repository according to the demands of this program set, and not obligated to merge others' changes to the library files into mine. However, any user that commented and suggested on the library update based on the program set update is welcome 👏
- If you want to use my
lcu_driverlibrary, please follow these steps:- Open my lcu-driver repo homepage.
- Click the green "Code" button. Then click DownloadZIP to download the source code of this repository.
- Extract the zip file to the current folder.
- Don't worry about the chaos after the extraction! The files should have been put in a subfolder.
- Open the directory where Python stores libraries.
- Basically, the directory is at
C:\Users\[Username]\AppData\Local\Programs\Python\Python[Version]\Lib\site-packages.- For example, my username is
19250, and my Python version is 3.13.3. Then the library directory should be
C:\Users\19250\AppData\Local\Programs\Python\Python312\Lib\site-packages
- For example, my username is
- If the last approach doesn't work, please enter the command
pip install lcu_driverin CMD to install the originallcu_driverlibrary and then search for lcu_driver in Everything App to locate to the Python library directory.
- Basically, the directory is at
- Select
lcu_driverfolder in the extracted files. Copy it to the Python library directory. If files already exist, please selectReplace the files in the destination. - If you need to recover the original
lcu_driverlibrary, please enterpip uninstall lcu_driverin CMD to uninstall the modified library, and then enterpip install lcu_driverto reinstall the original release of the library.
- openpyxl
- pandas
- requests
- pyperclip
- pickle
- urllib
- wcwidth
- bs4
- lcu_driver
- For this first time of installation of Python, please tick on
- To improve the response speed, please open any program in this program set by Command Prompt or Terminal, instead of Python IDLE.
- To prevent the window from flashing quickly, it's suggested that users first open Command Prompt (or Terminal), switch to the directory of the program set using
cdcommand and then open some program bypython [Filename]orpython -W ignore [Filename]. In this way, it's easy check the returned information.
- To prevent the window from flashing quickly, it's suggested that users first open Command Prompt (or Terminal), switch to the directory of the program set using
- All programs must run after the user logs in the LoL client.
- All opened .py files can be aborted by Ctrl + C while running. (Press for any times you want, until the program exits.)
- This program set provides some functions besides creating custom lobbies, just for entertainment. Anyone willing to make supplements and perfection is welcome!
- Declaration: Please name the subsequent customized programs in order, following the format
Customized Program [Number] - [Function].py. - Customized Program 01 returns the connection information by lcu_driver library.
- Customized Program 02 refers to the 根据Json创建房间 button in the GUI LeagueLobby software by Mario. When using, users need first modify the values of parameters in create_custom_lobby function and then double-click the file after saving the change.
- To check the returned lobby information after creating a lobby, please first open Command Prompt or Terminal and then type
python [Filename]orpython -W ignore [Filename].
- To check the returned lobby information after creating a lobby, please first open Command Prompt or Terminal and then type
- Customized Program 03 provides a basic tool for exploration into LCU API, which saves formatted returned result into
temporary data.txtin the same directory, and also saves the variable intotemporary data.pklin the binary form in the same directory. Some reference requests are listed in this program. All available APIs are from LCU Explorer.- Please input according to the examples. Illegal input will cause the program to exit. A legal input requires:
- Containing one or two spaces.
- If there're two spaces, users may pass a request body subsequently.
- Endpoint (The second string element of the list from the input string split by space) starting with a slash.
- Containing one or two spaces.
- To view all LCU APIs in a web instead of in an APP, please visit swagger or LCU Swagger UI. (For example, you may use Ctrl + F to search for certain API.)
- Please input according to the examples. Illegal input will cause the program to exit. A legal input requires:
- Customized Program 04 is designed to update
available-bots.xlsxin the home directory.- This workbook contains 3 sheets:
- Sheet1 contains information of bot players officially available in Practice Tool lobbies.
- Sheet2 contains information of bot players that can be added in Practice Tool lobbies.
- Compared with Sheet1, Sheet2 includes information of all bot players in Co-op vs. Ai matches of intermediate difficulty.
- Sheet3 contains information of all champions in League of Legends.
- Usually users aren't needed to update the champion data. I'll keep updating it if any new champion is released.
- This program can be run without logging into LoL client, but it only returns information of all champions.
- This program involves the following data resources:
- This workbook contains 3 sheets:
- Customized Program 05 (☆) is designed to search and export summoners' profile.
- This program supports queries based on summonerName and puuid.
- Thanks to LCU API, even if a summoner sets its profile private, its whole match history and rank data can still be fetched.
- This program supports command line arguments. Check these arguments through the command
python [filename] -h.CMD arguments Action Help message Value -r
--reservestore_true Load a match even if it doesn't contain the main player None -rt
--reserve_textstore_true Save a match even if it doesn't contain the main player None - Files generated by this program are located under the "召唤师信息(Summoner Information)" folder.
- The data resources required in this program are mainly from CommunityDragon database, and it's allowed to obtain these data resources offline. The release zip includes all necessary data resources. If these files are lost, when the user chooses to obtain the data resources offline, please create a folder named as
离线数据(Offline Data)in the main directory, open the url of the corresponding data resources and then download them to this new folder. - Since Patch 13.22, Riot ID has taken the place of summoner name. Therefore, if a summoner's information can't be visited by its summonerName, please add a "#" and the summoner's tagLine after the gameName.
- Note: Open a summoner's profile page in the League Client. Keep the mouse cursor stay on his/her gameName. You should see a window with the complete Riot ID with the postfixxed tagLine. Click to copy it. Paste it into the search bar on the top-right corner of the page to search this summoner.
- This program supports the following saving modes:
Note: [Scanning saving] and [Scanning loading] are jointly termed [Scan Mode] or [Local Recheck].Saving mode Definition Applicable product(s) Implementation steps Complete saving Save all matches' information and timeline json files and export all match sheets lol
tftLoL:
1. At "Search LoL matches?" stage, Enter any non-empty string to choose yes
2. Submit "3" to search all matches
3. Input any non-empty string to specify the match begIndex and endIndex by yourself
4. When setting the match begIndex and endIndex, press Enter directly
5. Press Enter directly to output json files of each match
6. After the program finishes calculating the number of sheets to be saved for each match, input any non-empty string to export all match sheets
TFT:
1. At "Search TFT matches?" stage, input any non-empty string to choose yes
2. Press Enter directly to output json files of each match
3. Input any non-empty string to confirm saving all matches' json files
4. After the program finishes calculating the number of sheets to be saved for each match, input any non-empty string to export all match sheetsComplete loading Export all match sheets while not saving the information and timeline json files of any match lol
tftLoL:
5. Input any non-empty string to refuse outputting json files of each match
The other steps are the same as those of [Complete saving]
TFT:
1. At "Search TFT matches?" stage, input any non-empty string to choose yes
2. Input any non-empty string to refuse outputting json files of each match
3. After the program finishes calculating the number of sheets to be saved for each match, input any non-empty string to export all match sheetsBulk saving Save the information and timeline json files of matches recorded in API within a specified range of matchID and export all match sheets lol LoL:
1. At "Search LoL matches?" stage, Enter any non-empty string to choose yes
2. Submit "3" to search all matches
3. Input any non-empty string to specify the match begIndex and endIndex by yourself
4. When setting the match begIndex and endIndex, input two integers split by space
5. Press Enter directly to output json files of each match
6. After the program finishes calculating the number of sheets to be saved for each match, input any non-empty string to export all match sheetsBulk loading Export sheets of matches recorded in API within a specified range of matchID while not saving their information and timeline json files lol LoL:
5. Input any non-empty string to refuse outputting json files of each match
The other steps are the same as those of [Bulk saving]Supplementary saving Save the information and timeline json files of the matches which haven't been saved to local before and export these match sheets lol
tftLoL:
1. At "Search LoL matches?" stage, input any non-empty string to choose yes
2. Submit "3" to search all matches
3. Press Enter directly to only search for the matches whose json files haven't been saved to local before
4. Press Enter directly to output json files of each match
5. After the program finishes calculating the number of sheets to be saved for each match, input any non-empty string to export all match sheets
TFT:
3. Press Enter directly to only save the matches which haven't been saved to local before
The other steps are the same as those of [Complete Saving]Supplementary loading Export sheets of matches whose information and timeline json files haven't been saved to local before, while not saving their information and timeline json files lol 4. Input any non-empty string to output json files of each match
The other steps are the same as those of [Supplementary saving]List saving Save the information and timeline json files of matches in a match list and export these match sheets lol 1. At "Search LoL matches?" stage, input any non-empty string to choose yes
2. Input an integer list wrapped by square brackets and split by comma as the matchID list
3. Press Enter directly to output json files of each match
4. After the program finishes calculating the number of sheets to be saved for each match, input any non-empty string to export all match sheetsList loading Export sheets of matches in a specified match list, while not saving the information and timeline json files of any match in this list lol 3. Input any non-empty string to refuse outputting json files of each match
The other steps are the same those of [List saving]Scanning saving Scan all the locally saved matches, search for the information and timeline of these matches, save the json files and export them to Excel lol 1. At "Search LoL matches?" stage, input any non-empty string to choose yes
2. Input the secret code "scan" to scan the local files and obtain the matchIDs
3. Press Enter directly to start local recheck or input any non-empty string to return to Step 2
4. Press Enter directly to output json files of each match
5. After the program finishes calculating the number of sheets to be saved for each match, input any non-empty string to export all match sheetsScanning loading Scan all the locally saved matches, search for the information and timeline of these matches and export them to Excel while not saving the json files lol 4. Input any non-empty string to refuse outputting json files of each match
The other steps are the same as those of [Scanning saving] - Under [Complete Saving] mode, the generated xlsx file contains 5 parts of sheets:
- Profile (Single sheet)
- Rank (Single sheet)
- Ladders (Single sheet)
- Champion Mastery (Single sheet)
- Match history (Five sheets)
- Recently played summoner (LoL)
- Recently played summoner (TFT)
- LoL match history
- [Local Recheck] match history
- TFT match history
- Details for each match (At most three sheets for each match)
- Game information
- Game timeline
- Game events
- Scan mode ([Local Recheck]) notes: (For the definition of some terms, check the description of corresponding commit.)
- The user isn't advised to export the information and timelines of more than 1600 normal matches (or the information of 5000 Arena matches) using this program.
- Right before running the scan mode, please delete the xlsx workbook (into Recycle Bin) or rename it, in case the original workbook is too big for this program to quickly read and export sheets into.
- [Local Recheck] is only supported for LoL matches for now.
- Every time the program exports a summoner's profile, if you need to sort out data based on the generated result, please modify the names of the sheets that you want to make changes, in case they would be overwritten and some data would be lost. For example, you may add " - Manual" after the names of the sheets to change.
- If the original workbook is big enough, it's highly recommended that the user make a backup of the original workbook before the export, in case an unexpected interruption could lead to a broken workbook.
- This program involves the following data resources:
- https://ddragon.leagueoflegends.com/api/versions.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/summoner-spells.json
- https://raw.communitydragon.org/{version}/cdragon/tft/{locale}.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/champion-summary.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/cherry-augments.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/items.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/perks.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/perkstyles.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/tftchampions.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/tftitems.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/companions.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/tfttraits.json
- This program relies on any encountered errors to update the exception handling code. Welcome for any developer to share the http errors when crawling the data 👏
- Customized Program 06 is designed to one-key start the TFT Tocker's Trial mode on PBE to gain 3000 RP. A simple double-click will work.
- Since Aug. 27th, 2023, TFT 1V0 mode has been unavailable.
- Customized Program 07 is designed to get information of items on sale in the store and collections of the main summoner.
- This program exports the information of store items and collections to
Store and Collections - {召唤师名称}.xlsxin the directory of the main summoner. - The imagePath field of the store table refers to URLs related to LCU API, which can be accessed only during when the League Client is running. The first visit of these URLs requires a username and a password. Please look for a line that starts with "riot" at the beginning of this program's output. The username is "riot", and the password is a string that follows "riot".
- The imagePath temporarily marked as default.png is actually inaccessible.
- This program involves the following data resources:
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/companions.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/skins.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/statstones.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/summoner-emotes.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/summoner-icons.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/tftdamageskins.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/tftmapskins.json
- https://raw.communitydragon.org/{version}/plugins/rcp-be-lol-game-data/global/{locale}/v1/ward-skins.json
- This program exports the information of store items and collections to
- Customized Program 08 is never expected to count the number of summoners on a server. (since the number is too large, let alone the brute-force traversal of summonerId)!
- Customized Program 09 is designed to search and export the existing game modes on the current server.
- Try running this program on multiple servers, and compare the available game modes on different servers. If lucky, you may find that on Chinese PBE server, you'll use Kai'Sa to solo with a bot player of intermediate difficulty in TFT Turbo 1v0.
- Customized Program 10 is designed to search for matches a specified summoner has played. The user may combine its use with Customized Program 05.
- Customized Program 11 is designed to search summoners that have recently played with the specific summoner.
- A large part of code in this program is inherited from Customized Program 05, including the scan mode. Nevertheless, this program only outputs the result and doesn't change any intermediate files (txt and json files) generated by Customized Program 05.
- This program supports command line arguments. Check these arguments through the command
python [filename] -h.CMD arguments Action Help message Value -r
--reservestore_true Load a match even if it doesn't contain the main player None -ss
--save_selfstore_true Save the main summoner's data even if they're contained in a match None - This program allows [Generate Mode] and [Detect Mode].
- [Generate Mode] saves information of players that a specific player have played with in recent matches into the Sheet "Recently Played Summoners" in the workbook whose name is prefixxed with "Summoner Profile" and save 9 bar charts with regard to players' game time and match counts.
- [Detect Mode] checks whether some players have been encountered before. Six situations are considered in this program. The core code resemble among different situations.
- In-lobby / During champ select / In-game
- Information of summoners that the main summoner encounters during champ select or in-game in past matches will be returned in this situation. The format of output refers to that of each record in the match infrrmation table generated by Customized Program 05.
- This mode supports checking rcently played summoners of the user (current summoner) and other players encountered during champ select stage or in game. Note: TFT matches do have champ select stage. Unfortunately, this stage lasts too shortly.
- Considering temporariness of champ select, this mode will only generate a temporary file in the home directory.
- The program generates the temporary file "Recently Played Summoner in Match {platformId}-{gameId}.xlsx" in this situation, where {platformId} represents the main summoner name and {gameId} represents a matchID.
- Friend list
- Information of friends in past matches will be returned in this situation.
- The program generates the temporary file "Recently Played Summoners in Friend List of {current_summonerName} - {platformId}.xlsx" in this situation, where {current_summonerName} represents the main summoner name and {platformId} represents the server.
- Friend requests
- Information of players whom the user want to friend with and those who want to friend with the user in the past matches will be returned.
- The program generates the temporary file "Recently Played Summoners in Friend Requests of {current_summonerName} - {platformId}.xlsx.xlsx" in this situation, where {current_summonerName} represents the main summoner name and {platformId} represents the server.
- Compared with other situaions, sheet names under this situation include the friend request direction. "in" represents a player that want to friend with the user, and vice versa.
- Invitations
- Information of players who invite or are invited by the user will be returned in this situation.
- This program generates the temporary file "Recently Played Summoners in Invitations to and from {current_summonerName} - {platformId}.xlsx.xlsx" in this situation, where {current_summonerName} represents the main summoner name and {platformId} represents the server.
- Compared with other situaions, sheet names under this situation include the invitation direction. "in" represents an inviter, and vice versa.
- Block list
- Information of blocked players will be returned in this situation,
- This program generates the temporary file "Recently Played Summoners in Block List of {current_summonerName} - {platformId}.xlsx.xlsx" in this situation, where {current_summonerName} represents the main summoner name and {platformId} represents the server.
- Any player list
- Information of players in a list input by user in the past matches will be returned.
- Each element of the input player list may be a summonerName or a puuid.
- The program generates the temporary file "Recently Played Summoners in Specified Player List.xlsx" in this situation.
- Information of players in a list input by user in the past matches will be returned.
- In-lobby / During champ select / In-game
- Under [Scan Mode], this program supports [Smurf Mode], which allows adding other accounts on the same server as smurf accounts.
- Similar to Customized Program 05, the [Scan Mode] in this program only applies for LoL matches.
- If for some reason (like the CMD window pops up and disappears immediately, or the match history fails to be fetched), the user fails to get whether the allies have been encountered before using [Detect Mode], the user can still [Single Check] whether there's any recently played summoner by inputting the in-game summoner name by hand.
- Since PBE Patch 13.22, players on Riot servers can't be searches with only gameName. Because the loading screen only displays the gameName, the user may wait until the game starts to check the gameName and slogan on the scoreboard.
- This program involves the same data resources as Customized Program 05.
- Customized Program 12 is used to sort out player loot information.
- The final result of this program is a 2-dimension table including a part of the field to be saved into a workbook. To get the generation path, please refer to Customized Program 05.
- This program only transforms and sorts out data. No data analysis is involved. If you have further needs, please analyze with Excel on your own.
- Customized Program 13 is used to fetch all ladder data in the current server.
- Files generated by this program are located under the "顶尖排位玩家(Ranked Apex)" folder.
- The generated xlsx file contains 2 parts of sheets:
- Split config (Double sheets)
- Split config
- Reward track
- League ladders
- Tier apex metadata (Single sheet)
- Apex
- Tier apex
- Ranked solo/duo
- Ranked Flex
- Ranked TFT
- Double Up (Workshop)
- Rated apex
- Hyper Roll
- Arena
- Tier apex
- Split config (Double sheets)
- Customized Program 14 is used to instantly enter a friend's party.
- Usage limits are added. Please don't abuse the program and edit the code at will.
- This program might be as useful as how you think. If you're dying to be carried, I suggest you keep clicking where the "join party" will occur desperately while running this program.
- Customized Program 15 is used to let the users pick a same champion in a custom game. This BUG has been fixed, so you may ignore this program.
- Customized Program 16 is used to simulate the behaviors related with chat service.
- Currently this program has the following features:
- Export friend data
- Manage friend groups
- Chat
- Export chat history
- Manage friend list
- Send lobby invitations
- Manage received invitations
- Spectate a game
- Manage team voice
- Manage block list
- Custom URF special mode is planted into this feature for manaegement of group members. This mode is hidden.
- Currently this program has the following features:
- Customized Program 17 is used to sort out all game type config. It's mainly used to configure the parameters of custom lobby creation request.
- Customized Program 18 is used to sort out all missions.
- You may check the PBE RP Bonus mission with this program.
- Customized Program 19 is used to simulate perk configuration and perk page operations in the League Client.
- Currently, this program provides the following functions:
- Check all perk information
- Check the recommended perk information of different champions, positions and maps
- Manage perk pages
- Export all pages
- Check, edit and export single page
- Toggle active page
- Sort pages
- Delete pages
- Currently, this program provides the following functions:
- Customized Program 20 is used to summary multiple players' game stats at a time.
- This program combines the search function in Customized Program 05 and the gameflow phase detection function in Customized Program 11 and summarizes player stats in the following situations:
- Allies with visible information during champ select stage
- All players in game
- All players in a previous match
- While basic stats are output, some other indices are also output, which refer to:
- Radar graph in LoL Helper Mobile
- Common statistics in LoL Esports (KDA, Kill Participant, Gold per Minute, CS per Minute, Damage per Gold Ratio, etc.)
- Data in certain format are added conditional formats in the exported workbook to improve intuitiveness.
- KDA is output as a one-digit float.
- Some LoL Esports statistics are output as three-digit floats.
- Percentages are output as two-digit percentages.
- Order cells are three-color scaled.
- Win and lose result cells are colored based on formula. "VICTORY" is colored green and "DEFEAT" is colored red.
- For convenience, this program supports command line arguments. Check these arguments through the command
python [filename] -h.CMD arguments Action Help message Value -e
--save_earlystore Export only the matches whose creation is earlier than the current queried match None -l
--localestore Set the language of constant dictionaries defined in the program. Only Simplified Chinese and English (US) are supported for now zh_CN (default)
en_US-os
--open_after_savestore_true After saving a file, open it without program asking None --verbose store_true Print detailed match loading process and exception handling procedural hints None --nonverbose store_true Output key information only None
- This program combines the search function in Customized Program 05 and the gameflow phase detection function in Customized Program 11 and summarizes player stats in the following situations:
- Customized Program 21 is used to simulate client operations at all gameflow phases. It's aimed at handle urgent situations when the League Client isn't well performed.
- Declaration: This program doesn't involve any automatized operations.
- This program combines core functions of the previous 20 customized programs. To experience the whole feature, please make sure Customized Program 19 is under the same directory.
- This program supports simulation at gameflow phases like unlogged, None, Lobby, Matchmaking, ReadyCheck, ChampSelect, InProgress, Reconnect, WaitingForStats, PreEndOfGame and EndOfGame. All supported operations are listed below, excluding the debugging function: (Suboperations of the same operation is only expanded at the first occurrence.)
- Unlogged
- Debug League Client endpoints
- Manage the League Client task
- Window management
- Show the window
- Minimize the window
- Enable taskbar flashing
- Resize the window
- Show the window
- Process management
- Launch ux
- Temporarily close ux
- Reload ux
- Terminate ux (!)
- Window management
- None
- Debug League Client endpoints
- Create a lobby
- Create a party
- Create a custom lobby
- Create through json
- Handle invitations
- Join party/lobby
- Party
- Custom lobby
- Clash
- Spectate a game
- Chat
- Manage the League Client task
- Lobby
- Debug League Client endpoints
- Manage a party
- Prepare before in queue
- Select positions (Ranked and Nexus Blitz only)
- Configure quickplay slot (Swiftplay only)
- Configure subteam data (Arena only)
- Toggle ready
- TFT loadouts (TFT only)
- Check friends leaderboard
- Toggle party open/closed
- Make party invite-only
- Open party to friends
- Change mode
- Create a party
- Create a custom lobby
- Create through json
- Find match
- Prepare before in queue
- Manage a custom lobby
- Add a bot
- Remove a bot
- Switch team
- Switch spectate status (!)
- Change mode
- Start game
- Invite to game
- Chat
- Manage members
- Promote to party owner
- Kick player from party
- Change invite priviledge
- Grant invites
- Revoke invites
- Print lobby information
- Handle invitations
- Join party/lobby
- Exit the party/lobby
- Manage the League Client task
- MatchMaking
- Debug League Client endpoints
- Print matchmaking information
- Chat
- Handle invitations
- Join party/lobby
- Quit the queue
- Manage the League Client task
- ReadyCheck
- Accept
- Decline
- Print the ready check information
- Manage the League Client task
- ChampSelect
- Debug League Client endpoints
- Swap
- Pick order
- Check
- Send
- Position
- Check
- Send
- Ally champions
- Check
- Send
- Available champion pool (Bench)
- Check
- Send
- Pick order
- Select a champion
- Decalre intent (unavailable)
- Ban
- Pick
- Reroll
- Prepare loadouts
- Perks (Need support from Customized Program 19)
- Summoner spells
- Skin
- Ward skin
- Emote
- Summoner icon
- Nexus finisher
- Banner
- Crest
- Tournament trophy
- Mute players
- Chat
- Others
- Unlock battle boost
- Toggle favorite champions on different positions
- Clear muted players
- Exit the champ select stage
- Output the champ select session
- Manage the League Client task
- InProgress
- Chat with friends
- Manage the League Client task
- Reconnect
- WaitingForStats
- PreEndOfGame
- Debug League Client endpoints
- Honor players
- Check the number of votes
- Not this time
- Print honor ballot information
- Print current sequence event
- Chat
- Manage the League Client task
- EndOfGame
- Debug League Client endpoints
- Check champion mastery updates
- Check stats block
- LoL
- TFT
- Chat
- Play again
- Dismiss
- Recall honor vote phase (!)
- Manage the League Client task
- Other phases
- Unlogged
- Without specific explanation, submit "0" to return to the last step.
- This program creates cache under the "cache" folder to speed up data resource loading.
- The local cache expires after 24 hours.
- Users may reload data resources to refresh local cache.
- Reading cache is expected to save 10 to 30 seconds of data resource loading.
清除临时文件.batis used to remove temporary files generated by customized programs. At present it can delete temporary files from customized programs 03, 05, 10, 11, 17, 19, 20 and 21.召唤师信息文件格式转换.batis used to rename the format of data files generated by Customized Program 05 into ".txt" or ".json".- Renaming a number of data files may results in the slow performance of Explorer, so please think twice to use this program.
- Since the scripts of this program contain Chinese characters, please run
chcp 65001in Command Prompt before running this program. - Within expectation, the prompt "1 files(s) moved" will constantly pop up in Command Prompt. Everything App is suggested for checking the number of txt files in the folder "召唤师信息(Summoner Information)".
- Try typing
"{folderPath}" .txtin the search bar of Everything App to check the txt file list of a folder. You should see the number of the txt files at the bottom-left corner of the Everything window.- An example of {folderPath}:
C:\Users\19250\Desktop\英雄联盟自定义房间创建\召唤师信息(Summoner Information).
- An example of {folderPath}:
- Try typing
- Item Program is used to generate item information table of all versions.
- Data resources are from DataDragon database> and CommunityDragon database.
- This program supports all languages supported by League of Legends.
- This program supports all versions archived by these two databases.
- Each generated table can be divided into 5 parts:
- Metadata
- Classification
- In-game tooltip
- Map availability (not available in item data from CommunityDragon)
- Basic stats
- If you want to freeze cells and enable autofilter in batch, you can write a Macro to fix the top rows of all sheets. The following is a demonstration, taking Microsoft Excel as an example.
- In Microsoft Excel, click "File" - "Options" - "Customize Ribbon". Tick on "Developer" and click "OK".
- Click "Developer" tab and then click "Visual Basic" to open the VBA editor.
- In "Project - VBAProject" subwindow of the new window, right click "VBAProject ({Workbook Name})". Then click "Insert" - "Module".
- Paste the following code into the new module subwindow:
Note: The above macro applies to all sheets. If you want it to only apply to certain sheets, you need to add a condition statement on the sheet attributes right below the for-statement and indent the subsequent code that do operations backward by one layer. 5. Close VBA editor and return to the Excel window. Click "Macro" in "Developer" tab. 6. Select "FreezeTopRowsAndSelectA1" and click "Run". 7. If you want to save the macro while saving the changes, please save this workbook as ".xlsm" format.Sub FreezeAndFilterTopRowsAndColumns() Dim ws As Worksheet Dim lastCol As Long For Each ws In ThisWorkbook.Worksheets ws.Activate ' Select this sheet If ws.AutoFilterMode Then ws.AutoFilterMode = False ' Remove any existing autofilter ActiveWindow.FreezePanes = False ' Disable the current pane freezing ActiveWindow.SplitColumn = 0 ' Remove any existing column split ActiveWindow.SplitRow = 0 ' Remove any existing row split ws.Range("E3").Select ' Freeze the first two rows and four columns ActiveWindow.FreezePanes = True ' Freeze the panes ws.Range("A2").Select ' Select A2 cell lastCol = ws.Cells(2, ws.Columns.Count).End(xlToLeft).Column ' Determine the last column that has content in Line Two ws.Range(ws.Cells(2, 1), ws.Cells(2, lastCol)).Select ' Select the range from A2 to the last cell that has content in the same row Selection.AutoFilter ' Apply autofilter to the selected range ws.Range("A1").Select ' Cursor initialization - Select A1 cell Next ws End Sub
- Here're some other macros that might be useful.
- Clear format
Sub ClearFormat() Dim ws As Worksheet Dim lastCol As Long For Each ws In ThisWorkbook.Worksheets If InStr(ws.Name, "cdragon") > 0 Or ws.Name = "pbe" Or ws.Name = "latest" Then ' Select sheets produced when fetching CommunityDragon database ws.Activate If ws.AutoFilterMode Then ws.AutoFilterMode = False ActiveWindow.FreezePanes = False ActiveWindow.SplitColumn = 0 ActiveWindow.SplitRow = 0 ws.Range("A1").Select End If Next ws End Sub
- To make it convenient for users to look up LoL official terms, a translation program
trans.pyis added in the home directory.- Each run of this program supports summarizing and saving the translation data resources of a language. It also allows downloading data resources in all languages within one run.
- Since this program is only intended to correct the terms, the involved data resources are only used for program development, instead of the release. So, it's highly recommended that users run this program in the cloned repository folder, instead of the folder extracted from compressed files in Release.
- Customized Programs 05, 11, 13, 16, 19, 20 and 21 save content displayed in terminal into local logs while running. You can check them under the "日志(Logs)" folder.
- To let user understand the structure of the large dataframes, a workbook
Customized Program Main Dataframe Structure.xlsxis added in the home directory to illustrate how the dataframes are organized.- The following is the illustration on the structure of
LoLGame_info_dfin Customized Programs 05 and 20,recent_LoLPlayers_dfin Customized Programs 11 and 16 andLoLGame_stat_headerin Customized Program 20, to explain some settings, which won't be repeated in the following context:- There're 6 columns in the sheets
05 - LoLGame_info_header,11 - LoLGame_info_header,16 - LoLGame_info_headerand20 - LoLGame_stat_header, and the first 3 columns are the main data area.Indexrepresents the index of the keys of the dictionary variableLoLGame_info_data.Keyrepresents the keys of the dictionary variableLoLGame_info_data.Valuerepresents the values of the dictionary variableLoLGame_info_data.DirectlyImport?represents whether to analyze the data to be transformed from LCU API into the dataframe. A tick means reference without any change.OutputOrderrepresents the order to arrange the data when they're output into a worksheet.DisplayOrderrepresents the order to arrange the data when they're displayed in a webpage. Only the header sheets whose corresponding tables are to be displayed in a webpage have this column.
- 9~10 colors are used to divide the main data area in these sheets.
- Data not filled with any color mean
Keydoesn't serve as the index of any variables of LCU API. - Data in the light green area mean
Keyis the index of the variableLoLGame_info. - Data in the light blue area mean
Keyis the index ofLoLGame_info["participantIdentities"][participantId]. - Data in the dark blue area mean
Keyis the index ofLoLGame_info["participantIdentities"][participantId]["player"]. - Data in the dark green area mean
Keyis the index ofLoLGame_info["participants"][participantId]. - Data in the orange area mean
Keyis the index ofLoLGame_info["participants"][participantId]["stats"]. - Data in the purple area mean
Keycomes fromLoLGame_info["teams"][teamId]["bans"].- Note that no key in this area exists to be the direct index.
- Data in the yellow area mean
Keyis the direct index ofLoLGame_info["participants"][participantId]["timeline"]. - Data in the pink area mean
Keydoesn't serve as the index of any variables of LCU API.- Currently, the purple area only contains
ally?, a judgement whether the queried player is an ally of the main player. In the exported sheet, a tick means the queried player is the ally of the main player.
- Currently, the purple area only contains
- Data in the grey area mean
Keycomes fromLoLGame_info["participants"][participantId]["stats"].- Values of this part of keys are obtained by comparison and mathematical calculation.
- Data not filled with any color mean
- Some keys are colored white. These keys don't belong to the indices of any variable in LCU API, but actually come from them. For example,
gameModeNamenever occurs in the json object of the game information, but actually originates fromLoLGame_infoand corresponds to the key"gameMode". - To obtain the output/display order lists, users need only arrange the table according to the ascending order of
OutputOrderorDisplayOrderand then copy the cells inIndexcolumn.
- There're 6 columns in the sheets
LoLChampions_dfin Customized Programs 04 and 21:- 8 colors are used to divide the main data area in the sheet
04 - LoLChampions_header (LCU)and21 - LoLChampions_header:- Data not filled with any color mean
Keyis the direct index ofLoLChampions[championId]. - Data in the light blue area mean
Keycomes fromLoLChampions[championId]["ownership"]. - Data in the deep blue area mean
Keycomes fromLoLChampions[championId]["ownership"]["rental"]. - Data in the light green area mean
Keycomes fromLoLChampions[championId]["roles"]. - Data in the orange area mean
Keycomes fromLoLChampions[championId]["tacticalInfo"]. - Data in the pink area mean
Keycomes fromLoLChampions[championId]["passive"]. - Data in the deep green area mean
Keycomes fromLoLChampions[championId]["spells"][spell_index]. - Data in the yellow area mean
Keycomes from the endpoint/lol-perks/v1/recommended-champion-positions.
- Data not filled with any color mean
- 7 colors are used to divide the main data area in the sheet
04 - LoLChampions_header (ddr).- Data not filled with any color mean
Keyis the direct index ofLoLChampions[championId]. - Data in the light blue area mean
Keycomes fromLoLChampions[championId]["image"]. - Data in the light green area mean
Keycomes fromLoLChampions[championId]["tags"]. - Data in the deep blue area mean
Keycomes fromLoLChampions[championId]["stats"]. - Data in the orange area mean
Keyis the index ofLoLChampions[championId]["stats"]. - Data in the pink area mean
Keycomes fromLoLChampions[championId]["spells"][spell_index]. - Data in the deep green area mean
Keycomes fromLoLChampions[championId]["passive"].
- Data not filled with any color mean
- 7 colors are used to divide the main data area in the sheet
04 - LoLChampions_header (cdr).- Data not filled with any color mean
Keyis the direct index ofLoLChampions[championId]. - Data in the light blue area mean
Keycomes fromLoLChampions[championId]["tacticalInfo"]. - Data in the light green area mean
Keycomes fromLoLChampions[championId]["playStyleInfo"]. - Data in the deep blue area mean
Keycomes fromLoLChampions[championId]["info"]. - Data in the deep green area mean
Keycomes fromLoLChampions[championId]["roles"]. - Data in the orange area mean
Keycomes fromLoLChampions[championId]["passive"]. - Data in the pink area mean
Keycomes fromLoLChampions[championId]["spells"][spell_index].
- Data not filled with any color mean
- 8 colors are used to divide the main data area in the sheet
mastery_dfin Customized Program 05:- 3 colors are used to divide the main data area in the sheet
05 - mastery_header.- Data in the blue area mean
Keyis the direct index of the variablemastery[champion_iter].- Keys in white only include
championandalias, representing the titles and aliases of champions, respectively. Only championIds are provided in LCU API.
- Keys in white only include
- Data in the light green area mean
Keycomes frommastery[champion_iter]["nextSeasonMilestone"]. - Data in the deep purple area mean
Keycomes frommastery[champion_iter]["nextSeasonMilestone"]["rewardConfig"].
- Data in the blue area mean
- 3 colors are used to divide the main data area in the sheet
ranked_dfin Customized Program 05:Keyin the sheet05 - ranked_headercan all be the index ofranked["queues"][id].- Note that redundancy exists in the
OutputOrdercolumn. The essential reason for this is that the tier of TFT turbo and that of other rank modes are recorded into 2 variables separately, while the two tiers are expected to be stored in a single column. Therefore, theOutputOrderof some keys are the same.
ladders_dfin Customized Program 05:- 4 colors are used to divide the main data area in the sheet
05 - ladders_header.- Data not filled with any color mean
Keyis the direct index ofladders[ladderId]. - Data in the light bluea area mean
Keyis the index ofladders[ladderId]["divisions"][divisionId]["standings"][standingId]. - Data in the light green area mean
Keyis the index of the endpoint/lol-summoner/v2/summoners/puuid/{puuid}. - Data in the orange area mean
Keydoesn't serve as the index of any variables of LCU API.
- Data not filled with any color mean
- 4 colors are used to divide the main data area in the sheet
LoLHistory_dfin Customized Programs 05 and 11:- 6 colors are used to divide the main data area in the sheets
05 - LoLHistory_headerand11 - LoLHistory_header.- Data not filled with any color mean
Keydoesn't serve as the index of any variables of LCU API. - Data in the light blue area mean
Keyis the index ofLoLHistory["games"]["games"]. - Data in the light green area mean
Keyis the direct index ofLoLHistory["games"]["games"]["participantIdentities"][0]["player"]. - Data in the orange area mean
Keyis the index ofLoLHistory["games"]["games"]["participants"][0]. - Data in the dark green area mean
Keyis the index ofLoLHistory["games"]["games"]["participants"][0]["stats"]. - Data in the purple area mean
Keyis the direct index ofLoLHistory["games"]["games"]["participants"][0]["timeline"].
- Data not filled with any color mean
- 6 colors are used to divide the main data area in the sheets
LoLGame_leaderboard_dfandTFTGame_leaderboard_dfin Customized Program 05 andsocial_leaderboard_dfin Customized Program 20:- 2 colors are used to divide the main data area in sheets
05 - LoLGame_leaderboard_header,05 - TFTGame_leaderboard_headerand20 - social_leaderboard_header.- Data in the blue area mean
Keyis the index ofparticipantInfo. - Data not filled with any color mean
Keyis the index ofparticipant_leaderboard.
- Data in the blue area mean
- 2 colors are used to divide the main data area in sheets
LoLGame_timeline_dfin Customized Program 05:- 4 colors are used to divide the main data area in the sheet
05 - LoLGame_timeline_header.- Data in the blue area mean
Keyis the index offrames[frameId]. - Data in the grey area mean the value corresponding to
Keyis generated automatically and isn't related to LCU API. - Data in the green area mean
Keycomes fromLoLGame_info. - Data in the orange area mean
Keyis the index offrames[frameId]["participantFrames"][participantId].
- Data in the blue area mean
- 4 colors are used to divide the main data area in the sheet
LoLGame_event_dfin Customized Program 05:- The main data area in the sheet
05 - TFTHistory_headerisn't filled with any color.- Keys in dark red mean
Keyis the direct index of the variableevents[timestamp]. - Some keys are colored black. These keys don't belong to the indices of any variable in LCU API, but actually come from them. For example,
itemnever occurs in the json object of the game information, but actually originates fromLoLGame_timeline["frames"]["events"][eventId]and corresponds to the key"itemId".
- Keys in dark red mean
- The main data area in the sheet
TFTHistory_dfin Customized Program 05, "recent_TFTPlayers_dfin Customized Programs 11 and 16 andTFTGame_stat_df` in Customized Program 20:- 5 colors are used to divide the main data area in the sheets
05 - TFTHistory_header,11 - TFTHistory_headerand16 - TFTGame_stat_header.- Data not filled with any color mean
Keydoesn't serve as the index of any variables of LCU API. - Data in the sky blue area mean
Keyis the index ofTFTHistory[gameIndex]["json"]. - Data in the green area mean
Keyis the index ofTFTHistory[gameIndex]["json"]["participants"]. - Data in the pink area mean the first half of
Keyis the index ofTFTHistory[gameIndex]["json"]["participants"][participantId]["traits"], while the second half is the index ofTFTHistory[gameIndex]["json"]["participants"][participantId]["traits"][trait_index]. - Data in the dark blue area mean the first part of
Keyis the index ofTFTHistory[gameIndex]["json"]["participants"][participantId]["units"].- For
Keywhose index is between 129~183, the second part is the direct index ofTFTHistory[gameIndex]["json"]["participants"][participantId]["units"][unit_index]. - For
Keywhose index is greater than or equal to 184, the second part comes fromTFTHistory[gameIndex]["json"]["participants"][participantId]["units"][unit_index]["items"], and the third part is the direct index ofTFTHistory[gameIndex]["json"]["participants"][participantId]["units"][unit_index]["items"][item_index].
- For
- Data not filled with any color mean
- The only difference of the contents between the sheet
05 - TFTGame_info_headerand the sheet05 - TFTHistory_headeris the first 9 lines.
- 5 colors are used to divide the main data area in the sheets
catalog_dfin Customized Program 07:- 3 colors are used to divide the main data area in the sheet
07 - catalog_header.Itemdenodes any element incatalogList.- Data not filled with any color mean
Keyis the direct index of the variableitem. - Data in the blue area mean
Keycomes from the index ofitem["prices"][priceId]. - Data in the green area mean
Keycomes fromitem["prices"][priceId]["sale"].
- Data not filled with any color mean
- 3 colors are used to divide the main data area in the sheet
store_dfin Customized Program 07:- 5 colors are used to divide the main data area in the sheet
07 - store_header.itemdenodes any element instore.- Data not filled with any color
- 5 colors are used to divide the main data area in the sheet
collection_dfin Customized Programs 07 and 21:- 2 colors are used to divide the main data area in the sheets
07 - collection_headerand21 - collection_header.Itemdenodes any element incatalogList.- Data not filled with any color mean
Keyis the direct index of the variableitem. - Data in the blue area mean
Keyis the index ofitem["payload"].
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheets
queues_dfin Customized Programs 09 and 20:- 4 colors are used to divide the main data area in the sheets
09 - queues_headerand20 - queues_header.- Data in the blue area mean
Keyis the direct index of the variablequeues[id]. - Data in the orange area mean
Keyis the index of the variablequeues[id]["gameTypeConfig"]. - Data in the blue area mean
Keyis the index of the variablequeues[id]["queueRewards"].
- Data in the blue area mean
- 4 colors are used to divide the main data area in the sheets
recent_players_metaDfin Customized Program 11:- The main data area in the sheet
11 - recent_players_metadata_he(11 - recent_players_metadata_header) isn't filled with any color.Keyis the direct index of the variablerecent_players_metadata_list.
- The main data area in the sheet
player_loot_dfin Customized Program 12:- No color is used to divide the main data area in the sheet
12 - player_loot_header, because these keys are all indices ofplayer_loot[i].
- No color is used to divide the main data area in the sheet
splits_info_dfin Customized Program 13:- 4 colors are used to divide the main data area in the sheet
13 - splits_info_header.- Data in the blue green area mean
Keycomes fromsplitsConfig["splits"][splitId]. - Data in the light green area mean
Keycomes fromsplitsConfig["splits"][splitId]["victoriousSkinRewardGroup"]. - Data in the orange area mean
Keycomes fromsplitsConfig["splits"][splitId]["victoriousSkinRewardGroup"]["splitPointsByHighestSeasonTier"]
- Data in the blue green area mean
- 4 colors are used to divide the main data area in the sheet
rewardTrack_dfin Customized Program 13:- 3 colors are used to divide the main data area in the sheet
13 - rewardTrack_header.- Data in the light blue area mean
Keyis the index ofsplitsConfig["splits"][splitId]. - Data in the orange area mean the value corresponding to
Keyis generated automatically and isn't related to LCU API. - Data in the light green area mean
Keyis the index ofsplitsConfig["splits"][splitId]["rewardTrack"][rewardTrackId]["rewards"][rewardId].
- Data in the light blue area mean
- 3 colors are used to divide the main data area in the sheet
challenger_ladders_metadata_dfin Customized Program 13:- 2 colors are used to divide the main data area in the sheet
13 - challenger_ladders_metadat(13 - challenger_ladders_metadata_headerin full form).- Data in the light blue area mean
Keyis the index ofladders. - Data in the light green area mean
Keyis the index ofladders["divisions"][divisionId].
- Data in the light blue area mean
- 2 colors are used to divide the main data area in the sheet
ladders_df["challenger_ladder"][queueType]in Customized Program 13:- 2 colors are used to divide the main data area in the sheet
13 - challenger_ladders_header.- Data not filled with any color mean
Keyis the index ofladders["divisions"][divisionId]["standings"][standingId]. - Data in the light blue area mean
Keyis the index of the endpoint/lol-summoner/v2/summoners/puuid/{puuid}.
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
ladders_df["topRated_ladder"][queueType]in Customized Program 13:- 2 colors are used to divide the main data area in the sheet
13 - topRated_ladders_header.- Data not filled with any color mean
Keyis the direct index ofladders["standings"][standingId]. - Data in the light blue area mean
Keyis the index of the endpoint/lol-summoner/v2/summoners/puuid/{puuid}.
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
friend_hovercard_dfin Customized Program 16:- 4 colors are used to divide the main data area in the sheet
16 - friend_hovercard_header.frienddenodes any element infriends.- Data in the blue area mean
Keyis the index of the variablefriend. - Data in the light green area mean
Keyis the index offriend["lol"]. - Data in the orange area mean the second half of
Keyis the index ofeval(friend["lol"]["pty"]). - Data in the green area mean the second half of
Keyis the index ofeval(friend["lol"]["regalia"]).
- Data in the blue area mean
- 4 colors are used to divide the main data area in the sheet
friend_hovercard_df_simplein Customized Program 16:- The main data area in the sheet
16 - friend_hovercard_header_si(16 - friend_hovercard_header_simple) isn't filled with any color.frienddenodes any element infriends.Keyis the direct index of the variablefriend.
- The main data area in the sheet
friend_groups_dfin Customized Program 16:- The main data area in the sheet
16 - friend_groups_headerisn't filled with any color.groupdenodes any element infriend_groups.Keyis the direct index of the variablegroup.
- The main data area in the sheet
conversation_dfin Customized Programs 16 and 21:- The main data area in the sheets
16 - conversation_headerand21 - conversation_headerisn't filled with any color.conversationdenodes any element inconversations.Keyis the direct index of the variableconversation.
- The main data area in the sheets
message_dfin Customized Program 16:- The main data area in the sheet
16 - message_headerisn't filled with any color.messagedenodes any element inmessages.Keyis the index of the variablemessage.Keywhose index is less than 9 is the direct index of the variablemessage.- The second half of
Keywhose index is greater than or equal to 9 comes fromget_infofunction.
- The main data area in the sheet
friend_request_dfin Customized Program 16:- The main data area in the sheet
16 - friend_request_headerisn't filled with any color.friend_requestdenodes any element infriend_requests.Keyis the index of the variablefriend_request.Keywhose index is less than 10 is the direct index of the variablefriend_request.- The second half of
Keywhose index is greater than or equal to 9 is the direct index ofsummonerIcons[friend_request["icon"]].
- The main data area in the sheet
party_dfin Customized Program 16:- 4 colors are used to divide the main data area in the sheet
16 - party_header.partydenodes any element inparties.- Data in the blue area mean
Keyis the direct index of the variableparty. - Data in the light green area mean the second half of
Keyis the direct index ofqueues[party["queueId"]]. - Data in the orange area mean
Keycomes fromparty. - Data in the yellow area mean
Keydoesn't serve as the index of any variables of LCU API.- Currently, the purple area only contains
full?, a judgement whether the party is full. In the exported sheet, a tick means the party is full.
- Currently, the purple area only contains
- Data in the blue area mean
- 4 colors are used to divide the main data area in the sheet
invid_dfin Customized Programs 16 and 21:- 3 colors are used to divide the main data area in the sheets
16 - invid_headerand21 - invid_header.inviddenodes any element inreceivedInvitations.- Data in the blue area mean
Keyis the index of the variableinvid. - Data in the light green area mean
Keyis the direct index ofinvid["gameConfig"]. - Data in the orange area mean the second half of
Keycomes fromqueues.
- Data in the blue area mean
- 3 colors are used to divide the main data area in the sheets
muted_player_dfin Customized Program 16:- The main data area in the sheet
16 - player_mute_headerisn't filled with any color.muted_playerdenodes any element inmuted_players.Keyis the index of the variablemuted_player.Keywhose index is less than 5 is the direct index of the variablemuted_player.Keywhose index is greater than or equal to 5 comes fromget_infofunction.
- The main data area in the sheet
champSelect_team_dfin Customized Program 16 andplayers_dfin Customized Program 21:- The main data area in the sheets
16 - champSelect_team_header,20 - champSelect_players_headerand21 - champSelect_players_headerisn't filled with any color.playerdenodes any element inplayers.Keyis the index of the variableplayer.
- The main data area in the sheets
captureDevices_dfin Customized Program 16:- The main data area in the sheet
16 - captureDevices_headerisn't filled with any color.devicedenotes any value incaptureDevices.Keyis the direct index of the variabledevice.
- The main data area in the sheet
voiceSettings_dfin Customized Program 16:- The main data area in the sheet
16 - voiceSettings_headerisn't filled with any color.Keyis the index of the variabledevice.Keywhose index is less than 12 is the direct index of the variabledevice.Keywhose index is greater than or equal to 12 comes fromcaptureDevices.
- This dataframe uses a legacy creation method. Refer to the definition of
info_datain Customized Program 05.
- The main data area in the sheet
participant_record_dfin Customized Program 16:- The main data area in the sheet
16 - participant_record_headerisn't filled with any color.participantdenodes any element inparticipant_records.Keyis the index of the variableparticipant.Keywhose index is less than 8 is the direct index of the variableparticipant.Key9 and 10 come fromget_infofunction.
- The main data area in the sheet
blockList_dfin Customized Program 16:- The main data area in the sheet
16 - blockList_headerisn't filled with any color.playerdenodes any element inblockList.Keyis the index of the variableplayer.Keywhose index is less than 8 is the direct index of the variableplayer.- The second half
Keyis the index of the data resource that the first half represents.
- The main data area in the sheet
gametype_config_dfin Customized Program 17:- The main data area in the sheet
17 - gametype_config_headerisn't filled with any color.configdenotes any element ingametype_config.Keyis the direct index of the variableconfig.
- The main data area in the sheet
mission_dfin Customized Program 18:- 6 colors are used to divide the main data area in the sheet
18 - mission_header.missiondenotes any element inmissions.- Data not filled with any color mean
Keyis the index ofmission. - Data in the blue area mean the second half of
Keyis the direct index ofmission["display"]. - Data in the light blue area mean
Keycomes frommission["metadata"]. - Data in the deep blue area mean the second half of
Keyis the direct index ofmission["rewardStrategy"]. - Data in the organge area mean
Keycomes frommission["objective"][objectiveId]. - Data in the purple area mean the second half of
Keycomes fromobjective. - Data in the blue, light green, deep green and purple areas are handled by the same code frame.
- Data not filled with any color mean
- 6 colors are used to divide the main data area in the sheet
objective_group_dfin Customized Program 18:- 2 colors are used to divide the main data area in the sheet
18 - objective_group_header.objectivedenotes any element inobjectives.objectiveGroupdenotes any element inobjective["objectives"].- Data not filled with any color mean
Keyis the index ofobjective. - Data in the blue area mean the second half of
Keyis the index ofobjectiveGroup.
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
perk_dfin Customized Program 19:- The main data area in the sheet
19 - perk_headerisn't filled with any color.perkdenotes any element infperks.Keyis the index ofperk.
- The main data area in the sheet
recommendedPage_dfin Customized Program 19:- 3 colors are used to divide the main data area in the sheet
19 - recommendedPage_header.pagedenotes any element inrecommendedPages.- Data not filled with any color mean
Keyis the index ofpage. - Data in the blue area mean the second half of
Keyis the direct index ofpage["keystone"]. - Data in the green area mean
Keycomes frompage["perks"][perkId].
- Data not filled with any color mean
- 3 colors are used to divide the main data area in the sheet
perkPage_dfin Customized Programs 19 and 21:- 3 colors are used to divide the main data area in the sheets
19 - perkPage_headerand21 - perkPage_header.pagedenotes any element inperkPages.- Data not filled with any color mean
Keyis the index ofpage. - Data in the blue area mean the second half of
Keyis the direct index ofpage["pageKeystone"]. - Data in the green area mean
Keycomes frompage["uiPerks"][pageId].
- Data not filled with any color mean
- 3 colors are used to divide the main data area in the sheets
inGame_players_dfin Customized Program 20:- 2 colors are used to divide the main data area in the sheet
20 - inGame_players_header.playerdenotes any element inteamOne + teamTwo.loadoutdenotesplayer's loadout.- Data not filled with any color mean
Keyis the index ofplayer. - Data in the blue area mean
Keyis the index ofloadout.
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
process_dfin Customized Program 20:- 2 colors are used to divide the main data area in the sheet
20 - process_header.- Data not filled with any color mean
Keydoesn't serve as the index of any variables. - Data in the blue area mean
Keyis the direct index ofparentandchild.
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
swaps_dfin Customized Program 21:- The main data area in the sheet
21 - swaps_headerisn't filled with any color.Keyis the direct index of the variableswap.
- The main data area in the sheet
custom_game_dfin Customized Program 21:- The main data area in the sheet
21 - custom_game_headerisn't filled with any color.lobbydenotes any element incustom_lobbies.Keyis the index oflobby.
- The main data area in the sheet
skins_dfin Customized Program 21:- 6 colors are used to divide the main data area in the sheet
21 - skins_header.skindenotes any element inchampionSkins.values().skin_flatdenotes any element inskins_flat.values().- Data not filled with any color mean
Keyis the direct index ofskin["emblems"]. - Data in the light green area mean
Keycomes fromskin["emblems"].- The latter half of
KeyNo. 29 and 30 is the direct index ofskin["emblems"]. - The latter half of
KeyNo. 31 and 32 is the direct index ofskin["emblems"]["emblemPath"].
- The latter half of
- Data in the deep green area mean the latter half of
Keyis the direct index ofskin["questSkinInfo"]. - Data in the yellow area mean
Keycomes fromskin_flat.KeyNo. 41~44 is the direct index ofskin_flat.- The latter half of
KeyNo. 45~47 is the direct index ofLoLChampions[skin_flat["championId"]].
- Data in the light blue area mean the latter half of
Keyis the direct index ofskin_flat["ownership"]. - Data in the deep blue area mean the third part of
Keyis the index ofskin_flat["ownership"]["rental"].
- Data not filled with any color mean
- 6 colors are used to divide the main data area in the sheet
grid_champion_dfin Customized Program 21:- 2 colors are used to divide the main data area in the sheet
21 - grid_champion_header.championdenotes any element ingrid_champions.- Data not filled with any color mean
Keyis the index ofchampion. - Data in the blue area mean
Keyis the direct index ofchampion["selectionStatus"].
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
grid_champion_dfin Customized Program 21:- The main data area in the sheet
21 - grid_champion_headerisn't filled with any color.playerdenotes any element inmuted_players.Keyis the index ofplayer.KeyNo. 0~3 is the direct index of the variableplayer.KeyNo. 4 and 5 is the direct index ofplayer_info["body"].
- The main data area in the sheet
social_leaderboard_dfin Customized Program 21:- The main data area in the sheet
21 - social_leaderboard_headerisn't filled with any color.playerdenotes any element insocial_leaderboard["rowData"].Keyis the index ofplayer.KeyNo. 0~15 is the direct index of the variableplayer.KeyNo. 16 and 17 is the direct index ofsummonerIcons[player["profileIconId"]].
- The main data area in the sheet
availableBot_dfin Customized Program 21:- 2 colors are used to divide the main data area in the sheet
21 - availableBot_header.- Data not filled with any color mean
Keyis the direct index of the variablebot. - Data in the blue area mean
Keyis the direct indexLoLChampions[bot["id"]].
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
member_dfin Customized Program 21:- The main data area in the sheet
21 - member_headerisn't filled with any color.memberdenotes any element inmembers.Keyis the index ofmembers.
- The main data area in the sheet
ballot_player_dfin Customized Program 21:- The main data area in the sheet
21 - ballot_player_headerisn't filled with any color.playerdenotes any element inhonor_ballot["eligibleAllies"] + honor_ballot["eligibleOpponents"].Keyis the index ofplayer.
- The main data area in the sheet
eog_mastery_update_dfin Customized Program 21:- The main data area in the sheet
21 - eog_mastery_update_headerisn't filled with any color.Keyis the index ofmastery_updates.KeyNo. 0~18 is the direct index ofmastery_updates.- The latter half of
KeyNo. 19~21 is the direct index ofLoLChampions[mastery_updates["championId"]]. - The latter half of
KeyNo. 22 and 23 is the direct index ofplayer_info["body"].
- The main data area in the sheet
eog_stat_metaDf_lolin Customized Program 21:- 4 colors are used to divide the main data area in the sheet
21 - eog_stat_metadata_lol_head(21 - eog_stat_metadata_lol_header).- Data not filled with any color mean
Keyis the index ofeog_stats_block. - Data in the blue area mean the latter half of
Keyis the direct index ofeog_stats_block["mucJwtDto"]. - Data in the green area mean the latter half of
Keyis the direct index ofeog_stats_block["rerollData"]. - Data in the orange area mean the latter half of
Keyis the index ofeog_stats_block["teamBoost"]. - Data in the blue, green and orange areas are handled by the same code frame.
- Data not filled with any color mean
- 4 colors are used to divide the main data area in the sheet
eog_teamstat_df_lolin Customized Program 21:- 2 colors are used to divide the main data area in the sheet
21 - eog_stat_metadata_lol_head(21 - eog_stat_metadata_lol_header).teamdenotes any element ineog_stats_block["teams"].- Data not filled with any color mean
Keyis the index ofteam. - Data in the blue area mean the latter half of
Keyis the index ofteam["stats"].
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
eog_playerstat_df_lolin Customized Program 21:- 2 colors are used to divide the main data area in the sheet
21 - eog_player_stat_lol_he(21 - eog_player_stat_lol_header).teamdenotes any element ineog_stats_block["teams"].playerdenotes any element inteam["players"].- Data not filled with any color mean
Keyis the index ofplayer. - Data in the blue area mean the latter half of
Keyis the index ofplayer["stats"].
- Data not filled with any color mean
- 2 colors are used to divide the main data area in the sheet
eog_stat_metaDf_tftin Customized Program 21:- The main data area in the sheet
21 - eog_stat_metadata_lol_he(21 - eog_playerstat_data_lol_header) isn't filled with any color.Keyis the index oftft_eog_stats.
- The main data area in the sheet
eog_stat_df_tftin Customized Program 21:- 7 colors are used to divide the main data area in the sheet
21 - eog_playerstat_data_tft_he(21 - eog_playerstat_data_tft_header).playerdenotes any element intft_eog_stats["players"].- Data not filled with any color mean
Keyis the index ofplayer.KeyNo. 0~14 is the direct index ofplayer.- The latter half of
KeyNo. 15 and 16 is the direct index ofsummonerIcons[player["iconId"]].
- Data in the green area mean the latter half of
Keyis the direct index ofplayer["augments"][augmentIndex]. - Data in the orange area mean the latter half of
Keyis the direct index ofplayer["boardPieces"][unit_index]. - Data in the blue area mean the third part of
Keyis the direct index ofplayer["boardPieces"][unit_index]["items"][item_index]. - Data in the purple area mean the latter half of
Keyis the direct index ofplayer["companion"]. - Data in the yellow area mean the latter half of
Keyis the direct index ofplayer["customAugmentContainer"]. - Data in the purple area mean the latter half of
Keyis the direct index ofplayer["playbook"]. - Data in the purple, yellow and pink areas are handled by the same code frame.
- Data not filled with any color mean
- 7 colors are used to divide the main data area in the sheet
LoLItem_df's metadata in Item Program:- 3 colors are used to divide the main data area in the sheet
Item Program - base_header (ddr.itemdenotes the value of keyiinLoLItems_locale["data"].item_defaultdenotes the value of keyiinLoLItems_default["data"].- Data not filled with any color mean
Keydoesn't serve as the index of any variables of item data. - Data in the blue area mean
Keyis the index ofitem. - Data in the blue area mean
Keycomes fromitem["gold"].
- Data not filled with any color mean
- The main data area in the sheet
Item Program - base_header (cdrisn't filled with any color.itemdenotes any element inLoLItems_locale.item_defaultdenotes any element inLoLItems_default.Keyis the index ofitem.
- 3 colors are used to divide the main data area in the sheet
- The following is the illustration on the structure of
- Declaration: Please name the subsequent customized programs in order, following the format
- Normally, text files generated by this program set are organized with indents. If the original dictionary variable in python runtime environment is required to recur, then simply pass a file pointer created by
openfunction to theloadfunction injsonlibrary, such asfp = open("{filename}.txt", "r", encoding = "utf-8")andd = json.load(fp).- If the user wants to transform a json string with indents generated by
dumpsfunction into a json string without indents just in the runtime environment, he/she only needs to pass the string generated bydumpsfunctin intoloadsfunction, such asformatted = json.dumps({dictvariable}, indent = 8, ensure_ascii = False)andd = json.loads(formatted).
- If the user wants to transform a json string with indents generated by
As a beginner in programming, I've just learned some basic usage of Python, and each function is implemented based on structured programming, without using the concepts of classes and objects, which may explain the code redundancy and low level of integration. For example, in Customized Program 05, a number of lines of codes are actually copied from some other part of the code. Moreover, for long strings, I choose to write them in single lines, considering decreasing the number of code lines, which is not friendly for a glance, and I apologize for this. In addition, I realized that more annotations are needed for the codes. Last but not least, since I haven't learned anything about GUI (the only one I've ever used is Visual Basic 😂), I'm only capable of designing programs that interact with CMD. (To be honest, I haven't planned to design the graphics interface for now and in the near future.)
To be honest, there're not any really innovative ideas besides ZhiHu Author XHXIAIEIN's perception and Riot's official API. The program set mainly crawls and sorts out data. If any interesting idea pops up in your mind, welcome to fork this repository, create your own branch and submit pull requests!
In the future, if possible, I'll perform a regression based on the match information dataframe generated by Customized Program 05 but combined with WeGame or OP.GG score, to predict the current player performance evaluation mechanism.