steam_user_owns_dlc

Check to see if the user owns the specified DLC (Downloadable Content).

Syntax:

GML Code Example

steam_user_owns_dlc(dlc_id);


Argument Description
dlc_id The unique identifier for the DLC to be checked (an integer).


Returns: Boolean


Description

If your game has DLC created for it, you can use this function to check and see whether the user has bought it before accessing any files associated with it. The function returns true if the player owns the content, and false if the user does not, but note that even if the user owns the DLC, they may not have it installed, so you should use the additional function of steam_user_installed_dlc to check that it is installed as well before using it.


Example:

GML Code Example

global.Level_Max = 100;
 if steam_user_owns_dlc(10354)
    {
    if steam_user_installed_dlc(10354)
       {
       global.Level_max = 200;
       }
    }
 

The above code will check to see if the user has bought, and installed, the DLC with the id 10354, and if so set a global variable to a different value.





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