@Override public void render(GL10 gl) { if (frames == null) { frames = TextureManager.getTexture(resId); return; } if (alpha != 0) { if (!cutout.isGenerated()) cutout.generate(frames.getWidth(), frames.getHeight()); final float width = scale.x * cutout.frameWidth; final float height = scale.y * cutout.frameHeight; frames.prepare(gl, cutout.textureBuffers[currentFrame], GL10.GL_CLAMP_TO_EDGE); frames.draw(gl, pos.x, pos.y, width, height, rotation); } }