Yes, that's what I need to achieve, don't ask why:)
So, since this is mainly OS dependent stuff I will be using Windows or Linux (whatever is simpler)
Every second my program will: 
1. do a screenshot, analyze the board and other stuff (this I can do)
2. then move the mouse to some XY and do a left-click
that's all
My main concern is: is there any library for capturing screenshots and then left clicking somwhere on the screen?
I've done this very thing before - use PIL to get the screenshots, and pywinauto to generate the mouse clicks.
python program that plays flash games for me