idCache[index] = 0;
    public boolean removeTexture(Texture tex) {        if (!texture.contains(tex)) return false;                int index = texture.indexOf(tex);        if (index == numTexUnits-1) {            numTexUnits--;            return texture.remove(tex);        }                texture.set(index, null);        return true;    }