access to items in a list unity?

0

In a array I can access the elements by means of the key

arraay[elemtno]

But in a list as I access each element since I do not have to do

 list[elemento]

If you have an idea, I appreciate your time.

    
asked by Jose Eduardo 05.08.2018 в 03:57
source

2 answers

0

With the get and the index number you can get the example value ...

list.get[0];

I hope you HELP ReNiceCode ....

    
answered by 05.08.2018 в 05:23
0

To access a generic list you can use the index. In a generic list are organized from 0 to N - 1. Unlike a hashmap or dictionary that are stored by keys and without a specific order.

public List<Object> Objetos = new List<Object>();
Objetos[index].parametros = nuevo_valor
    
answered by 05.08.2018 в 18:18