v0.14.6.0

This commit is contained in:
Joonas Rikkonen
2021-06-17 17:54:52 +03:00
parent 3f324b14e8
commit c27e2ea5ab
348 changed files with 13156 additions and 4266 deletions
@@ -20,33 +20,5 @@ namespace Barotrauma
}
}
}
/// <summary>
/// Sends a message to all clients telling them that all upgrades on the submarine were reset.
/// </summary>
/// <remarks>
/// <param name="newUpgrades"/> is supposed to have a list of reloaded metadata but seeing as
/// this method is currently only used when switching submarines and that disables the repair NPC
/// until the next round so currently there's no need for it as we get the new values from the save
/// file anyways.
/// </remarks>
/// <see cref="UpgradeManager.ClientRead"/>
private void SendUpgradeResetMessage(Dictionary<string, int> newUpgrades)
{
foreach (Client c in GameMain.Server.ConnectedClients)
{
IWriteMessage outmsg = new WriteOnlyMessage();
outmsg.Write((byte)ServerPacketHeader.RESET_UPGRADES);
outmsg.Write(true);
outmsg.Write(Campaign.Money);
// outmsg.Write((uint)newUpgrades.Count);
// foreach (var (key, value) in newUpgrades)
// {
// outmsg.Write(key);
// outmsg.Write((byte)value);
// }
GameMain.Server?.ServerPeer?.Send(outmsg, c.Connection, DeliveryMethod.Reliable);
}
}
}
}