Changed some variable names that didn't make very much sense.