Trying to make game work without spawning, but...
I need a little help.
I'm using recycling methods to make my game run faster, but I'm having an issue.
I have a rule where I'd normally spawn 3 different things at the same time, as in:
When (conditions), then
Spawn actor (actor1) at rotation 0
Spawn actor (actor1) at rotation 15
Spawn actor (actor1) at rotation -15
However, now it looks like
When (conditions), then
Change attribute (game.spawnCounter) to (game.spawnCounter+1)%game.numberSpawned
Change attribute (game.spawnCounter) to (game.spawnCounter+1)%game.numberSpawned
Change attribute (game.spawnCounter) to (game.spawnCounter+1)%game.numberSpawned
The problem is when stacked like this, I only end up spawning the third actor. I guess the engine isn't in the state where only 1 is added long enough for the actor to see it's its time to shine. I want to get this working (where 3 would be spawned or moved simultaneously) without using timers. Is this possible?
Thanks in advance.
I'm using recycling methods to make my game run faster, but I'm having an issue.
I have a rule where I'd normally spawn 3 different things at the same time, as in:
When (conditions), then
Spawn actor (actor1) at rotation 0
Spawn actor (actor1) at rotation 15
Spawn actor (actor1) at rotation -15
However, now it looks like
When (conditions), then
Change attribute (game.spawnCounter) to (game.spawnCounter+1)%game.numberSpawned
Change attribute (game.spawnCounter) to (game.spawnCounter+1)%game.numberSpawned
Change attribute (game.spawnCounter) to (game.spawnCounter+1)%game.numberSpawned
The problem is when stacked like this, I only end up spawning the third actor. I guess the engine isn't in the state where only 1 is added long enough for the actor to see it's its time to shine. I want to get this working (where 3 would be spawned or moved simultaneously) without using timers. Is this possible?
Thanks in advance.
Comments
I heard the i4S has more ram then an xbox 360.
I already know this game will be more or less a "bullet hell" sort of game, and want to code smart from the beginning, rather than having to go back in and salvage it when the memory bogs down. I test on an iPhone 4S and an iPad 2, but I've also seen how poorly those types of games can run on 3GS's, which are still under support.