예제 #1
0
 static public void WriteInstance(NetworkWriter writer, SyncListString items)
 {
     writer.Write((ushort)items.Count);
     for (int i = 0; i < items.Count; i++)
     {
         writer.Write(items[i]);
     }
 }
예제 #2
0
        static public void ReadReference(NetworkReader reader, SyncListString syncList)
        {
            ushort count = reader.ReadUInt16();

            syncList.Clear();
            for (ushort i = 0; i < count; i++)
            {
                syncList.AddInternal(reader.ReadString());
            }
        }
예제 #3
0
        static public SyncListString ReadInstance(NetworkReader reader)
        {
            ushort count  = reader.ReadUInt16();
            var    result = new SyncListString();

            for (ushort i = 0; i < count; i++)
            {
                result.AddInternal(reader.ReadString());
            }
            return(result);
        }