Error when building : ArgumentOutOfRange Exception

Hi everyone,

We are working on a point & click project on unity 5.0. Everything works fine. Then we launched a build for PC & another for Mac with just a level to test the performances. And then something strange occurred.

The player doesn’t respond, and the action button detect the click but do nothing. Then we tried another build, with “development build” to see what’s going on. And then, we saw that we have a repetition of the same error:

" ArgumentOutOfRange Exception : Argument is out of Range. Parameter name: index"

we don’t know where its come from. Does anyone has an idea ?

thx a lot for any help you can provide us.

Isn’t there more to the error (like a source file and line number?). Anyway, that’s not much to go on, but…

Somewhere in your code, you’re accessing a collection (list, array, etc) by an index value, and that value is outside the valid range of items in the collection. For instance, the following code will generate that error:

var myList = new List<string>() { "a", "b", "c" };
var s = myList[3];

… since the valid index range for the “myList” collection is 0-2.