ds_map_size

With this function you can find how many key/values pairs the (previously created) DS map contains.

 

Syntax:

ds_map_size(id);

ArgumentTypeDescription
idDS MapThe id of the data structure to check.

 

Returns:

Real

 

Example:

if (ds_map_size(inventory) > 49)
{
    full = true;
}

The above code will check the size of the DS map (ie: number of key/value pairs) and if it is greater than 49 it sets the variable "full" to true.