@drincs/nqtr 0.1.6 → 0.1.8

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.
Files changed (92) hide show
  1. package/dist/classes/Activity.d.mts +4 -7
  2. package/dist/classes/Activity.d.ts +4 -7
  3. package/dist/classes/Activity.js +10 -2
  4. package/dist/classes/Activity.js.map +1 -1
  5. package/dist/classes/Activity.mjs +10 -2
  6. package/dist/classes/Activity.mjs.map +1 -1
  7. package/dist/classes/Commitment.d.mts +2 -4
  8. package/dist/classes/Commitment.d.ts +2 -4
  9. package/dist/classes/Commitment.js +5 -1
  10. package/dist/classes/Commitment.js.map +1 -1
  11. package/dist/classes/Commitment.mjs +5 -1
  12. package/dist/classes/Commitment.mjs.map +1 -1
  13. package/dist/classes/index.d.mts +1 -3
  14. package/dist/classes/index.d.ts +1 -3
  15. package/dist/classes/index.js +10 -2
  16. package/dist/classes/index.js.map +1 -1
  17. package/dist/classes/index.mjs +10 -2
  18. package/dist/classes/index.mjs.map +1 -1
  19. package/dist/classes/navigation/ActivityRoom.d.mts +1 -3
  20. package/dist/classes/navigation/ActivityRoom.d.ts +1 -3
  21. package/dist/classes/navigation/ActivityRoom.js +5 -1
  22. package/dist/classes/navigation/ActivityRoom.js.map +1 -1
  23. package/dist/classes/navigation/ActivityRoom.mjs +5 -1
  24. package/dist/classes/navigation/ActivityRoom.mjs.map +1 -1
  25. package/dist/classes/navigation/Location.d.mts +2 -4
  26. package/dist/classes/navigation/Location.d.ts +2 -4
  27. package/dist/classes/navigation/Location.js +5 -1
  28. package/dist/classes/navigation/Location.js.map +1 -1
  29. package/dist/classes/navigation/Location.mjs +5 -1
  30. package/dist/classes/navigation/Location.mjs.map +1 -1
  31. package/dist/classes/navigation/Map.d.mts +2 -4
  32. package/dist/classes/navigation/Map.d.ts +2 -4
  33. package/dist/classes/navigation/Map.js +8 -4
  34. package/dist/classes/navigation/Map.js.map +1 -1
  35. package/dist/classes/navigation/Map.mjs +8 -4
  36. package/dist/classes/navigation/Map.mjs.map +1 -1
  37. package/dist/classes/navigation/Room.d.mts +2 -4
  38. package/dist/classes/navigation/Room.d.ts +2 -4
  39. package/dist/classes/navigation/Room.js +18 -6
  40. package/dist/classes/navigation/Room.js.map +1 -1
  41. package/dist/classes/navigation/Room.mjs +18 -6
  42. package/dist/classes/navigation/Room.mjs.map +1 -1
  43. package/dist/classes/navigation/index.d.mts +1 -3
  44. package/dist/classes/navigation/index.d.ts +1 -3
  45. package/dist/classes/navigation/index.js +31 -11
  46. package/dist/classes/navigation/index.js.map +1 -1
  47. package/dist/classes/navigation/index.mjs +31 -11
  48. package/dist/classes/navigation/index.mjs.map +1 -1
  49. package/dist/decorators/ActivityDecorator.d.mts +0 -3
  50. package/dist/decorators/ActivityDecorator.d.ts +0 -3
  51. package/dist/decorators/CommitmentDecorator.d.mts +1 -3
  52. package/dist/decorators/CommitmentDecorator.d.ts +1 -3
  53. package/dist/decorators/RoomDecorator.d.mts +1 -3
  54. package/dist/decorators/RoomDecorator.d.ts +1 -3
  55. package/dist/decorators/index.d.mts +1 -3
  56. package/dist/decorators/index.d.ts +1 -3
  57. package/dist/functions/ActivityFunctions.d.mts +1 -3
  58. package/dist/functions/ActivityFunctions.d.ts +1 -3
  59. package/dist/functions/ActivityFunctions.js.map +1 -1
  60. package/dist/functions/ActivityFunctions.mjs.map +1 -1
  61. package/dist/functions/NavigationFunctions.d.mts +1 -3
  62. package/dist/functions/NavigationFunctions.d.ts +1 -3
  63. package/dist/functions/NavigationFunctions.js +5 -1
  64. package/dist/functions/NavigationFunctions.js.map +1 -1
  65. package/dist/functions/NavigationFunctions.mjs +5 -1
  66. package/dist/functions/NavigationFunctions.mjs.map +1 -1
  67. package/dist/functions/RoutineFunctions.d.mts +1 -3
  68. package/dist/functions/RoutineFunctions.d.ts +1 -3
  69. package/dist/functions/index.d.mts +1 -3
  70. package/dist/functions/index.d.ts +1 -3
  71. package/dist/functions/index.js +5 -1
  72. package/dist/functions/index.js.map +1 -1
  73. package/dist/functions/index.mjs +5 -1
  74. package/dist/functions/index.mjs.map +1 -1
  75. package/dist/{index-Cu7BBJil.d.ts → index-Cu8ZAiqF.d.ts} +19 -20
  76. package/dist/{index-Lm3w4aIL.d.mts → index-DhsRZJ3g.d.mts} +19 -20
  77. package/dist/index.d.mts +1 -3
  78. package/dist/index.d.ts +1 -3
  79. package/dist/index.js +41 -13
  80. package/dist/index.js.map +1 -1
  81. package/dist/index.mjs +41 -13
  82. package/dist/index.mjs.map +1 -1
  83. package/dist/override/{GraphicItem.js → GraphicItemType.js} +1 -1
  84. package/dist/override/GraphicItemType.mjs +3 -0
  85. package/dist/override/index.d.mts +1 -1
  86. package/dist/override/index.d.ts +1 -1
  87. package/package.json +2 -2
  88. package/dist/override/GraphicItem.mjs +0 -3
  89. /package/dist/override/{GraphicItem.d.mts → GraphicItemType.d.mts} +0 -0
  90. /package/dist/override/{GraphicItem.d.ts → GraphicItemType.d.ts} +0 -0
  91. /package/dist/override/{GraphicItem.js.map → GraphicItemType.js.map} +0 -0
  92. /package/dist/override/{GraphicItem.mjs.map → GraphicItemType.mjs.map} +0 -0
