private void action(int action) { mCubicStartAniSprite.setVisible(false); mCubicStartAniSprite.stopAnimation(0); switch (action) { case ACTION_TURN_LEVEL_1: case ACTION_TURN_LEVEL_2: case ACTION_TURN_LEVEL_3: ACTION = action; final Body body = (Body) this.getUserData(); final Vector2 vector2 = Vector2Pool.obtain(body.getPosition()); int frame[] = new int[] {0, 1}; body.setAngularDamping(1.2f); vector2.x = vector2.x / 3; vector2.y = vector2.y / 3; if (action == ACTION_TURN_LEVEL_2) { frame = new int[] {2, 3}; body.setAngularDamping(2.2f); vector2.x = vector2.x / 2; vector2.y = vector2.y / 2; } else if (action == ACTION_TURN_LEVEL_3) { frame = new int[] {4, 5}; body.setAngularDamping(3.2f); } Vol3Osyougatsu.OGG_A3_A_5_KOMATEI.play(); mCubicTurnAniSprite.animate(new long[] {250, 250}, frame, -1); mCubicTurnAniSprite.setVisible(true); body.setActive(true); Log.i(TAG, "body.getPosition " + vector2); vector2.x = random(vector2.x) + new Random().nextFloat(); vector2.y = random(vector2.y) + new Random().nextFloat(); body.setLinearVelocity(vector2); Log.i(TAG, "body.getPosition change " + vector2); this.unregisterUpdateHandler(timerHandler); this.registerUpdateHandler( timerHandler = new TimerHandler( 6f, new ITimerCallback() { @Override public void onTimePassed(TimerHandler timerHandler) { // Stop Turn stopTurn(); } })); break; } }
@Override public void dispose() { body.setActive(false); body.setAwake(false); Iterator<Joint> joints = world.getJoints(); while (joints.hasNext()) { Joint joint = joints.next(); if (joint.getBodyA() == body || joint.getBodyB() == body) { world.destroyJoint(joint); } } world.destroyBody(body); body = null; }
private static void cleanRemovableBodies() { ///// WORLD Step////////CleanStuff// if (removableBodies.size > 0) { boolean clearRemovable = false; for (Body body : removableBodies) { body.setActive( false); // Body wont be active while it waits deletion; This must happen outside the // Step process; if (!WORLD.isLocked()) { WORLD.destroyBody(body); clearRemovable = true; } } if (clearRemovable) { removableBodies.clear(); // collisionPairsDictionary.clear(); } } ///// WORLD Step////////CleanStuff// }
public Level21() { setBackground(new Background(0, 0, 0)); setOnSceneTouchListener(this); activity = World1Activity.getSharedInstance(); Camera mCamera = activity.mCamera; Level1.mPhysicsWorld = new PhysicsWorld(new Vector2(0, SensorManager.GRAVITY_EARTH), false); mPhysicsWorld = Level1.mPhysicsWorld; Sprite bg = new Sprite(0, 0, activity.menuBgTexture6, activity.getVertexBufferObjectManager()); setBackground(new SpriteBackground(bg)); // activity.gameToast("The bugs have morphed and can travel through lines"); // PhysicsWorld bPhysicsWorld = new PhysicsWorld(new Vector2(0, // SensorManager.GRAVITY_THE_ISLAND), false); final VertexBufferObjectManager vertexBufferObjectManager = activity.getVertexBufferObjectManager(); final Rectangle ground = new Rectangle(0, mCamera.getHeight() - 2, mCamera.getWidth(), 2, vertexBufferObjectManager); final Rectangle roof = new Rectangle(0, 0, mCamera.getWidth(), 2, vertexBufferObjectManager); final Rectangle left = new Rectangle(0, 0, 2, mCamera.getHeight(), vertexBufferObjectManager); final Rectangle right = new Rectangle(mCamera.getWidth() - 2, 0, 2, mCamera.getHeight(), vertexBufferObjectManager); final Rectangle reset = new Rectangle(0, 0, 200, 20, vertexBufferObjectManager); ground.setColor(0, 255, 255); // right.setColor(Color.RED); // final FixtureDef wallFixtureDef = PhysicsFactory.createFixtureDef(0, 0.5f, 0.5f, false, // CATEGORYBIT_WALL, MASKBITS_WALL, (short)0); Body Ground = PhysicsFactory.createBoxBody(mPhysicsWorld, ground, BodyType.StaticBody, WALL_FIXTURE_DEF); Body Roof = PhysicsFactory.createBoxBody(mPhysicsWorld, roof, BodyType.StaticBody, WALL_FIXTURE_DEF); Body Left = PhysicsFactory.createBoxBody(mPhysicsWorld, left, BodyType.StaticBody, WALL_FIXTURE_DEF); Body Right = PhysicsFactory.createBoxBody(mPhysicsWorld, right, BodyType.StaticBody, WALL_FIXTURE_DEF); Body Reset = PhysicsFactory.createBoxBody(mPhysicsWorld, reset, BodyType.StaticBody, WALL_FIXTURE_DEF); Ground.setUserData("ground"); Roof.setUserData("roof"); Left.setUserData("left"); Right.setUserData("right"); Reset.setUserData("tw"); attachChild(ground); attachChild(roof); attachChild(left); attachChild(right); Rectangle help = new Rectangle(50, 220, 250, 10, vertexBufferObjectManager); Body Help = PhysicsFactory.createBoxBody(mPhysicsWorld, help, BodyType.StaticBody, WALL_FIXTURE_DEF); final Rectangle help2 = new Rectangle(0, 220, 50, 10, vertexBufferObjectManager); final Body Help2 = PhysicsFactory.createBoxBody(mPhysicsWorld, help2, BodyType.StaticBody, WALL_FIXTURE_DEF); Help2.setUserData("help"); help2.setColor(Color.WHITE); attachChild(help2); Rectangle block = new Rectangle(180, 220, 250, 10, vertexBufferObjectManager); block.setRotation(90); Body Block = PhysicsFactory.createBoxBody(mPhysicsWorld, block, BodyType.StaticBody, WALL_FIXTURE_DEF); Block.setUserData("block"); Help.setUserData("help"); block.setColor(Color.WHITE); help.setColor(Color.WHITE); attachChild(help); attachChild(block); // final FixtureDef objectFixtureDef2 = PhysicsFactory.createFixtureDef(10, 0.2f, 0.5f,false, // CATEGORYBIT_WALL, MASKBITS_WALL, (short)0); final Text elapsedText = new Text( 600, 10, activity.mFont3, "Score:0123456789", activity.getVertexBufferObjectManager()); registerUpdateHandler( new TimerHandler( 1 / 10f, true, new ITimerCallback() { @Override public void onTimePassed(final TimerHandler pTimerHandler) { if (score > 2501) { score = (score - Math.round(activity.mCurrentScene.getSecondsElapsedTotal())); elapsedText.setText("Score:" + score); } else { score = 2500; elapsedText.setText("Score:" + score); } } })); attachChild(elapsedText); final DelayModifier dMod = new DelayModifier( 2, new IEntityModifierListener() { @Override public void onModifierStarted(IModifier arg0, IEntity arg1) {} public void onModifierFinished(IModifier arg0, IEntity arg1) { destroy(0); } }); final Rectangle bL = new Rectangle(150, 365, 50, 20, vertexBufferObjectManager); final Rectangle bB = new Rectangle(125, 355, 50, 10, vertexBufferObjectManager); final Rectangle bR = new Rectangle(175, 355, 50, 10, vertexBufferObjectManager); final Rectangle finish = new Rectangle(150, 360, 50, 20, vertexBufferObjectManager); bR.setRotation(90); bB.setRotation(90); one = new Rectangle(765, 290, 25, 35, vertexBufferObjectManager); two = new Rectangle(765, 330, 25, 35, vertexBufferObjectManager); three = new Rectangle(765, 370, 25, 35, vertexBufferObjectManager); four = new Rectangle(765, 410, 25, 35, vertexBufferObjectManager); five = new Rectangle(765, 450, 25, 35, vertexBufferObjectManager); one.setColor(Color.GREEN); two.setColor(Color.GREEN); three.setColor(Color.YELLOW); four.setColor(Color.YELLOW); five.setColor(Color.RED); attachChild(one); attachChild(two); attachChild(three); attachChild(four); attachChild(five); Rectangle laser = new Rectangle(350, 200, 20, 20, vertexBufferObjectManager); laser.setColor(Color.RED); attachChild(laser); final Line lase = new Line(350, 205, 805, 200, 5, vertexBufferObjectManager); final Body Lase = PhysicsFactory.createLineBody(mPhysicsWorld, lase, WALL_FIXTURE_DEF); Lase.setUserData("laser"); lase.setColor(Color.RED); lase.setVisible(false); Lase.setActive(false); attachChild(lase); registerUpdateHandler( new IUpdateHandler() { @Override public void onUpdate(float pSecondsElapsed) { x = x + 1; if (x == 50) { lase.setVisible(true); Lase.setActive(true); } else if (x == 100) { lase.setVisible(false); Lase.setActive(false); x = 0; } } @Override public void reset() { // TODO Auto-generated method stub } }); final Rectangle powerup = new Rectangle(665, 050, 15, 15, vertexBufferObjectManager); powerup.setColor(Color.RED); final Body power = PhysicsFactory.createBoxBody(mPhysicsWorld, powerup, BodyType.StaticBody, WALL_FIXTURE_DEF); powerup.setVisible(true); power.setActive(true); Body bod = PhysicsFactory.createBoxBody(mPhysicsWorld, bL, BodyType.StaticBody, WALL_FIXTURE_DEF); Body lbod = PhysicsFactory.createBoxBody(mPhysicsWorld, bR, BodyType.StaticBody, WALL_FIXTURE_DEF); Body rbod = PhysicsFactory.createBoxBody(mPhysicsWorld, bB, BodyType.StaticBody, WALL_FIXTURE_DEF); Body Finish = PhysicsFactory.createBoxBody( mPhysicsWorld, finish, BodyType.StaticBody, CIRCLE_FIXTURE_DEF); // Rectangle help = new Rectangle(0, 220, 300, 10, vertexBufferObjectManager); // Body Help = PhysicsFactory.createBoxBody(mPhysicsWorld, help, BodyType.StaticBody, // wallFixtureDef); // Rectangle block = new Rectangle(180, 220, 250, 10, vertexBufferObjectManager); // block.setRotation(90); // Body Block = PhysicsFactory.createBoxBody(mPhysicsWorld, block, BodyType.StaticBody, // wallFixtureDef); // Block.setUserData("block"); bod.setUserData("body"); rbod.setUserData("body"); lbod.setUserData("body"); Finish.setUserData("finish"); power.setUserData("power"); // Help.setUserData("Help"); bL.setColor(Color.WHITE); // block.setColor(255, 0, 0); bR.setColor(Color.WHITE); bB.setColor(Color.WHITE); // help.setColor(255, 0, 0); finish.setColor(0, 0, 1); finish.setVisible(false); // attachChild(block); attachChild(bL); attachChild(bR); attachChild(bB); // attachChild(help); attachChild(finish); attachChild(powerup); // centerText = new Text(320, 40, activity.mFont, "IMPORTANT!!! Keep an eye \n out for powerups // \n to help you through \n the level \n (touch anywhere to make \n this message dissapear)", // new TextOptions(HorizontalAlign.CENTER), vertexBufferObjectManager); // attachChild(centerText); // final ButtonSprite button = new ButtonSprite(5, 5, activity.mMenuResetTextureRegion, // vertexBufferObjectManager); // attachChild(button); final int blue = activity.faceSelected(1); if (blue == 1) face = new AnimatedSprite(05, 150, activity.redFace, activity.getVertexBufferObjectManager()); else if (blue == 2) face = new AnimatedSprite(05, 150, activity.blueFace, activity.getVertexBufferObjectManager()); else if (blue == 3) face = new AnimatedSprite(05, 150, activity.yellowFace, activity.getVertexBufferObjectManager()); else if (blue == 4) face = new AnimatedSprite(05, 150, activity.hairFace, activity.getVertexBufferObjectManager()); else if (blue == 5) face = new AnimatedSprite(05, 150, activity.djFace, activity.getVertexBufferObjectManager()); else if (blue == 6) face = new AnimatedSprite(05, 150, activity.jetFace, activity.getVertexBufferObjectManager()); else if (blue == 7) face = new AnimatedSprite(05, 150, activity.slowFace, activity.getVertexBufferObjectManager()); else if (blue == 8) face = new AnimatedSprite(05, 150, activity.fastFace, activity.getVertexBufferObjectManager()); else face = new AnimatedSprite(05, 150, activity.redFace, activity.getVertexBufferObjectManager()); body = PhysicsFactory.createCircleBody( mPhysicsWorld, face, BodyType.DynamicBody, FACE_FIXTURE_DEF); body.setUserData("face"); face.animate(200); attachChild(face); mPhysicsWorld.registerPhysicsConnector(new PhysicsConnector(face, body, true, true)); registerUpdateHandler(mPhysicsWorld); Random r = new Random(); int i = r.nextInt(4 - 1) + 1; if (i == 1) { enemy = new Sprite(400, 200, activity.bug2, activity.getVertexBufferObjectManager()); enemy2 = new Sprite(400, 200, activity.bug3, activity.getVertexBufferObjectManager()); enemy3 = new Sprite(400, 200, activity.bug1, activity.getVertexBufferObjectManager()); } else if (i == 2) { enemy = new Sprite(400, 200, activity.bug2, activity.getVertexBufferObjectManager()); enemy2 = new Sprite(400, 200, activity.bug1, activity.getVertexBufferObjectManager()); enemy3 = new Sprite(400, 200, activity.bug2, activity.getVertexBufferObjectManager()); } else if (i == 3) { enemy = new Sprite(400, 200, activity.bug3, activity.getVertexBufferObjectManager()); enemy2 = new Sprite(400, 200, activity.bug2, activity.getVertexBufferObjectManager()); enemy3 = new Sprite(400, 200, activity.bug3, activity.getVertexBufferObjectManager()); } else enemy = new Sprite(400, 200, activity.bug1, activity.getVertexBufferObjectManager()); enemy2 = new Sprite(400, 200, activity.bug2, activity.getVertexBufferObjectManager()); enemy3 = new Sprite(400, 200, activity.bug3, activity.getVertexBufferObjectManager()); // final Rectangle enemy = new Rectangle(600,400, 15, 15, // activity.getVertexBufferObjectManager()); Enemy = PhysicsFactory.createBoxBody( mPhysicsWorld, enemy, BodyType.DynamicBody, CIRCLE_FIXTURE_DEF); Enemy.setUserData("enemy"); attachChild(enemy); mPhysicsWorld.registerPhysicsConnector(new PhysicsConnector(enemy, Enemy, true, true)); // final Rectangle enemy2 = new Rectangle(500,400, 15, 15, // activity.getVertexBufferObjectManager()); Enemy2 = PhysicsFactory.createBoxBody( mPhysicsWorld, enemy2, BodyType.DynamicBody, CIRCLE_FIXTURE_DEF); Enemy2.setUserData("enemy"); attachChild(enemy2); mPhysicsWorld.registerPhysicsConnector(new PhysicsConnector(enemy2, Enemy2, true, true)); // final Rectangle enemy3 = new Rectangle(400,400, 15, 15, // activity.getVertexBufferObjectManager()); Enemy3 = PhysicsFactory.createBoxBody( mPhysicsWorld, enemy3, BodyType.DynamicBody, CIRCLE_FIXTURE_DEF); Enemy3.setUserData("enemy"); attachChild(enemy3); mPhysicsWorld.registerPhysicsConnector(new PhysicsConnector(enemy3, Enemy3, true, true)); // Enemy.setLinearVelocity(10, -10); /*final AnimatedSprite windArea = new AnimatedSprite(200, 0, 50, 500, activity.mBoxFaceTextureRegion, activity.getVertexBufferObjectManager()) { @Override protected void onManagedUpdate(float pSecondsElapsed) { if (face.collidesWith(this)) { body.applyLinearImpulse(new Vector2(0, -10f), body.getWorldCenter()); } }; }; // windArea.setVisible(false); attachChild(windArea); */ Rectangle pauseBtn = new Rectangle(10, 10, 100, 100, activity.getVertexBufferObjectManager()) { @Override public boolean onAreaTouched( TouchEvent pSceneTouchEvent, float pTouchAreaLocalX, float pTouchAreaLocalY) { if (pSceneTouchEvent.getAction() == MotionEvent.ACTION_UP) { Scene menu = (activity.createMenuScene()); activity.menu = 21; setChildScene(menu, false, true, true); } return true; } }; pauseBtn.setVisible(false); // pauseBtn.setColor(0,0,1); attachChild(pauseBtn); registerTouchArea(pauseBtn); final Text resetText = new Text( 10, 10, activity.mFont3, "Pause", new TextOptions(HorizontalAlign.CENTER), vertexBufferObjectManager); attachChild(resetText); mPhysicsWorld.setContactListener( new ContactListener() { @Override public void beginContact(final Contact contact) { final Fixture A = contact.getFixtureA(); final Fixture B = contact.getFixtureB(); final Body bodyA = A.getBody(); final Body bodyB = B.getBody(); String abe = bodyA.getUserData().toString(); String be = bodyB.getUserData().toString(); if (abe == "left" || be == "left") { Enemy.applyLinearImpulse(new Vector2(1, 0.5f), body.getWorldCenter()); Enemy2.applyLinearImpulse(new Vector2(1, 0.5f), body.getWorldCenter()); Enemy3.applyLinearImpulse(new Vector2(1, 0.5f), body.getWorldCenter()); } else if (abe == "power" && be != "enemy") { l = -5; activity.gameToast("Nice super shield active. Resetting line...."); linesDrawn = 0; rectangle(linesDrawn); powerup.setVisible(false); power.setActive(false); help2.setVisible(false); Help2.setActive(false); } if (abe == "finish" && be == "face") { bB.setColor(0, 0, 1); bL.setColor(0, 0, 1); bR.setColor(0, 0, 1); // lase.setVisible(false); // Lase.setActive(false); // x = 500; registerEntityModifier(dMod); } if (abe == "laser" && be == "face") { if (l >= 0) { l = l + 1; activity.gameToast("Shield only blocks one laser hit-Hit #" + l); if (l == 2) destroy(1); } else if (l < 0) { activity.gameToast("Super Shield active"); l = l + 1; } } else if (abe == "roof" || be == "roof") { Enemy.applyLinearImpulse(new Vector2(0.5f, 1f), body.getWorldCenter()); Enemy2.applyLinearImpulse(new Vector2(0.5f, 1f), body.getWorldCenter()); Enemy3.applyLinearImpulse(new Vector2(0.5f, 1f), body.getWorldCenter()); } else if (abe == "right" || be == "right") { Enemy.applyLinearImpulse(new Vector2(-1, 0.5f), body.getWorldCenter()); Enemy2.applyLinearImpulse(new Vector2(-1, 0.5f), body.getWorldCenter()); Enemy3.applyLinearImpulse(new Vector2(-1, 0.5f), body.getWorldCenter()); } else if (abe == "ground" || be == "ground") { Enemy.applyLinearImpulse(new Vector2(0.5f, -2f), body.getWorldCenter()); Enemy2.applyLinearImpulse(new Vector2(0.5f, -2f), body.getWorldCenter()); Enemy3.applyLinearImpulse(new Vector2(0.5f, -2f), body.getWorldCenter()); } else if (abe == "enemy" && be == "face") { if (l >= 0) { l = l + 1; activity.gameToast("Hit #" + l); if (l == 3) destroy(1); } else if (l < 0) { if (dead == 0) { enemy.setVisible(false); Enemy.setActive(false); dead = dead + 1; l = l + 1; activity.gameToast("Enemy eleminated"); } else if (dead == 1) { enemy2.setVisible(false); Enemy2.setActive(false); l = l + 1; dead = dead + 1; activity.gameToast("Enemy 2 eleminated"); } else if (l == -3) { enemy3.setVisible(false); Enemy3.setActive(false); l = l + 1; dead = dead + 1; activity.gameToast("Enemy 3 eleminated"); } else { l = l + 1; } } } } @Override public void endContact(final Contact pContact) {} @Override public void preSolve(Contact contact, Manifold oldManifold) {} @Override public void postSolve(Contact contact, ContactImpulse impulse) {} }); }
@Override public void setActive(boolean a) { active = a; body.setActive(active); }
protected void drawScene() { Log.i(TAG, "----------drawScene------------------------------"); this.mPhysicsWorld = new PhysicsWorld(new Vector2(0, 0), false); this.registerUpdateHandler(mPhysicsWorld); this.mPhysicsWorld.setContactListener(contactListener); final Sprite spriteBackGround = new Sprite( 960 / 2 - mBackGroundTextureRegion.getWidth() / 2, 0, mBackGroundTextureRegion, mVertexBufferObjectManager); this.attachChild(spriteBackGround); for (int i = 0; i < mTabSprite.length; i++) { mTabSprite[i] = new Sprite( 960 / 2 - 1150 / 2, 89.5f, tpTab[i].getTexturePackTextureRegionLibrary().get(0), mVertexBufferObjectManager); this.attachChild(mTabSprite[i]); mTabSprite[i].setVisible(false); } mTabSprite[0].setVisible(true); final Body body = this.physicsEditorShapeLibrary.createBody( "a3_5_1_iphone_dai", mTabSprite[0], this.mPhysicsWorld); this.mPhysicsWorld.registerPhysicsConnector( new PhysicsConnector(mTabSprite[0], body, true, true)); mTabSprite[0].setUserData(body); // Cubic Choose mCubicChooseSpite[CUBIC_YELLOW] = new Sprite( 279, 70, tpOne .getTexturePackTextureRegionLibrary() .get(Vol3OsyougatsuResource.packer_parta_1.A3_6_4_IPHONE_KOMA_ID), mVertexBufferObjectManager); this.attachChild(mCubicChooseSpite[CUBIC_YELLOW]); mCubicChooseSpite[CUBIC_GREEN] = new Sprite( 200, 90f, tpOne .getTexturePackTextureRegionLibrary() .get(Vol3OsyougatsuResource.packer_parta_1.A3_6_3_IPHONE_KOMA_ID), mVertexBufferObjectManager); this.attachChild(mCubicChooseSpite[CUBIC_GREEN]); mCubicChooseSpite[CUBIC_BLUE] = new Sprite( 110, 107, tpOne .getTexturePackTextureRegionLibrary() .get(Vol3OsyougatsuResource.packer_parta_1.A3_6_2_IPHONE_KOMA_ID), mVertexBufferObjectManager); this.attachChild(mCubicChooseSpite[CUBIC_BLUE]); mCubicChooseSpite[CUBIC_ORANGE] = new Sprite( 22f, 135, tpOne .getTexturePackTextureRegionLibrary() .get(Vol3OsyougatsuResource.packer_parta_1.A3_6_1_IPHONE_KOMA_ID), mVertexBufferObjectManager); this.attachChild(mCubicChooseSpite[CUBIC_ORANGE]); cubicTouch = new CubicTouch(0, 0, 960, 640, null); this.attachChild(cubicTouch); this.registerTouchArea(cubicTouch); for (int i = CUBIC_ORANGE; i <= CUBIC_YELLOW; i++) { final TextureRegion iOTextureRegion = new TextureRegion( bitmapTexture[i % 2], 2, 2, mCubicStartTiledTexture[i].getWidth(), mCubicStartTiledTexture[i].getHeight()); mCubicEntity[i] = new CubicEntity( 0, 100, i, mCubicStartTiledTexture[i], mCubicTurnTiledTexture[i], mCubicStopTiledTexture[i], mCubicTurnOptionTiledTexture, iOTextureRegion); this.attachChild(mCubicEntity[i]); mCubicEntity[i].setVisible(false); // Body final Body bodyCubic = this.physicsEditorShapeLibrary.createBody( CUBIC_BODYNAME[i], mCubicEntity[i], this.mPhysicsWorld); bodyCubic.setFixedRotation(true); bodyCubic.setActive(false); mCubicEntity[i].setUserData(bodyCubic); mPhysicsWorld.registerPhysicsConnector( new PhysicsConnector(mCubicEntity[i], bodyCubic, true, true)); } final SceneTouch sceneTouch = new SceneTouch(0, 0, 960, 640, null); this.attachChild(sceneTouch); this.registerTouchArea(sceneTouch); mSuzuAniSprite = new AnimatedSprite( 960 / 2 - mSuzuTiledTexTure.getWidth() / 2, -19, mSuzuTiledTexTure, mVertexBufferObjectManager); this.attachChild(mSuzuAniSprite); mShishiAniSprite = new AnimatedSprite(960, 59.5f, mShishiTiledTexTure, mVertexBufferObjectManager); this.attachChild(mShishiAniSprite); mShishiAniSprite.setVisible(false); mArrowSprite = new Sprite( 120, 133, tpThree .getTexturePackTextureRegionLibrary() .get(Vol3OsyougatsuResource.packer_parta_3.A3_8_1_IPHONE_YAJIRUSHI_ID), mVertexBufferObjectManager); this.attachChild(mArrowSprite); mArrowSprite.setVisible(false); }
private void removePhysics(final IShape pShape) { final Body body = (Body) pShape.getUserData(); body.setActive(false); }