MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / updateSelectedPart

Method updateSelectedPart

src/Battlescape/MedikitView.cpp:129–139  ·  view source on GitHub ↗

* Updates the selected body part. * If there is a wounded body part, selects that. * Otherwise does not change the selected part. */

Source from the content-addressed store, hash-verified

127 * Otherwise does not change the selected part.
128 */
129void MedikitView::updateSelectedPart()
130{
131 for (int i = 0; i < 6; ++i)
132 {
133 if (_unit->getFatalWound(i))
134 {
135 _selectedPart = i;
136 break;
137 }
138 }
139}
140}

Callers 1

onHealClickMethod · 0.80

Calls 1

getFatalWoundMethod · 0.80

Tested by

no test coverage detected