Android Game Release (Bugs)

@nuclycz said: LG Nitro HD (P930) with CM 10.1.3 (Android 4.2.2)

NullPointerException… Stack trace:

http://imgur.com/a/U9HZx

Where in the process of the game (or before) were you when this error happened? Was it after the start menus but before the game? Or while playing?

I’m starting to think this is unrelated to texture size. I am going to have to go through the AnimElement class and find out what id potentially different than the GUI library’s Element class. They both use the same shader and I have yet to find a device that won’t run the standard GUI components even using Effects… it runs without hitch on every Android device I have tried it on.

The AnimElement is used for TextElement text and as long as it is created and remains static, I’ve been able to get this to run fine on all devices as well.

It has to be related to the buffer update process in the AnimElement’s mesh.

/sigh… I bet I have overlooked the issue a good 1000 times by now which just means it’s going to take me forever to spot it >.<

1 Like

And my conclusion is:

GUI Element Mesh uses put(index, value) for updating buffers

AnimElement Mesh uses .rewind() .put(val).put(val).put(val)

which is likely incurring a bunch of overhead that isn’t necessary and hopefully what is causing some of these Samsung devices to choke.

A rewind on potentially 4 different buffers and a position update for each put against each buffer being updated. As apposed to no rewind and no alteration to the position using put(index, val)

@nehon I think you are probably the most familiar with android dev. Could this difference be a potential cause for this?

@t0neg0d said: Where in the process of the game (or before) were you when this error happened? Was it after the start menus but before the game? Or while playing?

The screen goes black after clicking on “1 PLAYER” for a second and then this error pops out.

1 Like

I haven’t read through all pages, so this error might have been posted already, but I’m running on a Galaxy S4 active (Android 4.2.2) and get the error posted below right after ‘stage 1’ appears on the screen.

1 Like

In stack3d i use the BatchNode a lot. And it does a lot of these operations.
I didn’t test myself but I never had any crash report from those devices. I’ll try to test it at work (i can access different kinds of devices there, and there is a samsung note 2).
It should not be an issue… but it could… :stuck_out_tongue:

1 Like
@nehon said: In stack3d i use the BatchNode a lot. And it does a lot of these operations. I didn't test myself but I never had any crash report from those devices. I'll try to test it at work (i can access different kinds of devices there, and there is a samsung note 2). It should not be an issue..... but it could... :p

I updated the mesh to do this and put out another version. Still waiting for access to a note 2 to see if it was helpful or not.

on samsung galaxy s2, the game works until the first few seconds of gameplay.

i get an error: com.jme3.renderer.RendererException: an OpenGL error has occurred: invlaid operaiton at …

it only gives me the option to “kill” the app, theres no report button. I’m not sure how to copy and paste the error to give you the full error message.

edit: i looked back a few pages. the error message I got was the same as reveance’s error message that he posted a few posts before mine.

1 Like
@icamefromspace said: on samsung galaxy s2, the game works until the first few seconds of gameplay.

i get an error: com.jme3.renderer.RendererException: an OpenGL error has occurred: invlaid operaiton at …

it only gives me the option to “kill” the app, theres no report button. I’m not sure how to copy and paste the error to give you the full error message.

edit: i looked back a few pages. the error message I got was the same as reveance’s error message that he posted a few posts before mine.

Out of curiosity… is the version you downloaded 1.3?

@t0neg0d said: Out of curiosity... is the version you downloaded 1.3?

yes its version 1.3

1 Like

hey i updated to the version 1.3 too and have still the same out of memory exception at the application start on my samsung galaxy s3 mini

@Snowsun92 said: hey i updated to the version 1.3 too and have still the same out of memory exception at the application start on my samsung galaxy s3 mini

Ok… it’s not an issue with the buffer update then. My next guess is the use of Pool for display text. This would pre-allocate memory for the direct buffers for each in the pool.

Which I’m glad about, as I think put(index, val) is slower and would have lived with it if it worked. It’s fine for GUI components, as they stay static more than not, but the AnimElement is updating far to often to rely on this.

