Added some of the camera initialization code into the environment loading function