protected override void Parse(ref BitStreamReader bsr)
        {
            PaintType = (PaintType)bsr.ReadByte();
            EHandle   = bsr.ReadEHandle();
            UnkHf1    = bsr.ReadFloat();
            UnkHf2    = bsr.ReadFloat();
            byte len = bsr.ReadByte();

            bsr.ReadVector3(out Center);
            if (bsr.BitsRemaining % 48 != 0)
            {
                throw new ParseException($"{GetType().Name} doesn't have the right number of bits left, " +
                                         $"expected a multiple of 48 but got {bsr.BitsRemaining}");
            }
            Positions = new Vector3[len];
            for (int i = 0; i < len; i++)
            {
                Positions[i] = Center + new Vector3(bsr.ReadSShort(), bsr.ReadSShort(), bsr.ReadSShort());
            }
        }
 protected override void Parse(ref BitStreamReader bsr)
 {
     S1 = bsr.ReadSShort();
     S2 = bsr.ReadSShort();
     S3 = bsr.ReadSShort();
 }
Exemplo n.º 3
0
 protected override void Parse(ref BitStreamReader bsr)
 {
     TokenName = bsr.ReadNullTerminatedString();
     Duration  = bsr.ReadSShort() * 0.1f;
     Flags     = (CloseCaptionFlags)bsr.ReadByte();
 }