| 2915 | } |
| 2916 | |
| 2917 | void BattleView::orderPsiAttack(StateRef<BattleUnit> u, PsiStatus status, bool right) |
| 2918 | { |
| 2919 | if (battle.battleViewSelectedUnits.empty()) |
| 2920 | { |
| 2921 | return; |
| 2922 | } |
| 2923 | |
| 2924 | auto unit = battle.battleViewSelectedUnits.front(); |
| 2925 | auto item = unit->agent->getFirstItemInSlot(right ? EquipmentSlotType::RightHand |
| 2926 | : EquipmentSlotType::LeftHand); |
| 2927 | |
| 2928 | if (unit->startAttackPsi(*state, u, status, item->type)) |
| 2929 | { |
| 2930 | activeTab->findControlTyped<RadioButton>("BUTTON_CONTROL")->setChecked(false); |
| 2931 | activeTab->findControlTyped<RadioButton>("BUTTON_PANIC")->setChecked(false); |
| 2932 | activeTab->findControlTyped<RadioButton>("BUTTON_STUN")->setChecked(false); |
| 2933 | activeTab->findControlTyped<RadioButton>("BUTTON_PROBE")->setChecked(false); |
| 2934 | selectionState = BattleSelectionState::Normal; |
| 2935 | } |
| 2936 | } |
| 2937 | |
| 2938 | void BattleView::orderHeal(BodyPart part) |
| 2939 | { |
nothing calls this directly
no test coverage detected