Most times, the ones who go to fancy and luxury restaurants, bars, etc, are always broke. They do it just ti show off (showing off what they do not have and may never have). Someone who is economical will know very well that cooking and eating at home will save money, sometimes you can pick a lower quality of what you want to get, just because you’re being economical and trying to cover everything you need to.
There is some truth in what you said but honestly, the rest is completely out of context. Restaurant and eatery are costly but we also have reasonably ones that sell good meals at cheaper rate, they don't hike the price of foods the way some do their own and they are even more healthier when you compare them to the ones with high prices. They are also in hirachy, eateries are bigger costlier than restaurant and restaurants are costlier than Buka; Eatery>>>Restaurant >>>Buka, in that manner.
The reason why you see people visit food places to buy food is not because they don't want to cook or doesn't have money or just showing off. The problem is that some people don't know how to cook, they have tried many times but it doesn't work because they are bad cook and has probably in their life never help their mom in the kitchen for once. Some people might want to cook but they don't have the time because imagine where you go to work from 6am to 6pm, it will be difficult to cook as an employed worker that is always busy from Monday to Saturday or even sunfdays.
You should also consider inflation, to buy food items to prepare a pot of soup might even be twice bigger than what you might even spend in restaurant, it's not "might", buying food right now to eat is more economical for a single person, but if you are married, then I think it's okay to consider cooking because it's better and economical to cook than buy food for 4 people.