For example, my character has a damage resistance of 5. The Guynmart shield has a chance of giving a 2-round bark skin x2 effect (+2 to damage resistance). When I fight a mist of the crypt (damage potential 1-7), I've observed sequences in the combat log like:
- You are affected by Bark skin x2 (2 rounds).
- Mist of the crypt hits you for 1 hp!
I did a quick read-through of the code to confirm the behavior. The flow of logic looks something like this:
Code: Select all
CombatController::attackWithCurrentMonster
CombatController::monsterAttacks
CombatController::attack
ActorStatsController::removeActorHealth // DAMAGE CAUSED BY ATTACK IS APPLIED HERE
CombatController::applyAttackHitStatusEffects
ActorStatsController::applyUseEffect
ActorStatsController::rollForConditionEffect
CombatActionListeners::onPlayerReceviesActorCondition
MainActivity::onPlayerReceviesActorCondition
MainActivity::message
CombatLog::append // PLAYER STATUS EFFECT IS ADDED TO THE LOG HERE
CombatActionListeners::onMonsterReceivesActorCondition
MainActivity::onMonsterReceivesActorCondition
MainActivity::message
CombatLog::append // MONSTER STATUS EFFECT IS ADDED TO THE LOG HERE
ActorStatsController::applyActorCondition // STATUS EFFECT IS APPLIED TO STATS HERE
CombatActionListeners::onMonsterAttackSuccess
MainActivity::onMonsterAttackSuccess
MainActivity::message
CombatLog::append // DAMAGE CAUSED BY ATTACK IS ADDED TO THE LOG HERE