I'm currently investigating the possibilities to move Imperii to an applet and it works perfectly locally but when deploying on a remote server, the loading time increases a lot! And I don't mean the download time of the jar's itself but the loading of resources from the jars in the game.
I have successfully used applets with jme before without these huge loading times. So I am confused why I am getting them now.
The following is what I have located is slow when deployed:
Loading of particlessytems saved as .jme
Loading of geometry saved as .jme
An example from the log:
INFO: Model "City" loaded as resource stream in 457 mS. (locally)
INFO: Model "City" loaded as resource stream in 8900 mS. (remotely)
After loading, the game runs fine in normal speed.
So what might be wrong? Probably something with loading of jme files but is there anything I must be extra carefull when loading from jar's downloaded from servers?
I have tested both having resources in the same jar as the classes and separately.
And I have tested using both getResource and getAsResourceStream, and the second is a little faster but not much.
If you can specify classpath jars that are not located locally then you might be able to debug the slow loading times. As a crude fix to the issue, I would suggest reading the entire file, then wrap it as a ByteArrayInputStream and give it to the BinaryImporter.