public void read(MemoryStream msdata) { roomUid = proto_util.readUInt(msdata); roomType = proto_util.readUInt(msdata); PSimpleRole.readLoop(msdata, roleList); roomState = proto_util.readUByte(msdata); curPlayCount = proto_util.readUByte(msdata); }
public void write(MemoryStream msdata) { proto_util.writeUInt(msdata, roomUid); proto_util.writeUInt(msdata, roomType); PSimpleRole.writeLoop(msdata, roleList); proto_util.writeUByte(msdata, roomState); proto_util.writeUByte(msdata, curPlayCount); }
public static void readLoop(MemoryStream msdata, List <PSimpleRole> p) { int Len = proto_util.readShort(msdata); for (int i = 0; i < Len; i++) { PSimpleRole _pm = new PSimpleRole(); _pm.read(msdata); p.Add(_pm); } }