First Example Uploaded

3 views
Skip to first unread message

Clayton Lilly

unread,
Aug 6, 2009, 9:29:30 AM8/6/09
to Gamaray
I uploaded the source code for a very simple dynamic dimension called
Asteroids into the Files section. If you just want to try out the
compiled application, there's a link on the developers page you can
click from your G1. More examples will be coming soon.
Message has been deleted

Brooks Knight

unread,
Aug 10, 2009, 10:07:16 AM8/10/09
to Gamaray
Nice example! It ran a little slow on my G1 but that was fine.
Is there any way to animate the explosions?

You can improve the speed of your code by removing unnecessary method
calls.
For example,
out.println("<?xml version=\"1.0\" encoding=\"utf-8\"?>");
out.println("<dimension version=\"1.0\">");
out.println(" <name>Asteroids</name>");
out.println(" <relativeAltitude>false</relativeAltitude>");
|
All those out.println() take time. I removed all but one of the
out.println() and the code runs faster.
|
out.println("<?xml version=\"1.0\" encoding=\"utf-8\"?>" +
"\n <dimension version=\"1.0\">" +
"\n <name>Asteroids</name>" +
"\n <relativeAltitude>false</
relativeAltitude>");
Thanks,
Brooks

Clayton Lilly

unread,
Aug 10, 2009, 10:44:32 AM8/10/09
to Gamaray
What aspect of the application was slow, the response time of the
dimension or the rendering of the asteroids? Combining the println
calls is definitely a good optimization, but given the performance of
the server that the code is running on and the minimal load its under,
I'm not sure that would affect response time (if that was the slowness
you were speaking of).

Animations are very high on the TODO list, and its looking like they
won't be much trouble.

Brooks Knight

unread,
Aug 12, 2009, 9:07:26 AM8/12/09
to Gamaray
Both actually :( The response time was much slow than the asteroid
render time. When looking for an asteroid I would first see a blue
dot, after a second the asteroid would load. I am guessing this will
go away when I get a faster phone. I gave up on the response time, I
would press on an asteroid and move on, not waiting for it to change
to an explosion because it took to long. I do commend you for writing
GamaRay so that every press is registered!

I would hope that eventually the server would not be running under
minimal load :)
Glad to here animation is coming along. GamaRay will be a lot more
impressive with animation.
Reply all
Reply to author
Forward
0 new messages