fixed some dead end stuff. performance improvements