The devil was simply tormenting this man. That is what pride can do to someone who is, otherwise, intelligent. At the peak of his glory, he is foolishly attending to non issues. Humility is very advantageous in obvious ways we can comprehend and also in deeper ways.
Pride is a sneaky, destructive monster.
And David was greatly distressed; for the people spake of stoning him, because the soul of all the people was grieved, every man for his sons and for his daughters: but David encouraged himself in the Lord his God.
1 Samuel 30:6 KJV
An important "but" in our lives. A necessary one. Today, we have more than David had -
a better covenant
unrestricted access to His presence
other benefits of the new covenant.
In the face of difficulties and apparent hopelessness, we should turn our attention to the all wise, all powerful and all knowing. And He cares. The end will be good.
Psalm 34:5 KJV
 They looked unto him, and were lightened: and their faces were not ashamed.
Psalm 34:5 NLT
 Those who look to him for help will be radiant with joy; no shadow of shame will darken their faces.
I can think of a number of characters in the Bible and in our days who have imbibed the attitude of clay in God’s hand. Shouldn’t we also?
The 3 Hebrew children. Dan 3
Paul. Gal. 2:20; Act 20:24
Esther. Esth 4:16
Persecuted Christians eg Richard Wumbrand
Risky mission work
Etc. - we easily remember more.
We’re not disappointed in the end results of their lives
But today’s glorified motivational messages, clothed as God’s utterance, have avoided this area.
May The Lord grant us grace to be humble enough to refuse to see ourselves beyond a clay in His hand to do with us as He pleases.
Trust me, this is the beginning of true abundant life.