| 638 | } |
| 639 | |
| 640 | int Game_Party::GetAverageLevel() { |
| 641 | int party_lvl = 0; |
| 642 | |
| 643 | std::vector<Game_Actor*> actors = GetActors(); |
| 644 | std::vector<Game_Actor*>::iterator it; |
| 645 | |
| 646 | if (actors.empty()) { |
| 647 | return 0; |
| 648 | } |
| 649 | |
| 650 | for (it = actors.begin(); it != actors.end(); ++it) { |
| 651 | party_lvl += (*it)->GetLevel(); |
| 652 | } |
| 653 | |
| 654 | return party_lvl / (int)actors.size(); |
| 655 | } |
| 656 | |
| 657 | int Game_Party::GetFatigue() { |
| 658 | const auto& actors = GetActors(); |
no test coverage detected