Tag: andengine

How to override onSetContentView while Using Ratio Resolution policy in Andengine Base game activity

I am developing (Learning to build 🙂 ) a game with andengine GLES2. I am using Base game activity , and i overrides the setContent view to place my admob ad.Every thing works fine except the resolution policy . Ratio Resolution policy is the one I am using along with CAMERA_WIDTH = 800; and CAMERA_HEIGHT […]

andengine compileReleaseNdk error

I want to use andengine in my android studio project but I have ndk error while building. Error:Execution failed for task ‘:andEngine:compileReleaseNdk’. > com.android.ide.common.internal.LoggedErrorException: Failed to run command: D:\Android\android-ndk-r9d\ndk-build.cmd NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=D:\Android\workspace\simpleclock\simple_clock_as\andEngine\build\intermediates\ndk\release\Android.mk APP_PLATFORM=android-19 NDK_OUT=D:\Android\workspace\simpleclock\simple_clock_as\andEngine\build\intermediates\ndk\release\obj NDK_LIBS_OUT=D:\Android\workspace\simpleclock\simple_clock_as\andEngine\build\intermediates\ndk\release\lib APP_ABI=all Error Code: 2 Output: D:/Android/android-ndk-r9d/toolchains/arm-linux-androideabi-4.6/prebuilt/windows-x86_64/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld.exe: D:\Android\workspace\simpleclock\simple_clock_as\andEngine\build\intermediates\ndk\release\obj/local/armeabi-v7a/objs/andengine_shared/D_\Android\workspace\simpleclock\simple_clock_as\andEngine\src\main\jni\src\GLES20Fix.o: in function Java_org_andengine_opengl_GLES20Fix_glVertexAttribPointer:GLES20Fix.c(.text.Java_org_andengine_opengl_GLES20Fix_glVertexAttribPointer+0x40): error: undefined reference to ‘glVertexAttribPointer’ D:/Android/android-ndk-r9d/toolchains/arm-linux-androideabi-4.6/prebuilt/windows-x86_64/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld.exe: D:\Android\workspace\simpleclock\simple_clock_as\andEngine\build\intermediates\ndk\release\obj/local/armeabi-v7a/objs/andengine_shared/D_\Android\workspace\simpleclock\simple_clock_as\andEngine\src\main\jni\src\GLES20Fix.o: in function Java_org_andengine_opengl_GLES20Fix_glDrawElements:GLES20Fix.c(.text.Java_org_andengine_opengl_GLES20Fix_glDrawElements+0x30): error: […]

Drawing a Circular Timer (AndEngine)

I’m using AndEngine, and within that framework, I’d like to make a circular timer graphic. Specifically, I’d like to display the wait period for reuse of an ability. The idea is to dynamically fill the arc as the timer progresses. Something like this: The java.awt.Graphics object has a fillArc() method that seems perfect for me. […]

Displaying Ad In AndEngine

I am trying to display an advertisement using Greystrip in AndEngine. I cannot figure out how this is done because it doesnt use a Layout to inflate views, but yet sprites. i use BaseGameActivity to create my application for each scene i would like to display adds on. In GreyStrip this is how they tell […]

body.setTransform does not work inside contact listener (andEngine and box2d)

I’m trying to move player body while contact with teleport but setTransform isn’t executed.This is my contact listener mPhysicsWorld.setContactListener(new ContactListener() { @Override public void beginContact(Contact contact) { final Fixture fixtureA = contact.getFixtureA(); final Body bodyA = fixtureA.getBody(); final Fixture fixtureB = contact.getFixtureB(); final Body bodyB = fixtureB.getBody(); if(bodyA.getUserData().equals(“Player”) || bodyB.getUserData().equals(“Player”) ) { for(int i = […]

What is maximum size of texture (Andengine)

What is maximum size of texture that should be used in andengine. I used this.diamondTexture = new Texture(2048, 512, TextureOptions.BILINEAR_PREMULTIPLYALPHA); When loading in device(HTC G1 T-Mobile) it shows blank screen. After reducing the image size and when replacing the above line with this this.diamondTexture = new Texture(1024, 512, TextureOptions.BILINEAR_PREMULTIPLYALPHA); Its running . Whats the problem […]

Switching from AndEngine to libgdx – what to know?

I’ve been testing with AndEngine for months, but still haven’t produced any game prototypes. There are few reasons why I want to switch to libgdx: – AndEngine is using libgdx’s INI wrapper for Box2d, but updates reach Andengine slowly – I’m primarily targeting Android, but having option for easy porting to other platforms could come […]

Cocos vs AndEngine for android

I want to make a game using Tiled Map Editor and I want to move the character around using a D-Pad for moving the character So I’m wondering which Engine would be better AndEngine or Cocos2d Keep in mind i’m a beginner at this so I’d like to stare at a lot of tutorials. 😀 […]

Pass additional data to fragment shader through VBO – DynamicSpriteBatch

I’m learning opengl shaders with AndEngine , my goal is to make DynamicSpriteBatch with some lightshader where light position will be passed throught vbo to each draw call in spritebatch so i can manipulate light source on every sprite. So i have created LightSpriteBatch ( with drawtype.dynamic ) public class LightSpriteBatch extends Shape { // […]

AndEngine RenderTexture Exception: GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT

I have developed an Android game which is played by many people. One user out of 100-200 faces an Exception that I cannot make any sense of. I use a RenderTexture which throws the following Exception when I try to initialize it: Fatal Exception: org.andengine.opengl.exception.RenderTextureInitializationException org.andengine.opengl.exception.GLFrameBufferException: GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT It works on 99% of all devices. The […]

Android Babe is a Google Android Fan, All about Android Phones, Android Wear, Android Dev and Android Games Apps and so on.