Variable renaming and added constants.
Cleanup.