I have created a items list in the Data folder called Food and I would like to test to see if they work by adding them to the inventory, but I think it could only be done if I create an Event by calling the script or something.
In summary Is there a way to add items to inventory using a script?
$gameParty.gainItem(item, quantity)
Yeah, the missing part is that you would need to open whatever external file contained the data and use it to construct a Game_Item. I have the same questions as Andar does.
So this would basically involve a plugin where you expand DataManager's initialisation to create a $dataFoods global variable, and you'd then have to write an isFood function, add a check for that to Game_Party's itemContainer function...there are a number of things you'd have to change in order to have a new item type that draws from a json file.
Decent start, but you're forgetting to add the creation of $dataFoods in DataManager.
Also keep in mind that some of the branches based on kind draw their values from something the developer set in the database, and you don't have that for your food type, so you'll have to work around those cases.