Game lags

zNiiCzNiiC Member Posts: 74
edited April 2012 in Working with GS (Mac)
In my game, red balls spawn from the top right corner and move to the bottom left. After about 2 seconds of playing, everything gets really laggy, although there are only 15-20 balls on screen.

*After they go offscreen, they hit a wall and are destroyed*

How can I overcome this? Is there a better way to spawn them?

Answers

  • SAZ_1SAZ_1 Member Posts: 397
    do they spawn at the same time?? ... whats the size of the balls? anything else on the scene other then the ball and the wall that destroys them?
  • zNiiCzNiiC Member Posts: 74
    One spawns every 1.5 seconds while the other one spawns every 1.8 seconds. I made the balls 5x5 in photoshop along with GameSalad. The only other thing is a joystick and another ball you control with the joystick.
  • zNiiCzNiiC Member Posts: 74
    It even lags with about 5 actors in the scene.
  • UtopianGamesUtopianGames Member Posts: 5,692
    edited April 2012
    Sounds like the balls all have movable on have you tried to use interpolate and unchecking movable although it shouldn't lag tbh.

    Try using interpolate 0,0 change the time to whatever suits.

    Darren.
  • scitunesscitunes Member, Sous Chef Posts: 4,047
    laggy in the preview, viewer, adhoc, all...???

    If it is just in the gs creator preview and you have music in your game then it is just a creator bug and will not affect your final build at all.
  • zNiiCzNiiC Member Posts: 74
    I have I music, but I will try to uncheck moveable.
  • zNiiCzNiiC Member Posts: 74
    I have no music*
  • zNiiCzNiiC Member Posts: 74
    I found out that every 0.1 seconds it would randomly spawn an actor, so that would cause it to lag. Although it fixed it, it still lags occasionally for about .5 seconds.
  • App SurgeApp Surge Member Posts: 651
    The best way to test for lag/glitch issues is to create an Ad Hoc. Try doing that and see if it still lags.
  • slinky1988slinky1988 Member, PRO Posts: 89
    Maybe because you are spawning and destroying the actors? It might be better if you had the actors on the scene and made them recycle instead. And interpolate when you can!
Sign In or Register to comment.