How exactly does the touchscreen events in OpenGL ES games prevent Android? Also, if the game is 3D, how do you know that the user touched an object in the background? Thank you.
See the overlayed glossaurs view in the broken event E in your class. And the user should compare the Touch Event coordinates with the object coordinates to know the object touch. @ Override Public Boolean On Touch Event (Motion Adventure E) {Float X = EX (); Float y = eta yi (); Switch (e.getAction ()) {case MotionEvent.ACTION_MOVE: float dx = x - mPreviousX; Float DI = y - Muppires; MRenderer.mAngleX + = dx * TOUCH_SCALE_FACTOR; MRenderer.mAngleY + = dy * TOUCH_SCALE_FACTOR; RequestRender (); } MPreviousX = x; MPreviousY = y; Back true; }
Comments
Post a Comment