In Chapter 22, Tom thinks the storm is intended for him because he has a guilty conscience.
It is summer, and Tom is at a bit of a loss as to what to do with himself. In addition, he is still troubled over having secretly witnessed the murder of Dr. Robinson. Because he is attracted to the "showy character" of the uniforms of the Cadets of Temperance, he decides to join their ranks, promising to give up smoking, chewing tobacco, and profanity. Sadly, Tom soon finds himself sorely tempted to do all these things, and is forced to give up his membership before a mere forty-eight hours have passed.
Tom's malaise deepens, and to make things worse, he catches the measles. During the two weeks during which he is laid up, a "revival" comes to town, and everyone - even his rapscallion friends - "[gets] religion." Even the incorrigible Huck Finn quotes to him from Scripture, and Tom, still laboring under the "dreadful secret" of the murder, and his recent dismal failure to live up to expectations in the Cadets, feels as if "he alone of all the town [is] lost, forever and forever."
Such is Tom's state of mind when the terrible storm strikes. Consumed by guilt, he firmly believes that "he [has] taxed the forbearance of the powers above to the extremity of endurance and that this [is] the result." Tom sees the storm has been wrought to bring about his destruction, a just punishment for his sins and perceived depravity (Chapter 22).