×

Discussion Board

Results 1 to 9 of 9

Thread: Loading Time

  1. #1
    Registered User
    Join Date
    May 2004
    Posts
    25

    Loading Time

    Hello everyone, I have some problems with my game, Hope that someone can help me. I have many variable to initialize at the beginning of my MIDlet(35 variable........with 20 array).Strange things always happen is when I load my game to 6600 and play it, it always exited to the main menu after 2 seconds. I already asked about that strange things to this forum and found some solutions.I try to give more time to load the image by make the startApp sleep time but it doesn't work I think. Anybody got suggestion to make that loading time. I don't know if the problem is because of I initialize large amount of sprite array(20) or maybe I put too many variables in the MAIN body.

    Thankss everyoneee

  2. #2
    Registered User
    Join Date
    Jul 2003
    Location
    Finland, Tampere
    Posts
    1,113
    Do you want not to enter menu until the game finished loading?

    Use any of the SpashScreen examples. There's a number of them on the web and on the Sun's site.

    Personally I prefer showing Splash Canvas, then I start loading images, updating progress indicator after each file is loaded. When loading is finished, I change displayables to show menu

  3. #3
    Registered User
    Join Date
    May 2004
    Posts
    25
    I'm currently trying that and still in deployment. Does massive amount of variables upon initialization also affect this problem(always going back to main menu)??

  4. #4
    Registered User
    Join Date
    Jul 2003
    Location
    Finland, Tampere
    Posts
    1,113
    There is no "automatic" going to the main menu. MIDlets can have no menu at all.
    It is you, who commands the phone to show this or that particular screen

  5. #5
    Registered User
    Join Date
    May 2004
    Posts
    25
    woops sorry hahahaha. I mean Main Menu in the mobile phones(The Selection Menu),not the one after MidLet executed.So the work is if we press the game Icon in the Phone Menu, it will initialize the MIDlet.Inside the MIDlet there's variable.So for now I'm already succeded in doing that by putting Thread.sleep after I create the loading Form,but before creating the loading Form, I initialize all the picture.The question is, how about the variables(eg:int,Sprite sprite,LayerManager manager)? I have a lot of them.Its never crash again tough, but will there be a possibilty to crash the games at initialization because of it has too much variable(not Images).Thanks for your answer before.I really appreciate your help.I'm still a newbie here, around 3 weeks from zero hahahaha.

  6. #6
    Registered User
    Join Date
    Jul 2003
    Location
    Finland, Tampere
    Posts
    1,113
    Do you mean that when you start your MIDlet, after 2 secs of loading it is closed and you go back to the Symbian?

    This looks like a bug. Probably you unintentionally close your MIDlet yourself.

  7. #7
    Registered User
    Join Date
    May 2004
    Posts
    25
    yeppp,correct!! its like that.I think to initialize the MIDlet, the phone will take time as many as necessary.But on the other hand, There're maybe some limitation on how big the cellphone can initialize.

    Thanks

    Dark

  8. #8
    Super Contributor
    Join Date
    Mar 2003
    Location
    Israel
    Posts
    2,280
    I can't say I ever noticed this behaviour on a Series 60 device.
    But I had a very similar problem with an SE T610. If the startup time was too long the MIDlet would just close itself. It seems that you need to put something on screen as soon as you can or the MIDlet would crap out. It got solved when I added a "Loading" screen at the beginning, and started loading resources only after that.

    shmoove

  9. #9
    Regular Contributor
    Join Date
    May 2004
    Posts
    61
    yes, the loading course is a good solution for the load problem, when i developed the games, i always give the load time about 2 second , the wait the first level source was loaded. then the game start!

Posting Permissions

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