Hello, I've spent a lot of time this week (over 20 hours) trying to perfect a script that I need but with no real success. I've mostly used macro software that are user friendly but they aren't very efficient. I almost succeeded with one software but it caused problems with my mouse, the script wouldn't perform the actions I needed fast enough so it would move my mouse and cause problems.
About the script:
- There are 27 objects placed in horizontal lines, in total 3 rows with 9 objects in each row. They are equidistant from one another so it would look like this:
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
Each number is a bar with 2 colors like a percentage, when the percentage is 100% the bar is fully green and when it's 1% it's almost completely red, when it's 100% red the object disappears in this manner:
1 2 3 4 5 6 7 8 9
1 2 3 4 6 7 8 9 1
2 3 4 5 6 7 8 9
In this case the 5th object in the second row became completely red and disappeared, the remaining objects moved up 1 spot and there are now 28 objects. The goal of my script is to pixel search the red color at 29 different spots for the 29 objects at a specific coordinate of when the bar is 70% red, if the bar is 70% red then it will detect a red pixel instead of a green one at that coordinate:
When it detects a red pixel, it will select the object by left clicking at the red pixel and then press delete to remove the object. Once this process is done, I will manually reselect the 28 objects with an addtional new 29th object with a box using my mouse, this last part will be manual, but if the first part that is scripted isn't instantanous so it nterferes with my mouse and I'm not able to reselect 29 objects with the newly added one. The bars will become red quickly, maybe 3-4 red pixels per second, so I have to be able to reselect 29 objects and enable the script to delete 1 object as fast as possible to be able to repeat this 3 times in a second.
This is what my original script in that software looked like:
Again, this script works, but it moves my mouse so I'm not able to reselect stuff quickly enough (I see my mouse moving on the screen and the final mouse location is different every time). When I press F1 the script should turn on, and constantly check for red pixels at those 29 locations, if one is found it will select it by clicking there and pressing delete. If another red pixel appears at the 29 spots a minute later it will do it again automatically without me pressing hotkeys. To disable the script I will repress F1,