You are not logged in.
Pages: 1
This is similar to the PHP version of "in_array(value, array)"
// in_array(value,array)
//
// Returns boolean of true/false
// checks if item is within the array or not
//
// value value to check, string
// array group of elements, array
//
var searchArray = argument[1];
var findValue = argument[0];
var loop = 0;
repeat (array_length_1d(searchArray))
{
if (searchArray[loop++] == findValue) return true;
}
return false;
Offline
Heheh, nice. I wrote something just like this yesterday for a project. Very useful. Thank you for the submission and welcome to the forums!
Abusing forum power since 1986.
Offline
No problem! Glad to be here. I've used game maker 1.4 many many years ago. I've been in web dev for a long time now, and im moving back into some game dev projects. Would love to help build up some resource.
Offline
Pages: 1