modified engine to keep track of if it is currently running