implement reset macro on porta flag

This commit is contained in:
tildearrow 2022-02-08 17:02:27 -05:00
parent 6fb5ca0f78
commit 23dc509524
11 changed files with 14 additions and 12 deletions

View File

@ -250,7 +250,7 @@ int DivPlatformAmiga::dispatch(DivCommand c) {
break;
}
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_GET_VOLMAX:

View File

@ -315,7 +315,7 @@ int DivPlatformAY8910::dispatch(DivCommand c) {
return 15;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_PRE_NOTE:

View File

@ -368,7 +368,7 @@ int DivPlatformAY8930::dispatch(DivCommand c) {
return 31;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_PRE_NOTE:

View File

@ -271,8 +271,10 @@ int DivPlatformC64::dispatch(DivCommand c) {
chan[c.chan].note=c.value;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].keyOn=true;
if (parent->song.resetMacroOnPorta) {
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].keyOn=true;
}
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_PRE_NOTE:

View File

@ -313,7 +313,7 @@ int DivPlatformGB::dispatch(DivCommand c) {
break;
case DIV_CMD_PRE_PORTA:
if (chan[c.chan].active) {
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
}
chan[c.chan].inPorta=c.value;
break;

View File

@ -375,7 +375,7 @@ int DivPlatformNES::dispatch(DivCommand c) {
chan[c.chan].note=c.value;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_GET_VOLMAX:

View File

@ -366,7 +366,7 @@ int DivPlatformPCE::dispatch(DivCommand c) {
chan[c.chan].note=c.value;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_GET_VOLMAX:

View File

@ -262,7 +262,7 @@ int DivPlatformSAA1099::dispatch(DivCommand c) {
return 15;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_PRE_NOTE:

View File

@ -188,7 +188,7 @@ int DivPlatformSMS::dispatch(DivCommand c) {
chan[c.chan].actualNote=c.value;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_GET_VOLMAX:

View File

@ -215,7 +215,7 @@ int DivPlatformTIA::dispatch(DivCommand c) {
return 15;
break;
case DIV_CMD_PRE_PORTA:
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
chan[c.chan].inPorta=c.value;
break;
case DIV_CMD_PRE_NOTE:

View File

@ -674,7 +674,7 @@ int DivPlatformYM2610::dispatch(DivCommand c) {
break;
case DIV_CMD_PRE_PORTA:
if (c.chan>3) {
chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
if (parent->song.resetMacroOnPorta) chan[c.chan].std.init(parent->getIns(chan[c.chan].ins));
}
chan[c.chan].inPorta=c.value;
break;