コード例 #1
0
        public ThreadSimulationProxy(ISimulation simulation)
        {
            this.simulation = simulation;
            Settings        = ((Simulation)simulation).Settings; // whoa! a cast!

            physicsWorker = new PhysicsWorker {
                Simulation = this
            };
            physicsThread = new Thread(physicsWorker.Run)
            {
                IsBackground = true
            };
        }
コード例 #2
0
        public ThreadSimulationProxy(ISimulation simulation)
        {
            this.simulation = simulation;

            //currentSimulationStep = new SimulationStep();

            physicsWorker = new PhysicsWorker {
                Simulation = this,                                 /*SimulationStepQueue = simulationStepQueue, SimulationQueueNotEmpty = simulationQueueNotEmpty */
            };
            physicsThread = new Thread(physicsWorker.Run)
            {
                IsBackground = true
            };

            physicsThread.Start();
        }
コード例 #3
0
        public ThreadSimulationProxy(ISimulation simulation)
        {
            this.simulation = simulation;

            //currentSimulationStep = new SimulationStep();

            physicsWorker = new PhysicsWorker { Simulation = this, /*SimulationStepQueue = simulationStepQueue, SimulationQueueNotEmpty = simulationQueueNotEmpty */ };
            physicsThread = new Thread(physicsWorker.Run) { IsBackground = true };

            physicsThread.Start();
        }