updated to work again, not overhaul yet...