Quantcast
Viewing latest article 2
Browse Latest Browse All 4

Answer by karma0413

Array index out of range means that you are trying to access a position in the array, that does not exist. Put in some debug lines that check: 1. How big your array truthfully is 2. Where you are at in terms of accessing it. // First, check how big the array truthfully is... int a = prefabpool.Length; You should note that even you have 7 items in your array as an example.... Then the array starts at 0 and ends at 6. Arrays always start at zero print (a); print (i); // Check which spot in the array you really are trying to use

Viewing latest article 2
Browse Latest Browse All 4

Trending Articles