mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-31 01:59:52 -06:00
Merge pull request #10932 from JosJuice/nfs
DiscIO: Add support for the NFS format
This commit is contained in:
@ -133,8 +133,8 @@ GameFile::GameFile(std::string path) : m_file_path(std::move(path))
|
||||
m_block_size = volume->GetBlobReader().GetBlockSize();
|
||||
m_compression_method = volume->GetBlobReader().GetCompressionMethod();
|
||||
m_file_size = volume->GetRawSize();
|
||||
m_volume_size = volume->GetSize();
|
||||
m_volume_size_is_accurate = volume->IsSizeAccurate();
|
||||
m_volume_size = volume->GetDataSize();
|
||||
m_volume_size_type = volume->GetDataSizeType();
|
||||
m_is_datel_disc = volume->IsDatelDisc();
|
||||
m_is_nkit = volume->IsNKit();
|
||||
|
||||
@ -158,7 +158,7 @@ GameFile::GameFile(std::string path) : m_file_path(std::move(path))
|
||||
m_valid = true;
|
||||
m_file_size = m_volume_size = File::GetSize(m_file_path);
|
||||
m_game_id = SConfig::MakeGameID(m_file_name);
|
||||
m_volume_size_is_accurate = true;
|
||||
m_volume_size_type = DiscIO::DataSizeType::Accurate;
|
||||
m_is_datel_disc = false;
|
||||
m_is_nkit = false;
|
||||
m_platform = DiscIO::Platform::ELFOrDOL;
|
||||
@ -349,7 +349,7 @@ void GameFile::DoState(PointerWrap& p)
|
||||
|
||||
p.Do(m_file_size);
|
||||
p.Do(m_volume_size);
|
||||
p.Do(m_volume_size_is_accurate);
|
||||
p.Do(m_volume_size_type);
|
||||
p.Do(m_is_datel_disc);
|
||||
p.Do(m_is_nkit);
|
||||
|
||||
@ -827,7 +827,7 @@ std::string GameFile::GetFileFormatName() const
|
||||
|
||||
bool GameFile::ShouldAllowConversion() const
|
||||
{
|
||||
return DiscIO::IsDisc(m_platform) && m_volume_size_is_accurate;
|
||||
return DiscIO::IsDisc(m_platform) && m_volume_size_type == DiscIO::DataSizeType::Accurate;
|
||||
}
|
||||
|
||||
bool GameFile::IsModDescriptor() const
|
||||
|
@ -104,7 +104,7 @@ public:
|
||||
const std::string& GetApploaderDate() const { return m_apploader_date; }
|
||||
u64 GetFileSize() const { return m_file_size; }
|
||||
u64 GetVolumeSize() const { return m_volume_size; }
|
||||
bool IsVolumeSizeAccurate() const { return m_volume_size_is_accurate; }
|
||||
DiscIO::DataSizeType GetVolumeSizeType() const { return m_volume_size_type; }
|
||||
bool IsDatelDisc() const { return m_is_datel_disc; }
|
||||
bool IsNKit() const { return m_is_nkit; }
|
||||
bool IsModDescriptor() const;
|
||||
@ -145,7 +145,7 @@ private:
|
||||
|
||||
u64 m_file_size{};
|
||||
u64 m_volume_size{};
|
||||
bool m_volume_size_is_accurate{};
|
||||
DiscIO::DataSizeType m_volume_size_type{};
|
||||
bool m_is_datel_disc{};
|
||||
bool m_is_nkit{};
|
||||
|
||||
|
@ -27,14 +27,14 @@
|
||||
|
||||
namespace UICommon
|
||||
{
|
||||
static constexpr u32 CACHE_REVISION = 21; // Last changed in PR 10187
|
||||
static constexpr u32 CACHE_REVISION = 23; // Last changed in PR 10932
|
||||
|
||||
std::vector<std::string> FindAllGamePaths(const std::vector<std::string>& directories_to_scan,
|
||||
bool recursive_scan)
|
||||
{
|
||||
static const std::vector<std::string> search_extensions = {".gcm", ".tgc", ".iso", ".ciso",
|
||||
".gcz", ".wbfs", ".wia", ".rvz",
|
||||
".wad", ".dol", ".elf", ".json"};
|
||||
static const std::vector<std::string> search_extensions = {
|
||||
".gcm", ".tgc", ".iso", ".ciso", ".gcz", ".wbfs", ".wia",
|
||||
".rvz", ".nfs", ".wad", ".dol", ".elf", ".json"};
|
||||
|
||||
// TODO: We could process paths iteratively as they are found
|
||||
return Common::DoFileSearch(directories_to_scan, search_extensions, recursive_scan);
|
||||
|
Reference in New Issue
Block a user