Adding Recenter logic
Removing old code