TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches

◆ Download()

static void Terraria.Social.Steam.SteamedWraps.Download ( PublishedFileId_t publishId,
IDownloadProgress uiProgress = null,
bool forceUpdate = false )
inlinestaticpackage

Updates and/or Downloads the Item specified by publishId.

Definition at line 619 of file SteamedWraps.cs.

620 {
621 //IL_0016: Unknown result type (might be due to invalid IL or missing references)
622 //IL_000f: Unknown result type (might be due to invalid IL or missing references)
623 //IL_0010: Unknown result type (might be due to invalid IL or missing references)
624 //IL_0077: Unknown result type (might be due to invalid IL or missing references)
625 //IL_0040: Unknown result type (might be due to invalid IL or missing references)
626 //IL_0036: Unknown result type (might be due to invalid IL or missing references)
627 //IL_005c: Unknown result type (might be due to invalid IL or missing references)
628 if (!SteamAvailable)
629 {
630 return;
631 }
632 if (SteamClient)
633 {
634 SteamUGC.SubscribeItem(publishId);
635 }
637 {
638 Utils.LogAndConsoleInfoMessage(Language.GetTextValue("tModLoader.SteamDownloader"));
639 if (!((!SteamClient) ? SteamGameServerUGC.DownloadItem(publishId, true) : SteamUGC.DownloadItem(publishId, true)))
640 {
642 throw new ArgumentException("Downloading Workshop Item failed due to unknown reasons");
643 }
645 Utils.LogAndConsoleInfoMessage(Language.GetTextValue("tModLoader.EndDownload"));
646 }
647 else
648 {
649 Utils.LogAndConsoleErrorMessage(Language.GetTextValue("tModLoader.SteamRejectUpdate", publishId));
650 }
651 }
static string GetTextValue(string key)
Retrieves the text value for a specified localization key. The text returned will be for the currentl...
Definition Language.cs:35
Contains methods to access or retrieve localization values. The Localization Guideteaches more about ...
Definition Language.cs:12
static bool DoesWorkshopItemNeedUpdate(PublishedFileId_t publishId)
static void InnerDownloadHandler(IDownloadProgress uiProgress, PublishedFileId_t publishId)

References Terraria.Social.Steam.SteamedWraps.DoesWorkshopItemNeedUpdate(), Terraria.Localization.Language.GetTextValue(), Terraria.Social.Steam.SteamedWraps.InnerDownloadHandler(), Terraria.Utils.LogAndConsoleErrorMessage(), Terraria.Utils.LogAndConsoleInfoMessage(), Terraria.Social.Steam.SteamedWraps.ReportCheckSteamLogs(), Terraria.Social.Steam.SteamedWraps.SteamAvailable, and Terraria.Social.Steam.SteamedWraps.SteamClient.

Referenced by Terraria.Social.Steam.WorkshopBrowserModule.DownloadItem(), and Terraria.Social.Steam.WorkshopSocialModule.TryGetInfoForMod().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: