@dcl/playground-assets 7.0.6-4137912823.commit-aa69b28 → 7.0.6-4138167187.commit-c9d306a

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.
package/dist/index.js CHANGED
@@ -13677,30 +13677,30 @@
13677
13677
  if (hasRequiredGset) return gset;
13678
13678
  hasRequiredGset = 1;
13679
13679
  Object.defineProperty(gset, "__esModule", { value: true });
13680
- gset.createGSet = void 0;
13680
+ gset.createVersionGSet = void 0;
13681
13681
  /**
13682
13682
  *
13683
13683
  * @returns a new GSet
13684
13684
  */
13685
- function createGSet() {
13685
+ function createVersionGSet() {
13686
13686
  const lastVersion = new Map();
13687
13687
  return {
13688
13688
  /**
13689
13689
  *
13690
- * @param n
13691
- * @param v
13690
+ * @param number
13691
+ * @param version
13692
13692
  * @returns
13693
13693
  */
13694
- addTo(n, v) {
13695
- if (v < 0) {
13694
+ addTo(number, version) {
13695
+ if (version < 0) {
13696
13696
  return false;
13697
13697
  }
13698
- const currentValue = lastVersion.get(n);
13698
+ const currentValue = lastVersion.get(number);
13699
13699
  // If the version is >=, it means the value it's already in the set
13700
- if (currentValue !== undefined && currentValue >= v) {
13700
+ if (currentValue !== undefined && currentValue >= version) {
13701
13701
  return true;
13702
13702
  }
13703
- lastVersion.set(n, v);
13703
+ lastVersion.set(number, version);
13704
13704
  return true;
13705
13705
  },
13706
13706
  /**
@@ -13738,7 +13738,7 @@
13738
13738
  }
13739
13739
  };
13740
13740
  }
13741
- gset.createGSet = createGSet;
13741
+ gset.createVersionGSet = createVersionGSet;
13742
13742
 
13743
13743
  return gset;
13744
13744
  }
@@ -13909,7 +13909,7 @@
13909
13909
  */
13910
13910
  const state = {
13911
13911
  components: new Map(),
13912
- deletedEntities: (0, gset_1.createGSet)()
13912
+ deletedEntities: (0, gset_1.createVersionGSet)()
13913
13913
  };
13914
13914
  /**
13915
13915
  * We should call this fn in order to update the state
@@ -14128,7 +14128,7 @@
14128
14128
  let entityCounter = RESERVED_STATIC_ENTITIES;
14129
14129
  const usedEntities = new Set();
14130
14130
  let toRemoveEntities = [];
14131
- const removedEntities = gsetExports.createGSet();
14131
+ const removedEntities = gsetExports.createVersionGSet();
14132
14132
  function generateNewEntity() {
14133
14133
  if (entityCounter > MAX_ENTITY_NUMBER - 1) {
14134
14134
  throw new Error(`It fails trying to generate an entity out of range ${MAX_ENTITY_NUMBER}.`);
@@ -42220,7 +42220,7 @@
42220
42220
  }
42221
42221
  }
42222
42222
 
42223
- let subscribeFunction = async () => { };
42223
+ let subscribeFunction = async () => ({});
42224
42224
  function createSubscriber(eventName) {
42225
42225
  return () => {
42226
42226
  subscribeFunction({ eventId: eventName }).catch(console.error);