示例#1
0
 static public void WriteInstance(NetworkWriter writer, SyncListFloat items)
 {
     writer.Write((ushort)items.Count);
     for (int i = 0; i < items.Count; i++)
     {
         writer.Write(items[i]);
     }
 }
 static public void WriteInstance(NetworkWriter writer, SyncListFloat items)
 {
     writer.Write((ushort)items.Count);
     foreach (var item in items)
     {
         writer.Write(item);
     }
 }
示例#3
0
 public static void WriteInstance(NetworkWriter writer, SyncListFloat items)
 {
     writer.Write((ushort)items.Count);
     foreach (float num in (SyncList <float>)items)
     {
         writer.Write(num);
     }
 }
示例#4
0
 public static void WriteInstance(NetworkWriter writer, SyncListFloat items)
 {
     writer.Write((ushort)items.Count);
     foreach (float value in items)
     {
         writer.Write(value);
     }
 }
示例#5
0
        /// <summary>
        /// An internal function used for serializing SyncList member variables.
        /// </summary>
        /// <param name="reader"></param>
        /// <param name="syncList"></param>
        static public void ReadReference(NetworkReader reader, SyncListFloat syncList)
        {
            ushort count = reader.ReadUInt16();

            syncList.Clear();
            for (ushort i = 0; i < count; i++)
            {
                syncList.AddInternal(reader.ReadSingle());
            }
        }
示例#6
0
        public static void ReadReference(NetworkReader reader, SyncListFloat syncList)
        {
            ushort num = reader.ReadUInt16();

            syncList.Clear();
            for (ushort num2 = 0; num2 < num; num2 += 1)
            {
                syncList.AddInternal(reader.ReadSingle());
            }
        }
示例#7
0
        /// <summary>
        ///   <para>An internal function used for serializing SyncList member variables.</para>
        /// </summary>
        /// <param name="reader"></param>
        /// <param name="syncList"></param>
        public static void ReadReference(NetworkReader reader, SyncListFloat syncList)
        {
            ushort num = reader.ReadUInt16();

            syncList.Clear();
            for (ushort index = 0; (int)index < (int)num; ++index)
            {
                syncList.AddInternal(reader.ReadSingle());
            }
        }
示例#8
0
        static public SyncListFloat ReadInstance(NetworkReader reader)
        {
            ushort count  = reader.ReadUInt16();
            var    result = new SyncListFloat();

            for (ushort i = 0; i < count; i++)
            {
                result.AddInternal(reader.ReadSingle());
            }
            return(result);
        }
示例#9
0
        public static SyncListFloat ReadInstance(NetworkReader reader)
        {
            ushort        num           = reader.ReadUInt16();
            SyncListFloat syncListFloat = new SyncListFloat();

            for (ushort num2 = 0; num2 < num; num2 += 1)
            {
                syncListFloat.AddInternal(reader.ReadSingle());
            }
            return(syncListFloat);
        }
示例#10
0
        public static SyncListFloat ReadInstance(NetworkReader reader)
        {
            ushort        num  = reader.ReadUInt16();
            SyncListFloat num2 = new SyncListFloat();

            for (ushort i = 0; i < num; i = (ushort)(i + 1))
            {
                num2.AddInternal(reader.ReadSingle());
            }
            return(num2);
        }
示例#11
0
        public static SyncListFloat ReadInstance(NetworkReader reader)
        {
            ushort        num           = reader.ReadUInt16();
            SyncListFloat syncListFloat = new SyncListFloat();

            for (ushort index = 0; (int)index < (int)num; ++index)
            {
                syncListFloat.AddInternal(reader.ReadSingle());
            }
            return(syncListFloat);
        }
示例#12
0
        public static void WriteInstance(NetworkWriter writer, SyncListFloat items)
        {
            writer.Write((ushort)items.Count);
            IEnumerator <float> enumerator = items.GetEnumerator();

            try
            {
                while (enumerator.MoveNext())
                {
                    float current = enumerator.Current;
                    writer.Write(current);
                }
            }
            finally
            {
                if (enumerator == null)
                {
                }
                enumerator.Dispose();
            }
        }