removed old functions causing warnings, cleaned up code/removed some old crust