@gamelearn/arcade-components 1.27.0 → 1.27.2
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.
|
@@ -392,13 +392,13 @@ var DialogComponent = function DialogComponent(_ref) {
|
|
|
392
392
|
target.applyQuaternion(camera.quaternion);
|
|
393
393
|
var distance = camera.position.distanceTo(target.position);
|
|
394
394
|
var staticDisplay = distance > 70 && !zoomInActor && !showArrowTop;
|
|
395
|
-
target.translateY(staticDisplay || showArrowTop ?
|
|
395
|
+
target.translateY(staticDisplay || showArrowTop ? -1 : 0); // Detectar posicion de personaje a izq o derecha de pantalla
|
|
396
396
|
|
|
397
397
|
var vector = new _three.Vector3();
|
|
398
398
|
vector.setFromMatrixPosition(head.matrixWorld);
|
|
399
399
|
var p = vector.project(defaultCamera);
|
|
400
|
-
target.translateX(headSize);
|
|
401
400
|
var isLeft = p.x < 0;
|
|
401
|
+
target.translateX(-1);
|
|
402
402
|
messagePosition.current = {
|
|
403
403
|
pos: target.position.toArray(),
|
|
404
404
|
child: head,
|
|
@@ -570,7 +570,7 @@ var DialogComponent = function DialogComponent(_ref) {
|
|
|
570
570
|
}, [currentMessage, nextLine, start, stop, currentLine === null || currentLine === void 0 ? void 0 : currentLine.audioType, autoPlayCond, audio, voice, audioFailed]); // Positioning Bubble Message logic
|
|
571
571
|
|
|
572
572
|
var checkBubbleBounds = (0, _react.useCallback)(function (group, bubble) {
|
|
573
|
-
if (currentLine !== null && currentLine !== void 0 && currentLine.slots && currentMessage.show) {
|
|
573
|
+
if (currentLine !== null && currentLine !== void 0 && currentLine.slots && currentMessage.show && bubble !== null && bubble !== void 0 && bubble.current) {
|
|
574
574
|
var talkingCharacter = currentLine === null || currentLine === void 0 ? void 0 : currentLine.slots.find(function (slot) {
|
|
575
575
|
return slot.talking;
|
|
576
576
|
});
|
|
@@ -633,7 +633,7 @@ var DialogComponent = function DialogComponent(_ref) {
|
|
|
633
633
|
|
|
634
634
|
messagePosition.current.pos[0] -= headSpace;
|
|
635
635
|
animationTarget.current.translateX(-10 + headSpace);
|
|
636
|
-
animationTarget.current.translateY(
|
|
636
|
+
animationTarget.current.translateY(0);
|
|
637
637
|
animationTarget.current.translateZ(30);
|
|
638
638
|
}
|
|
639
639
|
|
package/dist/helpers/index.js
CHANGED
|
@@ -158,6 +158,7 @@ var setWeight = function setWeight(action, weight) {
|
|
|
158
158
|
|
|
159
159
|
var executeCrossFade = function executeCrossFade(startAction, endAction, duration) {
|
|
160
160
|
if (startAction === endAction) return;
|
|
161
|
+
if (!startAction || !endAction) return;
|
|
161
162
|
startAction.play();
|
|
162
163
|
startAction.reset();
|
|
163
164
|
endAction.reset();
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@gamelearn/arcade-components",
|
|
3
3
|
"author": "Gamelearn",
|
|
4
4
|
"license": "unlicense",
|
|
5
|
-
"version": "1.27.
|
|
5
|
+
"version": "1.27.2",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"files": [
|
|
8
8
|
"dist",
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
"interactjs": "^1.10.11",
|
|
28
28
|
"konva": "^7.2.5",
|
|
29
29
|
"prop-types": "15.7.2",
|
|
30
|
-
"react-konva": "^
|
|
31
|
-
"react-konva-utils": "^0.
|
|
30
|
+
"react-konva": "^18.1.0",
|
|
31
|
+
"react-konva-utils": "^0.3.0",
|
|
32
32
|
"react-pdf": "5.2.0",
|
|
33
33
|
"react-promise-suspense": "0.3.3",
|
|
34
34
|
"react-typist": "^2.0.5",
|