protected Stream UnpackEntry(Stream input, NsaEntry nsa_entry) { if (null == nsa_entry || !(Compression.LZSS == nsa_entry.CompressionType || Compression.SPB == nsa_entry.CompressionType)) return input; using (input) { var decoder = new Unpacker (input, nsa_entry.UnpackedSize); if (Compression.SPB == nsa_entry.CompressionType) return decoder.SpbDecodedStream(); else return decoder.LzssDecodedStream(); } }