package/dist/index.mjs CHANGED
@@ -363,7 +363,11 @@ var ActivityStoredAbstract = class {
363
363
  if (typeof this._renderIcon !== "function") {
364
364
  return (props) => this._renderIcon;
365
365
  }
366
- return this._renderIcon;
366
+ if (this._renderIcon !== void 0) {
367
+ return (props) => {
368
+ return this._renderIcon(this, props);
369
+ };
370
+ }
367
371
  }
368
372
  /**
369
373
  * The function that is called when the activity is runned.
@@ -483,7 +487,11 @@ var ActivityModel = class {
483
487
  if (typeof this._renderIcon !== "function") {
484
488
  return (props) => this._renderIcon;
485
489
  }
486
- return this._renderIcon;
490
+ if (this._renderIcon !== void 0) {
491
+ return (props) => {
492
+ return this._renderIcon(this, props);
493
+ };
494
+ }
487
495
  }
488
496
  /**
489
497
  * The function that is called when the activity is runned.
@@ -615,7 +623,11 @@ var CommitmentBaseModel = class extends StoredClassModel {
615
623
  if (typeof this._renderImage !== "function") {
616
624
  return (props) => this._renderImage;
617
625
  }
618
- return this._renderImage;
626
+ if (this.renderImage !== void 0) {
627
+ return (props) => {
628
+ return this.renderImage(this, props);
629
+ };
630
+ }
619
631
  }
620
632
  /**
621
633
  * Execution type. If is "automatic" the onRun() runned automatically when the palayer is in the room. If is "interaction" the player must interact with the character to run the onRun() function.
@@ -785,7 +797,11 @@ var LocationBaseModel = class extends StoredClassModel {
785
797
  if (typeof this._renderIcon !== "function") {
786
798
  return (props) => this._renderIcon;
787
799
  }
788
- return this._renderIcon;
800
+ if (this._renderIcon !== void 0) {
801
+ return (props) => {
802
+ return this._renderIcon(this, props);
803
+ };
804
+ }
789
805
  }
790
806
  /**
791
807
  * The map where the location is.
@@ -832,7 +848,7 @@ var MapBaseModel = class extends StoredClassModel {
832
848
  constructor(id, props = {}) {
833
849
  super(MAP_CATEGORY, id);
834
850
  this.defaultName = props.name || "";
835
- this._renderImege = props.renderImage;
851
+ this._renderImage = props.renderImage;
836
852
  this.defaultDisabled = props.disabled || false;
837
853
  this.defaultHidden = props.hidden || false;
838
854
  }
@@ -850,10 +866,14 @@ var MapBaseModel = class extends StoredClassModel {
850
866
  * The function for rendering the image of the map.
851
867
  */
