diff --git a/Torch.API/Torch.API.csproj b/Torch.API/Torch.API.csproj index 83783d4..c7137e0 100644 --- a/Torch.API/Torch.API.csproj +++ b/Torch.API/Torch.API.csproj @@ -74,11 +74,6 @@ ..\GameBinaries\SpaceEngineers.ObjectBuilders.XmlSerializers.dll False - - False - ..\GameBinaries\SteamSDK.dll - False - diff --git a/Torch.Server/Managers/InstanceManager.cs b/Torch.Server/Managers/InstanceManager.cs index c6b1d3b..82ecd95 100644 --- a/Torch.Server/Managers/InstanceManager.cs +++ b/Torch.Server/Managers/InstanceManager.cs @@ -105,9 +105,10 @@ namespace Torch.Server.Managers var sb = new StringBuilder(); foreach (var mod in world.Checkpoint.Mods) sb.AppendLine(mod.PublishedFileId.ToString()); - + DedicatedConfig.Mods = world.Checkpoint.Mods.Select(x => x.PublishedFileId).ToList(); + Log.Debug("Loaded mod list from world"); if (!modsOnly) @@ -165,7 +166,8 @@ namespace Torch.Server.Managers checkpoint.SessionName = DedicatedConfig.WorldName; checkpoint.Settings = DedicatedConfig.SessionSettings; checkpoint.Mods.Clear(); - foreach (var modId in DedicatedConfig.Model.Mods) + + foreach (var modId in DedicatedConfig.Mods) checkpoint.Mods.Add(new MyObjectBuilder_Checkpoint.ModItem(modId)); MyObjectBuilderSerializer.SerializeXML(sandboxPath, false, checkpoint); diff --git a/Torch.Server/Managers/MultiplayerManagerDedicated.cs b/Torch.Server/Managers/MultiplayerManagerDedicated.cs index 6420e85..60e1b67 100644 --- a/Torch.Server/Managers/MultiplayerManagerDedicated.cs +++ b/Torch.Server/Managers/MultiplayerManagerDedicated.cs @@ -11,7 +11,7 @@ using Sandbox; using Sandbox.Engine.Multiplayer; using Sandbox.Engine.Networking; using Sandbox.Game.World; -using SteamSDK; +using Steamworks; using Torch.API; using Torch.API.Managers; using Torch.Managers; @@ -150,9 +150,8 @@ namespace Torch.Server.Managers //Largely copied from SE private void ValidateAuthTicketResponse(ulong steamId, JoinResult response, ulong steamOwner) { - var state = new P2PSessionState(); - Peer2Peer.GetSessionState(steamId, ref state); - var ip = state.GetRemoteIP(); + //SteamNetworking.GetP2PSessionState(new CSteamID(steamId), out P2PSessionState_t state); + var ip = "0"; //state.GetRemoteIP(); _log.Debug($"ValidateAuthTicketResponse(user={steamId}, response={response}, owner={steamOwner})"); diff --git a/Torch.Server/Torch.Server.csproj b/Torch.Server/Torch.Server.csproj index 02fd9a0..04e32f5 100644 --- a/Torch.Server/Torch.Server.csproj +++ b/Torch.Server/Torch.Server.csproj @@ -117,10 +117,8 @@ ..\GameBinaries\SpaceEngineers.ObjectBuilders.XmlSerializers.dll False - - False - ..\GameBinaries\SteamSDK.dll - False + + ..\GameBinaries\Steamworks.NET.dll diff --git a/Torch.Server/ViewModels/ConfigDedicatedViewModel.cs b/Torch.Server/ViewModels/ConfigDedicatedViewModel.cs index 7838e5e..e0014f1 100644 --- a/Torch.Server/ViewModels/ConfigDedicatedViewModel.cs +++ b/Torch.Server/ViewModels/ConfigDedicatedViewModel.cs @@ -76,8 +76,9 @@ namespace Torch.Server.ViewModels public List Administrators { get => _config.Administrators; set => SetValue(x => _config.Administrators = x, value); } public List Banned { get => _config.Banned; set => SetValue(x => _config.Banned = x, value); } - - public List Mods { get => _config.Mods; set => SetValue(x => _config.Mods = x, value); } + + private List _mods = new List(); + public List Mods { get => _mods; set => SetValue(x => _mods = x, value); } public int AsteroidAmount { get => _config.AsteroidAmount; set => SetValue(x => _config.AsteroidAmount = x, value); } diff --git a/Torch.Server/ViewModels/SessionSettingsViewModel.cs b/Torch.Server/ViewModels/SessionSettingsViewModel.cs index b0337fb..39f6dff 100644 --- a/Torch.Server/ViewModels/SessionSettingsViewModel.cs +++ b/Torch.Server/ViewModels/SessionSettingsViewModel.cs @@ -59,7 +59,7 @@ namespace Torch.Server.ViewModels /// [Display(Name = "Enable block limits")] - public System.Boolean EnableBlockLimits { get => _settings.EnableBlockLimits; set => SetValue(ref _settings.EnableBlockLimits, value); } + public MyBlockLimitsEnabledEnum EnableBlockLimits { get => _settings.BlockLimitsEnabled; set => SetValue(ref _settings.BlockLimitsEnabled, value); } /// [Display(Name = "Enable remote removal of owned blocks")] diff --git a/Torch.Server/ViewModels/SteamUserViewModel.cs b/Torch.Server/ViewModels/SteamUserViewModel.cs index 87d4987..56bbd9f 100644 --- a/Torch.Server/ViewModels/SteamUserViewModel.cs +++ b/Torch.Server/ViewModels/SteamUserViewModel.cs @@ -3,7 +3,7 @@ using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; -using SteamSDK; +using Steamworks; namespace Torch.Server.ViewModels { @@ -15,7 +15,7 @@ namespace Torch.Server.ViewModels public SteamUserViewModel(ulong id) { SteamId = id; - Name = SteamAPI.Instance.Friends.GetPersonaName(id); + Name = SteamFriends.GetFriendPersonaName(new CSteamID(id)); } public SteamUserViewModel() : this(0) { } diff --git a/Torch.Server/Views/ChatControl.xaml.cs b/Torch.Server/Views/ChatControl.xaml.cs index 5cce943..3aa3d17 100644 --- a/Torch.Server/Views/ChatControl.xaml.cs +++ b/Torch.Server/Views/ChatControl.xaml.cs @@ -19,7 +19,6 @@ using Torch; using Sandbox; using Sandbox.Engine.Multiplayer; using Sandbox.Game.World; -using SteamSDK; using Torch.API; using Torch.API.Managers; using Torch.API.Session; diff --git a/Torch.Server/Views/ModsControl.xaml.cs b/Torch.Server/Views/ModsControl.xaml.cs index e9d4641..3fc7ec2 100644 --- a/Torch.Server/Views/ModsControl.xaml.cs +++ b/Torch.Server/Views/ModsControl.xaml.cs @@ -15,7 +15,6 @@ using System.Windows.Media.Imaging; using System.Windows.Navigation; using System.Windows.Shapes; using Sandbox.Engine.Networking; -using SteamSDK; using VRage.Game; namespace Torch.Server @@ -45,16 +44,16 @@ namespace Torch.Server mods = dialog.Result; } - foreach (var id in mods) - { - var details = SteamHelper.GetItemDetails(id); - if (details.FileType != WorkshopFileType.Community) - continue; + //foreach (var id in mods) + //{ + // var details = SteamHelper.GetItemDetails(id); + // if (details.FileType != WorkshopFileType.Community) + // continue; - var item = SteamHelper.GetModItem(details); - var desc = details.Description.Length < 500 ? details.Description : details.Description.Substring(0, 500); - ModList.Items.Add(new ModViewModel(item, desc)); - } + // var item = SteamHelper.GetModItem(details); + // var desc = details.Description.Length < 500 ? details.Description : details.Description.Substring(0, 500); + // ModList.Items.Add(new ModViewModel(item, desc)); + //} } private void modList_OnMouseDoubleClick(object sender, MouseButtonEventArgs e) diff --git a/Torch.Server/Views/PlayerListControl.xaml.cs b/Torch.Server/Views/PlayerListControl.xaml.cs index d7c2179..bc26eb6 100644 --- a/Torch.Server/Views/PlayerListControl.xaml.cs +++ b/Torch.Server/Views/PlayerListControl.xaml.cs @@ -19,7 +19,6 @@ using Sandbox.Engine.Multiplayer; using Sandbox.Game.Multiplayer; using Sandbox.Game.World; using Sandbox.ModAPI; -using SteamSDK; using Torch.API; using Torch.API.Managers; using Torch.API.Session; diff --git a/Torch/Commands/TorchCommands.cs b/Torch/Commands/TorchCommands.cs index d8144ff..53f68b9 100644 --- a/Torch/Commands/TorchCommands.cs +++ b/Torch/Commands/TorchCommands.cs @@ -10,7 +10,7 @@ using System.Threading.Tasks; using System.Timers; using Sandbox.Game.Multiplayer; using Sandbox.ModAPI; -using SteamSDK; +using Steamworks; using Torch; using Torch.API; using Torch.API.Managers; @@ -33,11 +33,14 @@ namespace Torch.Commands [Permission(MyPromoteLevel.None)] public void GetIP(ulong steamId = 0) { - var state = new P2PSessionState(); + Context.Respond("Cannot obtain client IP."); + return; + if (steamId == 0) steamId = Context.Player.SteamUserId; - Peer2Peer.GetSessionState(steamId, ref state); - var ip = new IPAddress(BitConverter.GetBytes(state.RemoteIP).Reverse().ToArray()); + + SteamNetworking.GetP2PSessionState(new CSteamID(steamId), out P2PSessionState_t state); + var ip = new IPAddress(BitConverter.GetBytes(state.m_nRemoteIP).Reverse().ToArray()); Context.Respond($"Your IP is {ip}"); } diff --git a/Torch/Managers/MultiplayerManagerBase.cs b/Torch/Managers/MultiplayerManagerBase.cs index 82c131c..c8c68b8 100644 --- a/Torch/Managers/MultiplayerManagerBase.cs +++ b/Torch/Managers/MultiplayerManagerBase.cs @@ -21,7 +21,6 @@ using Sandbox.Game.Entities.Character; using Sandbox.Game.Multiplayer; using Sandbox.Game.World; using Sandbox.ModAPI; -using SteamSDK; using Torch.API; using Torch.API.Managers; using Torch.Collections; diff --git a/Torch/Managers/NetworkManager/NetworkManager.cs b/Torch/Managers/NetworkManager/NetworkManager.cs index 95a3032..139deaa 100644 --- a/Torch/Managers/NetworkManager/NetworkManager.cs +++ b/Torch/Managers/NetworkManager/NetworkManager.cs @@ -29,6 +29,8 @@ namespace Torch.Managers private static Func _typeTableGetter; [ReflectedGetter(Name = "m_methodInfoLookup")] private static Func> _methodInfoLookupGetter; + [ReflectedMethod(Type = typeof(MyReplicationLayer), Name = "GetObjectByNetworkId")] + private static Func _getObjectByNetworkId; public NetworkManager(ITorchBase torchInstance) : base(torchInstance) { @@ -133,7 +135,7 @@ namespace Torch.Managers } var stream = new BitStream(); - stream.ResetRead(packet); + stream.ResetRead(packet.BitStream); var networkId = stream.ReadNetworkId(); //this value is unused, but removing this line corrupts the rest of the stream @@ -150,7 +152,8 @@ namespace Torch.Managers } else // Instance event { - var sendAs = ((MyReplicationLayer)MyMultiplayer.ReplicationLayer).GetObjectByNetworkId(networkId); + //var sendAs = ((MyReplicationLayer)MyMultiplayer.ReplicationLayer).GetObjectByNetworkId(networkId); + var sendAs = _getObjectByNetworkId((MyReplicationLayer)MyMultiplayer.ReplicationLayer, networkId); if (sendAs == null) { return; diff --git a/Torch/Managers/UpdateManager.cs b/Torch/Managers/UpdateManager.cs index 4a76c13..bdaaf32 100644 --- a/Torch/Managers/UpdateManager.cs +++ b/Torch/Managers/UpdateManager.cs @@ -11,7 +11,6 @@ using System.Threading; using System.Threading.Tasks; using NLog; using Octokit; -using SteamSDK; using Torch.API; namespace Torch.Managers diff --git a/Torch/Patches/ObjectFactoryInitPatch.cs b/Torch/Patches/ObjectFactoryInitPatch.cs index 51fc46e..c680edd 100644 --- a/Torch/Patches/ObjectFactoryInitPatch.cs +++ b/Torch/Patches/ObjectFactoryInitPatch.cs @@ -31,6 +31,7 @@ namespace Torch.Patches internal static void ForceRegisterAssemblies() { + var userAssemblies = MyPlugins.UserAssemblies; // static MyEntities() called by MySandboxGame.ForceStaticCtor RuntimeHelpers.RunClassConstructor(typeof(MyEntities).TypeHandle); { @@ -38,7 +39,14 @@ namespace Torch.Patches ObjectFactory_RegisterFromAssemblySafe(factory, typeof(MySandboxGame).Assembly); // calling assembly ObjectFactory_RegisterFromAssemblySafe(factory, MyPlugins.GameAssembly); ObjectFactory_RegisterFromAssemblySafe(factory, MyPlugins.SandboxAssembly); - ObjectFactory_RegisterFromAssemblySafe(factory, MyPlugins.UserAssembly); + //ObjectFactory_RegisterFromAssemblySafe(factory, MyPlugins.UserAssembly); + if (userAssemblies != null) + { + foreach (var assembly in userAssemblies) + { + ObjectFactory_RegisterFromAssemblySafe(factory, assembly); + } + } } // static MyGuiManager(): @@ -51,7 +59,14 @@ namespace Torch.Patches ComponentTypeFactory_RegisterFromAssemblySafe(MyPlugins.SandboxAssembly); ComponentTypeFactory_RegisterFromAssemblySafe(MyPlugins.GameAssembly); ComponentTypeFactory_RegisterFromAssemblySafe(MyPlugins.SandboxGameAssembly); - ComponentTypeFactory_RegisterFromAssemblySafe(MyPlugins.UserAssembly); + //ComponentTypeFactory_RegisterFromAssemblySafe(MyPlugins.UserAssembly); + if (userAssemblies != null) + { + foreach (var assembly in userAssemblies) + { + ComponentTypeFactory_RegisterFromAssemblySafe(assembly); + } + } } // static MyObjectPoolManager() diff --git a/Torch/SteamHelper.cs b/Torch/SteamHelper.cs deleted file mode 100644 index d9e92c3..0000000 --- a/Torch/SteamHelper.cs +++ /dev/null @@ -1,132 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Text; -using System.Text.RegularExpressions; -using System.Threading; -using System.Threading.Tasks; -using Microsoft.Win32; -using NLog; -using Sandbox; -using Sandbox.Engine.Networking; -using Sandbox.Engine.Platform; -using SteamSDK; -using Torch.API; -using VRage.Game; - -namespace Torch -{ - public static class SteamHelper - { - private static CancellationTokenSource _tokenSource = new CancellationTokenSource(); - private static CancellationToken _cancelToken; - private static Logger _log = LogManager.GetCurrentClassLogger(); - public static string BasePath { get; private set; } - private static string _libraryFolders; - - public static void Init() - { - BasePath = Registry.GetValue(@"HKEY_CURRENT_USER\Software\Valve\Steam", "SteamPath", null) as string; - _libraryFolders = File.ReadAllText(Path.Combine(BasePath, @"steamapps\libraryfolders.vdf")); - _cancelToken = _tokenSource.Token; - - Task.Run(() => - { - while (!_cancelToken.IsCancellationRequested) - { - SteamAPI.Instance.RunCallbacks(); - Thread.Sleep(100); - } - }); - } - - public static void StopCallbackLoop() - { - _tokenSource.Cancel(); - } - - public static MySteamWorkshop.SubscribedItem GetItemInfo(ulong itemId) - { - MySteamWorkshop.SubscribedItem item = null; - - using (var mre = new ManualResetEvent(false)) - { - SteamAPI.Instance.RemoteStorage.GetPublishedFileDetails(itemId, 0, (ioFail, result) => - { - if (!ioFail && result.Result == Result.OK) - { - item = new MySteamWorkshop.SubscribedItem - { - Title = result.Title, - Description = result.Description, - PublishedFileId = result.PublishedFileId, - SteamIDOwner = result.SteamIDOwner, - Tags = result.Tags.Split(' '), - TimeUpdated = result.TimeUpdated, - UGCHandle = result.FileHandle - }; - } - else - { - _log.Error($"Failed to get item info for {itemId}"); - } - - mre.Set(); - }); - - mre.WaitOne(); - mre.Reset(); - - return item; - } - } - - public static SteamUGCDetails GetItemDetails(ulong itemId) - { - SteamUGCDetails details = default(SteamUGCDetails); - using (var re = new AutoResetEvent(false)) - { - SteamAPI.Instance.UGC.RequestUGCDetails(itemId, 0, (b, result) => - { - if (!b && result.Details.Result == Result.OK) - details = result.Details; - else - _log.Error($"Failed to get item details for {itemId}"); - - re.Set(); - }); - - re.WaitOne(); - } - - return details; - } - - public static MyObjectBuilder_Checkpoint.ModItem GetModItem(ulong modId) - { - var details = GetItemDetails(modId); - return new MyObjectBuilder_Checkpoint.ModItem(null, modId, details.Title); - } - - public static MyObjectBuilder_Checkpoint.ModItem GetModItem(SteamUGCDetails details) - { - return new MyObjectBuilder_Checkpoint.ModItem(null, details.PublishedFileId, details.Title); - } - - public static string GetInstallFolder(string subfolderName) - { - var basePaths = new List(); - var matches = Regex.Matches(_libraryFolders, @"""\d+""[ \t]+""([^""]+)""", RegexOptions.Singleline); - foreach (Match match in matches) - { - basePaths.Add(match.Groups[1].Value); - } - - var path = basePaths.Select(p => Path.Combine(p, "SteamApps", "common", subfolderName)).FirstOrDefault(Directory.Exists); - if (path != null && !path.EndsWith("\\")) - path += "\\"; - return path; - } - } -} diff --git a/Torch/SteamService.cs b/Torch/SteamService.cs deleted file mode 100644 index 552bc4f..0000000 --- a/Torch/SteamService.cs +++ /dev/null @@ -1,95 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using NLog; -using SteamSDK; -using VRage.Steam; -using Sandbox; -using Sandbox.Engine.Networking; -using Torch.Utils; -using VRage.GameServices; - -namespace Torch -{ - /// - /// SNAGGED FROM PHOENIX84'S SE WORKSHOP TOOL - /// Keen's steam service calls RestartIfNecessary, which triggers steam to think the game was launched - /// outside of Steam, which causes this process to exit, and the game to launch instead with an arguments warning. - /// We have to override the default behavior, then forcibly set the correct options. - /// - public class SteamService : MySteamService - { - private static readonly Logger _log = LogManager.GetCurrentClassLogger(); - -#pragma warning disable 649 - [ReflectedSetter(Name = nameof(SteamServerAPI))] - private static Action _steamServerAPISetter; - [ReflectedSetter(Name = "m_gameServer")] - private static Action _steamGameServerSetter; - [ReflectedSetter(Name = nameof(AppId))] - private static Action _steamAppIdSetter; - [ReflectedSetter(Name = nameof(API))] - private static Action _steamApiSetter; - [ReflectedSetter(Name = nameof(IsActive))] - private static Action _steamIsActiveSetter; - [ReflectedSetter(Name = nameof(UserId))] - private static Action _steamUserIdSetter; - [ReflectedSetter(Name = nameof(UserName))] - private static Action _steamUserNameSetter; - [ReflectedSetter(Name = nameof(OwnsGame))] - private static Action _steamOwnsGameSetter; - [ReflectedSetter(Name = nameof(UserUniverse))] - private static Action _steamUserUniverseSetter; - [ReflectedSetter(Name = nameof(BranchName))] - private static Action _steamBranchNameSetter; - [ReflectedSetter(Name = nameof(InventoryAPI))] - private static Action _steamInventoryAPISetter; - [ReflectedMethod] - private static Action RegisterCallbacks; - [ReflectedSetter(Name = nameof(Peer2Peer))] - private static Action _steamPeer2PeerSetter; -#pragma warning restore 649 - - public SteamService(bool isDedicated, uint appId) - : base(true, appId) - { - SteamServerAPI.Instance.Dispose(); - _steamServerAPISetter.Invoke(this, null); - _steamGameServerSetter.Invoke(this, null); - _steamAppIdSetter.Invoke(this, appId); - - if (isDedicated) - { - _steamServerAPISetter.Invoke(this, null); - _steamGameServerSetter.Invoke(this, new MySteamGameServer()); - } - else - { - SteamAPI steamApi = SteamAPI.Instance; - _steamApiSetter.Invoke(this, steamApi); - bool initResult = steamApi.Init(); - if (!initResult) - _log.Warn("Failed to initialize SteamService"); - _steamIsActiveSetter.Invoke(this, initResult); - - if (IsActive) - { - _steamUserIdSetter.Invoke(this, steamApi.GetSteamUserId()); - _steamUserNameSetter.Invoke(this, steamApi.GetSteamName()); - _steamOwnsGameSetter.Invoke(this, steamApi.HasGame()); - _steamUserUniverseSetter.Invoke(this, (MyGameServiceUniverse)steamApi.GetSteamUserUniverse()); - _steamBranchNameSetter.Invoke(this, steamApi.GetBranchName()); - steamApi.LoadStats(); - - _steamInventoryAPISetter.Invoke(this, new MySteamInventory()); - RegisterCallbacks(this); - } else - _log.Warn("SteamService isn't initialized; Torch Client won't start"); - } - - _steamPeer2PeerSetter.Invoke(this, new MySteamPeer2Peer()); - } - } -} diff --git a/Torch/Torch.csproj b/Torch/Torch.csproj index 703a964..9c803a5 100644 --- a/Torch/Torch.csproj +++ b/Torch/Torch.csproj @@ -84,9 +84,8 @@ ..\GameBinaries\SpaceEngineers.ObjectBuilders.XmlSerializers.dll False - - ..\GameBinaries\SteamSDK.dll - False + + ..\GameBinaries\Steamworks.NET.dll @@ -254,13 +253,11 @@ - - diff --git a/Torch/Utils/MiscExtensions.cs b/Torch/Utils/MiscExtensions.cs index 6f97755..272b20d 100644 --- a/Torch/Utils/MiscExtensions.cs +++ b/Torch/Utils/MiscExtensions.cs @@ -6,7 +6,7 @@ using System.Net; using System.Text; using System.Threading; using System.Threading.Tasks; -using SteamSDK; +using Steamworks; namespace Torch.Utils { @@ -52,10 +52,10 @@ namespace Torch.Utils return result; } - public static IPAddress GetRemoteIP(this P2PSessionState state) + public static IPAddress GetRemoteIP(this P2PSessionState_t state) { // What is endianness anyway? - return new IPAddress(BitConverter.GetBytes(state.RemoteIP).Reverse().ToArray()); + return new IPAddress(BitConverter.GetBytes(state.m_nRemoteIP).Reverse().ToArray()); } } } diff --git a/Torch/Utils/Reflection.cs b/Torch/Utils/Reflection.cs index 5234a29..fbbbb46 100644 --- a/Torch/Utils/Reflection.cs +++ b/Torch/Utils/Reflection.cs @@ -5,7 +5,6 @@ using System.Reflection; using System.Text; using System.Threading.Tasks; using NLog; -using SteamSDK; namespace Torch.Utils { diff --git a/Torch/VRageGame.cs b/Torch/VRageGame.cs index 49dc49d..eafe74a 100644 --- a/Torch/VRageGame.cs +++ b/Torch/VRageGame.cs @@ -35,6 +35,7 @@ using VRage.Plugins; using VRage.Steam; using VRage.Utils; using VRageRender; +using MyRenderProfiler = VRage.Profiler.MyRenderProfiler; namespace Torch { @@ -198,8 +199,8 @@ namespace Torch MySandboxGame.Config.GraphicsRenderer = graphicsRenderer; } MyRenderProxy.Initialize(renderer); - MyRenderProxy.GetRenderProfiler().SetAutocommit(false); - MyRenderProxy.GetRenderProfiler().InitMemoryHack("MainEntryPoint"); + MyRenderProfiler.SetAutocommit(false); + MyRenderProfiler.InitMemoryHack("MainEntryPoint"); } // Loads object builder serializers. Intuitive, right? @@ -276,7 +277,7 @@ namespace Torch MyObjectBuilder_Checkpoint checkpoint = MyLocalCache.LoadCheckpoint(sessionPath, out checkpointSize); if (MySession.IsCompatibleVersion(checkpoint)) { - if (MySteamWorkshop.DownloadWorldModsBlocking(checkpoint.Mods).Success) + if (MyWorkshop.DownloadWorldModsBlocking(checkpoint.Mods).Success) { // MySpaceAnalytics.Instance.SetEntry(MyGameEntryEnum.Load); MySession.Load(sessionPath, checkpoint, checkpointSize); diff --git a/Torch/ViewModels/PlayerViewModel.cs b/Torch/ViewModels/PlayerViewModel.cs index c05a64c..857bb41 100644 --- a/Torch/ViewModels/PlayerViewModel.cs +++ b/Torch/ViewModels/PlayerViewModel.cs @@ -4,7 +4,6 @@ using System.Linq; using System.Text; using System.Threading.Tasks; using Sandbox.Engine.Multiplayer; -using SteamSDK; using Torch.API; using VRage.Replication;