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 }; }
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(); }