Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Have to press twice for a Group-Init / Sort Macro

I'm running the standard 5E config for the group-init API. I'd like a macro to first call init rolling and then immediately sort Unfortunately, I have to click my macro button twice in order for it to execute  both commands. Is this expected behavior? Is there some way to make it do what I want?  My macro is !group-init !group-init --sort
1628982303
Kraynic
Pro
Sheet Author
Did you bring up !group-init --help ?  There is an option there.  There is probably a command to set it as well, but I'll leave that to you to look up if you don't want to click the setting in help.
1628987539

Edited 1628987799
Hi @kraynic, thanks for taking the time to respond. Sorry though, I'm not quite sure I understand what you're trying to say. I have "descending" selected. I can see that the help file says Sorting occurs when the sort command ( !group-init --sort ) is issued, when stack entries are merged into the current Turn Order, and when new entries are added to the Turn Order with a GroupInitiative command (like  !group-init ). But when I run just !group-init by itself, it doesn't actually sort them for me, hence my attempt to do both actions in a macro.
1628989629
The Aaron
Roll20 Production Team
API Scripter
Since rolling dice is asynchronous, this ends up being: !group-init Request dice roll !group-init --sort Sort turn order Dice finish rolling Add turns and change values.  I think there's an auto sort option, I need to look into it. You could also probd my use the delay script. 
1629007913

Edited 1629008182
Kraynic
Pro
Sheet Author
The Aaron said: Since rolling dice is asynchronous, this ends up being: !group-init Request dice roll !group-init --sort Sort turn order Dice finish rolling Add turns and change values.  I think there's an auto sort option, I need to look into it. You could also probd my use the delay script.  Well, here is a mystery for you...  It always (as far as I remember anyway) sorted the initiative order in one of my games.  There was a dice modifier set, but no tie-breaker.  I was testing with 4 characters to make sure I hadn't imagined it, and it sorted every the time, no problem.  There is another game that I tested that didn't sort.  There was a tie breaker set in that game, but no dice modifier.   I didn't pay much attention to it sorting or not during play, just because I run that game a bit differently (different game systems). I went into the game that was sorting, gave it a dice modifier, and it quit sorting.  I took the modifier off and it still won't sort...  That game has some age on it, so did GroupInitiative autosort before at some point?  Maybe it was a holdover from an older version? Somehow I had a game where GI was sorting initiative with the roll... and now I broke it! Edit:  I found another game (a one-shot) that I ran over a year ago.  It autosorts with the initiative roll as well. 
1629055589

Edited 1629055613
I wasn't able to figure out how to get GroupInit to autosort for me by itself.  However, I installed CombatMaster and began using that, which (among other things) handled initiative ordering and sorting, so I'm happy now (if still perplexed by GroupInit) 
1629125311
Andreas J.
Forum Champion
Sheet Author
Translator
Yeah I haven't got group-init to auto-sort either last time I tried, always need to run the "--sort" command separately.
1629134650
The Aaron
Roll20 Production Team
API Scripter
hmmm... Sounds like there is definitely a bug in there.
1629176701
vÍnce
Pro
Sheet Author
Strange.  Auto sort has been/is working for our group.  Pathfinder 1e.
I have two games with group-init.  One sorts automatically every time.  The other game doesn't.  They have the exact same group-init settings and APIs installed.  It's baffling. I end up doing what Ryan was doing and just hitting the group-init macro button again to sort it.  It would be nice if the auto sort always worked, but alas.  Still better than not having group-init! :-)