android - Gravity problem (When registerUpdateHandler?) -


i have problem gravity. make map of game add elements boxes, brick etc. using code:

private void addface2(final scene pscene, final float px, final float py, final int pwidth, final int pheight, final string ptype, final string gbodytype) {         final sprite face;         final body body2;         bodytype bodytype;          face = new sprite(px, py, pwidth, pheight, this.mboxtextureregion);          bodytype = bodytype.dynamicbody;          body2 = physicsfactory.createboxbody(this.mphysicsworld, face, bodytype, boxfixturedef);          pscene.attachchild(face);         this.mphysicsworld.registerphysicsconnector(new physicsconnector(face, body2, true, true));         boxy.add(face);  } 

everything "ok" elements bouncing!? think problem lies in this.mscene.registerupdatehandler(this.mphysicsworld);.

i want ask how stop bouncing not removing gravity?

http://s3.ifotos.pl/img/fail_hsrpxhe.png

sorry english, work on it..

check boxfixturedef , fixturedef whatever using ground.

new fixturedef(density,elasticity,friction)

/** friction coefficient, in range [0,1]. **/


Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

jQuery Ajax Render Fragments OR Whole Page -