GB has a nice function that returns the index of where an item is in an array. If the item is not in the array, returns -1.
Now I have one big global array named MAGZ_ARRAY but the function doesn't work with that array.
First it was an array in array, so I thought that was the problem but after I've changed that it still won't work.
_index = [player, MAGZ_ARRAY] call indexOf
hint format ["%1",_index]
I'm sure the player is in that array, but it creates an error... it's too long to read.
I tried :
_myarray = format ["%1",MAGZ_ARRAY]
But that returns a string and I need an array :'(
What the hell, MAGZ_ARRAY is an array!