×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    Dec 2011
    Posts
    7

    Mobile Game Lags after few seconds

    www.megaupload.com/?d=1T7OI8XJ

    Please see attached link.
    IDE : Netbeans 7.01
    Third Party API : marge 0.5 (included inside)
    Platform : Nokia 5730XM

    Good Day, I kindly need your help, I'm currently developing a game for my school project. After running the GameCanvas, the game slowly lags. When I'm running it in emulator (WTK 3.0) everything is fine, after a while it starts to lag very hard, I don't know what is the problem cause I can't find any source on the net to compare with.

    Hope you can help me solve it cause I'm having hard time finding out what is causing the lag. Thanks for your help.

  2. #2
    Nokia Developer Moderator
    Join Date
    Dec 2011
    Posts
    174

    Re: Mobile Game Lags after few seconds

    Hi balubad,

    and welcome to Nokia Developer Discussion Boards!

    In your updateScore() you insert a lot of layers and that is one of the reason the game starts to lag. Use layer.getSize() to track if there are some other layers that are slowing the game down.

    -tiviinik

  3. #3
    Registered User
    Join Date
    Dec 2011
    Posts
    7

    Re: Mobile Game Lags after few seconds

    Quote Originally Posted by tiviinik View Post
    Hi balubad,

    and welcome to Nokia Developer Discussion Boards!

    In your updateScore() you insert a lot of layers and that is one of the reason the game starts to lag. Use layer.getSize() to track if there are some other layers that are slowing the game down.

    -tiviinik

    Thanks Dude, it solved my problem , it only keep on adding up new sprites. I saw the problem in the first conditional statement of my update Score that is why after some few seconds it starts to lag cause there's more than 4k elements in the layer. Now it doesn't reach 30 elements. Thanks again. =)

Similar Threads

  1. Key repeats (possibly caused by network lags)
    By atleta in forum Feedback - Nokia Developer Services & Infrastructure
    Replies: 1
    Last Post: 2009-12-29, 17:16
  2. How to send information to the server from mobile for every 10 seconds automatically
    By chatrapati.nokia.santhosh in forum Mobile Java General
    Replies: 12
    Last Post: 2009-10-15, 08:49
  3. Show baloon for 5 seconds, disapear for 3 seconds, apear again in 5 seconds
    By RAiNMAKER in forum [Archived] Flash Lite on Nokia Devices
    Replies: 3
    Last Post: 2008-10-14, 07:00
  4. Replies: 3
    Last Post: 2008-05-05, 20:42
  5. Mobile Game
    By law1603 in forum Mobile Java General
    Replies: 0
    Last Post: 2004-07-12, 06:29

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •