This should be part of the HandleInput function, not seperate