iap_enumerate_products

Populate a ds_list with all the currently available IAP products from the target store.

Syntax:

GML Code Example

iap_enumerate_products();


Returns: N/A


Description

This function retrieves the list of in app purchase product ids encountered. On most platforms this will simply return the set of product ids provided through iap_activate(), but on platforms where the store provides the facility to retrieve a complete list of available products for a title then this set of product ids will include any and all available product ids for the game. The function requires that you supply a previously made ds_list (which you should clear first if it has been used for other purposes) which will be populated by the function call. Regardless of platform, if the target store is not available then it will get the product IDs from those supplied when you activated purchases using iap_activate.


Example:

GML Code Example

var status = iap_status();
 var iap_list = ds_list_create();
 if status == iap_status_available
    {
    iap_enumerate_products(iap_list);
    }
 

The above code checks the status of the target IAP store, and if it is available it will populate the created list with the available product IDs for future use.





No Examples Submitted

Does this page need better examples? Be the first to Submit

No Edits Suggested

Is this page unclear or not descriptive enough? Suggest an edit to the page and with enough upvotes your changes will be made.

No Questions Have Been Ask

Do you have a question about this page? Ask it Here