Note that red tokens represent "computer".Instead of moving token 22 to position 19 (wich will form a new mill) , my evalFunction() makes another decisionand moves something let's say like token 21 to position 9 , or 18 to position 10.

Can you help me improve my eval function so that token 22 moves to 19 ?( so that mill 21-22-23 breaks and token 22 forms a new mill on 18-19-20)

I am not sure how to help further. You need to find a situation where the program reproducibly does the wrong thing, then carefully analyze what the program is doing, probably with the help of a debugger or perhaps just by adding a bunch of print statements to your program. Try to figure out where the program is doing something different than what you expected.