private void UpdateFocus(MassTestChamber master, int deltaTime) { int direction = master.SimulationInput.PollInteger(MassTestChamber.FocusMotorKey); if (direction != 0) { FocusCart.Drive(direction > 0, deltaTime); } bool field = master.SimulationInput.PollBoolean(MassTestChamber.FieldGeneratorKey); Central.ShowAs(Emitter.IsProvidingMass, field, IsDischarging); master.SimulationOutput.SetValue(MassTestChamber.FocusFrontKey, FocusCart.FrontPositionReached); master.SimulationOutput.SetValue(MassTestChamber.FocusBackKey, FocusCart.BackPositionReached); }