When a cat is thrust out into the world and they are unused to it, they quickly have to figure out how to be the more dominant male and how to get a position of "strength" with other cats. They will usually do this by humping. They will hump females AND males and it's usually not sexual at all.
It sounds like he's still trying to maintain his "rank" even though he is home. You should discourage and ignore the behavior. This means, push him away and then ignore him for a while.
He will soon settle back down and will become the nice kitty you once had.
Let me know if you still don't understand or if you have questions.
