When worms are to the point that they are vomited it is normally a pretty serious case but with proper medication and treatment he should be okay, Like stated it is normal for him to go off feeding while being wormed especially with it being a heavy parasite load. Chances are good he will recover tho if you can get him feeding.