Spawning VS Recycling problem - Video Inside
Good morning everyone! I am currently working on a new project but I have encountered this huge problem which I just can't solve. Basically the aim of my game is similar to traffic rush, with a huge difference... it has a huge round about placed in the middle. My problem comes when I spawn the cars to enter the game...because when I do, all the other cars shudder (stop for half an instant) and this is quite annoying when spawning cars continuosly.
I have tried recycling but it actually made the Memory situation worse (10MB worse!) than the normal spawning.
My question is: is it possible to spawn actors without reducing the framerate for that annoying instant when the actor is spawned?
You can notice the problem here:

You notice the problem mainly around 0:14 secs
IDEA, GRAPHICS AND EVERYTHING IN THE VIDEO IS COPYRIGHTED BY ME! :P
haha, any help is appreciated
Giacomo
P.S. Ignore the overlapping of the cars nd other problems because I havn't yet programmed them.
I have tried recycling but it actually made the Memory situation worse (10MB worse!) than the normal spawning.
My question is: is it possible to spawn actors without reducing the framerate for that annoying instant when the actor is spawned?
You can notice the problem here:

You notice the problem mainly around 0:14 secs
IDEA, GRAPHICS AND EVERYTHING IN THE VIDEO IS COPYRIGHTED BY ME! :P
haha, any help is appreciated

Giacomo
P.S. Ignore the overlapping of the cars nd other problems because I havn't yet programmed them.
Comments
kipper
p.s. it looks like a cool game.
I have also tried storing the cars off screen, but the amount of cars can go up to 90 cars and th memory usage goes up to 70 MB when starting the scene :P
I am goint to try another method now to recycle the cars. If only there was a way to reset the self.time attribute it would all be ok.
I'm sure i'll find a work around soon.
Thanks kipper
Basically the recycling works fine the first time around the round about, but the second time round the cars start jumping aroun the screen due to the self.time messing up with my orbit (taken from tshirt's orbit demo).
I'm now going to try doing a simple work around which will take a long time (and is too difficult to explain :P)
I'll let you know how it goes.
Giacomo