Example #1
0
 /// <summary>
 /// Removes a client subscription from updates.
 /// </summary>
 /// <param name="client">The mod client which will no longer receive mod status updates.</param>
 public void RemoveClient(SteamUGCService.IClient client)
 {
     if (client != null)
     {
         clients.Remove(client);
     }
 }
 /// <summary>
 /// Applied before RemoveClient runs.
 /// </summary>
 internal static bool Prefix(SteamUGCService.IClient client)
 {
     if (!SafeMode)
     {
         SteamUGCServiceFixed.Instance.RemoveClient(client);
     }
     return(SafeMode);
 }
Example #3
0
        /// <summary>
        /// Adds a client subscription for updates.
        /// </summary>
        /// <param name="client">The mod client which will receive mod status updates.</param>
        public void AddClient(SteamUGCService.IClient client)
        {
            if (client != null)
            {
                clients.Add(client);
                if (firstEvent)
                {
                    // Update with all
                    var noMods = ListPool <PublishedFileId_t, SteamUGCServiceFixed> .Allocate();

                    var noPreview = ListPool <SteamUGCService.Mod, SteamUGCServiceFixed> .
                                    Allocate();

                    client.UpdateMods(allMods.Keys, noMods, noMods, noPreview);
                    noMods.Recycle();
                    noPreview.Recycle();
                }
            }
        }
Example #4
0
 /// <summary>
 /// Applied before RemoveClient runs.
 /// </summary>
 internal static bool Prefix(SteamUGCService.IClient client)
 {
     SteamUGCServiceFixed.Instance.RemoveClient(client);
     return(false);
 }