Commit 73c8cb55 authored by liubing's avatar liubing

调整动画时间。

parent e682cf4b
......@@ -617,7 +617,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
// 计算节点落位后的角度
const angle = this._getAngleByTargetPos();
await asyncTweenTo(piece, 0.3, {
await asyncTweenTo(piece, 0.5, {
x: rightBlock.x + offsetX[color],
y: rightBlock.y + offsetY[color],
angle: angle || piece.angle,
......@@ -799,7 +799,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
const angle = this._getAngleByTargetPos();
await asyncTweenTo(
node,
0.3,
0.5,
{ x: touchStartPos.nodeX, y: touchStartPos.nodeY , angle: angle || node.angle},
{ easing: "cubicOut" }
);
......@@ -1459,14 +1459,14 @@ export default class SceneComponent extends MyCocosSceneComponent {
dice["cantRoll"] = true;
cc.tween(dice)
.by(1.5, { angle: 360 }, { easing: "cubicIn" })
.to(time / 2, { angle: targetAngle })
.by(0.5, { angle: 360 })
.by(0.5, { angle: 360 })
.by(0.5, { angle: 360 })
.by(0.5, { angle: 360 })
.by((1 / 6) * num / 2, { angle: 60 * num })
.by(1.5, { angle: 360 }, { easing: "cubicOut" })
.by(0.75, { angle: 360 }, { easing: "cubicIn" })
.to(time / 4, { angle: targetAngle })
.by(0.25, { angle: 360 })
.by(0.25, { angle: 360 })
.by(0.25, { angle: 360 })
.by(0.25, { angle: 360 })
.by((1 / 12) * num / 2, { angle: 60 * num })
.by(0.75, { angle: 360 }, { easing: "cubicOut" })
.call(() => {
dice["cantRoll"] = false;
resolve(null);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment