Fix for 188
This commit is contained in:
@@ -10,7 +10,7 @@ namespace Torch.Mod
|
|||||||
[MySessionComponentDescriptor(MyUpdateOrder.AfterSimulation)]
|
[MySessionComponentDescriptor(MyUpdateOrder.AfterSimulation)]
|
||||||
public class TorchModCore : MySessionComponentBase
|
public class TorchModCore : MySessionComponentBase
|
||||||
{
|
{
|
||||||
public const long MOD_ID = 1406994352;
|
public const ulong MOD_ID = 1406994352;
|
||||||
private static bool _init;
|
private static bool _init;
|
||||||
|
|
||||||
public override void UpdateAfterSimulation()
|
public override void UpdateAfterSimulation()
|
||||||
|
@@ -143,8 +143,8 @@ namespace Torch.Server.ViewModels
|
|||||||
[Torch.Views.Display(Description = "Enables in game scripts.", Name = "Enable Ingame Scripts", GroupName = "Others")]
|
[Torch.Views.Display(Description = "Enables in game scripts.", Name = "Enable Ingame Scripts", GroupName = "Others")]
|
||||||
public bool EnableIngameScripts { get => _settings.EnableIngameScripts; set => SetValue(ref _settings.EnableIngameScripts, value); }
|
public bool EnableIngameScripts { get => _settings.EnableIngameScripts; set => SetValue(ref _settings.EnableIngameScripts, value); }
|
||||||
|
|
||||||
[Torch.Views.Display(Description = "", Name = "Flora Density", GroupName = "Environment")]
|
[Torch.Views.Display(Description = "", Name = "Flora Density Multiplier", GroupName = "Environment")]
|
||||||
public int FloraDensity { get => _settings.FloraDensity; set => SetValue(ref _settings.FloraDensity, value); }
|
public float FloraDensityMultiplier { get => _settings.FloraDensityMultiplier; set => SetValue(ref _settings.FloraDensityMultiplier, value); }
|
||||||
|
|
||||||
[Torch.Views.Display(Description = "Enables tool shake feature.", Name = "Enable Tool Shake", GroupName = "Players")]
|
[Torch.Views.Display(Description = "Enables tool shake feature.", Name = "Enable Tool Shake", GroupName = "Players")]
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
@@ -165,9 +165,6 @@ namespace Torch.Server.ViewModels
|
|||||||
[Torch.Views.Display(Description = "Enables random encounters in the world.", Name = "Enable Encounters", GroupName = "NPCs")]
|
[Torch.Views.Display(Description = "Enables random encounters in the world.", Name = "Enable Encounters", GroupName = "NPCs")]
|
||||||
public bool EnableEncounters { get => _settings.EnableEncounters; set => SetValue(ref _settings.EnableEncounters, value); }
|
public bool EnableEncounters { get => _settings.EnableEncounters; set => SetValue(ref _settings.EnableEncounters, value); }
|
||||||
|
|
||||||
[Torch.Views.Display(Description = "", Name = "Enable Flora", GroupName = "Environment")]
|
|
||||||
public bool EnableFlora { get => _settings.EnableFlora; set => SetValue(ref _settings.EnableFlora, value); }
|
|
||||||
|
|
||||||
[Torch.Views.Display(Description = "Enables possibility of converting grid to station.", Name = "Enable Convert to Station", GroupName = "Others")]
|
[Torch.Views.Display(Description = "Enables possibility of converting grid to station.", Name = "Enable Convert to Station", GroupName = "Others")]
|
||||||
public bool EnableConvertToStation { get => _settings.EnableConvertToStation; set => SetValue(ref _settings.EnableConvertToStation, value); }
|
public bool EnableConvertToStation { get => _settings.EnableConvertToStation; set => SetValue(ref _settings.EnableConvertToStation, value); }
|
||||||
|
|
||||||
|
@@ -343,5 +343,8 @@ namespace Torch.Collections
|
|||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
bool ICollection.IsSynchronized => true;
|
bool ICollection.IsSynchronized => true;
|
||||||
|
|
||||||
|
/// <inheritdoc/>
|
||||||
|
int ICollection.Count => Count;
|
||||||
}
|
}
|
||||||
}
|
}
|
@@ -13,6 +13,7 @@ using Torch.Utils;
|
|||||||
using VRage;
|
using VRage;
|
||||||
using VRage.Library.Collections;
|
using VRage.Library.Collections;
|
||||||
using VRage.Network;
|
using VRage.Network;
|
||||||
|
using VRageMath;
|
||||||
|
|
||||||
namespace Torch.Managers
|
namespace Torch.Managers
|
||||||
{
|
{
|
||||||
@@ -150,7 +151,10 @@ namespace Torch.Managers
|
|||||||
//this value is unused, but removing this line corrupts the rest of the stream
|
//this value is unused, but removing this line corrupts the rest of the stream
|
||||||
var blockedNetworkId = stream.ReadNetworkId();
|
var blockedNetworkId = stream.ReadNetworkId();
|
||||||
var eventId = (uint)stream.ReadUInt16();
|
var eventId = (uint)stream.ReadUInt16();
|
||||||
|
bool flag = stream.ReadBool();
|
||||||
|
Vector3D? position = new Vector3D?();
|
||||||
|
if (flag)
|
||||||
|
position = new Vector3D?(stream.ReadVector3D());
|
||||||
|
|
||||||
CallSite site;
|
CallSite site;
|
||||||
object obj;
|
object obj;
|
||||||
|
@@ -277,7 +277,7 @@ namespace Torch
|
|||||||
MyObjectBuilder_Checkpoint checkpoint = MyLocalCache.LoadCheckpoint(sessionPath, out checkpointSize);
|
MyObjectBuilder_Checkpoint checkpoint = MyLocalCache.LoadCheckpoint(sessionPath, out checkpointSize);
|
||||||
if (MySession.IsCompatibleVersion(checkpoint))
|
if (MySession.IsCompatibleVersion(checkpoint))
|
||||||
{
|
{
|
||||||
if (MyWorkshop.DownloadWorldModsBlocking(checkpoint.Mods).Success)
|
if (MyWorkshop.DownloadWorldModsBlocking(checkpoint.Mods, null).Success)
|
||||||
{
|
{
|
||||||
// MySpaceAnalytics.Instance.SetEntry(MyGameEntryEnum.Load);
|
// MySpaceAnalytics.Instance.SetEntry(MyGameEntryEnum.Load);
|
||||||
MySession.Load(sessionPath, checkpoint, checkpointSize);
|
MySession.Load(sessionPath, checkpoint, checkpointSize);
|
||||||
|
Reference in New Issue
Block a user