diff --git a/MyceliumNetworkingForCW/Message.cs b/MyceliumNetworkingForCW/Message.cs index 08eaf12..59fadd8 100644 --- a/MyceliumNetworkingForCW/Message.cs +++ b/MyceliumNetworkingForCW/Message.cs @@ -256,6 +256,7 @@ public void WriteObject(Type type, object value) { typeof(ushort), (Message msg, object value) => { msg.WriteUShort((ushort)value); } }, { typeof(long), (Message msg, object value) => { msg.WriteLong((long)value); } }, { typeof(ulong), (Message msg, object value) => { msg.WriteULong((ulong)value); } }, + { typeof(float), (Message msg, object value) => { msg.WriteFloat((float)value); } }, { typeof(string), (Message msg, object value) => { msg.WriteString((string)value); } }, { typeof(Vector3), (Message msg, object value) => { msg.WriteVector3((Vector3)value); } }, { typeof(Quaternion), (Message msg, object value) => { msg.WriteQuaternion((Quaternion)value); } }, @@ -515,6 +516,7 @@ public object ReadObject(Type type) { typeof(ushort), (Message msg) => { return msg.ReadUShort(); } }, { typeof(long), (Message msg) => { return msg.ReadLong(); } }, { typeof(ulong), (Message msg) => { return msg.ReadULong(); } }, + { typeof(float), (Message msg) => { return msg.ReadFloat(); } }, { typeof(string), (Message msg) => { return msg.ReadString(); } }, { typeof(Vector3), (Message msg) => { return msg.ReadVector3(); } }, { typeof(Quaternion), (Message msg) => { return msg.ReadQuaternion(); } },