Hey all, I really appreciate all of the help I have gotten with this.

Just a heads up for some of the issues posted, as it has really helped in tracking down issues with the 2D framework!

Issue 1. The invalid operation problem has been resolved (will be in the update I am pushing out there now), I had missed something when applying the fix for alpha values of 0f and explains why the game was crashing when 1 Player (or 2, 3, 4) was being clicked. At that point I was fading in 3 gui controls and they were showing initially at an alpha value of 0… basically meaning I was ASKING Samsung devices to crash =)

Issue 2. The oom expection was/is a problem in my test game and preloading everything… and I mean EVERYTHING. I’m pushing out an update for this now which hopefully resolves this issue, however it won’t be available for a while. This one had me chasing ghosts for days >.< The good news is, I learned a few things about condensing down atlas images to utilize space as effectively as possible! I also tried a few ideas I may not have otherwise and learned a few new tricks for game dev.

Again, I can’t thank you all enough for taking the time to help me test this as I have extremely limited access to android devices and I am guessing at most of the potential fixes. I think I may have finally tracked down a Note 2 I can get for testing. All I could find were Note 3’s and I have no idea whether or not this device has the same problem as the Note 2 and other devices throwing the oom exception. But… since I know the Note 2 is semi-picky… I really want one of these specifically.

Once I am able to get this in working order with these devices, I’ll post a thread about my finding so others can avoid some of the mistakes I ran into with these exceptions, what was causing them and what fixed them specifically.

I’ll also be zipping up this project and making the source code available at that point as well. Don’t want to do this until I know these issues are resolved (tested, etc)

@nehon said: In stack3d i use the BatchNode a lot. And it does a lot of these operations. I didn't test myself but I never had any crash report from those devices. I'll try to test it at work (i can access different kinds of devices there, and there is a samsung note 2). It should not be an issue..... but it could... :p

I ended up reverting the changes after testing them. It is noticeably slower on android and is really apparent when the buffers are being updated frequently. It works fine for the GUI components as they are only altered if they are resized. Thanks for this info… it was very helpful!

Quick update (been out all day)

Just checked version 1.4 on my note2 and its behaving the same way, crash right at the start - no graphics seen but music in the background. (OpenGL oom error same as before)

Again if I enable OpenGL traces to “call stack on glGetError” then the game runs fine.

–Radan.

1 Like
@radanz said: Quick update (been out all day)

Just checked version 1.4 on my note2 and its behaving the same way, crash right at the start - no graphics seen but music in the background. (OpenGL oom error same as before)

Again if I enable OpenGL traces to “call stack on glGetError” then the game runs fine.

–Radan.

Ok… I’m hoping to get a hold of a Note2 within a few weeks and start testing the library in stages to determine if this is the issue, or the game itself (which I’m thinking is the case still) is the issue. Unfortunately, I can’t test simple examples without irritating the living shit out of someone =)> So, I’m going to have to get a Note 3 see if it generates the same error and then trade it for someone’s Note 2, as I need one of the problem devices to test with.

If I can return the favor of testing anything… please feel free to ask me any time. I’m limited on Android devices (a couple tablets)… however, anything at all I can do… just ask.

hey @t0neg0d

i have tested the new 1.4 version. I have the same OpenGL oom error. I think the Note 2 and the Galaxy S3 mini has the same problems.

Hate to be a bother, but after figuring out what the issue with BitmapText and the oom error was, I updated the app and pushed out the fixed version of the game to the Google Play Store. I also fixed the weapons to scale the velocity based on dpi as well as a few other minor updates.

If anyone with a device that this failed for would be willing to give it another go and just let me know if the fixes worked, I’d really appreciate it!

No problem, I will test this for you.
Awaiting google’s publish…

:google:

1 Like

Great news, it now works flawlessly on my Galaxy Note 2.

=D

Well done. Nice base game to work with to test android/jME things.

I love it !!!

1 Like