When you replaced the motor, did you check all the sensors?
How's the O2 sensor?
What temp was the coolant running at?
When you shut off the motor did you let it run at idle for a few minutes before shutting it off? I had a rig that I had to let it idle before I shut it down.