FillNetworkData uses NetBuffer instead of OutgoingMessage

This commit is contained in:
Regalis
2015-11-04 20:21:34 +02:00
parent 9f9f0205e7
commit 5a21d64b3a
23 changed files with 36 additions and 39 deletions
+2 -1
View File
@@ -6,6 +6,7 @@ using System.Xml.Linq;
using FarseerPhysics;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Lidgren.Network;
namespace Barotrauma
{
@@ -471,7 +472,7 @@ namespace Barotrauma
h.ID = (ushort)int.Parse(element.Attribute("ID").Value);
}
public override bool FillNetworkData(Networking.NetworkEventType type, Lidgren.Network.NetOutgoingMessage message, object data)
public override bool FillNetworkData(Networking.NetworkEventType type, NetBuffer message, object data)
{
message.WriteRangedSingle(MathHelper.Clamp(volume/FullVolume, 0.0f, 1.5f), 0.0f, 1.5f, 6);