eggdrop icon indicating copy to clipboard operation
eggdrop copied to clipboard

Feature add: List bots on partyline in Alpha order when doing .bots or .botinfo

Open d3vils opened this issue 7 years ago • 6 comments

This would be nice to have the ability to list the bots on the party line in order.

IE .bots Bots: 1zark, Cras, Ewalk, Nope

instead of .bots Ewalk, 1zark, Nope, Cras

d3vils avatar Oct 28 '18 23:10 d3vils

Hi d3vils,

Could you provide a use case for this? How do you intend to use this? Thanks

vanosg avatar Oct 29 '18 00:10 vanosg

Hi vanosg,

This would make it a lot easier to know when/which bot(s) are missing/and not currently linked in order to troubleshoot what happened to the missing.

Thanks

d3vils avatar Oct 29 '18 01:10 d3vils

We could use posix qsort for .bots and .botinfo or we could make the bot->next list a sorted list.

michaelortmann avatar Aug 16 '19 18:08 michaelortmann

Whatever would be easiest.

d3vils avatar Aug 16 '19 18:08 d3vils

Add this at the end of your configuration file and see if it works:

unbind dcc - bots *dcc:bots
bind dcc - bots sortedbots
proc sortedbots {hand idx param} {
  putidx $idx [join [lsort [split [*dcc:bots $hand $idx $param]]]]
}
`

thommey avatar Mar 14 '20 15:03 thommey

I like this sort feature and would like to see it in our scripts directory and loaded by default in eggdrop.conf.

michaelortmann avatar Feb 03 '21 13:02 michaelortmann