public void onLoad(GL10 gl, QuickTiGame2dGameView view) { if (loaded) return; this.view = view; // load particle setting from Particle Designer XML loadParticleXML(); if (gzipBase64Data != null && gzipBase64Data.length() > 0) { view.loadTexture(gl, image, gzipBase64Data); gzipBase64Data = ""; } QuickTiGame2dTexture aTexture = view.getTextureFromCache(image); // if texture is not yet cached, try to load texture here if (aTexture == null && image != null) { view.loadTexture(gl, image); aTexture = view.getTextureFromCache(image); } if (aTexture != null) { hasTexture = true; if (width == 0) width = aTexture.getWidth(); if (height == 0) height = aTexture.getHeight(); } createTextureBuffer(gl); createQuadBuffer(gl); if (hasTexture && !aTexture.isSnapshot()) view.onLoadSprite(this); if (debug) GLHelper.checkError(gl); loaded = true; }