Loading...
Searching...
No Matches
WorkshopRevisionBase Interface Reference
Inheritance diagram for WorkshopRevisionBase:
WorkshopRevision

Public Member Functions

proto external bool IsLatest ()
 Returns true if this is latest revision of its asset.
 
proto external bool IsCurrent ()
 Return true if this is current revision of its asset.
 
proto external string GetVersion ()
 Returns version numbers as a string.
 
proto external int GetSizeKB ()
 Returns total size of this revision in KibiBytes.
 
proto external WorkshopJob RequestDownload (notnull BackendCallback callback)
 Will request download of this revision.
 
proto external void RequestDetails (notnull BackendCallback callback)
 Will request missing details about this revision.
 
proto external WorkshopRevision GetWorkshopRevision ()
 Returns full WorkshopRevision structure of this if it was previously requested with successful result.
 

Member Function Documentation

◆ GetSizeKB()

proto external int WorkshopRevisionBase.GetSizeKB ( )

Returns total size of this revision in KibiBytes.

Note
If size is less than 1 KB it is always rounded to 1.
Warning
This does not represent how many data will user download but can be used to determine how much space will this revision take on disk. TODO: For download and update there will be method to calculate delta patch size which will specify how much data will need to be downloaded in relation to data user already has downloaded in this or other assets.

◆ GetVersion()

proto external string WorkshopRevisionBase.GetVersion ( )

Returns version numbers as a string.

◆ GetWorkshopRevision()

proto external WorkshopRevision WorkshopRevisionBase.GetWorkshopRevision ( )

Returns full WorkshopRevision structure of this if it was previously requested with successful result.

Warning
Casting this into WorkshopRevision can be also possible but could introduce undesired behavior due to missing validation checks.
Exceptions
VME- if you attempt to get full asset when it was previously not requested.

◆ IsCurrent()

proto external bool WorkshopRevisionBase.IsCurrent ( )

Return true if this is current revision of its asset.

◆ IsLatest()

proto external bool WorkshopRevisionBase.IsLatest ( )

Returns true if this is latest revision of its asset.

◆ RequestDetails()

proto external void WorkshopRevisionBase.RequestDetails ( notnull BackendCallback callback)

Will request missing details about this revision.

Generally when you have partial revision from assets or outdated data when local asset is loaded at the start of the game. After missing data are successfully fetched you can also retrieve full WorkshopRevision via GetWorkshopRevision().

Note
If all details are already loaded then this method finished immediately without sending any request.

◆ RequestDownload()

proto external WorkshopJob WorkshopRevisionBase.RequestDownload ( notnull BackendCallback callback)

Will request download of this revision.

Warning
State of the asset must be at least SUBSCRIBED before you can download this revision.
Exceptions
VME- if download is requested while asset is not subscribed.
  • if download is requested while this asset is already processing different job
  • if download is requested for revision which is already downloaded - is current revision
Returns
WorkshopJob of this task through which download process can be tracked and further controlled.

The documentation for this interface was generated from the following file: