Changed to work properly with updated engine.