@leafer-game/miniapp 2.2.8 → 2.2.9

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.
@@ -2992,7 +2992,7 @@ const PathCommandNodeHelper = {
2992
2992
  toCommand(_nodes) {
2993
2993
  return [];
2994
2994
  },
2995
- toNode(_data) {
2995
+ toNode(_data, _filterSamePoint) {
2996
2996
  return [];
2997
2997
  }
2998
2998
  };
@@ -7046,7 +7046,7 @@ class LeafLevelList {
7046
7046
  }
7047
7047
  }
7048
7048
 
7049
- const version = "2.2.8";
7049
+ const version = "2.2.9";
7050
7050
 
7051
7051
  class LeaferCanvas extends LeaferCanvasBase {
7052
7052
  get allowBackgroundColor() {
@@ -15167,6 +15167,7 @@ const HighCurveHelper = {
15167
15167
  motionDistance = UnitConvert.number(motionDistance, total);
15168
15168
  if (offsetX) motionDistance += offsetX;
15169
15169
  if (motionDistance > total) motionDistance = motionDistance % total;
15170
+ if (motionDistance < 0) motionDistance = total + motionDistance;
15170
15171
  let nowDistance = 0, distance, to = {};
15171
15172
  let i = 0, index = 0, x = 0, y = 0, startX = 0, startY = 0, toX, toY, command;
15172
15173
  let x1, y1, x2, y2, t;
@@ -15375,11 +15376,7 @@ ui$1.getMotionPathData = function() {
15375
15376
  return getMotionPathData(getMotionPath(this));
15376
15377
  };
15377
15378
 
15378
- ui$1.getMotionContentHeight = function() {
15379
- return this.__layout.boxBounds.height;
15380
- };
15381
-
15382
- ui$1.getMotionPoint = function(motionDistance, motionAround, motionVertical, offsetX = 0, offsetY = 0, pathElement) {
15379
+ ui$1.getMotionPoint = function(motionDistance, motionAround, offsetX = 0, offsetY = 0, pathElement) {
15383
15380
  if (!pathElement) pathElement = getMotionPath(this);
15384
15381
  const data = getMotionPathData(pathElement);
15385
15382
  if (!data.total) return {};
@@ -15392,25 +15389,7 @@ ui$1.getMotionPoint = function(motionDistance, motionAround, motionVertical, off
15392
15389
  if (point.rotation) PointHelper.rotate(tempPoint, point.rotation, point);
15393
15390
  PointHelper.copy(point, tempPoint);
15394
15391
  }
15395
- let verticalType, verticalOffset;
15396
- if (isObject(motionVertical)) verticalType = motionVertical.type, verticalOffset = motionVertical.offset; else if (isNumber(motionVertical)) verticalOffset = motionVertical; else verticalType = motionVertical;
15397
- if (verticalType !== "below" || offsetY) {
15398
- const {rotation: rotation} = point, height = this.getMotionContentHeight();
15399
- if (verticalOffset) offsetY += verticalType === "above" ? -verticalOffset : verticalOffset;
15400
- switch (verticalType) {
15401
- case "above":
15402
- toVertical(point, rotation, -height + offsetY);
15403
- break;
15404
-
15405
- case "center":
15406
- toVertical(point, rotation, -height / 2 + offsetY);
15407
- break;
15408
-
15409
- case "below":
15410
- default:
15411
- toVertical(point, rotation, offsetY);
15412
- }
15413
- }
15392
+ if (offsetY) toVertical(point, point.rotation, offsetY);
15414
15393
  MatrixHelper.toOuterPoint(pathElement.localTransform, point);
15415
15394
  return point;
15416
15395
  };