mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-22 05:15:51 +12:00
Fail and warn if an amiibo is loaded at the wrong time
This commit is contained in:
parent
72ae5d2bfa
commit
cf54fd6d1d
2 changed files with 12 additions and 0 deletions
|
@ -48,6 +48,13 @@ void NFCService::handleSyncRequest(u32 messagePointer) {
|
|||
bool NFCService::loadAmiibo(const std::filesystem::path& path) {
|
||||
IOFile file(path, "rb");
|
||||
|
||||
if (!initialized || tagStatus != TagStatus::Scanning) {
|
||||
Helpers::warn("It's not the correct time to load an amiibo! Make sure to load amiibi when the game is searching for one!");
|
||||
file.close();
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!file.isOpen()) {
|
||||
printf("Failed to open Amiibo file");
|
||||
file.close();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue