Unstable 0.16.0.0
This commit is contained in:
@@ -97,7 +97,7 @@ namespace Barotrauma.Networking
|
||||
private readonly SerializableProperty property;
|
||||
private readonly string typeString;
|
||||
private readonly object parentObject;
|
||||
|
||||
|
||||
public string Name
|
||||
{
|
||||
get { return property.Name; }
|
||||
@@ -214,7 +214,7 @@ namespace Barotrauma.Networking
|
||||
|
||||
public void Write(IWriteMessage msg, object overrideValue = null)
|
||||
{
|
||||
if (overrideValue == null) overrideValue = property.GetValue(parentObject);
|
||||
if (overrideValue == null) { overrideValue = Value; }
|
||||
switch (typeString)
|
||||
{
|
||||
case "float":
|
||||
@@ -314,6 +314,7 @@ namespace Barotrauma.Networking
|
||||
{
|
||||
NetPropertyData netPropertyData = new NetPropertyData(this, property, typeName);
|
||||
UInt32 key = ToolBox.StringToUInt32Hash(property.Name, md5);
|
||||
if (key == 0) { key++; } //0 is reserved to indicate the end of the netproperties section of a message
|
||||
if (netProperties.ContainsKey(key)){ throw new Exception("Hashing collision in ServerSettings.netProperties: " + netProperties[key] + " has same key as " + property.Name + " (" + key.ToString() + ")"); }
|
||||
netProperties.Add(key, netPropertyData);
|
||||
}
|
||||
@@ -717,13 +718,6 @@ namespace Barotrauma.Networking
|
||||
set;
|
||||
}
|
||||
|
||||
[Serialize("", true)]
|
||||
public string CampaignSubmarines
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
|
||||
private YesNoMaybe traitorsEnabled;
|
||||
[Serialize(YesNoMaybe.No, true)]
|
||||
public YesNoMaybe TraitorsEnabled
|
||||
@@ -1067,7 +1061,6 @@ namespace Barotrauma.Networking
|
||||
}
|
||||
|
||||
#if SERVER
|
||||
MultiPlayerCampaign.UpdateCampaignSubs();
|
||||
SelectNonHiddenSubmarine();
|
||||
#endif
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user