55 lines
1.5 KiB
C#
55 lines
1.5 KiB
C#
using System;
|
|
|
|
namespace UnityEngine.Networking
|
|
{
|
|
// Token: 0x02000066 RID: 102
|
|
public sealed class SyncListString : SyncList<string>
|
|
{
|
|
// Token: 0x06000523 RID: 1315 RVA: 0x0001E2B7 File Offset: 0x0001C4B7
|
|
protected override void SerializeItem(NetworkWriter writer, string item)
|
|
{
|
|
writer.Write(item);
|
|
}
|
|
|
|
// Token: 0x06000524 RID: 1316 RVA: 0x0001E2C4 File Offset: 0x0001C4C4
|
|
protected override string DeserializeItem(NetworkReader reader)
|
|
{
|
|
return reader.ReadString();
|
|
}
|
|
|
|
// Token: 0x06000525 RID: 1317 RVA: 0x0001E2E0 File Offset: 0x0001C4E0
|
|
[Obsolete("ReadReference is now used instead")]
|
|
public static SyncListString ReadInstance(NetworkReader reader)
|
|
{
|
|
ushort num = reader.ReadUInt16();
|
|
SyncListString syncListString = new SyncListString();
|
|
for (ushort num2 = 0; num2 < num; num2 += 1)
|
|
{
|
|
syncListString.AddInternal(reader.ReadString());
|
|
}
|
|
return syncListString;
|
|
}
|
|
|
|
// Token: 0x06000526 RID: 1318 RVA: 0x0001E324 File Offset: 0x0001C524
|
|
public static void ReadReference(NetworkReader reader, SyncListString syncList)
|
|
{
|
|
ushort num = reader.ReadUInt16();
|
|
syncList.Clear();
|
|
for (ushort num2 = 0; num2 < num; num2 += 1)
|
|
{
|
|
syncList.AddInternal(reader.ReadString());
|
|
}
|
|
}
|
|
|
|
// Token: 0x06000527 RID: 1319 RVA: 0x0001E360 File Offset: 0x0001C560
|
|
public static void WriteInstance(NetworkWriter writer, SyncListString items)
|
|
{
|
|
writer.Write((ushort)items.Count);
|
|
for (int i = 0; i < items.Count; i++)
|
|
{
|
|
writer.Write(items[i]);
|
|
}
|
|
}
|
|
}
|
|
}
|