@urso/core 0.8.11 → 0.8.13

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@urso/core",
3
- "version": "0.8.11",
3
+ "version": "0.8.13",
4
4
  "description": "HTML5 game engine",
5
5
  "main": "build/js/index.js",
6
6
  "author": "Megbrimef",
@@ -16,7 +16,6 @@ import { gsap } from 'gsap';
16
16
  window.gsap = gsap;
17
17
 
18
18
  import { Howler, Howl } from 'howler';
19
- window.Howler = Howler;
20
19
 
21
20
  window.UrsoUtils = {
22
21
  Howler: Howler,
@@ -1,4 +1,3 @@
1
- const { Howler } = require("howler");
2
1
  const ModulesAssetsBaseModel = require('./../baseModel');
3
2
 
4
3
  class ModulesAssetsModelsAudiosprite extends ModulesAssetsBaseModel {
@@ -8,7 +7,7 @@ class ModulesAssetsModelsAudiosprite extends ModulesAssetsBaseModel {
8
7
  this.type = Urso.types.assets.AUDIOSPRITE;
9
8
  this.codecs = ['ogg', 'm4a', 'mp3', 'wav'];
10
9
 
11
- const codec = this.codecs.filter(codec => Howler.codecs(codec))[0];
10
+ const codec = this.codecs.filter(codec => UrsoUtils.Howler.codecs(codec))[0];
12
11
 
13
12
  this.contents = Urso.helper.recursiveGet('contents', params, [
14
13
  { type: Urso.types.assets.JSON, key: `${this.key}_audiospriteJson`, path: `${this.path}.json` },
@@ -24,8 +24,8 @@ class ModulesObjectsModelsHitArea extends ModulesObjectsBaseModel {
24
24
  );
25
25
  this.disableRightClick = Urso.helper.recursiveGet('disableRightClick', params, false);
26
26
  this.keyDownAction = Urso.helper.recursiveGet('keyDownAction', params, false);
27
- this.onOverCallback = Urso.helper.recursiveGet('onOverCallback', params, false);
28
- this.onOutCallback = Urso.helper.recursiveGet('onOutCallback', params, false);
27
+ this.mouseOverAction = Urso.helper.recursiveGet('mouseOverAction', params, false);
28
+ this.mouseOutAction = Urso.helper.recursiveGet('mouseOutAction', params, false);
29
29
  this.onTouchMoveCallback = Urso.helper.recursiveGet('onTouchMoveCallback', params, false);
30
30
  this.handlePointerupoutside = Urso.helper.recursiveGet('handlePointerupoutside', params, true);
31
31
  /**
@@ -138,16 +138,16 @@ class ModulesObjectsModelsHitArea extends ModulesObjectsBaseModel {
138
138
  if (this._isDisabled)
139
139
  return false;
140
140
 
141
- if (this.onOverCallback)
142
- this.onOverCallback();
141
+ if (this.mouseOverAction)
142
+ this.mouseOverAction();
143
143
  }
144
144
 
145
145
  _onOut() {
146
146
  if (this._isDisabled)
147
147
  return false;
148
148
 
149
- if (this.onOutCallback)
150
- this.onOutCallback();
149
+ if (this.mouseOutAction)
150
+ this.mouseOutAction();
151
151
  }
152
152
 
153
153
  _getEventLocalPosition(event) {