Mar
28
awarded Scholar
Mar
28
comment Efficient Bullet Firing Class
Thanks so much! That made the bullet firing system so efficient that it almost didn't drop the fps at all. Thanks again.
Mar
28
accepted Efficient Bullet Firing Class
Feb
17
comment Efficient Bullet Firing Class
I can have up to 20 or 30 bullets at one time. I have tried running a profiler. The piece of code that takes the longest is the bullet's init code. So I tried creating a bullet pool and storing the bullets in an NSMutableArray. But the calls to NSMutableArray objectAtIndex and NSMutableArray insertObject: atIndex proved to be more time consuming than just creating the bullets when fired. Does anyone know how games like Call of Duty and Halo handle bullets? I recently started paying attention to the frame-rates when firing bullets in those games and they didn't drop at all.
Feb
16
awarded Student
Feb
16
asked Efficient Bullet Firing Class