Ammo counter

Hi, I was recently playing the game destiny and I saw soemthing I really like, as the title suggests it is an ammo counter for a ar15 or something like that. The way I thought this might be done is with a linear potentiometer inside te magazine and have that imputed into the arduino UNO or micro and output the data to a seven segment display. The ammo in the magazine would push the pot down and then the # in the led display would be at whatever # of bullets you have in the magazine

Do you have the skills to fit a linear potentiometer in the gun safely, without interfering with the feeding of bullets? If so, I can't imagine why you'd be asking here. If not, I can't imagine that it matters.

I'd use an accelerometer on the gun to sense the recoil from each round fired and count up from zero. No modifications necessary to the magazines.

Thanks for the feedback , I was thinking of doing this for magazine fed paintball and not a real firearm, te paintball magazines have lots of space in the mags to play with, anyways does anybody have a link to something that is a similar project to this? Thanks

https://www.google.com/search?q=arduino+ammo+counter