Skip to content

array_contains( array, value )

Hyomoto edited this page Oct 16, 2020 · 2 revisions
Jump To Go Back Arguments Methods Variables

array_contains( array, value )

Returns the index of the first found instance of value in array. If it does not exist, returns -1 instead.

var _contains	= array_contains( [ "eggs", "bread", "milk" ], "bread" );

show_debug_message( _contains );

Arguments

Name Type Purpose
array array none provided
value mixed none provided
Clone this wiki locally