From 02522696b63ea1098d87e5c97044a7c9e376fb47 Mon Sep 17 00:00:00 2001 From: SkywalkerJi Date: Sat, 26 Feb 2022 23:56:37 +0800 Subject: [PATCH] v0.2.10 --- README.md | 35 +- data/breakpoint.json | 170 ++++++++ data/tier.json | 930 +++++++++++++++++++++++++++++++++++++++++++ locales/zh-CN.json | 3 +- locales/zh-TW.json | 3 +- mdt.py | 14 + mdt_gui.py | 22 + mdt_service.py | 16 + 8 files changed, 1187 insertions(+), 6 deletions(-) create mode 100644 data/breakpoint.json create mode 100644 data/tier.json diff --git a/README.md b/README.md index 18d0be1..d1d2f17 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,7 @@ Yu-Gi-Oh! Master Duel Translation Script * 一键导出Master Duel游戏卡组,兼容ygopro格式。 * 可一键直达网页卡查和官方数据库,MDT也有目前最好的 [Secret Pack查询工具](https://ygo.xn--uesr8qr0rdwk.cn/)。 * 支持全屏置顶、无边框、半透明。 +* 支持对重要UR,主流断点进行警示。 ![MDT](https://github.com/SkywalkerJi/mdt/raw/master/IMG/v0.2.5.png "MDT v0.2.5") @@ -145,7 +146,6 @@ python mdt_cli.py [![Video Views](https://bilistats.lonelyion.com/views?uid=2012479&style=social&label=BiliBili&format=short)](https://www.bilibili.com/video/av551332211) [![YouTube Video Views](https://img.shields.io/youtube/views/AnzWFG2RZr0?style=social&label=YouTube)](https://www.youtube.com/watch?v=AnzWFG2RZr0) - *卡图反和谐补丁* [![Video Views](https://bilistats.lonelyion.com/views?uid=2012479&style=social&label=BiliBili&format=short)](https://www.bilibili.com/video/av765979539) [![YouTube Video Views](https://img.shields.io/youtube/views/ickw082Snwo?style=social&label=YouTube)](https://www.youtube.com/watch?v=ickw082Snwo) @@ -230,6 +230,30 @@ CLI版本在MDT v0.2.3版本进行拆分,拆分后对CLI版本只做基础可 +
+ Q6:以前能使用,现在无法使用?切换不同账号后无法使用?我确定开启条件正确,但是一直显示“等待检测”? + +先在游戏的开始页面(game start 那个页面),确认左上角的游戏版本号和readme中支持的游戏版本号一致。如果不一致请更新MDT或更新游戏。 + +确认其他条件正确,比如:使用管理员权限开启,已经完整解压全部文件,右键exe属性中解除锁定,在安全软件中添加信任,点击一张卡等。 + +如果条件都正确,请尝试更改steam存档缓存文件后缀。一般在游戏安装位置,目录地址类似`SteamLibrary\steamapps\common\Yu-Gi-Oh! Master Duel\LocalData`。里面有一个形如`93b16f2`的文件夹。先备份一下,然后在这个文件夹后面加几个1,`93b16f21111111111111111`。再开游戏和mdt试一下。 + +
+ +
+ Q6:MDT为何不支持抽卡界面汉化? + +目前对抽卡界面进行汉化需要对游戏进行注入,操作风险较高。所以还在考虑当中。 + +还有一种办法是引入CV引擎进行匹配,侵入性小,但是会消耗部分性能。 + +另外商店卡片是固定的,卡表可以在[MDT-web](https://ygo.xn--uesr8qr0rdwk.cn/)查询。 + +如果你有更好的实现方式欢迎[issue](https://github.com/SkywalkerJi/mdt/issues/new)或 Pull Request。 + +
+ ## Contributing 有其他指针或功能欢迎提交 [issue](https://github.com/SkywalkerJi/mdt/issues/new) 或 Pull Request。 @@ -239,19 +263,22 @@ CLI版本在MDT v0.2.3版本进行拆分,拆分后对CLI版本只做基础可 如果你有错误报告、建议、想法,请随时通过以下方式联系开发者: * [issue](https://github.com/SkywalkerJi/mdt/issues/new) +* [![YouTube Channel Subscribers](https://img.shields.io/youtube/channel/subscribers/UC3kA_NGfQFHMMn-kja8GTFA?style=social)](https://www.youtube.com/channel/UC3kA_NGfQFHMMn-kja8GTFA?sub_confirmation=1) +* [Telegram](https://t.me/ygomasterduel) +* [![Twitter Follow](https://img.shields.io/twitter/follow/Skywalker_Ji?style=social&label=Follow)](https://twitter.com/Skywalker_Ji) * [NGA](https://bbs.nga.cn/read.php?tid=30415633) * [巴哈姆特](https://forum.gamer.com.tw/C.php?bsn=725&snA=54550&tnum=1) * [Q群 710144213](https://jq.qq.com/?_wv=1027&k=uyFt3qi0) -* [Telegram](https://t.me/ygomasterduel) -* [![Twitter Follow](https://img.shields.io/twitter/follow/Skywalker_Ji?style=social&label=Follow)](https://twitter.com/Skywalker_Ji) * [![Followers](https://bilistats.lonelyion.com/followers?uid=2012479&style=social&format=short&label=BiliBili%20关注)](https://space.bilibili.com/2012479) -* [![YouTube Channel Subscribers](https://img.shields.io/youtube/channel/subscribers/UC3kA_NGfQFHMMn-kja8GTFA?style=social)](https://www.youtube.com/channel/UC3kA_NGfQFHMMn-kja8GTFA?sub_confirmation=1) * 或其他途径。 ## Changelog *v0.2.10* * 支持配置隐藏滚动条。 +* 添加重要UR提示,数据基于NTUCGM。重要UR的卡密颜色会变更:红色为可以定义环境的强力卡片,是T1主流套牌的核心部件,不建议分解。绿色为部分卡组的构筑主力,如果要分解请务必确认。白色为普通UR,可考虑分解。 +* 添加主流卡组断点提示。主流卡组核心断点会进行警告,卡密背景底色变为橙色。目前支持:黄金国,龙辉巧,闪刀姬,幻影骑士团,电脑堺,恩底弥翁,召唤师,龙女仆,魔救,雷龙,英雄,调皮宝贝,源数,割草,抒情歌鸲,魔偶甜点,龙link。 +* 提示卡表可在data文件夹中自定义。或开启issue,我将在确定卡表后在下个版本中进行添加。 *v0.2.9* * 对游戏steam版本V1.0.2进行支持。 diff --git a/data/breakpoint.json b/data/breakpoint.json new file mode 100644 index 0000000..e3d1f35 --- /dev/null +++ b/data/breakpoint.json @@ -0,0 +1,170 @@ +{ + "13669": { + "cn_name": "闪刀姬-雫空", + "tier": 99 + }, + "13671": { + "cn_name": "闪刀起动-交闪", + "tier": 99 + }, + "13668": { + "cn_name": "闪刀姬-燎里", + "tier": 99 + }, + "15127": { + "cn_name": "红化血染之黄金国永生药", + "tier": 99 + }, + "15125": { + "cn_name": "黑化觉醒之黄金国永生药", + "tier": 99 + }, + "15635": { + "cn_name": "龙辉巧-右枢α", + "tier": 99 + }, + "16004": { + "cn_name": "龙辉巧-扶筐增二μβ'", + "tier": 99 + }, + "15083": { + "cn_name": "宣告者的神巫", + "tier": 99 + }, + "6845": { + "cn_name": "电子化天使-弁天-", + "tier": 99 + }, + "15487": { + "cn_name": "铁兽战线 弗拉克杜尔", + "tier": 99 + }, + "15012": { + "cn_name": "半龙女仆·寝室龙女", + "tier": 99 + }, + "12843": { + "cn_name": "召唤师 阿莱斯特", + "tier": 99 + }, + "15489": { + "cn_name": "电脑堺媛-瑞瑞", + "tier": 99 + }, + "15490": { + "cn_name": "电脑堺悟-老老", + "tier": 99 + }, + "14054": { + "cn_name": "幻影骑士团 锈蚀月刃斧", + "tier": 99 + }, + "15482": { + "cn_name": "幻影骑士团 破洞鳞甲", + "tier": 99 + }, + "13507": { + "cn_name": "刚炼装勇士·银金公主", + "tier": 99 + }, + "14442": { + "cn_name": "恩底弥翁的仆从", + "tier": 99 + }, + "13392": { + "cn_name": "魔导兽 胡狼", + "tier": 99 + }, + "13397": { + "cn_name": "魔导兽 刻耳柏洛斯尊主", + "tier": 99 + }, + "15098": { + "cn_name": "魔救之探索者", + "tier": 99 + }, + "15097": { + "cn_name": "魔救之追求者", + "tier": 99 + }, + "15099": { + "cn_name": "魔救之分析者", + "tier": 99 + }, + "13906": { + "cn_name": "雷电龙-雷龙", + "tier": 99 + }, + "13908": { + "cn_name": "雷兽龙-雷龙", + "tier": 99 + }, + "13581": { + "cn_name": "太阳电池人", + "tier": 99 + }, + "15478": { + "cn_name": "混沌领域", + "tier": 99 + }, + "9063": { + "cn_name": "幻影英雄 增量人", + "tier": 99 + }, + "14099": { + "cn_name": "调皮宝贝·岩石娃", + "tier": 99 + }, + "14022": { + "cn_name": "调皮宝贝·脉冲娃", + "tier": 99 + }, + "14021": { + "cn_name": "调皮宝贝·水滴娃", + "tier": 99 + }, + "14020": { + "cn_name": "调皮宝贝·火灯娃", + "tier": 99 + }, + "15384": { + "cn_name": "源数网络", + "tier": 99 + }, + "12801": { + "cn_name": "邻家割草", + "tier": 99 + }, + "5530": { + "cn_name": "名推理", + "tier": 99 + }, + "5980": { + "cn_name": "怪兽之门", + "tier": 99 + }, + "16394": { + "cn_name": "抒情歌鸲-鸟鸣呼唤", + "tier": 99 + }, + "12862": { + "cn_name": "抒情歌鸲-吟诵椋鸟", + "tier": 99 + }, + "11726": { + "cn_name": "魔偶甜点·布丁公主 巧克力布丁拼盘", + "tier": 99 + }, + "14198": { + "cn_name": "龙骑兵团骑士-始枪龙骑士", + "tier": 99 + }, + "14618": { + "cn_name": "绝对路由龙", + "tier": 99 + }, + "15756": { + "cn_name": "金满而谦虚之壶", + "tier": 99 + } +} \ No newline at end of file diff --git a/data/tier.json b/data/tier.json new file mode 100644 index 0000000..7770811 --- /dev/null +++ b/data/tier.json @@ -0,0 +1,930 @@ +{ + "7557": { + "cn_name": "真红眼暗钢龙", + "tier": 2 + }, + "11927": { + "cn_name": "太阳神之翼神龙-球体形", + "tier": 2 + }, + "13010": { + "cn_name": "究极传导恐兽", + "tier": 2 + }, + "15089": { + "cn_name": "机甲上校", + "tier": 2 + }, + "14770": { + "cn_name": "光界王战 玛多尔女王", + "tier": 2 + }, + "14801": { + "cn_name": "神威凤凰剑圣 基亚·弗里德", + "tier": 2 + }, + "14833": { + "cn_name": "机巧蹄-天迦久御雷", + "tier": 2 + }, + "5835": { + "cn_name": "混沌战士 -开辟的使者-", + "tier": 2 + }, + "6821": { + "cn_name": "光与暗之龙", + "tier": 2 + }, + "6888": { + "cn_name": "虚无之统括者", + "tier": 2 + }, + "7096": { + "cn_name": "命运英雄 血魔-D", + "tier": 2 + }, + "8283": { + "cn_name": "大天使 克里斯提亚", + "tier": 2 + }, + "9712": { + "cn_name": "暗黑界的龙神 格拉法", + "tier": 2 + }, + "12038": { + "cn_name": "怒炎坏兽 多哥兰", + "tier": 2 + }, + "12090": { + "cn_name": "天帝 埃忒耳", + "tier": 2 + }, + "12091": { + "cn_name": "冥帝 厄瑞玻斯", + "tier": 2 + }, + "12253": { + "cn_name": "青眼亚白龙", + "tier": 2 + }, + "13397": { + "cn_name": "魔导兽 刻耳柏洛斯尊主", + "tier": 2 + }, + "13912": { + "cn_name": "混源龙 巨涡始祖神", + "tier": 2 + }, + "13978": { + "cn_name": "未界域的大脚怪", + "tier": 2 + }, + "14056": { + "cn_name": "死灵王 恶眼", + "tier": 2 + }, + "14480": { + "cn_name": "机巧蛇-丛云远吕智", + "tier": 2 + }, + "15242": { + "cn_name": "教导的骑士 弗勒德莉丝", + "tier": 2 + }, + "15502": { + "cn_name": "兽王 阿尔法", + "tier": 2 + }, + "8110": { + "cn_name": "霞之谷的巨神鸟", + "tier": 2 + }, + "8692": { + "cn_name": "机甲要塞", + "tier": 2 + }, + "10522": { + "cn_name": "岚征龙-飙龙", + "tier": 2 + }, + "12901": { + "cn_name": "元素英雄 真诚新宇侠", + "tier": 2 + }, + "12906": { + "cn_name": "宙读之魔术士", + "tier": 2 + }, + "13819": { + "cn_name": "时械神 桑达伊恩", + "tier": 2 + }, + "14439": { + "cn_name": "创圣魔导王 恩底弥翁", + "tier": 2 + }, + "13396": { + "cn_name": "魔导兽 胡狼王", + "tier": 2 + }, + "9190": { + "cn_name": "幻影英雄 独善人", + "tier": 2 + }, + "11195": { + "cn_name": "古遗物-死镰", + "tier": 2 + }, + "6262": { + "cn_name": "救援猫", + "tier": 2 + }, + "6784": { + "cn_name": "元素英雄 天空侠", + "tier": 2 + }, + "7397": { + "cn_name": "雷王", + "tier": 2 + }, + "9229": { + "cn_name": "幻影英雄 仿生人", + "tier": 2 + }, + "9244": { + "cn_name": "黑羽-精锐之泽费洛斯", + "tier": 2 + }, + "11615": { + "cn_name": "娱乐伙伴 灵摆魔术家", + "tier": 2 + }, + "12441": { + "cn_name": "妖精传姬-白雪", + "tier": 2 + }, + "12688": { + "cn_name": "秘旋谍-花公子", + "tier": 2 + }, + "12952": { + "cn_name": "妖精传姬-辉夜", + "tier": 2 + }, + "13011": { + "cn_name": "食魂窃蛋龙", + "tier": 2 + }, + "13039": { + "cn_name": "电子界工具", + "tier": 2 + }, + "13047": { + "cn_name": "淘气仙星·坎迪娜", + "tier": 2 + }, + "13405": { + "cn_name": "冲浪检察官", + "tier": 2 + }, + "13459": { + "cn_name": "地中族导师", + "tier": 2 + }, + "13581": { + "cn_name": "太阳电池人", + "tier": 2 + }, + "15010": { + "cn_name": "宵星之骑士 吉尔苏", + "tier": 2 + }, + "9702": { + "cn_name": "由魔界到现世的死亡导游", + "tier": 2 + }, + "11168": { + "cn_name": "数学家", + "tier": 2 + }, + "11560": { + "cn_name": "齐唱僵尸", + "tier": 2 + }, + "12033": { + "cn_name": "星际仙踪-多萝塞尔", + "tier": 2 + }, + "12312": { + "cn_name": "浮幽樱", + "tier": 2 + }, + "13463": { + "cn_name": "幻变骚灵·多功能诈骗者", + "tier": 2 + }, + "15022": { + "cn_name": "朔夜时雨", + "tier": 2 + }, + "4817": { + "cn_name": "精神操作", + "tier": 2 + }, + "4821": { + "cn_name": "手札抹杀", + "tier": 2 + }, + "5328": { + "cn_name": "增援", + "tier": 2 + }, + "5551": { + "cn_name": "天声的服从", + "tier": 2 + }, + "6161": { + "cn_name": "封印之黄金柜", + "tier": 2 + }, + "6901": { + "cn_name": "简易融合", + "tier": 2 + }, + "7187": { + "cn_name": "英雄到来", + "tier": 2 + }, + "7248": { + "cn_name": "抵价购物", + "tier": 2 + }, + "8352": { + "cn_name": "化石调查", + "tier": 2 + }, + "12250": { + "cn_name": "遭受妨碍的坏兽安眠", + "tier": 2 + }, + "13671": { + "cn_name": "闪刀起动-交闪", + "tier": 2 + }, + "14137": { + "cn_name": "新宇融合", + "tier": 2 + }, + "14301": { + "cn_name": "电脑网挖矿", + "tier": 2 + }, + "14742": { + "cn_name": "冥王结界波", + "tier": 2 + }, + "14876": { + "cn_name": "闪电风暴", + "tier": 2 + }, + "15286": { + "cn_name": "天底的使徒", + "tier": 2 + }, + "5533": { + "cn_name": "王家长眠之谷", + "tier": 2 + }, + "7857": { + "cn_name": "不死世界", + "tier": 2 + }, + "9049": { + "cn_name": "龙之溪谷", + "tier": 2 + }, + "11851": { + "cn_name": "试胆竞速", + "tier": 2 + }, + "12572": { + "cn_name": "暗黑圣域", + "tier": 2 + }, + "13092": { + "cn_name": "淘气仙星的灯光舞台", + "tier": 2 + }, + "15384": { + "cn_name": "源数网络", + "tier": 2 + }, + "15642": { + "cn_name": "流星辉巧群", + "tier": 2 + }, + "7445": { + "cn_name": "超融合", + "tier": 2 + }, + "11101": { + "cn_name": "古遗物的神智", + "tier": 2 + }, + "12900": { + "cn_name": "鹰身女妖的羽毛吹雪", + "tier": 2 + }, + "13634": { + "cn_name": "打草惹蛇", + "tier": 2 + }, + "14901": { + "cn_name": "梦现之梦魔镜", + "tier": 2 + }, + "14328": { + "cn_name": "大逮捕", + "tier": 2 + }, + "4426": { + "cn_name": "恶魔科学怪人", + "tier": 2 + }, + "15083": { + "cn_name": "宣告者的神巫", + "tier": 2 + }, + "14906": { + "cn_name": "魔术师双魂", + "tier": 2 + }, + "11377": { + "cn_name": "崇光之宣告者", + "tier": 2 + }, + "15640": { + "cn_name": "龙仪巧-天龙流星=DRA", + "tier": 2 + }, + "11485": { + "cn_name": "三叉龙之影灵衣", + "tier": 2 + }, + "13358": { + "cn_name": "嵌合巨舰龙", + "tier": 2 + }, + "13924": { + "cn_name": "雷神龙-雷龙", + "tier": 2 + }, + "14025": { + "cn_name": "调皮宝贝屋子管家", + "tier": 2 + }, + "15027": { + "cn_name": "半龙女仆·耀光龙女", + "tier": 2 + }, + "14765": { + "cn_name": "半龙女仆·龙女管家", + "tier": 2 + }, + "11258": { + "cn_name": "神影依·拿非利", + "tier": 2 + }, + "12590": { + "cn_name": "ABC-神龙歼灭者", + "tier": 2 + }, + "13923": { + "cn_name": "超雷龙-雷龙", + "tier": 2 + }, + "15272": { + "cn_name": "灰烬龙 落胤龙", + "tier": 2 + }, + "15994": { + "cn_name": "烙印龙 白界龙", + "tier": 2 + }, + "11313": { + "cn_name": "假面英雄 暗爪", + "tier": 2 + }, + "11257": { + "cn_name": "神影依·米德拉什", + "tier": 2 + }, + "14968": { + "cn_name": "神影依·七贤巨鲲魔", + "tier": 2 + }, + "11878": { + "cn_name": "旧神 努茨", + "tier": 2 + }, + "13466": { + "cn_name": "千年眼纳祭神", + "tier": 2 + }, + "11614": { + "cn_name": "奥特玛雅·卓尔金", + "tier": 2 + }, + "14751": { + "cn_name": "炎斩机 终末西格马", + "tier": 2 + }, + "13852": { + "cn_name": "黑羽-重装铠翼鸦", + "tier": 2 + }, + "15996": { + "cn_name": "红莲蔷薇龙", + "tier": 2 + }, + "7973": { + "cn_name": "正义盟军 陆军元帅", + "tier": 2 + }, + "8732": { + "cn_name": "冰结界之龙 三叉龙", + "tier": 2 + }, + "11722": { + "cn_name": "幻龙星-嘲风", + "tier": 2 + }, + "12078": { + "cn_name": "琰魔龙 红莲魔·渊", + "tier": 2 + }, + "12324": { + "cn_name": "青眼精灵龙", + "tier": 2 + }, + "12781": { + "cn_name": "水晶机巧-中枢大蛇", + "tier": 2 + }, + "15515": { + "cn_name": "电脑堺狐-仙仙", + "tier": 2 + }, + "11834": { + "cn_name": "爆龙剑士 点火星·日珥", + "tier": 2 + }, + "12074": { + "cn_name": "PSY骨架王·Ω", + "tier": 2 + }, + "12321": { + "cn_name": "水晶翼同调龙", + "tier": 2 + }, + "14114": { + "cn_name": "装弹枪管狞猛龙", + "tier": 2 + }, + "14662": { + "cn_name": "天威之龙鬼神", + "tier": 2 + }, + "15105": { + "cn_name": "魔救之奇迹-巨龙晶石", + "tier": 2 + }, + "15277": { + "cn_name": "混沌魔龙 混沌支配者", + "tier": 2 + }, + "7898": { + "cn_name": "黑蔷薇龙", + "tier": 2 + }, + "8137": { + "cn_name": "动力工具龙", + "tier": 2 + }, + "13710": { + "cn_name": "方程式运动员 电光赛道名将", + "tier": 2 + }, + "15232": { + "cn_name": "电脑堺兽-鹫鹫", + "tier": 2 + }, + "7696": { + "cn_name": "废品战士", + "tier": 2 + }, + "9554": { + "cn_name": "科技属 超图书馆员", + "tier": 2 + }, + "12638": { + "cn_name": "源龙星-望天吼", + "tier": 2 + }, + "16471": { + "cn_name": "No.99 希望皇 霍普德拉戈纳", + "tier": 2 + }, + "14180": { + "cn_name": "超重型炮塔列车 破天巨爱", + "tier": 2 + }, + "9963": { + "cn_name": "超重型炮塔列车 古斯塔夫最大炮", + "tier": 2 + }, + "11069": { + "cn_name": "No.62 银河眼光子龙皇", + "tier": 2 + }, + "11461": { + "cn_name": "银河眼 重铠光子龙", + "tier": 2 + }, + "12260": { + "cn_name": "No.38 希望魁龙 银河巨神", + "tier": 2 + }, + "14288": { + "cn_name": "宵星之机神 丁吉尔苏", + "tier": 2 + }, + "10004": { + "cn_name": "星圣神龙 托勒密星团M7", + "tier": 2 + }, + "12108": { + "cn_name": "永远的淑女 贝阿特丽切", + "tier": 2 + }, + "11765": { + "cn_name": "电子龙·无限", + "tier": 2 + }, + "9824": { + "cn_name": "星圣·昴星团", + "tier": 2 + }, + "11726": { + "cn_name": "魔偶甜点·布丁公主 巧克力布丁拼盘", + "tier": 2 + }, + "15520": { + "cn_name": "弧叛逆超量龙", + "tier": 2 + }, + "9761": { + "cn_name": "进化帝·半鸟龙", + "tier": 2 + }, + "9822": { + "cn_name": "大薰风骑士 翠玉", + "tier": 2 + }, + "9869": { + "cn_name": "进化帝·翔龙", + "tier": 2 + }, + "10176": { + "cn_name": "齿轮齿巨人 X", + "tier": 2 + }, + "10270": { + "cn_name": "魔偶甜点后·后冠提拉米苏", + "tier": 2 + }, + "10332": { + "cn_name": "龙神鲨", + "tier": 2 + }, + "10354": { + "cn_name": "深渊的潜伏者", + "tier": 2 + }, + "13019": { + "cn_name": "龙卷龙", + "tier": 2 + }, + "14289": { + "cn_name": "魔偶甜点教师·眼镜蛋奶酥", + "tier": 2 + }, + "11320": { + "cn_name": "彼岸的旅人 但丁", + "tier": 2 + }, + "12642": { + "cn_name": "饼蛙", + "tier": 2 + }, + "12544": { + "cn_name": "No.100 源数龙", + "tier": 2 + }, + "12862": { + "cn_name": "抒情歌鸲-吟诵椋鸟", + "tier": 2 + }, + "16004": { + "cn_name": "龙辉巧-扶筐增二μβ'", + "tier": 2 + }, + "16392": { + "cn_name": "抒情歌鸲-合唱小琉璃", + "tier": 2 + }, + "15036": { + "cn_name": "电子界到临者@火灵天星", + "tier": 2 + }, + "15741": { + "cn_name": "闭锁世界的冥神", + "tier": 2 + }, + "13082": { + "cn_name": "防火龙", + "tier": 2 + }, + "13258": { + "cn_name": "装弹枪管龙", + "tier": 2 + }, + "13419": { + "cn_name": "锁龙蛇-骷髅四面鬼", + "tier": 2 + }, + "13602": { + "cn_name": "梦幻崩影·狮鹫", + "tier": 2 + }, + "14028": { + "cn_name": "调皮宝贝吼吼龙", + "tier": 2 + }, + "15527": { + "cn_name": "铁兽战线 凶鸟之施莱格", + "tier": 2 + }, + "13036": { + "cn_name": "解码语者", + "tier": 2 + }, + "13089": { + "cn_name": "星杯战士 宁吉尔苏", + "tier": 2 + }, + "13416": { + "cn_name": "廷达魔三角之锐角地狱犬", + "tier": 2 + }, + "13492": { + "cn_name": "光道宰制者 基里奥斯", + "tier": 2 + }, + "13590": { + "cn_name": "拓扑三叶双头蛇", + "tier": 2 + }, + "14054": { + "cn_name": "幻影骑士团 锈蚀月刃斧", + "tier": 2 + }, + "14193": { + "cn_name": "混沌之战士 混沌战士", + "tier": 2 + }, + "14935": { + "cn_name": "王神鸟 斯摩夫", + "tier": 2 + }, + "14937": { + "cn_name": "神圣魔皇后 塞勒涅", + "tier": 2 + }, + "14940": { + "cn_name": "幻兽机 曙光女神百头龙", + "tier": 2 + }, + "13371": { + "cn_name": "秘旋谍-双螺旋特工", + "tier": 2 + }, + "13496": { + "cn_name": "天球之圣刻印", + "tier": 2 + }, + "13500": { + "cn_name": "圣骑士的追想 伊索德", + "tier": 2 + }, + "13506": { + "cn_name": "彼岸的黑天使 基路伯", + "tier": 2 + }, + "14125": { + "cn_name": "转生炎兽 日光狼", + "tier": 2 + }, + "14199": { + "cn_name": "废铁翼龙", + "tier": 2 + }, + "14205": { + "cn_name": "急袭猛禽-智慧林鸮", + "tier": 2 + }, + "15282": { + "cn_name": "战华盟将-双龙", + "tier": 2 + }, + "13668": { + "cn_name": "闪刀姬-燎里", + "tier": 2 + }, + "14483": { + "cn_name": "魔女术人偶·阿鲁鲁女神", + "tier": 2 + }, + "14741": { + "cn_name": "原始生命态 尼比鲁", + "tier": 1 + }, + "15123": { + "cn_name": "黄金卿 黄金国巫妖", + "tier": 1 + }, + "13896": { + "cn_name": "恐龙摔跤手·潘克拉辛角龙", + "tier": 1 + }, + "14740": { + "cn_name": "次元吸引者", + "tier": 1 + }, + "11708": { + "cn_name": "幽鬼兔", + "tier": 1 + }, + "12950": { + "cn_name": "灰流丽", + "tier": 1 + }, + "13587": { + "cn_name": "屋敷童", + "tier": 1 + }, + "9455": { + "cn_name": "增殖的G", + "tier": 1 + }, + "8933": { + "cn_name": "效果遮蒙者", + "tier": 1 + }, + "15524": { + "cn_name": "天霆号 阿宙斯", + "tier": 1 + }, + "12960": { + "cn_name": "真龙皇 法·王·兽", + "tier": 1 + }, + "11296": { + "cn_name": "No.86 英豪冠军 击灭枪王", + "tier": 1 + }, + "12788": { + "cn_name": "十二兽 龙枪", + "tier": 1 + }, + "14958": { + "cn_name": "未来No.0 未来龙皇 霍普", + "tier": 1 + }, + "13750": { + "cn_name": "刺刀枪管龙", + "tier": 1 + }, + "14297": { + "cn_name": "双穹之骑士 阿斯特拉姆", + "tier": 1 + }, + "14496": { + "cn_name": "召命之神弓-阿波罗萨", + "tier": 1 + }, + "15032": { + "cn_name": "访问码语者", + "tier": 1 + }, + "13601": { + "cn_name": "梦幻崩影·独角兽", + "tier": 1 + }, + "13508": { + "cn_name": "水晶机巧-继承玻纤", + "tier": 1 + }, + "14676": { + "cn_name": "I:P伪装舞会莱娜", + "tier": 1 + }, + "14932": { + "cn_name": "同盟运输车", + "tier": 1 + }, + "14944": { + "cn_name": "捕食植物 青锁龙森蚺", + "tier": 1 + }, + "13346": { + "cn_name": "连接栗子球", + "tier": 1 + }, + "14338": { + "cn_name": "转生炎兽 独角兔", + "tier": 1 + }, + "4842": { + "cn_name": "死者苏生", + "tier": 1 + }, + "5236": { + "cn_name": "愚蠢的埋葬", + "tier": 1 + }, + "4895": { + "cn_name": "成金哥布林", + "tier": 1 + }, + "5537": { + "cn_name": "星球改造", + "tier": 1 + }, + "8197": { + "cn_name": "一对一", + "tier": 1 + }, + "12801": { + "cn_name": "邻家割草", + "tier": 1 + }, + "15296": { + "cn_name": "三战之才", + "tier": 1 + }, + "13619": { + "cn_name": "墓穴的指名者", + "tier": 1 + }, + "14627": { + "cn_name": "抹杀之指名者", + "tier": 1 + }, + "15299": { + "cn_name": "禁忌的一滴", + "tier": 1 + }, + "4343": { + "cn_name": "雷击", + "tier": 1 + }, + "4678": { + "cn_name": "鹰身女妖的羽毛扫", + "tier": 1 + }, + "13631": { + "cn_name": "无限泡影", + "tier": 1 + }, + "4861": { + "cn_name": "神之宣告", + "tier": 1 + }, + "12187": { + "cn_name": "神之通告", + "tier": 1 + }, + "4960": { + "cn_name": "王宫的敕命", + "tier": 1 + }, + "9153": { + "cn_name": "虚无空间", + "tier": 1 + }, + "13447": { + "cn_name": "千查万别", + "tier": 1 + } +} \ No newline at end of file diff --git a/locales/zh-CN.json b/locales/zh-CN.json index 66b21ef..1b49236 100644 --- a/locales/zh-CN.json +++ b/locales/zh-CN.json @@ -40,6 +40,7 @@ "显示英文名": "显示英文名", "显示日文名": "显示日文名", "显示卡密": "显示卡密", - "卡包查询": "卡包查询" + "卡包查询": "卡包查询", + "隐藏滚动条": "隐藏滚动条" } } \ No newline at end of file diff --git a/locales/zh-TW.json b/locales/zh-TW.json index b82bf51..f02e3cc 100644 --- a/locales/zh-TW.json +++ b/locales/zh-TW.json @@ -40,6 +40,7 @@ "显示英文名": "顯示英文名", "显示日文名": "顯示日文名", "显示卡密": "顯示卡號", - "卡包查询": "卡包查詢" + "卡包查询": "卡包查詢", + "隐藏滚动条": "隱藏滾動條" } } \ No newline at end of file diff --git a/mdt.py b/mdt.py index 56f317d..da0f2c6 100644 --- a/mdt.py +++ b/mdt.py @@ -23,6 +23,8 @@ sleep_time = 0.1 cards_db_CN = {} cards_db_TW = {} +card_tier_list = {} +break_point = {} pause_hotkey = "ctrl+p" switch_hotkey = "ctrl+s" @@ -155,6 +157,8 @@ def config_load(): global switch_hotkey global cards_db_CN global cards_db_TW + global card_tier_list + global break_point con = configparser.ConfigParser() try: con.read(config_file, encoding="utf-8") @@ -175,6 +179,16 @@ def config_load(): cards_db_TW = json.load(f) except Exception: pass + try: + with open("./data/tier.json", "rb") as f: + card_tier_list = json.load(f) + except Exception: + pass + try: + with open("./data/breakpoint.json", "rb") as f: + break_point = json.load(f) + except Exception: + pass def main(): diff --git a/mdt_gui.py b/mdt_gui.py index c389e05..a573f67 100644 --- a/mdt_gui.py +++ b/mdt_gui.py @@ -117,6 +117,26 @@ def i18n_set(locale: str): i18n.set("locale", locale) +def show_card_tier(window, cid): + tier = service.get_card_tier(str(cid)) + if tier: + if tier == 1: + window["-id-"].update(text_color="#FF6666") + if tier == 2: + window["-id-"].update(text_color="#99CC66") + else: + window["-id-"].update(text_color="white") + + +def show_break_point(window, cid): + tier = service.get_break_point(str(cid)) + print(tier) + if tier == 99: + window["-id-"].update(background_color="#FF9933") + else: + window["-id-"].update(background_color="#3F3F3F") + + def main(): global sync_ui global web_search @@ -358,6 +378,8 @@ def main(): else: window["-pdesc_frame-"].update(visible=False) window["-desc-"].update(card_t["text"]["desc"]) + show_card_tier(window, cid) + show_break_point(window, cid) except Exception: pass # print("数据库中未查到该卡") diff --git a/mdt_service.py b/mdt_service.py index b9baa42..84289a4 100644 --- a/mdt_service.py +++ b/mdt_service.py @@ -40,6 +40,22 @@ def get_cards_db(locale: str): return None +def get_card_tier(cid: str): + if mdt.card_tier_list: + if cid in mdt.card_tier_list: + return mdt.card_tier_list[cid]["tier"] + else: + return None + + +def get_break_point(cid: str): + if mdt.break_point: + if cid in mdt.break_point: + return mdt.break_point[cid]["tier"] + else: + return None + + def get_deck_dict(): return reader.get_deck_dict()