fix daPy_npc_c::setRestart regression

This commit is contained in:
LagoLunatic
2023-11-01 01:14:16 -04:00
parent e5b40fab3e
commit cac834d67f
3 changed files with 7 additions and 8 deletions
+5 -5
View File
@@ -146,11 +146,11 @@ public:
void onCondition(u16 cond) { mCondition |= cond; }
void offCondition(u16 cond) { mCondition &= ~cond; }
bool checkCommandTalk() { return mCommand == dEvtCmd_INTALK_e; }
bool checkCommandItem() { return mCommand == dEvtCmd_INGETITEM_e; }
bool checkCommandDoor() { return mCommand == dEvtCmd_INDOOR_e; }
bool checkCommandDemoAccrpt() { return mCommand == dEvtCmd_INDEMO_e; }
bool checkCommandCatch() { return mCommand == dEvtCmd_INCATCH_e; }
BOOL checkCommandTalk() { return mCommand == dEvtCmd_INTALK_e; }
BOOL checkCommandItem() { return mCommand == dEvtCmd_INGETITEM_e; }
BOOL checkCommandDoor() { return mCommand == dEvtCmd_INDOOR_e; }
BOOL checkCommandDemoAccrpt() { return mCommand == dEvtCmd_INDEMO_e; }
BOOL checkCommandCatch() { return mCommand == dEvtCmd_INCATCH_e; }
/* 0x04 */ u16 mCommand;
/* 0x06 */ u16 mCondition;
+2 -2
View File
@@ -817,7 +817,7 @@ int daObjMknjD::Act_c::Execute(Mtx** i_mtx) {
case 0:
mEvtInfo.onCondition(1);
if (mEvtInfo.checkCommandTalk() == true) {
if (mEvtInfo.checkCommandTalk()) {
m0500 = 1;
m043F = 0x0B;
}
@@ -943,7 +943,7 @@ int daObjMknjD::Act_c::Execute(Mtx** i_mtx) {
mEvtInfo.onCondition(1);
mEvtInfo.onCondition(32);
if (mEvtInfo.checkCommandTalk() == true) {
if (mEvtInfo.checkCommandTalk()) {
if (dComIfGp_event_chkTalkXY()) {
m0500 = 0;
m043F = 9;
-1
View File
@@ -50,7 +50,6 @@ BOOL daPy_npc_c::check_moveStop() {
/* 8015A524-8015A590 .text setRestart__10daPy_npc_cFSc */
void daPy_npc_c::setRestart(s8 option) {
/* Nonmatching (this matched at some point, what broke it?) */
if (option == dComIfGs_getRestartOption()) {
bool playerInDoor = dComIfGp_getPlayer(0)->mEvtInfo.checkCommandDoor();
s8 roomNo = current.roomNo;