| Reply | « Previous Thread | Next Thread » |
|
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 |
| darkermaster |
| View Public Profile |
| Find all posts by darkermaster |
|
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 |
|
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)??
|
| darkermaster |
| View Public Profile |
| Find all posts by darkermaster |
|
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 |
|
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.
|
| darkermaster |
| View Public Profile |
| Find all posts by darkermaster |
|
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. |
|
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 |
| darkermaster |
| View Public Profile |
| Find all posts by darkermaster |
|
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 |
|
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!
|
| Reply | « Previous Thread | Next Thread » |
| Thread Tools | Search this Thread |
|---|---|