This is because the conditional statement does not work correctly.
Wherever you made changes, there should be.
Code
- Your code:
- if (ch)
- ++regen->count;
- #ifdef __ENABLE_MONSTER_CONTROLLER__
- if (MonsterControllerNS::GetCounterType(ch->GetRaceNum()).has_value())
- CMonsterController::instance().HandleCounter(ch, ch->GetMapIndex());
- #endif
- Correct code:
- if (ch)
- {
- ++regen->count;
- #ifdef __ENABLE_MONSTER_CONTROLLER__
- if (MonsterControllerNS::GetCounterType(ch->GetRaceNum()).has_value())
- CMonsterController::instance().HandleCounter(ch, ch->GetMapIndex());
- #endif
- }