From 549c16295f341e51635a259695f14eb775aac730 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 3 May 2011 00:02:03 +0300 Subject: Add min, max, critical hits to debug window. --- src/gui/debugwindow.cpp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'src/gui/debugwindow.cpp') diff --git a/src/gui/debugwindow.cpp b/src/gui/debugwindow.cpp index e9c79a890..cbfce25dc 100644 --- a/src/gui/debugwindow.cpp +++ b/src/gui/debugwindow.cpp @@ -246,6 +246,9 @@ TargetDebugTab::TargetDebugTab() mTargetPartyLabel = new Label(strprintf("%s ?", _("Target Party:"))); mTargetGuildLabel = new Label(strprintf("%s ?", _("Target Guild:"))); mAttackDelayLabel = new Label(strprintf("%s ?", _("Attack delay:"))); + mMinHitLabel = new Label(strprintf("%s ?", _("Minimal hit:"))); + mMaxHitLabel = new Label(strprintf("%s ?", _("Maximum hit:"))); + mCriticalHitLabel = new Label(strprintf("%s ?", _("Critical hit:"))); place(0, 0, mTargetLabel, 2); place(0, 1, mTargetIdLabel, 2); @@ -253,6 +256,9 @@ TargetDebugTab::TargetDebugTab() place(0, 3, mAttackDelayLabel, 2); place(0, 4, mTargetPartyLabel, 2); place(0, 5, mTargetGuildLabel, 2); + place(0, 6, mMinHitLabel, 2); + place(0, 7, mMaxHitLabel, 2); + place(0, 8, mCriticalHitLabel, 2); place.getCell().matchColWidth(0, 0); place = h.getPlacer(0, 1); @@ -288,6 +294,13 @@ void TargetDebugTab::logic() mTargetGuildLabel->setCaption(strprintf("%s %s", _("Target Guild:"), target->getGuildName().c_str())); + mMinHitLabel->setCaption(strprintf("%s %d", + _("Minimal hit:"), target->getMinHit())); + mMaxHitLabel->setCaption(strprintf("%s %d", + _("Maximum hit:"), target->getMaxHit())); + mCriticalHitLabel->setCaption(strprintf("%s %d", + _("Critical hit:"), target->getCriticalHit())); + const int delay = target->getAttackDelay(); if (delay) { @@ -308,6 +321,9 @@ void TargetDebugTab::logic() mTargetPartyLabel->setCaption(strprintf("%s ?", _("Target Party:"))); mTargetGuildLabel->setCaption(strprintf("%s ?", _("Target Guild:"))); mAttackDelayLabel->setCaption(strprintf("%s ?", _("Attack delay:"))); + mMinHitLabel->setCaption(strprintf("%s ?", _("Minimal hit:"))); + mMaxHitLabel->setCaption(strprintf("%s ?", _("Maximum hit:"))); + mCriticalHitLabel->setCaption(strprintf("%s ?", _("Critical hit:"))); } mTargetLabel->adjustSize(); -- cgit v1.2.3-70-g09d2