コード例 #1
0
ファイル: pCampBot.cs プロジェクト: otakup0pe/opensim
        public static void Main(string[] args)
        {
            IConfig config = ParseConfig(args);
            if (config.Get("help") != null || config.Get("loginuri") == null)
            {
                Help();
            }
            else
            {
                int botcount = config.GetInt("botcount", 1);

                BotManager bm = new BotManager();

                //startup specified number of bots.  1 is the default
                bm.dobotStartup(botcount, config);

                while (true)
                {
                    try
                    {
                        MainConsole.Instance.Prompt();
                    }
                    catch (Exception e)
                    {
                        m_log.ErrorFormat("Command error: {0}", e);
                    }
                }
            }
        }
コード例 #2
0
ファイル: pCampBot.cs プロジェクト: JAllard/osmodified
        public static void Main(string[] args)
        {
            IConfig config = ParseConfig(args);
            if (config.Get("help") != null || config.Get("loginuri") == null)
            {
                Help();
            }
            else if (config.Get("firstname") == null ||  config.Get("lastname") == null || config.Get("password") == null)
            {
                Console.WriteLine("ERROR: You must supply a firstname, lastname and password for the bots.");
            }
            else
            {
                int botcount = config.GetInt("botcount", 1);

                BotManager bm = new BotManager();

                //startup specified number of bots.  1 is the default
                bm.dobotStartup(botcount, config);

                while (true)
                {
                    try
                    {
                        MainConsole.Instance.Prompt();
                    }
                    catch (Exception e)
                    {
                        m_log.ErrorFormat("Command error: {0}", e);
                    }
                }
            }
        }
コード例 #3
0
        public static void Main(string[] args)
        {
            IConfig config = ParseConfig(args);

            if (config.Get("help") != null || config.Get("loginuri") == null)
            {
                Help();
            }
            else if (config.Get("firstname") == null || config.Get("lastname") == null || config.Get("password") == null)
            {
                Console.WriteLine("ERROR: You must supply a firstname, lastname and password for the bots.");
            }
            else
            {
                int botcount = config.GetInt("botcount", 1);

                BotManager bm = new BotManager();

                //startup specified number of bots.  1 is the default
                bm.dobotStartup(botcount, config);

                while (true)
                {
                    try
                    {
                        MainConsole.Instance.Prompt();
                    }
                    catch (Exception e)
                    {
                        m_log.ErrorFormat("Command error: {0}", e);
                    }
                }
            }
        }
コード例 #4
0
ファイル: pCampBot.cs プロジェクト: 4U2NV/opensim
        public static void Main(string[] args)
        {
            IConfig config = ParseConfig(args);

            if (config.Get("help") != null || config.Get("loginuri") == null)
            {
                Help();
            }
            else
            {
                int botcount = config.GetInt("botcount", 1);

                BotManager bm = new BotManager();

                //startup specified number of bots.  1 is the default
                bm.dobotStartup(botcount, config);

                while (true)
                {
                    try
                    {
                        MainConsole.Instance.Prompt();
                    }
                    catch (Exception e)
                    {
                        m_log.ErrorFormat("Command error: {0}", e);
                    }
                }
            }
        }
コード例 #5
0
ファイル: pCampBot.cs プロジェクト: justasabc/opensim75
        public static void Main(string[] args)
        {
            XmlConfigurator.Configure();

            IConfig config = ParseConfig(args);
            if (config.Get("help") != null || config.Get("loginuri") == null)
            {
                Help();
            }
            else if (config.Get("firstname") == null ||  config.Get("lastname") == null || config.Get("password") == null)
            {
                Console.WriteLine("ERROR: You must supply a firstname, lastname and password for the bots.");
            }
            else
            {
                int botcount = config.GetInt("botcount", 1);

                BotManager bm = new BotManager();

                //startup specified number of bots.  1 is the default
                Thread startBotThread = new Thread(o => bm.dobotStartup(botcount, config));
                startBotThread.Name = "Initial start bots thread";
                startBotThread.Start();

                while (true)
                {
                    try
                    {
                        //MainConsole.Instance.Output("Please input command...");
                        MainConsole.Instance.Prompt();
                    }
                    catch (Exception e)
                    {
                        m_log.ErrorFormat("Command error: {0}", e);
                    }
                }
            }
        }