RiseOne Posted September 26, 2023 Posted September 26, 2023 First of all, I know nothing about programming. I got ChatGPT to write a script for me to search for a specific image on the screen and click, here it is: While True ; Capture the screen $screen = _ScreenCapture_Capture("", 0, 0, 0, 0) ; Search for the image on the screen $search = _ScreenCapture_Search("ryba.png", 0, 0, 0, 0, $screen) ; If the image is found, click on it If Not @error Then MouseClick("left", $search[0], $search[1]) EndIf ; Sleep for a short interval to avoid excessive clicking Sleep(1000) ; Sleep for 1 second (adjust as needed) WEnd I'm getting this error. How do I fix it? I've tried running as administrator and installing a different version of AutoIt.
Developers Jos Posted September 26, 2023 Developers Posted September 26, 2023 So you have no clue what you are running and ask us to fix any chatgpt errors? What exactly is the purpose of this script and what are you automating? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
RiseOne Posted September 26, 2023 Author Posted September 26, 2023 2 minutes ago, Jos said: So you have no clue what you are running and ask us to fix any chatgpt errors? What exactly is the purpose of this script and what are you automating? The purpose is, like I said, to constantly search for a specific image (ryba.png) on the screen and click on it once it appears. If the script GPT wrote is incorrect, please say so. You seem irritated with the fact it was AI that wrote it.
Developers Jos Posted September 26, 2023 Developers Posted September 26, 2023 That doesn't answer the "what" question. Using image search isn't the best way of automating programs. So what is it for? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
RiseOne Posted September 26, 2023 Author Posted September 26, 2023 Automating a fishing minigame where you need to click on constantly appearing images of fishes, once it's clicked, you need to wait a few seconds until they start appearing again.
Developers Jos Posted September 26, 2023 Developers Posted September 26, 2023 That's what I sort of expected, so you better now first read our forum rules carefully before posting again Ps not irritated by AI having written it, but rather you simply dumping it here to have others fix it without putting any effort in yourself... it seems. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Developers Jos Posted September 26, 2023 Developers Posted September 26, 2023 Welcome to the AutoIt forum. Unfortunately you appear to have missed the Forum rules on your way in. Please read them now - particularly the bit about not discussing game automation - and then you will understand why you will get no help and this thread will now be locked. See you soon with a legitimate question I hope. The Moderation team SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Recommended Posts