i have a list of gameobjects that store my inventory as a list and i want to show\instantiate in a menu the items (i dont have adding items as a part of the game yet so i start the player with three items)
`public List ItemList = new List();
ItemList.Add(RedPotion);
ItemList.Add(BluePotion);
ItemList.Add(GoldPotion);
Instantiate(ItemList[2], Item2Location);`
it gives me an error “Index was out of range. Must be non-negative and less than the size of the collection.”