コード例 #1
0
ファイル: AuthManifest.cs プロジェクト: Hoikas/mudpit
 public AuthManifest(string dir, string[] files)
 {
     foreach (string file in files) {
         AuthFileEntry afe = new AuthFileEntry();
         afe.fName = dir + "\\" + Path.GetFileName(file);
         afe.fSize = new FileInfo(file).Length;
         fFiles.Add(afe);
     }
 }
コード例 #2
0
ファイル: AuthManifest.cs プロジェクト: Hoikas/mudpit
        public void Read(UruStream s)
        {
            while (true) {
                AuthFileEntry entry = new AuthFileEntry();
                entry.fName = s.ReadUnicodeString();
                if (entry.fName == String.Empty) break;
                entry.fSize = (long)(s.ReadUShort() << 16 | s.ReadUShort() & 0xFFFF);
                s.ReadUShort(); //NULL

                fFiles.Add(entry);
            }
        }