Reworks input to use callbacks instead of state checking. Still needs polish.