Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
kaleohanopahala authored Feb 8, 2025
1 parent 736f302 commit be58419
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/creatures/creature.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1154,6 +1154,10 @@ void Creature::onAttacked() {
}

void Creature::onAttackedCreatureDrainHealth(const std::shared_ptr<Creature> &target, int32_t points) {
if (!target || points <= 0) {
return;
}

target->addDamagePoints(static_self_cast<Creature>(), points);
}

Expand Down

0 comments on commit be58419

Please sign in to comment.