use the currently selected countermeasure
| 1499 | |
| 1500 | // use the currently selected countermeasure |
| 1501 | bool UseCountermeasure() { |
| 1502 | int type, id; |
| 1503 | |
| 1504 | Players[Player_num].counter_measures.GetPosTypeID(type, id); |
| 1505 | if (!type && !id) |
| 1506 | return false; |
| 1507 | |
| 1508 | if (Players[Player_num].counter_measures.UsePos(&Objects[Players[Player_num].objnum])) { |
| 1509 | if (Game_mode & GM_MULTI && (Netgame.local_role == LR_SERVER)) { |
| 1510 | MultiSendInventoryRemoveItem(Player_num, type, id); |
| 1511 | } |
| 1512 | } |
| 1513 | return true; |
| 1514 | } |
| 1515 | |
| 1516 | // Checks for an object in any of the players inventorys and removes it |
| 1517 | void InventoryRemoveObject(int objhandle) { |
no test coverage detected