C# Class Steamworks.SteamApps

Exibir arquivo Open project: rlabrecque/Steamworks.NET Class Usage Examples

Public Methods

Method Description
BGetDLCDataByIndex ( int iDLC, AppId_t &pAppID, bool &pbAvailable, string &pchName, int cchNameBufferSize ) : bool

Returns metadata for DLC by index, of range [0, GetDLCCount()]

BIsAppInstalled ( AppId_t appID ) : bool

returns true if that app is installed (not necessarily owned)

BIsCybercafe ( ) : bool
BIsDlcInstalled ( AppId_t appID ) : bool

Takes AppID of DLC and checks if the user owns the DLC & if the DLC is installed

BIsLowViolence ( ) : bool
BIsSubscribed ( ) : bool
BIsSubscribedApp ( AppId_t appID ) : bool

only use this member if you need to check ownership of another game related to yours, a demo for example

BIsSubscribedFromFreeWeekend ( ) : bool

Checks if the user is subscribed to the current app through a free weekend

This function will return false for users who have a retail or other type of license

Before using, please ask your Valve technical contact how to package and secure your free weekened

BIsVACBanned ( ) : bool
GetAppBuildId ( ) : int

return the buildid of this app, may change at any time based on backend updates to the game

GetAppInstallDir ( AppId_t appID, string &pchFolder, uint cchFolderBufferSize ) : uint

returns current app install folder for AppID, returns folder name length

GetAppOwner ( ) : CSteamID

returns the SteamID of the original owner. If different from current user, it's borrowed

GetAvailableGameLanguages ( ) : string
GetCurrentBetaName ( string &pchName, int cchNameBufferSize ) : bool

returns current beta branch name, 'public' is the default branch

GetCurrentGameLanguage ( ) : string
GetDLCCount ( ) : int

Returns the number of DLC pieces for the running app

GetDlcDownloadProgress ( AppId_t nAppID, ulong &punBytesDownloaded, ulong &punBytesTotal ) : bool

get download progress for optional DLC

GetEarliestPurchaseUnixTime ( AppId_t nAppID ) : uint

returns the Unix time of the purchase of the app

GetFileDetails ( string pszFileName ) : SteamAPICall_t
GetInstalledDepots ( AppId_t appID, DepotId_t pvecDepots, uint cMaxDepots ) : uint

return installed depots in mount order

GetLaunchQueryParam ( string pchKey ) : string

Returns the associated launch param if the game is run via steam://run/<appid>//?param1=value1;param2=value2;param3=value3 etc.

Parameter names starting with the character '@' are reserved for internal use and will always return and empty string.

Parameter names starting with an underscore '_' are reserved for steam features -- they can be queried by the game,

but it is advised that you not param names beginning with an underscore for your own features.

InstallDLC ( AppId_t nAppID ) : void

Install/Uninstall control for optional DLC

MarkContentCorrupt ( bool bMissingFilesOnly ) : bool

signal Steam that game files seems corrupt or missing

RequestAllProofOfPurchaseKeys ( ) : void

Request all proof of purchase keys for the calling appid and asociated DLC.

A series of AppProofOfPurchaseKeyResponse_t callbacks will be sent with

appropriate appid values, ending with a final callback where the m_nAppId

member is k_uAppIdInvalid (zero).

RequestAppProofOfPurchaseKey ( AppId_t nAppID ) : void

Request legacy cd-key for yourself or owned DLC. If you are interested in this

data then make sure you provide us with a list of valid keys to be distributed

to users when they purchase the game, before the game ships.

You'll receive an AppProofOfPurchaseKeyResponse_t callback when

the key is available (which may be immediately).

UninstallDLC ( AppId_t nAppID ) : void

Method Details

BGetDLCDataByIndex() public static method

Returns metadata for DLC by index, of range [0, GetDLCCount()]

public static BGetDLCDataByIndex ( int iDLC, AppId_t &pAppID, bool &pbAvailable, string &pchName, int cchNameBufferSize ) : bool
iDLC int
pAppID AppId_t
pbAvailable bool
pchName string
cchNameBufferSize int
return bool

BIsAppInstalled() public static method

returns true if that app is installed (not necessarily owned)

public static BIsAppInstalled ( AppId_t appID ) : bool
appID AppId_t
return bool

BIsCybercafe() public static method

public static BIsCybercafe ( ) : bool
return bool

BIsDlcInstalled() public static method

Takes AppID of DLC and checks if the user owns the DLC & if the DLC is installed

public static BIsDlcInstalled ( AppId_t appID ) : bool
appID AppId_t
return bool

BIsLowViolence() public static method

