cleaning up

Cleaning up some code so I can use it on the other senses.