* Returns the soldier's craft string, which * is either the soldier's wounded status, * the assigned craft name, or none. * @param lang Language to get strings from. * @return Full name. */
| 225 | * @return Full name. |
| 226 | */ |
| 227 | std::wstring Soldier::getCraftString(Language *lang) const |
| 228 | { |
| 229 | std::wstring s; |
| 230 | if (_recovery > 0) |
| 231 | { |
| 232 | s = lang->getString("STR_WOUNDED"); |
| 233 | } |
| 234 | else if (_craft == 0) |
| 235 | { |
| 236 | s = lang->getString("STR_NONE_UC"); |
| 237 | } |
| 238 | else |
| 239 | { |
| 240 | s = _craft->getName(lang); |
| 241 | } |
| 242 | return s; |
| 243 | } |
| 244 | |
| 245 | /** |
| 246 | * Returns a localizable-string representation of |
no test coverage detected