Bf2 is like 1942, except BF2 has some updated technology, and it can utilize Loop Keys, or Regions, these keys specify a region within the .wav file that loops, so when the sound reaches the second key it replays the sound from the first, then once ammunition is depleted it finishes the sample. Sound Forge has tools for this.
Alternatively, you could make a very short sound, lets say you are making it for a BAR that shoots 600 rounds a minute, well in that case you should make a sound that is 0.1 (60/600) seconds in length, to loop with each shot (old 1942 method). The downside to this method is there will be no reverb (reverb that is part of the sound iteslf) afterwards, so the sound will just stop. Probably why its better for distance sounds.