10.12.2016, 11:40
It obviously tells you whats wrong: [11:48:56] [debug] Attempted to read/write array element at index 40 in array of size 40
If you have an array with the size of 40, you can access index 0 to 39
If you have an array with the size of 40, you can access index 0 to 39