There was once a chossid who was accustomed to travel to his rebbe, Rabbi Yisroel of Ruzin for the holidays. Over time, this chossid became wealthy. Thinking that he no longer needed the rebbe‘s help and encouragement, he ceased visiting his rebbe. However, once his visits ended, his streak of luck ended with it and he became a pauper.
Eventually, he travelled to Ruzin in the hopes that his rebbe could pray on his behalf and provide solace for his sorry state.
When he told his rebbe of his terrible situation, the R. Yisroel told him the following story:
“Once, there were two brothers that lived in a home that they had inherited from their father. The two brothers were especially close and they each participated in each other’s lives. In time though, a fight broke out between the two and they stopped talking to one another.
“In place of their warm feelings for one another, now there was only tension and discord.
“After a number of years, one of the brothers married off his daughter. Wishing to make amends with his only close relative, he invited his brother whom he had not spoken to in years. Though he invited him and wished to resolve their issues, his brother refused to come.
“During the night of the wedding, in the midst of the dancing, the brother who refused to come lay in bed, while the other was dejected that his brother did not come to his own daughter’s wedding.
“The musician exclaimed to the brother who was marrying of his daughter: ‘If you give me a bottle of whisky, I will bring your brother to the wedding.’
“When the bother agreed to the deal, the musician took his violin and went to the home of the angry brother. He began playing a beautiful tune outside his window – one which was particularly enchanting. So hypnotized was the brother by the music, that he got out of bed, followed the musician into the wedding hall while still in his pajamas, and began dancing to the melody.
“The musician remarked: ‘If you wouldn’t have been in a dispute with your brother, you would have not needed to dance while in your pajamas.'”
G-d desires a relationship with us. He wants us to talk to Him and pray to Him. Oftentimes, when we do not pray to Him, G-d causes negative things to befall us so that we remember Him. Were we to recall G-d when things were good though, negative things would not befall us to begin with.