Esempio n. 1
0
 private void stopThread()
 {
     manazerKola.stopThread();
     thread.Join();
     thread      = null;
     manazerKola = null;
 }
Esempio n. 2
0
        private void startThread()
        {
            if (difficultyOfRound == Difficulty.None)
            {
                return;
            }
            if (manazerKola == null)
            {
                manazerKola = new RoundGovernor(true, ref arrayOfObjectInGame, g, this, graph, difficultyOfRound);
            }
            if (thread == null)
            {
                thread = new Thread(new ThreadStart(manazerKola.run));
            }

            manazerKola.nastavFPS(actualFPS);
            // Start the thread
            thread.Start();

            // Spin for a while waiting for the started thread to become
            // alive:
            while (!thread.IsAlive)
            {
                ;
            }
        }
Esempio n. 3
0
        private void startThread()
        {
            if (difficultyOfRound == Difficulty.None)
            {
                if (isH6ServerDead())
                {
                    System.Console.WriteLine("H6 server has been destroyed.");
                }
                return;
            }
            if (manazerKola == null)
            {
                manazerKola = new RoundGovernor(true, ref arrayOfObjectInGame, g, this, graph, difficultyOfRound);
            }
            if (thread == null)
            {
                thread = new Thread(new ThreadStart(manazerKola.run));
            }

            manazerKola.nastavFPS(actualFPS);
            // Start the thread
            thread.Start();

            // Spin for a while waiting for the started thread to become
            // alive:
            while (!thread.IsAlive)
            {
                ;
            }
        }
Esempio n. 4
0
        public World(List <ThinkingObject> objectInGame, int startingLifeOfH6Server)
        {
            manazerKola         = new RoundGovernor(true, arrayOfObjectInGame);
            thread              = new Thread(new ThreadStart(manazerKola.run));
            arrayOfObjectInGame = objectInGame;

            setLifeOfH6ServerPc(startingLifeOfH6Server);
        }
Esempio n. 5
0
        private void stopThread()
        {
            manazerKola.stopThread();
            RoundGovernor.running = false;

            thread.Join();
            thread      = null;
            manazerKola = null;
        }
Esempio n. 6
0
        private void startThread()
        {
            if (manazerKola == null)
            {
                manazerKola = new RoundGovernor(true, arrayOfObjectInGame, g);
            }
            if (thread == null)
            {
                thread = new Thread(new ThreadStart(manazerKola.run));
            }

            // Start the thread
            thread.Start();

            // Spin for a while waiting for the started thread to become
            // alive:
            while (!thread.IsAlive)
            {
                ;
            }
        }