by DrClaes » Sat Oct 29, 2011 6:35 am
I'm working on an algorithm to resolve conflicts when several ants have orders to move into the same tile or each other's location; for the case described above, of two ants which would like to "swap places"; the actual switch is redundant, and it will speed up ant travel if they "bounce" off each other instead, swapping order queues.
E.g.
Ant 1 wants to move A->B->C
Ant 2 wants to move B->A->D
Orders as suggested above:
Ant 1: A->B
Ant 2: B->A
Orders after algorithm:
Ant 1: A->D
Ant 2: B->C
Anyone else doing this (and more sophisticated versions?)