public List <TableContainer> OpenNewTables() { // open tables List <TableContainer> tables; if (TableFoundEvent != null) { TableOpener.TableFoundDelegate tableDelegate = delegate(TableContainer table) { TableFoundEvent(table); }; tables = tableOpener.OpenNewTables(settings, tableDelegate); } else { tables = tableOpener.OpenNewTables(settings); } // log StreamWriter log = new StreamWriter(settings.Name + ".txt", true); log.WriteLine("## OpenNewTables (player, pot, flop, score) -> " + DateTime.Now + " ##"); foreach (TableContainer table in tables) { log.WriteLine(table.LobbyTable.ToCsvString()); } log.Close(); return(tables); }
public static void Main(string[] args) { Log.SetLevel(Log.Level.FINEST); Thread.Sleep(5000); Dictionary <string, string> config = BotAppLogic.ReadConfig(); Win32Control ctrl = new Win32Control(); TableOpener opener = new TableOpener(ctrl, new HumanMouse(ctrl), new Keyboard(ctrl), new TableIdentifier(new TableLayout9())); Settings settings = new Settings(); settings.AutoLocateTablesNum = 1; opener.OpenNewTables(settings, ImageRendererForm.newImageRendererForm()); Thread.Sleep(3000); opener.SitIn(); }