/// <summary>
/// Transaction variant number, irrelevant if nLockTime isn't specified. Its value is 0xffffffff by default.
/// </summary>
- public uint nSequence = 0xffffffff;
+ public uint nSequence = uint.MaxValue;
/// <summary>
/// Initialize new CTxIn instance as copy of another one.
/// </summary>
/// <param name="wBytes">Reference to byte sequence</param>
/// <returns>Inputs array</returns>
- public static CTxIn[] ReadTxInList(ref WrappedList<byte> wBytes)
+ public static CTxIn[] ReadTxInList(ref ByteQueue wBytes)
{
CTxIn[] vin;
{
// Fill inputs array
vin[nIndex] = new CTxIn();
- vin[nIndex].prevout = new COutPoint(wBytes.GetItems(36));
- vin[nIndex].scriptSig = new CScript(wBytes.GetItems((int)VarInt.ReadVarInt(ref wBytes)));
- vin[nIndex].nSequence = BitConverter.ToUInt32(wBytes.GetItems(4), 0);
+ vin[nIndex].prevout = new COutPoint(wBytes.Get(36));
+ vin[nIndex].scriptSig = new CScript(wBytes.Get((int)VarInt.ReadVarInt(ref wBytes)));
+ vin[nIndex].nSequence = BitConverter.ToUInt32(wBytes.Get(4), 0);
}
// Return inputs array
{
StringBuilder sb = new StringBuilder ();
- /*
- if (IsCoinBase)
- {
- sb.AppendFormat("CTxIn(txId={0}, coinbase={2}, nSequence={3})", txID.ToString(), n, Interop.ToHex(scriptSig.Bytes), nSequence);
- }
- else
- {
- sb.AppendFormat("CTxIn(txId={0}, n={1}, scriptSig={2}, nSequence={3})", txID.ToString(), n, scriptSig.ToString(), nSequence);
- }
- */
-
-
sb.AppendFormat("CTxIn(");
sb.Append(prevout.ToString());