public override byte[] toBinary() { writer = new st.net.NetBase.ByteWriter(); ushort lenpickup_list = (ushort)pickup_list.Count; writer.write_short(lenpickup_list); for (int i_pickup_list = 0; i_pickup_list < lenpickup_list; i_pickup_list++) { st.net.NetBase.pickup_des listData = pickup_list[i_pickup_list]; listData.toBinary(writer); } return(writer.data); }
public override void fromBinary(byte[] binary) { reader = new st.net.NetBase.ByteReader(binary); ushort lenpickup_list = reader.Read_ushort(); pickup_list = new List <st.net.NetBase.pickup_des>(); for (int i_pickup_list = 0; i_pickup_list < lenpickup_list; i_pickup_list++) { st.net.NetBase.pickup_des listData = new st.net.NetBase.pickup_des(); listData.fromBinary(reader); pickup_list.Add(listData); } }