No problem, let me know if youād like some configuration ideas / missing some feature.
Hi Tqfan,
Itās been a while since I played GD, but Iām back, I hope everything is going well for you.
Iām playing the Dawn of Masteries mod, but I donāt think that should have any affect on how GDAutocaster works. The build Iām playing with at the moment has a bunch of powers that I want to cast all the time, essentially keeping them running, like one would Blood of Dreeg, so Iām using [autocast by toggle]. Hereās that part of the relatively short profile:
[autocast by toggle]
autocast_right_away=true
cast1=t:a
delay1=4750
reset_key1=a
cast2=t:q,x
delay2=200
reset_key2=q
cast3=c:c,v
delay3=5050
inner_delay3=5050
reset_key3=v
Cast1 and Cast2 work fine, but Cast3 doesnāt. Cast3 is setting off two instances of the same skill each of which is on a ring and the game allows there to be 2 simultaneous instances. Each of the skills last 6 seconds and has a 10 second cooldown, so what Iām trying to do is have the instance on ācā go off and 5.05 seconds later the one on āvā goes off, then 5.05 seconds later ācā, and so on, essentially casting each just one of them go off every 5 seconds.
When I turn the toggle on, it works perfectly and it continues to work until I zone at which point both instances (c and v) start going off at the same time. If I turn off the toggle and wait until both instances cooldown, I can turn the toggle back on and it works fine until the next time I zone. There may be other things that are causing the loss of delay, but I can definitely see it happen every time I zone. Iāve also tried it with and without inner_delay specified. That doesnāt seem to matter.
Is there a better way to do this or should it work, but is bugged?
Edit ā It actually doesnāt seem to do it every time I zone either, although that often causes it. All I can say is that eventually, the two instances will start going off simultaneously. Sometimes, using the reset key will fix it, but not always.
Hi. delay3
needs to be 2 times longer than inner_delay3
for it to work as you want.
For example with delay3=11000
and inner_delay3=5500
youāll achieve the following:
- every 11 seconds
-
c
is presssed - 5500 ms gap
-
v
is pressed
-
which will result in them alternating roughly every 5500ms.
But you donāt even have to use a trick like that since thereās alternate
option (not sure when added so better to redownload)! Btw seems itās autocast_on_launch
now
[autocast by toggle]
autocast_on_launch=true
cast3=c:c,v
delay3=5100
alternate3=true
It alternates c
and v
with 5100 ms in between.
My post-Covid brain strikes again. I completely missed that āalternate=ā keyword when looking at the doc again. There is an example, but it isnāt explained in words.
So , ādelayā is the total time before the entire set of actions loops and the āalternateā keyword makes the loop choose a different inner action (stuff between commas), that it does during a loop. āInner_delayā controls the gap between the inner actions (without āalternateā).
Iād guess that inner_delay and alternate donāt play well together.
Thanks.
Precisely
I donāt even now, would have to look in the code[edit] I looked
inner_delay
wonāt work if alternate
is true, itās in a separate part of the code / different branch of IF
if (index)
{
key := keys_pressed[this.current_buttons[index]]
Send {%key%}
this.current_buttons[index] := 1 + Mod(this.current_buttons[index], keys_pressed.Length())
}
else
Common.PressButtons(keys_pressed, inner_delay)
before adding this feature I just had the last line Common.PressButtons...
This is for Advanced character because beginner might be slightly different
Here are my hotbars, 1st is active and the 2nd one is for toggling passive buffs once:
In-game Bindings recommendation for this specific config:
-
Q - skill 4, for manual Pneumatic Burst casts
- could potentially be also configured in GDAutocaster no in game but I chose native pressing
by [combo presses] such as combo1=q:4
- could potentially be also configured in GDAutocaster no in game but I chose native pressing
-
I also have W for Health pot and E for Blade Barrier so that
-
Q, W, E are in a row just like on the hotbar (4,5,6) and you should cast them in that order of priority when your Health drops
and itās easy to look at the hotbar and choose the first one thatās not on cooldown
-
Q, W, E are in a row just like on the hotbar (4,5,6) and you should cast them in that order of priority when your Health drops
-
Y configured for Hotbar swap in gameās Keybindings
-
Space configured to be skill 7 - not needed as it spammed on Space by GDAutocaster anyway
but it might speed up Shadow Strike activation by 100ms or so sometimes
Here the most important thing from my config:
[general]
suspend_key=Tab
suspend_stops_autocast=true
[autocast by toggle]
autocast_on_launch=true
cast1=`:4,4,4,4,4
delay1=23000
inner_delay1=1000
reset_key1=q
key_native_function1=true
cast2=`:2
delay2=2000
key_native_function2=true
[combo presses]
combo2=r:y,0,7,8,9,0,y
delay2=500
[autocast by hold]
delay=200
cast1=Space:7,8
cast2=RButton:7,0,9
cast3=s:9,0
(I have other minor stuff there like fast keyboard camera rotation / one click map / freezing Tribues for Crucible / camera speed hack / 1press to drink multiple potions etc.) Let me know if youāre interested in stuff like that.
Here is explanation of all the things:
[autocast by toggle]
cast1=`:4,4,4,4,4
delay1=23000
inner_delay1=1000
reset_key1=q
key_native_function1=true
cast2=`:2
delay2=2000
key_native_function2=true
The first one casts Pneumatic Burst automatically very rarely (every 23 second) but presses the buttons 5 times (which lasts less than PBās cooldown so itās not cast multiple times) to prevent it not being cast in loading screen / when youāre Shadow Striking and cannot cast then. Also makes the 23s timer reset when after you press Q (which is meant for manual PB casts).
The second one presses Word of Renewal button (2) every 2 seconds. I just spam it for more heals. No resetting / manual casts here because the heal amount is too small for it to be worth it
You can turn this on / off if needed with the ` in this config (over Tab)
The first one might look complicated because it uses many options [autocast by toggle] provides.
The key_native_function is a technical thing that I should honestly get rid of in GDAutocaster so itās not needed here.
[combo presses]
combo2=r:y,0,7,8,9,0,y
delay2=500
This one casts perma buffs and Spirits from the 2nd hotbar after pressing R.
Y needs to be configured for Hotbar swap in gameās Keybindings.
You can also have one just for 3 buffs w/o Spirits for when youāre nullified (Spirit donāt disappear then)
and maybe even smaller delay.
[autocast by hold]
delay=200
cast1=Space:7,8
cast2=RButton:7,0,9
cast3=s:9,0
-
cast1 (Space) spams Shadow Strike and another Movement Skill on Space just for movement / initiating the fight not for the fight itself
-
cast2 (RMB) is spamming Rune of Hagarrad, Shadow Strike and the Seal during the fight with RMB
- notice in this way Seal is spammed as often as possible, this can be configured in a different way so that Seal is cast only once per RMB Click + Hold if you prefer to cast it once per its whole life time which depends on your playstyle
-
cast2 (S) can be sometimes used to place Seals and Runes of Hagarrad manually before a fight
oh thank you a lot for this(i rearranged some bindings and it works fine now)
Great tool overall, but may I make the suggestion to enable comments in the config file?
Hey, I have 0 control over config because I use built in functions for reading config, I donāt parse it line by line.
However commenting in config file shouldnāt be a problem. Do you have some particular example that doesnāt work for you?
No I didnĀ“t try to use comments since I donĀ“t know how to markup them. Is it a leading ; ? If so maybe add it in the first post for documentation purposes.
Peruse AutoHotkeys documentation at its website.
ā
lol @tqFan - I just realized thoā¦ they are probably referring to your ini config files and not AHK scripts. DOH.
@Christian Thereās no need for that, write whatever and however you want, just avoid those things in the documentation / sample config at the start of the line. Your config can look like that for example:
[general]
THIS IS RESPONSIBLE FOR SUSPENDING THE HOTKEYS BUT NOT AUTOCASTS
suspend_key=Tab
[combo holds]
CAST AETHER RAY (0) ON DOUBE LEFT CLICK + HOLD
combo1=LButton:0
initial_delay1=50
double_press1=true
double_press_time_gap1=300
Also you cannot comment in this way after some value read by the program
double_press_time_gap1=300 // MY COMMENT
or this way
double_press_time_gap1=300 ; MY COMMENT
This is the function Iām using btw: IniRead - Syntax & Usage | AutoHotkey
Yes, I was referring to adding documentation to my ini-files.
Am I right in assuming, that every line that cannot be parsed is just ignored by the parser and wonĀ“t break the file?
So I could comment valid config lines out with an # at the start for example?
Thanks for the feedback by the way!
I preface all my comment lines with āCMT=ā. I know it isnāt necessary, but it makes then clearly comments and ensures that nothing that follows can affect the inputs. unless TqFan decides to make CMT an actual keyword, which seems darn unlikely. (I can see the April Fools day joke already! Donāt do it, TqFan. )
Having a way to add comments after the actual text of a functional statement (value read by the program) would be nice, but I understand the difficulty.
P.S. I just discovered [hide items]; as a current DoM player, Iām loving it. Many hugs TqFan.
Maybe i could just go over the config file and make a temporary copy of it stripped of these comments. And read it afterwards. The indicators of comments (do you have some in mind?) could be configurable in Defaults.ahk, but youād have to to recompile it yourself to change it . It super easy though
Iām glad you found it useful. You might be the second after me. I used it a lot in the past. Took some time to make it work reliably. The problem in grim dawn is you get stack up a lot of āitem hidden / shown messagesā depending on your config. These can be hidden by editing grim dawnās settings file but they still queue up albeit invisible delaying other messages
Yeah, the messages at the top of the screen become useless, but that happens with DoM any way if you are running with +heroes.
Pretty much anything that wouldnāt conflict with what can be coded would be fine. Semi-colon maybe?
I thought that would be the proposition. Iāve just checked and you can make it a hotkey in an AHK if you escape it:
`;::Space
This does not work in GDAutocaster (you get an error) but maybe I could potentially make it work someday. However the following works
[combo presses]
combo1=Space:;
Dunno, I started with C++ and //
comments so Iād probably choose that if thereās no better idea.
I started with Fortran (yeah, Iām old) and it used ā/xā to start a comment and ā**x/ā to end it. You definitely donāt want to deal with that nonsense. ā//ā is fine by me. (The āxā is supposed to be an asterisk, but for some reason it just doesnāt show up.)
I donāt know if you really need inline comments in an ini file. If you keep it standard ( ; for a line comment) users have the advantage of getting syntax highlight in their text editors. At least if they use a somewhat sophisticated one.
Last major updates 2 Nov 22:
- add option to comment after config entries
[general]
suspend_key=Tab//tralala
comment=//
[combo presses]
combo1=Space:0 // BWC
-
comment [optional]
- indicates a comment after a config entry, i.e. in
suspend_key=Tab//tralala
- in lines without config entries you can still comment however you want
- donāt comment in this particular line though
- indicates a comment after a config entry, i.e. in
// is the default if you donāt have this config entry.
I did it in this way because very little code was needed, the following does all the work
(and I already had a special function for reading config entries anyway):
comment_pos := InStr(output_var, comment, true)
if (comment_pos > 1)
output_var := SubStr(output_var, 1, comment_pos-1)
I also pushed to GitHub a lot of rewritten code because it was not very readable to me after a half year break so I had to make it clearer so watch out for some bugs (I tested everything but you never know).