public StrategyMemo(byte[] input, int offset, bool xd) { XD = xd; int count = BigEndian.ToInt16(input, offset); if (count > 500) { count = 500; } for (int i = 0; i < count; i++) { byte[] data = new byte[SIZE_ENTRY]; Array.Copy(input, 4 + offset + SIZE_ENTRY * i, data, 0, SIZE_ENTRY); Entries.Add(new StrategyMemoEntry(XD, data)); } }