852
868
  get renderImage() {
853
- if (typeof this._renderImege !== "function") {
854
- return (props) => this._renderImege;
869
+ if (typeof this._renderImage !== "function") {
870
+ return (props) => this._renderImage;
871
+ }
872
+ if (this.renderImage !== void 0) {
873
+ return (props) => {
874
+ return this.renderImage(this, props);
875
+ };
855
876
  }
856
- return this._renderImege;
857
877
  }
858
878
  /**
859
879
  * Whether is disabled. If it is a string, it is a Pixi'VN flag name.
@@ -1104,7 +1124,7 @@ var RoomBaseModel = class extends StoredClassModel {
1104
1124
  super(ROOM_CATEGORY, id);
1105
1125
  this._location = location;
1106
1126
  this.defaultName = props.name || "";
1107
- this._renderImege = props.renderImage;
1127
+ this._renderImage = props.renderImage;
1108
1128
  this.defaultActivityIds = ((_a = props.defaultActivities) == null ? void 0 : _a.map((activity) => activity.id)) || [];
1109
1129
  this.defaultDisabled = props.disabled || false;
1110
1130
  this.defaultHidden = props.hidden || false;
@@ -1137,10 +1157,14 @@ var RoomBaseModel = class extends StoredClassModel {
1137
1157
  * The function for rendering the image of the room.
1138
1158
  */
1139
1159
  get renderImage() {
1140
- if (typeof this._renderImege !== "function") {
1141
- return (props) => this._renderImege;
1160
+ if (typeof this._renderImage !== "function") {
1161
+ return (props) => this._renderImage;
1162
+ }
1163
+ if (this.renderImage !== void 0) {
1164
+ return (props) => {
1165
+ return this.renderImage(this, props);
1166
+ };
1142
1167
  }
1143
- return this._renderImege;
1144
1168
  }
1145
1169
  /**
1146
1170
  * The activities that are available in this room.
@@ -1304,7 +1328,11 @@ var RoomBaseModel = class extends StoredClassModel {
1304
1328
  if (typeof this._renderIcon !== "function") {
1305
1329
  return (props) => this._renderIcon;
1306
1330
  }
1307
- return this._renderIcon;
1331
+ if (this._renderIcon !== void 0) {
1332
+ return (props) => {
1333
+ return this._renderIcon(this, props);
1334
+ };
1335
+ }
1308
1336
  }
1309
1337
  /**
1310
1338
  * Get the character commitments of the room.