very ugly version but with basic functionality definetely refactor
oops, lets try that again