minerender 2.1.0-alpha.123 → 2.1.0-alpha.124

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3966,11 +3966,14 @@ var init_UVMapper = __esm({
3966
3966
  });
3967
3967
  }
3968
3968
  static fillMissingTextureKeys(textures, target) {
3969
- for (let faceName of CUBE_FACES) {
3970
- let v = textures[faceName];
3971
- if (v && v.startsWith("#")) {
3972
- target[faceName] = target[v.substr(1)];
3969
+ for (const key in textures) {
3970
+ let name = key;
3971
+ const seen = /* @__PURE__ */ new Set();
3972
+ while (textures[name]?.startsWith("#") && !seen.has(name)) {
3973
+ seen.add(name);
3974
+ name = textures[name].substr(1);
3973
3975
  }
3976
+ if (name !== key) target[key] = target[name];
3974
3977
  }
3975
3978
  return target;
3976
3979
  }