Changed some variable names to better reflect their purpose