File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
MLAPI/NetworkingManagerComponents/Binary Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -70,9 +70,9 @@ public byte ReadByte()
70
70
public void SkipPadded ( ) => bitCount += ( 8 - ( bitCount % 8 ) ) % 8 ;
71
71
public ushort ReadUShort ( ) => ( ushort ) ReadULong ( ) ;
72
72
public uint ReadUInt ( ) => ( uint ) ReadULong ( ) ;
73
- public sbyte ReadSByte ( ) => ( sbyte ) ZigZagDecode ( ReadByte ( ) ) ;
74
- public short ReadShort ( ) => ( short ) ZigZagDecode ( ReadUShort ( ) ) ;
75
- public int ReadInt ( ) => ( int ) ZigZagDecode ( ReadUInt ( ) ) ;
73
+ public sbyte ReadSByte ( ) => ( sbyte ) ZigZagDecode ( ReadULong ( ) ) ;
74
+ public short ReadShort ( ) => ( short ) ZigZagDecode ( ReadULong ( ) ) ;
75
+ public int ReadInt ( ) => ( int ) ZigZagDecode ( ReadULong ( ) ) ;
76
76
public long ReadLong ( ) => ZigZagDecode ( ReadULong ( ) ) ;
77
77
78
78
public float [ ] ReadFloatArray ( int known = - 1 ) => ReadArray ( ReadFloat , known ) ;
Original file line number Diff line number Diff line change @@ -358,8 +358,8 @@ private static Type GetUnsignedType(Type t) =>
358
358
t == typeof ( int ) ? typeof ( uint ) :
359
359
t == typeof ( long ) ? typeof ( ulong ) :
360
360
null ;
361
-
362
- public static ulong ZigZagEncode ( long d ) => ( ulong ) ( ( ( d >> 63 ) & 1 ) | ( d << 1 ) ) ;
361
+
362
+ public static ulong ZigZagEncode ( long d ) => ( ulong ) ( ( ( d >> 63 ) & 1 ) | ( d << 1 ) ) ;
363
363
364
364
public static long GetBitCount < T > ( T t )
365
365
{
You can’t perform that action at this time.
0 commit comments