| 778 | } |
| 779 | |
| 780 | int32_t TrapManager::getNeededWorkshopPointsPerTrap(TrapType trapType) |
| 781 | { |
| 782 | switch(trapType) |
| 783 | { |
| 784 | case TrapType::nullTrapType: |
| 785 | return 0; |
| 786 | case TrapType::cannon: |
| 787 | return ConfigManager::getSingleton().getTrapConfigInt32("CannonWorkshopPointsPerTile"); |
| 788 | case TrapType::spike: |
| 789 | return ConfigManager::getSingleton().getTrapConfigInt32("SpikeWorkshopPointsPerTile"); |
| 790 | case TrapType::boulder: |
| 791 | return ConfigManager::getSingleton().getTrapConfigInt32("BoulderWorkshopPointsPerTile"); |
| 792 | case TrapType::doorWooden: |
| 793 | return ConfigManager::getSingleton().getTrapConfigInt32("WoodenDoorPointsPerTile"); |
| 794 | default: |
| 795 | OD_LOG_ERR("Asked for wrong trap type=" + getTrapNameFromTrapType(trapType)); |
| 796 | break; |
| 797 | } |
| 798 | // We shouldn't go here |
| 799 | return 0; |
| 800 | } |
nothing calls this directly
no test coverage detected