code: function render(gl, width, height, dt, batch, shader) {
      time+=dt
      
      //switching textures is free, and doesn't update any buffers
      if (time > 1000) {
          batch.texture = batch.texture === tex2 ? tex : tex2
          time = 0
      }
  
      //draw our static vertex data
      batch.bind(shader)
      batch.draw()
      batch.unbind()
  }
docs: When calling draw(), only the last set texture will be used for all quads. You will want to set an explicit count for the batch to ensure all sprites are rendered.