Hi, I’ve got a function in a class, which returns an araay of strings:
(into a weaponCards class)
public string[] getCards(){
for (int i=0; i<5; i++) {
cardList[i] =(CardContainer[i].cardName);
}
return cardList;
}
and now I’d like to retrieve these array into another class, but I get a
NullReferenceException: Object reference not set to an instance of an object
(wrapper stelemref) object:stelemref (object,intptr,object)
.
I believed that I correctly initialize my array, but apparently not :
string[] values = new string[5];
values= weaponCards.getCards();
}