The TIP42C is a transistor, not a Darlington pair, so requires substantial base current to switchhigh current loads. Try 150 ohm resistor instead of the 1k base resistor. This probablyexplains the slow running.Is the sensor active low? It needs to be active low if driving a PNP transistor like the TIP42Inductive loads like motors need free-wheel diodes across them to protect from inductivevoltage spikes.
The PNP will only stop if its base and emitter voltages are within 0.4V of each other, presumably thisisn't happening. The multimeter is the tool you need all the time to see what's happening in circuits,I'd recommend checking all the voltages are what you'd expect for each condition. Perhaps the sensordoesn't behave like you assumed?
The sensor outputs a logic one (+3.5V) at the digital output when an object is placed in front of the sensor and logic zero (0V), when there is no object in front of the sensor.