@urso/core 0.1.95 → 0.1.96

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.
@@ -26,14 +26,6 @@ object-assign
26
26
  * MIT License
27
27
  */
28
28
 
29
- /*!
30
- * @pixi/accessibility - v5.3.11
31
- * Compiled Mon, 01 Nov 2021 16:10:12 UTC
32
- *
33
- * @pixi/accessibility is licensed under the MIT License.
34
- * http://www.opensource.org/licenses/mit-license
35
- */
36
-
37
29
  /*!
38
30
  * @pixi/constants - v5.3.11
39
31
  * Compiled Mon, 01 Nov 2021 16:10:12 UTC
@@ -172,6 +164,16 @@ object-assign
172
164
  * http://www.opensource.org/licenses/mit-license
173
165
  */
174
166
 
167
+ /*!
168
+ * pixi-viewport - v4.34.3
169
+ * Compiled Wed, 01 Dec 2021 19:28:04 UTC
170
+ *
171
+ * pixi-viewport is licensed under the MIT License.
172
+ * http://www.opensource.org/licenses/mit-license
173
+ *
174
+ * Copyright 2019-2020, David Figatner, All Rights Reserved
175
+ */
176
+
175
177
  /*!
176
178
  * resource-loader - v3.0.1
177
179
  * https://github.com/pixijs/pixi-sound
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@urso/core",
3
- "version": "0.1.95",
3
+ "version": "0.1.96",
4
4
  "description": "HTML5 game engine",
5
5
  "main": "build/js/index.js",
6
6
  "author": "Megbrimef",
@@ -29,7 +29,10 @@
29
29
  "pixi-projection": "0.3.15",
30
30
  "pixi-spine": "^2.1.11",
31
31
  "pixi.js": "^5.1.3",
32
- "pixi5-dragonbones": "5.7.0-2"
32
+ "pixi5-dragonbones": "5.7.0-2",
33
+ "pixi-scrollbox": "^2.3.1",
34
+ "pixi-viewport": "^4.34.0",
35
+ "pixi-text-input": "^1.0.6"
33
36
  },
34
37
  "devDependencies": {
35
38
  "@babel/core": "^7.12.10",
@@ -201,6 +201,17 @@ class LibHelper {
201
201
  return true;
202
202
  }
203
203
 
204
+ /**
205
+ * tranpose matrix (rows to cols)
206
+ * @param {Array} matrix
207
+ * @returns {Array}
208
+ */
209
+ transpose(matrix) {
210
+ return Object.keys(matrix[0])
211
+ .map(colNumber => matrix
212
+ .map(rowNumber => rowNumber[colNumber]));
213
+ }
214
+
204
215
  /**
205
216
  * recursive merge two objects into one
206
217
  * @param {Object} obj1
@@ -105,6 +105,21 @@ class ModulesObjectsCreate {
105
105
  case Urso.types.objects.EMITTER:
106
106
  model = this.getInstance('Models.Emitter', object);
107
107
  break;
108
+ case Urso.types.objects.SLIDER:
109
+ model = this.getInstance('Models.Slider', object);
110
+ break;
111
+ case Urso.types.objects.TOGGLE:
112
+ model = this.getInstance('Models.Toggle', object);
113
+ break;
114
+ case Urso.types.objects.CHECKBOX:
115
+ model = this.getInstance('Models.Checkbox', object);
116
+ break;
117
+ case Urso.types.objects.SCROLLBOX:
118
+ model = this.getInstance('Models.Scrollbox', object);
119
+ break;
120
+ case Urso.types.objects.TEXTINPUT:
121
+ model = this.getInstance('Models.TextInput', object);
122
+ break;
108
123
  default:
109
124
  break;
110
125
  }
@@ -16,5 +16,10 @@ Urso.Core.Modules.Objects.Models = {
16
16
  Mask: require('./mask.js'),
17
17
  Spine: require('./spine.js'),
18
18
  Text: require('./text.js'),
19
+ Slider: require('./slider.js'),
20
+ Toggle: require('./toggle.js'),
21
+ Checkbox: require('./checkbox.js'),
22
+ Scrollbox: require('./scrollbox.js'),
23
+ TextInput: require('./textInput.js'),
19
24
  World: require('./world.js')
20
25
  };
@@ -0,0 +1,91 @@
1
+ const UrsoCoreModulesObjectsModelsToggle = require('./toggle');
2
+
3
+ class ModulesObjectsModelsCheckbox extends UrsoCoreModulesObjectsModelsToggle {
4
+ constructor(params) {
5
+ super(params);
6
+
7
+ this._isDisabled = false;
8
+ this._lable = null;
9
+ this._checkbox = null;
10
+
11
+ this.type = Urso.types.objects.CHECKBOX;
12
+
13
+ this._createCheckbox();
14
+
15
+ this.enable = this.enable.bind(this);
16
+ this.disable = this.disable.bind(this);
17
+ }
18
+
19
+ setupParams(params) {
20
+ super.setupParams(params);
21
+
22
+ this.contents = [];
23
+ this.action = Urso.helper.recursiveGet('action', params, () => { this.emit(Urso.events.MODULES_OBJECTS_CHECKBOX_PRESS, this.name) });
24
+ this.lable = Urso.helper.recursiveGet('lable', params, false);
25
+
26
+ this.defaultStatus = Urso.helper.recursiveGet('defaultStatus', params, 'unpressed'); //pressed or unpressed
27
+ }
28
+
29
+ _createCheckbox() {
30
+ this._toggleStatus = this.defaultStatus;
31
+ this._checkbox = this._createObject(this.buttonFrames[`${this.defaultStatus}Out`])
32
+
33
+ if (this.lable)
34
+ this._lable = this._createObject(this.lable);
35
+ }
36
+
37
+ _createObject(model) {
38
+ model = Urso.helper.objectClone(model);
39
+ let object = Urso.objects.create(model, this);
40
+
41
+ object._baseObject.interactive = true;
42
+ object._baseObject.buttonMode = true;
43
+
44
+ object._baseObject
45
+ .on('pointerdown', this._onButtonDown.bind(this))
46
+ .on('pointerup', this._onButtonUp.bind(this))
47
+ .on('pointerupoutside', this._onButtonUp.bind(this))
48
+ .on('pointerover', this._onButtonOver.bind(this))
49
+ .on('pointerout', this._onButtonOut.bind(this));
50
+
51
+ return object;
52
+ }
53
+
54
+ _addBaseObject() {
55
+ this._baseObject = new PIXI.Container();
56
+ };
57
+
58
+ _drawGraphics({ polygon, rectangle, fillColor }) {
59
+ if (!polygon && !rectangle)
60
+ return;
61
+
62
+ this._checkbox._baseObject.clear();
63
+ this._checkbox._baseObject.beginFill(fillColor);
64
+
65
+ if (polygon && polygon.length) {
66
+ this._checkbox._baseObject.drawPolygon(polygon);
67
+ } else if (rectangle && rectangle.length) {
68
+ this._checkbox._baseObject.drawRect(...rectangle)
69
+ }
70
+
71
+ this._checkbox._baseObject.endFill();
72
+ };
73
+
74
+ _changeTexture(key) {
75
+ if (!this.buttonFrames[key]) {
76
+ if (key === `${this._toggleStatus}Out`) {
77
+ Urso.logger.error('ModulesObjectsModelsButton assets error: no out image ' + this.buttonFrames.out);
78
+ return false;
79
+ }
80
+
81
+ this._changeTexture(`${this._toggleStatus}Out`); // load default texture for this key
82
+ return false;
83
+ }
84
+ if (this.buttonFrames[key].type === Urso.types.objects.GRAPHICS)
85
+ this._drawGraphics(this.buttonFrames[key].figure);
86
+ else
87
+ this._checkbox.changeTexture(this.buttonFrames[key].assetKey);
88
+ }
89
+ }
90
+
91
+ module.exports = ModulesObjectsModelsCheckbox;
@@ -0,0 +1,62 @@
1
+ class ModulesObjectsModelsScrollbox extends Urso.Core.Modules.Objects.BaseModel {
2
+ constructor(params) {
3
+ super(params);
4
+
5
+ this.type = Urso.types.objects.SCROLLBOX;
6
+ this._addBaseObject();
7
+ this._createContent();
8
+ }
9
+
10
+ setupParams(params) {
11
+ super.setupParams(params);
12
+
13
+ this.content = Urso.helper.recursiveGet('content', params, []);
14
+ this.dragScroll = Urso.helper.recursiveGet('dragScroll', params, true);
15
+ this.scrollType = Urso.helper.recursiveGet('scrollType', params, 3);
16
+ }
17
+
18
+ _getScrollboxParams(){
19
+ return {
20
+ boxWidth: this.width,
21
+ boxHeight: this.height,
22
+ dragScroll: this.dragScroll,
23
+ fade: true,
24
+ fadeScrollbarTime: 300
25
+ }
26
+ }
27
+
28
+ _setScrollWidth(){
29
+ if(this.scrollType === 1 || this.scrollType === 0){
30
+ this._baseObject.scrollWidth = this.width;
31
+ this._baseObject.overflowX = 'hidden';
32
+ }
33
+ }
34
+
35
+ _setScrollHeight(){
36
+ if(this.scrollType === 2 || this.scrollType === 0){
37
+ this._baseObject.scrollHeight = this.height;
38
+ this._baseObject.overflowY = 'hidden'
39
+ }
40
+ }
41
+
42
+ _createContent(){
43
+ this.content.forEach(child => {
44
+ let object = Urso.objects.create(child)
45
+ this._baseObject.content.addChild(object._baseObject)
46
+ })
47
+
48
+ this._baseObject.update();
49
+ }
50
+
51
+ _addBaseObject() {
52
+ const params = this._getScrollboxParams();
53
+
54
+ const Scrollbox = require('pixi-scrollbox').Scrollbox;
55
+ this._baseObject = new Scrollbox(params);
56
+
57
+ this._setScrollHeight();
58
+ this._setScrollWidth();
59
+ };
60
+ }
61
+
62
+ module.exports = ModulesObjectsModelsScrollbox
@@ -0,0 +1,154 @@
1
+ class ModulesObjectsModelsSlider extends Urso.Core.Modules.Objects.BaseModel {
2
+ constructor(params) {
3
+ super(params);
4
+
5
+ this.type = Urso.types.objects.SLIDER;
6
+ this._sliderBg = null;
7
+ this._sliderHandle = null;
8
+ this._baseObject = null;
9
+ this._handleIsPulling = false;
10
+
11
+ this._addBaseObject();
12
+ this._createSliderTextures();
13
+ this._createValueText();
14
+ this._setDefaultValue();
15
+ }
16
+
17
+ setupParams(params) {
18
+ super.setupParams(params);
19
+ this.contents = [];
20
+ this.points = Urso.helper.recursiveGet('points', params, [0, 1]);
21
+ this.defaultValue = Urso.helper.recursiveGet('defaultValue', params, this.points[0]);
22
+ this.bgTexture = Urso.helper.recursiveGet('bgTexture', params, false);
23
+ this.handleTexture = Urso.helper.recursiveGet('handleTexture', params, false);
24
+ this.minValueTextModel = Urso.helper.recursiveGet('minValueTextModel', params, false);
25
+ this.maxValueTextModel = Urso.helper.recursiveGet('maxValueTextModel', params, false);
26
+ this.currentValueTextModel = Urso.helper.recursiveGet('currentValueTextModel', params, false);
27
+ }
28
+
29
+ _createSliderTextures() {
30
+ this._sliderBg = this._createTexture(this.bgTexture);
31
+ this._sliderHandle = this._createTexture(this.handleTexture);
32
+
33
+ this._setEvents(this._sliderBg._baseObject);
34
+ this._setEvents(this._sliderHandle._baseObject);
35
+ }
36
+
37
+ _createValueText() {
38
+ if (this.minValueTextModel) {
39
+ this.minValueText = Urso.objects.create(this.minValueTextModel, this);
40
+ this.minValueText.text = this.points[0];
41
+ }
42
+
43
+ if (this.maxValueTextModel) {
44
+ this.maxValueText = Urso.objects.create(this.maxValueTextModel, this);
45
+ this.maxValueText.text = this.points.length <= 2 ? '100' : this.points[this.points.length - 1];
46
+ }
47
+
48
+ if(this.currentValueTextModel){
49
+ this.currentValueText = Urso.objects.create(this.currentValueTextModel, this);
50
+ }
51
+ }
52
+
53
+ _createTexture(model) {
54
+ if (model.type === Urso.types.objects.GRAPHICS || model.type === Urso.types.objects.IMAGE)
55
+ return Urso.objects.create(model, this);
56
+ else
57
+ Urso.logger.error('ModulesObjectsModelsSlider objects error: textures should be GRAPHICS or IMAGE type');
58
+ }
59
+
60
+ _setEvents(obj) {
61
+ obj.interactive = true;
62
+ obj.buttonMode = true;
63
+
64
+ obj
65
+ .on('pointerdown', this._onPointerDown.bind(this))
66
+ .on('pointerup', this._onPointerUp.bind(this))
67
+ .on('pointerupoutside', this._onPointerUp.bind(this))
68
+ }
69
+
70
+ _addBaseObject() {
71
+ this._baseObject = new PIXI.Container();
72
+ };
73
+
74
+ _onPointerDown(obj) {
75
+ if (obj.target === this._sliderHandle._baseObject)
76
+ this._handleIsDragging = true;
77
+ }
78
+
79
+ _onMouseMove({ x }) {
80
+ if (!this._handleIsDragging)
81
+ return
82
+
83
+ if (x < this.x)
84
+ this._sliderHandle.x = 0;
85
+ else if (x > this.x + this._sliderBg._baseObject.width)
86
+ this._sliderHandle.x = this._sliderBg._baseObject.width;
87
+ else
88
+ this._sliderHandle.x = x - this.x;
89
+ }
90
+
91
+ _onPointerUp(obj) {
92
+ this._handleIsDragging = false;
93
+ let x;
94
+
95
+ if (obj.target === this._sliderBg._baseObject) {
96
+ x = obj.data.getLocalPosition(obj.target).x;
97
+ } else
98
+ x = this._sliderHandle.x;
99
+
100
+ this._dropHandle(x);
101
+ }
102
+
103
+ _setDefaultValue(){
104
+ if(!this.defaultValue)
105
+ return
106
+
107
+ if(!this.points.includes(this.defaultValue))
108
+ this.defaultValue = this.points[0];
109
+
110
+ let x = this.points.indexOf(this.defaultValue) * this._sliderBg._baseObject.width / (this.points.length - 1);
111
+
112
+ this._setNewValue(x, this.defaultValue);
113
+ }
114
+
115
+ _dropHandle(x) {
116
+ let value;
117
+ let handleX;
118
+
119
+ if(this.points.length <= 2){
120
+ handleX = x;
121
+ value = ~~(100 / this._sliderBg._baseObject.width * x);
122
+ }
123
+ // calculate closest point
124
+ else{
125
+ for (let i = 0; i < this.points.length; i++) {
126
+ let pointX = i * this._sliderBg._baseObject.width / (this.points.length - 1);
127
+
128
+ if (typeof (handleX) === 'number' && x - pointX < handleX - x) {
129
+ handleX = handleX;
130
+ } else {
131
+ handleX = pointX;
132
+ value = this.points[i];
133
+ }
134
+ }
135
+ }
136
+
137
+ this._setNewValue(handleX, value)
138
+ }
139
+
140
+ _setNewValue(x, value){
141
+ this._sliderHandle.x = x;
142
+
143
+ if (this.currentValueText)
144
+ this.currentValueText.text = value;
145
+
146
+ this.emit(Urso.events.MODULES_OBJECTS_SLIDER_SET_NEW_VALUE, { name: this.name, value: value });
147
+ }
148
+
149
+ _subscribeOnce() {
150
+ this.addListener(Urso.events.MODULES_SCENES_MOUSE_NEW_POSITION, this._onMouseMove.bind(this));
151
+ }
152
+ }
153
+
154
+ module.exports = ModulesObjectsModelsSlider;
@@ -0,0 +1,55 @@
1
+ class ModulesObjectsModelsTextInput extends Urso.Core.Modules.Objects.BaseModel {
2
+ constructor(params) {
3
+ super(params);
4
+
5
+ this.type = Urso.types.objects.TEXTINPUT;
6
+ this.text = '';
7
+ this._addBaseObject();
8
+ this._setRestrictedSymbosl();
9
+ }
10
+
11
+ setupParams(params) {
12
+ super.setupParams(params);
13
+
14
+ this.input = Urso.helper.recursiveGet('input', params, false);
15
+ this.box = Urso.helper.recursiveGet('box', params, false);
16
+ this.numbersOnly = Urso.helper.recursiveGet('numbersOnly', params, false);
17
+ this.allowedSymbols = Urso.helper.recursiveGet('allowedSymbols', params, false);
18
+ this.substituteText = Urso.helper.recursiveGet('substituteText', params, false);
19
+ }
20
+
21
+ restrictInput(allowedSymbols) {
22
+ this._baseObject.restrict = allowedSymbols;
23
+ }
24
+
25
+ disable(){
26
+ this._baseObject.disabled = true
27
+ }
28
+
29
+ enable(){
30
+ this._baseObject.disabled = false
31
+ }
32
+
33
+ _setRestrictedSymbosl() {
34
+ if (this.numbersOnly) {
35
+ const regex = new RegExp('^[0-9]*');
36
+ this.restrictInput(regex);
37
+ } else if (this.allowedSymbols) {
38
+ this.restrictInput(this.allowedSymbols);
39
+ }
40
+ }
41
+
42
+ _onBlur(){
43
+ this.text = this._baseObject.text;
44
+ const data = {name: this.name, class: this.class, id: this.id, text: this.text};
45
+ this.emit(Urso.events.MODULES_OBJECTS_TEXTINPUT_BLUR, data);
46
+ }
47
+
48
+ _addBaseObject() {
49
+ this._baseObject = new PIXI.TextInput({ input: this.input, box: this.box });
50
+ this._baseObject.substituteText = this.substituteText;
51
+ this._baseObject.on('blur', this._onBlur.bind(this))
52
+ };
53
+ }
54
+
55
+ module.exports = ModulesObjectsModelsTextInput;
@@ -0,0 +1,165 @@
1
+
2
+ const UrsoCoreModulesObjectsModelsButton = require('./button');
3
+
4
+ class ModulesObjectsModelsToggle extends UrsoCoreModulesObjectsModelsButton {
5
+ constructor(params) {
6
+ super(params);
7
+
8
+ this._toggleStatus = 'unpressed';
9
+
10
+ this.type = Urso.types.objects.TOGGLE;
11
+ this._addBaseObject();
12
+
13
+ this.enable = this.enable.bind(this);
14
+ this.disable = this.disable.bind(this);
15
+ }
16
+
17
+ setupParams(params) {
18
+ super.setupParams(params);
19
+
20
+ this.buttonFrames = {
21
+ pressedOver: Urso.helper.recursiveGet('buttonFrames.pressedOver', params, false),
22
+ pressedOut: Urso.helper.recursiveGet('buttonFrames.pressedOut', params, false),
23
+ unpressedOver: Urso.helper.recursiveGet('buttonFrames.unpressedOver', params, false),
24
+ unpressedOut: Urso.helper.recursiveGet('buttonFrames.unpressedOut', params, false),
25
+ pressedDown: Urso.helper.recursiveGet('buttonFrames.pressedDown', params, false),
26
+ unpressedDown: Urso.helper.recursiveGet('buttonFrames.unpressedDown', params, false),
27
+ pressedDisabled: Urso.helper.recursiveGet('buttonFrames.pressedDisabled', params, false),
28
+ unpressedDisabled: Urso.helper.recursiveGet('buttonFrames.unpressedDisabled', params, false),
29
+ }
30
+ }
31
+
32
+ setButtonFrame(key, assetKey) {
33
+ this.buttonFrames[key] = assetKey;
34
+
35
+ if (this._isOver)
36
+ this._changeTexture(`${this._toggleStatus}Over`);
37
+ else if(this._isDown)
38
+ this._changeTexture(`${this._toggleStatus}Down`);
39
+ else if(this._isDisabled)
40
+ this._changeTexture(`${this._toggleStatus}Disabled`);
41
+ else
42
+ this._changeTexture(`${this._toggleStatus}Out`);
43
+ }
44
+
45
+ enable() {
46
+ if (!this._isDisabled)
47
+ return false;
48
+
49
+ if (this._isOver)
50
+ this._changeTexture(`${this._toggleStatus}Over`);
51
+ else
52
+ this._changeTexture(`${this._toggleStatus}Out`);
53
+
54
+ this._isDisabled = false;
55
+ }
56
+
57
+ disable() {
58
+ if (this._isDisabled)
59
+ return false;
60
+
61
+ this._changeTexture(`${this._toggleStatus}Disabled`);
62
+ this._isDisabled = true;
63
+ }
64
+
65
+ _addBaseObject() {
66
+ this._baseObject = new PIXI.Sprite();
67
+ this._changeTexture('unpressedOut');
68
+
69
+ this._baseObject.interactive = true;
70
+ this._baseObject.buttonMode = true;
71
+
72
+ if (this.pixelPerfectOver) {
73
+ //todo
74
+ }
75
+
76
+ if (this.pixelPerfectClick) {
77
+ //todo
78
+ }
79
+
80
+ this._baseObject
81
+ .on('pointerdown', this._onButtonDown.bind(this))
82
+ .on('pointerup', this._onButtonUp.bind(this))
83
+ .on('pointerupoutside', this._onButtonUp.bind(this))
84
+ .on('pointerover', this._onButtonOver.bind(this))
85
+ .on('pointerout', this._onButtonOut.bind(this));
86
+ };
87
+
88
+ _onButtonDown() {
89
+ if (this._isDisabled)
90
+ return false;
91
+
92
+ this._isDown = true;
93
+
94
+ if (this.keyDownAction)
95
+ this.keyDownAction();
96
+
97
+ if (this._isDisabled) //can be disabled after keyDownAction
98
+ return false;
99
+
100
+ this._changeTexture(`${this._toggleStatus}Down`);
101
+
102
+ this._toggleStatus = this._toggleStatus === 'pressed' ? 'unpressed' : 'pressed';
103
+ }
104
+
105
+ _onButtonUp() {
106
+ if (this._isDisabled)
107
+ return false;
108
+
109
+ this._isDown = false;
110
+
111
+ if (this.action)
112
+ this.action();
113
+
114
+ if (this._isDisabled) //can be disabled after action
115
+ return false;
116
+
117
+ if (this._isOver)
118
+ this._changeTexture(`${this._toggleStatus}Over`);
119
+ else
120
+ this._changeTexture(`${this._toggleStatus}Out`);
121
+ }
122
+
123
+ _onButtonOver() {
124
+ this._isOver = true;
125
+
126
+ if (this._isDisabled || this._isDown)
127
+ return false;
128
+
129
+ if (this.mouseOverAction)
130
+ this.mouseOverAction();
131
+
132
+ this._changeTexture(`${this._toggleStatus}Over`);
133
+ }
134
+
135
+ _onButtonOut() {
136
+ this._isOver = false;
137
+
138
+ if (this._isDisabled || this._isDown)
139
+ return false;
140
+
141
+ if (this.mouseOutAction)
142
+ this.mouseOutAction();
143
+
144
+ this._changeTexture(`${this._toggleStatus}Out`);
145
+ }
146
+
147
+ _changeTexture(key) {
148
+ let texture = Urso.cache.getTexture(this.buttonFrames[key]);
149
+
150
+ if (!texture) {
151
+ if (key === `${this._toggleStatus}Out`) {
152
+ Urso.logger.error('ModulesObjectsModelsButton assets error: no out image ' + this.buttonFrames.out);
153
+ return false;
154
+ }
155
+
156
+ this._changeTexture(`${this._toggleStatus}Out`); // load default texture for this key
157
+ return false;
158
+ }
159
+
160
+ this._baseObject.texture = texture;
161
+ return true;
162
+ }
163
+ }
164
+
165
+ module.exports = ModulesObjectsModelsToggle;
@@ -31,7 +31,9 @@ class PropertyAdapter {
31
31
  Urso.types.objects.COMPONENT,
32
32
  Urso.types.objects.CONTAINER,
33
33
  Urso.types.objects.GROUP,
34
- Urso.types.objects.WORLD
34
+ Urso.types.objects.WORLD,
35
+ Urso.types.objects.SLIDER,
36
+ Urso.types.objects.SCROLLBOX,
35
37
  ];
36
38
 
37
39
  this._typesWithoutAnchor = [
@@ -40,7 +42,10 @@ class PropertyAdapter {
40
42
  Urso.types.objects.HITAREA,
41
43
  Urso.types.objects.MASK,
42
44
  Urso.types.objects.SPINE,
43
- Urso.types.objects.WORLD
45
+ Urso.types.objects.SLIDER,
46
+ Urso.types.objects.TEXTINPUT,
47
+ Urso.types.objects.CHECKBOX,
48
+ Urso.types.objects.WORLD,
44
49
  ];
45
50
  }
46
51
 
@@ -8,6 +8,9 @@ class ModulesObserverConfig {
8
8
  MODULES_ASSETS_LAZYLOAD_FINISHED: 'modules.assets.lazyLoad.finished',
9
9
  MODULES_OBJECTS_BUTTON_PRESS: 'modules.objects.button.press',
10
10
  MODULES_OBJECTS_HIT_AREA_PRESS: 'modules.objects.hitArea.press',
11
+ MODULES_OBJECTS_SLIDER_SET_NEW_VALUE: 'modules.objects.slider.setNewValue',
12
+ MODULES_OBJECTS_CHECKBOX_PRESS: 'modules.objects.checkbox.press',
13
+ MODULES_OBJECTS_TEXTINPUT_BLUR: 'modules.objects.textinput.blur',
11
14
  MODULES_LOGIC_SOUNDS_DO: 'modules.soundManager.do',
12
15
  MODULES_SOUND_MANAGER_UPDATE_CFG: 'modules.soundManager.updateCfg',
13
16
  MODULES_SOUND_MANAGER_SET_GLOBAL_VOLUME: 'modules.soundManager.setGlobalVolume',
@@ -32,7 +32,12 @@ class ModulesTemplateTypes {
32
32
  GROUP: 15,
33
33
  IMAGES_ANIMATION: 16,
34
34
  DRAGONBONES: 17,
35
- ATLASIMAGE: 18
35
+ ATLASIMAGE: 18,
36
+ SLIDER: 19,
37
+ TOGGLE: 20,
38
+ CHECKBOX: 21,
39
+ SCROLLBOX: 22,
40
+ TEXTINPUT: 23
36
41
  }
37
42
  }
38
43
  }