public static BIsLowViolence ( ) : bool
return bool

BIsSubscribed() public static method

public static BIsSubscribed ( ) : bool
return bool

BIsSubscribedApp() public static method

only use this member if you need to check ownership of another game related to yours, a demo for example

public static BIsSubscribedApp ( AppId_t appID ) : bool
appID AppId_t
return bool

BIsSubscribedFromFreeWeekend() public static method

Checks if the user is subscribed to the current app through a free weekend

This function will return false for users who have a retail or other type of license

Before using, please ask your Valve technical contact how to package and secure your free weekened

public static BIsSubscribedFromFreeWeekend ( ) : bool
return bool

BIsVACBanned() public static method

public static BIsVACBanned ( ) : bool
return bool

GetAppBuildId() public static method

return the buildid of this app, may change at any time based on backend updates to the game

public static GetAppBuildId ( ) : int
return int

GetAppInstallDir() public static method

returns current app install folder for AppID, returns folder name length

public static GetAppInstallDir ( AppId_t appID, string &pchFolder, uint cchFolderBufferSize ) : uint
appID AppId_t
pchFolder string
cchFolderBufferSize uint
return uint

GetAppOwner() public static method

returns the SteamID of the original owner. If different from current user, it's borrowed

public static GetAppOwner ( ) : CSteamID
return CSteamID

GetAvailableGameLanguages() public static method

public static GetAvailableGameLanguages ( ) : string
return string

GetCurrentBetaName() public static method

returns current beta branch name, 'public' is the default branch

public static GetCurrentBetaName ( string &pchName, int cchNameBufferSize ) : bool
pchName string
cchNameBufferSize int
return bool

GetCurrentGameLanguage() public static method

public static GetCurrentGameLanguage ( ) : string
return string

GetDLCCount() public static method

Returns the number of DLC pieces for the running app

public static GetDLCCount ( ) : int
return int

GetDlcDownloadProgress() public static method

get download progress for optional DLC

public static GetDlcDownloadProgress ( AppId_t nAppID, ulong &punBytesDownloaded, ulong &punBytesTotal ) : bool
nAppID AppId_t
punBytesDownloaded ulong
punBytesTotal ulong
return bool

GetEarliestPurchaseUnixTime() public static method

returns the Unix time of the purchase of the app

public static GetEarliestPurchaseUnixTime ( AppId_t nAppID ) : uint
nAppID AppId_t
return uint

GetFileDetails() public static method

public static GetFileDetails ( string pszFileName ) : SteamAPICall_t
pszFileName string
return SteamAPICall_t

GetInstalledDepots() public static method

return installed depots in mount order

public static GetInstalledDepots ( AppId_t appID, DepotId_t pvecDepots, uint cMaxDepots ) : uint
appID AppId_t
pvecDepots DepotId_t
cMaxDepots uint
return uint

GetLaunchQueryParam() public static method

Returns the associated launch param if the game is run via steam://run/<appid>//?param1=value1;param2=value2;param3=value3 etc.

Parameter names starting with the character '@' are reserved for internal use and will always return and empty string.

Parameter names starting with an underscore '_' are reserved for steam features -- they can be queried by the game,

but it is advised that you not param names beginning with an underscore for your own features.

public static GetLaunchQueryParam ( string pchKey ) : string
pchKey string
return string

InstallDLC() public static method

Install/Uninstall control for optional DLC

public static InstallDLC ( AppId_t nAppID ) : void
nAppID AppId_t
return void

MarkContentCorrupt() public static method

signal Steam that game files seems corrupt or missing

public static MarkContentCorrupt ( bool bMissingFilesOnly ) : bool
bMissingFilesOnly bool
return bool

RequestAllProofOfPurchaseKeys() public static method

Request all proof of purchase keys for the calling appid and asociated DLC.

A series of AppProofOfPurchaseKeyResponse_t callbacks will be sent with

appropriate appid values, ending with a final callback where the m_nAppId

member is k_uAppIdInvalid (zero).

public static RequestAllProofOfPurchaseKeys ( ) : void
return void

RequestAppProofOfPurchaseKey() public static method

Request legacy cd-key for yourself or owned DLC. If you are interested in this

data then make sure you provide us with a list of valid keys to be distributed

to users when they purchase the game, before the game ships.

You'll receive an AppProofOfPurchaseKeyResponse_t callback when

the key is available (which may be immediately).

public static RequestAppProofOfPurchaseKey ( AppId_t nAppID ) : void
nAppID AppId_t
return void

UninstallDLC() public static method

public static UninstallDLC ( AppId_t nAppID ) : void
nAppID AppId_t
return void