aboutsummaryrefslogtreecommitdiff
path: root/src/cmd_query.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/cmd_query.cc')
-rw-r--r--src/cmd_query.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/cmd_query.cc b/src/cmd_query.cc
index deff049..5172cda 100644
--- a/src/cmd_query.cc
+++ b/src/cmd_query.cc
@@ -39,8 +39,7 @@ namespace cmd {
for(auto w : creature::getAttacks(*c)) {
if(w->getName() == rollName) {
text << w->getText(*c) << std::endl;
- int abilityBonus = c->getBonus(creature::getBestAbility(getAbilityOptions(*w), *c));
- int bonus = abilityBonus + c->getProficiency();
+ int bonus = w->getToHitBonus(*c);
printResults(w->getName(), "attack", rolled, bonus);
text << " on hit: " << entry::formatDmg(*w, *c) << std::endl;
break;