Skip to content

Commit

Permalink
Configure card read DMA setting for DSiWare on flashcards
Browse files Browse the repository at this point in the history
  • Loading branch information
RocketRobz committed Sep 4, 2024
1 parent d9f5784 commit 5b3bd8b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions romsel_aktheme/arm9/source/perGameSettings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,7 @@ void perGameSettings (std::string filename) {
break;
case 5:
printSmall(false, perGameOpXpos, perGameOpYpos, "Card Read DMA:", Alignment::left, highlighted);
if (romUnitCode[cursorPosOnScreen] > 0 && (perGameSettings_dsiMode==-1 ? DEFAULT_DSI_MODE : perGameSettings_dsiMode > 0)) {
if (dsiFeatures() && romUnitCode[cursorPosOnScreen] > 0 && (perGameSettings_dsiMode==-1 ? DEFAULT_DSI_MODE : perGameSettings_dsiMode > 0)) {
printSmall(false, 256-perGameOpXpos, perGameOpYpos, "Off", Alignment::right, highlighted);
} else if (perGameSettings_cardReadDMA == -1) {
printSmall(false, 256-perGameOpXpos, perGameOpYpos, "Default", Alignment::right, highlighted);
Expand Down Expand Up @@ -974,7 +974,7 @@ void perGameSettings (std::string filename) {
}
break;
case 5:
if (romUnitCode[cursorPosOnScreen] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
if (!dsiFeatures() || romUnitCode[cursorPosOnScreen] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
perGameSettings_cardReadDMA--;
if (perGameSettings_cardReadDMA < -1) perGameSettings_cardReadDMA = 1;
}
Expand Down Expand Up @@ -1051,7 +1051,7 @@ void perGameSettings (std::string filename) {
}
break;
case 5:
if (romUnitCode[cursorPosOnScreen] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
if (!dsiFeatures() || romUnitCode[cursorPosOnScreen] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
perGameSettings_cardReadDMA++;
if (perGameSettings_cardReadDMA > 1) perGameSettings_cardReadDMA = -1;
}
Expand Down
6 changes: 3 additions & 3 deletions romsel_dsimenutheme/arm9/source/perGameSettings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -884,7 +884,7 @@ void perGameSettings (std::string filename) {
break;
case 5:
printSmall(false, perGameOpStartXpos, perGameOpYpos, STR_CARD_READ_DMA + ":", startAlign, FontPalette::dialog);
if (unitCode[CURPOS] > 0 && (perGameSettings_dsiMode==-1 ? DEFAULT_DSI_MODE : perGameSettings_dsiMode > 0)) {
if (dsiFeatures() && unitCode[CURPOS] > 0 && (perGameSettings_dsiMode==-1 ? DEFAULT_DSI_MODE : perGameSettings_dsiMode > 0)) {
printSmall(false, perGameOpEndXpos, perGameOpYpos, STR_OFF, endAlign, FontPalette::dialog);
} else if (perGameSettings_cardReadDMA == -1) {
printSmall(false, perGameOpEndXpos, perGameOpYpos, STR_DEFAULT, endAlign, FontPalette::dialog);
Expand Down Expand Up @@ -1080,7 +1080,7 @@ void perGameSettings (std::string filename) {
}
break;
case 5:
if (unitCode[CURPOS] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
if (!dsiFeatures() || unitCode[CURPOS] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
perGameSettings_cardReadDMA--;
if (perGameSettings_cardReadDMA < -1) perGameSettings_cardReadDMA = 1;
}
Expand Down Expand Up @@ -1158,7 +1158,7 @@ void perGameSettings (std::string filename) {
}
break;
case 5:
if (unitCode[CURPOS] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
if (!dsiFeatures() || unitCode[CURPOS] == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
perGameSettings_cardReadDMA++;
if (perGameSettings_cardReadDMA > 1) perGameSettings_cardReadDMA = -1;
}
Expand Down
6 changes: 3 additions & 3 deletions romsel_r4theme/arm9/source/perGameSettings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -795,7 +795,7 @@ void perGameSettings (std::string filename) {
break;
case 5:
printSmall(false, perGameOpXpos, perGameOpYpos, "Card Read DMA:", Alignment::left, highlighted);
if (romUnitCode > 0 && (perGameSettings_dsiMode==-1 ? DEFAULT_DSI_MODE : perGameSettings_dsiMode > 0)) {
if (dsiFeatures() && romUnitCode > 0 && (perGameSettings_dsiMode==-1 ? DEFAULT_DSI_MODE : perGameSettings_dsiMode > 0)) {
printSmall(false, 256-perGameOpXpos, perGameOpYpos, "Off", Alignment::right, highlighted);
} else if (perGameSettings_cardReadDMA == -1) {
printSmall(false, 256-perGameOpXpos, perGameOpYpos, "Default", Alignment::right, highlighted);
Expand Down Expand Up @@ -981,7 +981,7 @@ void perGameSettings (std::string filename) {
}
break;
case 5:
if (romUnitCode == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
if (!dsiFeatures() || romUnitCode == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
perGameSettings_cardReadDMA--;
if (perGameSettings_cardReadDMA < -1) perGameSettings_cardReadDMA = 1;
}
Expand Down Expand Up @@ -1058,7 +1058,7 @@ void perGameSettings (std::string filename) {
}
break;
case 5:
if (romUnitCode == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
if (!dsiFeatures() || romUnitCode == 0 || (perGameSettings_dsiMode==-1 ? (DEFAULT_DSI_MODE == TWLSettings::EDSMode) : perGameSettings_dsiMode < 1)) {
perGameSettings_cardReadDMA++;
if (perGameSettings_cardReadDMA > 1) perGameSettings_cardReadDMA = -1;
}
Expand Down

0 comments on commit 5b3bd8b

Please sign in to comment.