misakamikodo / mhxy_script Goto Github PK
View Code? Open in Web Editor NEW梦幻西游手游脚本(基于pyautogui、opencv,在python环境下运行文件)
梦幻西游手游脚本(基于pyautogui、opencv,在python环境下运行文件)
脚本一次只能辅助一个吗
作者您好 可以在mine.py脚本中加入东海湾地图吗
PS D:\mhxy_script-master> python game_process.py
<Win32Window left="36", top="239", width="648", height="513", title="梦幻西游:时空">
处理后: <Win32Window left="71", top="0", width="907", height="707", title="梦幻西游:时空">
<Win32Window left="-32000", top="-32000", width="160", height="28", title="梦幻西游:时空">
Traceback (most recent call last):
File "D:\mhxy_script-master\game_process.py", line 84, in
resize.moveZhuomianban()
File "D:\mhxy_script-master\game_process.py", line 29, in moveZhuomianban
self.__moveZhuomianbanFunc(niceSize)
File "D:\mhxy_script-master\game_process.py", line 16, in moveZhuomianbanFunc
pyautogui.moveTo(item.right - resizeOffset[0], item.bottom - resizeOffset[1])
File "C:\Users\WF\AppData\Local\Programs\Python\Python311\Lib\site-packages\pyautogui_init.py", line 598, in wrapper
returnVal = wrappedFunction(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\WF\AppData\Local\Programs\Python\Python311\Lib\site-packages\pyautogui_init.py", line 1283, in moveTo
mouseMoveDrag("move", x, y, 0, 0, duration, tween)
File "C:\Users\WF\AppData\Local\Programs\Python\Python311\Lib\site-packages\pyautogui_init.py", line 1509, in mouseMoveDrag
failSafeCheck()
File "C:\Users\WF\AppData\Local\Programs\Python\Python311\Lib\site-packages\pyautogui_init.py", line 1722, in failSafeCheck
raise FailSafeException(
pyautogui.FailSafeException: PyAutoGUI fail-safe triggered from mouse moving to a corner of the screen. To disable this fail-safe, set pyautogui.FAILSAFE to False. DISABLING FAIL-SAFE IS NOT RECOMMENDED.
PS D:\mhxy_script-master>
跟踪了脚本的流程,抓鬼是存在流程上的错误的,导致无法使用
OSError: Failed to read resources/fuben/selectfuben.png because file is missing, has improper permissions, or is an unsupported or invalid format
看日志应该是资源文件夹下面少了选择副本的图
大佬这个能不能优化下
还有一个建议是能不能增加挂机技能选择设置(自己设置第几个技能)
应用场景在于副本打完换捉鬼的时候需要换技能(例如辅助关奶)
想用这个来秒低价考古铲子,可以实现吗 多谢大佬
能给个视频教程吗,大佬
刚学python不是很懂,替换完*之后再运行script脚本就行了是吗
作者大哥你好,我是小白。给个联系方式哇,谢谢
大佬 你还更行代码吗
Traceback (most recent call last):
File "C:\Users\24945\Downloads\mhxy_script-master\mhxy_script-master\game_process.py", line 4, in
from mhxy import *
File "C:\Users\24945\Downloads\mhxy_script-master\mhxy_script-master\mhxy.py", line 5, in
import pyautogui
File "C:\Users\24945\anaconda3\lib\site-packages\pyautogui_init_.py", line 180, in
import pyscreeze
File "C:\Users\24945\anaconda3\lib\site-packages\pyscreeze_init_.py", line 25, in
import cv2
File "C:\Users\24945\anaconda3\lib\site-packages\cv2_init_.py", line 181, in
bootstrap()
File "C:\Users\24945\anaconda3\lib\site-packages\cv2_init_.py", line 97, in bootstrap
from . load_config_py3 import exec_file_wrapper
ValueError: source code string cannot contain null bytes
我拉取代码后调整了一下是能用的,我还在此基础上尝试开发了,我挺有兴趣的,可以一起开发,能认识一下吗,可以的话,联系方式可以发我邮箱 [email protected]
感谢楼主提供的免费代码, 找时间研究一下
我有个期望, 斗胆提一下: 这个游戏, 晚间活动, 副本, 地煞活动什么的我们都愿意自己打(5开打, 很快)
特别是副本 我们大号追求低回合过 这样奖励更好
让我最烦的是部分日常活动, 最烦的是宝图, 要点10次, 时间最久的是秘境(30分钟)
我如果作为玩家, 我的实际需求是:
能自动切到第二套装备(环装), 自动完成以下任务
宝图+师门+秘境+答题 非常希望有个工具做掉
实际场景:
一个n100的小盒子(windows)连着一个4G的热点 (每刷玩6个号, python调用adb让手机切一次飞行模式->更换IP)
白天启动开始刷: 宝图+师门+秘境, 然后做临时符摆摊8张, 挂离线抓鬼(换下一个角色)
晚上17点后, 切所有角色答题+领日常1000金币 -> 再次摆摊8张临时符 -> 离线抓鬼 -> 换角色
join
你好,昨天下午的提交里面, 删除的那两个文件,在mhxy_520.py,mhxy_even_guaji.py,myxh_remote_control.py,三个文件中有引用到,文件里面报错了~
运行pyqt脚本报错,
Traceback (most recent call last):
File "d:\mymhxy\ui\mhxy_pyqt.py", line 328, in
MyUiStart = MhxyApplication()
^^^^^^^^^^^^^^^^^
File "d:\mymhxy\ui\mhxy_pyqt.py", line 51, in init
self.cusomer_ipt.setText(self.conn.get('main', 'lastscript'))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Program Files\Python\Lib\configparser.py", line 759, in get
d = self._unify_values(section, vars)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Program Files\Python\Lib\configparser.py", line 1132, in _unify_values
raise NoSectionError(section) from None
configparser.NoSectionError: No section: 'main'
script.ini 这个文件里边
[main]
dir = D:\mymhxy 路径改为了存放脚本的根目录
start.bat 里边
:: 改成绝对目录
start pythonw "D:\mymhxy\ui\mhxy_pyqt.py" 这里也改了
ImportError: DLL load failed while importing QtGui: 找不到指定的程序。
报这个错误,但是pip list显示pyqt已经装了。
mac点击 所有的按钮都报错
windows = pyautogui.getAllWindows()
AttributeError: module 'pyautogui' has no attribute 'getAllWindows'
windowsList = pyautogui.getWindowsWithTitle('梦幻西游:时空')
AttributeError: module 'pyautogui' has no attribute 'getWindowsWithTitle'
小白,不懂python 不知道用什么替换
挖矿这里,运行体验后,在同一屏幕出现多个矿时,会出现遗漏的情况,这里是不是可以增加移动偏移量,重查找机制再进行识别一下
怎么用呢
请问可以直接改成直接改成手机里面运行吗?
桌面5开的话
使用UI下的mhxy_tkinter.py执行一键挖矿时,
报错:FileNotFoundError("文件不存在"),
根据异常抛错,发现mhxy_baotu.py文件的代码:file_path = os.path.join(os.path.abspath('.'), 'resources/richang/richang.ini') 在执行时的相对路径有问题,文件执行的路径是在mhxy_script\ui下去找的resources/richang/richang.ini
我这边的解决方案是:在mhxy_script目录下创建了oschdir.py文件先定义当前执行工作目录,然后mhxy_baotu.py引用import oschdir就解决了
import os
os.chdir('G:/mhxy_script')
因为不是技术同学,只能使用这种笨方法。不知道还有哪些更好的办法呢
我是做javaweb的,python对于深度学习方向比较熟悉,这种桌面应用没有经验。我尝试将python打包成exe,运行有问题,我用的anaconda虚拟环境,我猜测是环境没打进去?可以在readme讲解一下打包流程么,或者空闲时候做个Release版本。如果有需要我可以提供一些帮助。
Description:
In the mhxy_baotu.py file of the project, there is a Baotu class containing a mission function. This function utilizes recursion, but it seems to encounter a deadlock when it reaches the statement waitUtilFindPic(r'resources/fuben/select.png').
Issue:
The mission function within the Baotu class appears to have a deadlock problem during recursion. It gets stuck at the line where it waits for the select.png image to be found.
Expected Behavior:
The mission function should be able to recursively execute without encountering deadlock or getting stuck at any point.
Steps to Reproduce:
Execute the mission function of the Baotu class in mhxy_baotu.py.
Observe the execution behavior, especially when it reaches the waitUtilFindPic(r'resources/fuben/select.png') statement.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.