summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2021-07-05 22:51:00 +0200
committerGitHub <noreply@github.com>2021-07-05 22:51:00 +0200
commit3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf (patch)
tree43413a941ff3a0dbdc7ba9e515d55e027bd4dfe7 /src
parentMerge pull request #6540 from Kelebek1/nvdec (diff)
parentservice: mii: Retrieve the correct default miis. (diff)
downloadyuzu-3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf.tar
yuzu-3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf.tar.gz
yuzu-3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf.tar.bz2
yuzu-3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf.tar.lz
yuzu-3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf.tar.xz
yuzu-3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf.tar.zst
yuzu-3d03a6ae0232780ed6fb28e52dbdc5221cb3a7bf.zip
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/service/mii/manager.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core/hle/service/mii/manager.cpp b/src/core/hle/service/mii/manager.cpp
index 114aff31c..869d2763f 100644
--- a/src/core/hle/service/mii/manager.cpp
+++ b/src/core/hle/service/mii/manager.cpp
@@ -20,6 +20,7 @@ namespace {
constexpr ResultCode ERROR_CANNOT_FIND_ENTRY{ErrorModule::Mii, 4};
+constexpr std::size_t BaseMiiCount{2};
constexpr std::size_t DefaultMiiCount{RawData::DefaultMii.size()};
constexpr MiiStoreData::Name DefaultMiiName{u'y', u'u', u'z', u'u'};
@@ -415,7 +416,7 @@ u32 MiiManager::GetCount(SourceFlag source_flag) const {
count += 0;
}
if ((source_flag & SourceFlag::Default) != SourceFlag::None) {
- count += DefaultMiiCount;
+ count += (DefaultMiiCount - BaseMiiCount);
}
return static_cast<u32>(count);
}
@@ -445,7 +446,7 @@ ResultVal<std::vector<MiiInfoElement>> MiiManager::GetDefault(SourceFlag source_
return MakeResult(std::move(result));
}
- for (std::size_t index = 0; index < DefaultMiiCount; index++) {
+ for (std::size_t index = BaseMiiCount; index < DefaultMiiCount; index++) {
result.emplace_back(BuildDefault(index), Source::Default);
}