I am thinking of making a simple game with Unity. The aim would be to keep a person healthy by feeding it well balanced food and drinks.
Rather than hard codding every single type of food or drink I can think of I was thinking of letting the player choose any type of food he wants and then screen the internet for it's calorific value, saturated fat, sugars etc ...
This would make the game much more enjoyable than being limited by the foods I can think of.
I was wondering how you would go about doing that ? Could I use an API to extract data from google or wikipedia.
I noticed that when you type "[food] calories" in Google you get a return from the Wikipedia page like this:
Obviously, there is a way of extracting the data from Wikipedia and I could automate the searchs by taking the player's entry as a string and running a search with it.
How would one recommend going about this ? Also, is it safe ?