public void Load(PangyaBinaryReader reader, byte[] roomKey)
        {
            //var result = reader.ReadBytes(56);

            var decrypted = DecryptShot(
                reader.ReadBytes((int)(reader.BaseStream.Length - reader.BaseStream.Position))
                , roomKey);

            ResponseShot = decrypted.Take(38).ToArray();

            var readerDecripted = new PangyaBinaryReader(new MemoryStream(decrypted));

            ConnectionId = readerDecripted.ReadInt32();
            X            = readerDecripted.ReadInt32();
            Y            = readerDecripted.ReadInt32();
            Z            = readerDecripted.ReadInt32();

            ShotType  = (ShotTypeEnum)readerDecripted.ReadByte();
            Unknown1  = readerDecripted.ReadInt16();
            Pang      = readerDecripted.ReadUInt32();
            BonusPang = readerDecripted.ReadUInt32();
            Unknown2  = readerDecripted.ReadInt32();
            MatchData = readerDecripted.ReadBytes(6);
            Unknown3  = readerDecripted.ReadBytes(17);
        }
        public override void Load(PangyaBinaryReader reader)
        {
            ShotType = (ShotTypeEnum)reader.ReadUInt16();

            switch (ShotType)
            {
            case ShotTypeEnum.UNKOWN:
            {
                reader.Skip(9);
                Un = reader.ReadBytes(62);
            }
            break;

            default:
                Un = reader.ReadBytes(62);
                break;
            }
        }
Esempio n. 3
0
 public override void Load(PangyaBinaryReader reader)
 {
     ShotData = reader.ReadBytes(87);
 }