Esempio n. 1
0
 public void ToStreamEx(Stream s, PmxElementFormat f = null)
 {
     if (f == null)
     {
         f = ElementFormat;
     }
     byte[] array = new byte[4];
     array = ((!(f.Ver <= 1f)) ? Encoding.ASCII.GetBytes(PmxKey) : Encoding.ASCII.GetBytes(PmxKey_v1));
     s.Write(array, 0, array.Length);
     array = BitConverter.GetBytes(Ver);
     s.Write(array, 0, array.Length);
     f.ToStreamEx(s);
 }
Esempio n. 2
0
        // Token: 0x06000156 RID: 342 RVA: 0x0000F1EC File Offset: 0x0000D3EC
        public void ToStreamEx(Stream s, PmxElementFormat f)
        {
            bool flag = f == null;

            if (flag)
            {
                f = this.ElementFormat;
            }
            byte[] array = new byte[4];
            bool   flag2 = f.Ver <= 1f;

            if (flag2)
            {
                array = Encoding.ASCII.GetBytes(PmxHeader.PmxKey_v1);
            }
            else
            {
                array = Encoding.ASCII.GetBytes(PmxHeader.PmxKey);
            }
            s.Write(array, 0, array.Length);
            array = BitConverter.GetBytes(this.Ver);
            s.Write(array, 0, array.Length);
            f.ToStreamEx(s, null);
        }