Search found 1419 matches
- Today, 15:20
- Forum: Ask for Help (v1)
- Topic: V1: Reload script when Dropbox finishes syncing
- Replies: 2
- Views: 26
Re: V1: Reload script when Dropbox finishes syncing
One other idea is you can reload when a change is detected and static for over {{x}} seconds. It sounds like there may be more than one file involved in the sync. If not you can just reload after any file change is detected.
- 16 Apr 2024, 11:00
- Forum: Ask for Help (v1)
- Topic: Trim sentences
- Replies: 2
- Views: 27
Re: Trim sentences
Just for fun: A := new biga() ; requires https://github.com/biga-ahk/biga.ahk str := " This is the first sentence. `n This is the second. `n Here comes the the third sentence. " str2 := A.join(A.map(strSplit(str, "`n"), A.trim), "`n") ; => "This is the first sentence.`nThis is the second.`nHere come...
- 13 Apr 2024, 12:21
- Forum: Gaming Help (v1)
- Topic: click on image text
- Replies: 11
- Views: 153
Re: click on image text
For games you can post here: viewforum.php?f=18
- 13 Apr 2024, 12:19
- Forum: Scripts and Functions (v1)
- Topic: [Class] expect.ahk (rapid unit testing)
- Replies: 21
- Views: 3350
Re: [Class] expect.ahk (rapid unit testing)
v1 has if var contains as standard syntax, but this has been removed in v2 - which is a shame imho. Huh did not know that was removed in v2. Obviously since it is not a function in v1 it does not fit comfortably in one line expect.true(UserInput not in yes,no) or whatever it would be. My current pl...
- 12 Apr 2024, 15:46
- Forum: Ask for Help (v1)
- Topic: Is it possible to output several voices in one audio file?
- Replies: 2
- Views: 50
Re: Is it possible to output several voices in one audio file?
Sorry I misunderstood the question as speaking two voices at the same time. I don't know anything about file output.
- 11 Apr 2024, 22:14
- Forum: Scripts and Functions (v1)
- Topic: [Class] expect.ahk (rapid unit testing)
- Replies: 21
- Views: 3350
Re: [Class] expect.ahk (rapid unit testing)
Yes inStr returns the location. v1 does not have a built-in 'contains' function or that would be better. I believe most examples have been switched to a perhaps clearer expect.true((1 == 1))
Additionally ahk cannot differentiate true from 1
Additionally ahk cannot differentiate true from 1
- 10 Apr 2024, 11:36
- Forum: Scripts and Functions (v1)
- Topic: [Class] expect.ahk (rapid unit testing)
- Replies: 21
- Views: 3350
Re: [Class] expect.ahk (rapid unit testing)
I for sure see an issue with .writeResultsToFile and that's my fault as I don't use that feature much yet. Fix should be on github hopefully today along with some tests as there are currently NONE for that method
- 06 Apr 2024, 18:58
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
Now I am satisfied
- 05 Apr 2024, 10:05
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
You didn't use any arrays
What if user wanted to find a purple pixel or a green one? Not just variations
What if user wanted to find a purple pixel or a green one? Not just variations
- 03 Apr 2024, 15:09
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
this is my first time hearing about matching three possible different colors.
I would use an array
ForEach() {
if match { sortClosest => click location }
}
You get the general idea
I would use an array
ForEach() {
if match { sortClosest => click location }
}
You get the general idea
- 02 Apr 2024, 12:01
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
Yeah it was the code I posted earlier in the day.
The sorting comes from .resultsSortDistance
Prior to that I belive the search is plain left to right
The sorting comes from .resultsSortDistance
Prior to that I belive the search is plain left to right
- 01 Apr 2024, 09:43
- Forum: Ask for Help (v1)
- Topic: Help With google search
- Replies: 1
- Views: 45
Re: Help With google search
if the searchengine doesn't have a highlighted short answer what should the msgbox display?
- 01 Apr 2024, 08:30
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
I wanted to make a gif too
- 31 Mar 2024, 10:49
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
this should be pretty simple I heard :think: Just for my fun, not rigorously tested or production ready oGraphicSearch := new graphicsearch() ; requires https://github.com/Chunjee/graphicsearch.ahk redPixels := "|<redpixel>0xFD0F07@0.97$6.zzzzzU" resultsObj := oGraphicSearch.search(redPixels) if (re...
- 31 Mar 2024, 10:33
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
since some are bigger than others, a function that combines results that are {{x}} close to each other may be useful. my test query "|<redpixel>0xFD0F07@0.97$6.zzzzzU" found about 110 matches but my human eyes only count 25 so some reduction is needed since the big ones are registering more than once.
- 31 Mar 2024, 10:06
- Forum: Ask for Help (v1)
- Topic: Find color closest to cursor and click Topic is solved
- Replies: 24
- Views: 458
Re: Find color closest to cursor and click Topic is solved
Since pixelsearch only returns one match, you will need pixelSearchAll() or similar. Might I suggest https://github.com/Chunjee/graphicsearch.ahk ? Then calculate the distance from the cursor forEach. graphicsearch.ahk has .resultSortDistance which uses Pythagorean theorem to measure the distance to...
- 29 Mar 2024, 11:41
- Forum: Ask for Help (v1)
- Topic: Showing the first lines
- Replies: 2
- Views: 70
Re: Showing the first lines
just for fun: #Include <biga> A := new biga() ; requires https://github.com/biga-ahk/biga.ahk I := 3 H := "Line_1`r`nLine_2`r`nLine_3`r`nLine_4`r`nLine_5`r`nLine_6`r`nLine_7`r`nLine_8`r`nLine_9" firstThreeLines := A.join(A.take(A.split(H, "`r`n"), I), "`n") msgbox, % firstThreeLines ; => "Line_1`nLi...
- 29 Mar 2024, 01:19
- Forum: Ask for Help (v1)
- Topic: Object.Delete(Key) doesn't work in my case. Looks like a bug.
- Replies: 8
- Views: 340
Re: Object.Delete(Key) doesn't work in my case. Looks like a bug.
Good reminder and workaround. I think I ran into this once or twice
- 29 Mar 2024, 01:15
- Forum: Ask for Help (v1)
- Topic: Code review
- Replies: 2
- Views: 69
Re: Code review
Xpos and KolorCheck are not defined fyi
- 21 Mar 2024, 12:09
- Forum: Ask for Help (v1)
- Topic: confused about #include
- Replies: 10
- Views: 192
Re: confused about #include
just thinking out loud. It might look like: { "name": "Joe's Custom Plugin", "tasks": [ "pressOne", "functionClose()", "pressEsc" ], "hotkey": "w" } The downside is you have to code it twice in a way. Once to parse it and understand the input, then again to translate that input into hotkeys/actually...