| 249 | struct no_wounded |
| 250 | { |
| 251 | IC static bool predicate(const CEntityAlive* enemy) |
| 252 | { |
| 253 | const CAI_Stalker* stalker = smart_cast<const CAI_Stalker*>(enemy); |
| 254 | if (!stalker) |
| 255 | return (false); |
| 256 | |
| 257 | if (!stalker->wounded()) |
| 258 | return (false); |
| 259 | |
| 260 | return (true); |
| 261 | } |
| 262 | }; |
| 263 | |
| 264 | m_objects.erase(std::remove_if(m_objects.begin(), m_objects.end(), &no_wounded::predicate), m_objects.end()); |