socksocket
socksocket

Reputation: 4371

Fatal signal 11 (andengine project)

I'm creating and android game powered by andengine framework the box2d extension
I'm getting "Fatal Signal 11" which seems to happen out of nowhere (I guess you can call it randomly)

there no clues (at least, I don't aware to any clues to help me solve this problem)

my guesses are:
1) I'm creating game's entities using TimerTask class
2) maybe it has something to do with concurrency?

what do you think?
thanks,
socksocket

enter image description here

Upvotes: 0

Views: 1373

Answers (3)

Jyo Huang
Jyo Huang

Reputation: 11

it says touchEvent...maybe you set your density value of your FixtureDef too high.... try to set the density value <=1000 like below:

FixtureDef wallFixtureDef = PhysicsFactory.createFixtureDef(1000, 0.0f, 1.0f);

Body mGoundBody=PhysicsFactory.createBoxBody(this.mPhysicsWorld, ground, BodyType.StaticBody, wallFixtureDef);

hope this information can help you...

Upvotes: 1

jmroyalty
jmroyalty

Reputation: 2527

You could still use a TimerTask, you just need to be sure to call anything relating to AndEngine (creating or deleting sprites, etc) on the AndEngine update thread - you can use

runOnUpdateThread(new Runnable() {
@Override
public void run() {
// TODO Auto-generated method stub
// do your stuff in here
}
});

Upvotes: 5

DefZep
DefZep

Reputation: 153

I had the same issue and fixed it by taking the TimerTask out of the equation.

Upvotes: 1

Related Questions