| 1180 | |
| 1181 | void MissionHistory::AddMagazines(RString name, int count) |
| 1182 | { |
| 1183 | for (int j = 0; j < magazines.Size(); j++) |
| 1184 | { |
| 1185 | if (stricmp(magazines[j].name, name) == 0) |
| 1186 | { |
| 1187 | magazines[j].count += count; |
| 1188 | if (magazines[j].count <= 0) |
| 1189 | { |
| 1190 | magazines.Delete(j); |
| 1191 | } |
| 1192 | return; |
| 1193 | } |
| 1194 | } |
| 1195 | if (count <= 0) |
| 1196 | { |
| 1197 | return; |
| 1198 | } |
| 1199 | int index = magazines.Add(); |
| 1200 | magazines[index].name = name; |
| 1201 | magazines[index].count = count; |
| 1202 | } |
| 1203 | |
| 1204 | void CampaignHistory::SaveWeaponPool(WeaponsInfo& pool) |
| 1205 | { |
| 1206 | MissionHistory* mh = CurrentMission(); |
no test coverage detected