A great fall means a sudden uncontrollable descent. But, fall can also refer to the season that we also call autumn. So, this joke can be understood as Humpty Dumpty had a great (as in enjoyable) fall (as in autumn). Or, Humpty Dumpty had a great fall, as in a huge uncontrollable descent.
Humpty Dumpty had a great fall - and a pretty good spring and summer , too .