Added a bunch of checks for weather input values are correct.