Put the onion and butter in a large pot over medium heat. Cook until translucent and a little brown. Watch carefully and stir every few minutes to keep from burning. You can add a little more butter or olive oil if necessary.
Sprinkle the flour over the onions and stir to coat. Allow to cook for a minute stirring to keep from burning. It may be really thick but that is fine.
Add carrots and potatoes, then cover with enough hot water to leave a little room on top. Add salt and pepper and cook on medium high heat until veggies are tender but not falling apart, stirring every few minutes.
Make sure to stir frequently towards the end as the liquid will get very thick and can burn easily.
While the veggies are cooking, pour the cream of mushroom soup in a small pot, then fill the can up with milk, half and half, or cream and then add to the soup. Heat on medium, stirring as needed, until hot and combined.
When veggies are tender, add the soup mixture, ham and corn to the pot. Let cook on medium until the corn and ham are cooked through.
Serve with warm cornbread muffins and butter.