4 Commits

Author SHA1 Message Date
1e0537b63d refactor(hero): 优化怪物生成位置计算并添加调试日志
- 使用 MonStart 配置计算怪物出生位置,替代硬编码的 MonSet
- 添加 console.log 调试英雄和怪物的 siblingIndex
- 根据 y 坐标动态判断线路,提高代码可读性和可维护性
2025-11-04 11:12:43 +08:00
fc637529e2 地图动画,将英雄位置调整 2025-11-04 11:04:27 +08:00
5c9f299fd7 refactor(hero): 优化英雄缩放逻辑和位置配置
重构英雄缩放逻辑,使用统一的缩放计算方法替代硬编码值
调整英雄和怪物的初始位置坐标
在Hero和Monster类中添加size变量控制缩放
2025-11-04 10:38:20 +08:00
ed1b4f46a4 refactor(game): 删除BezierMove相关元文件并更新英雄和地图资源
- 删除assets/script/game/BezierMove.meta及相关文件
- 新增多个地图动画资源文件(lr.anim, lr2.anim等)
- 调整多个英雄预制体的尺寸和碰撞体参数
- 更新地图预制体(map_rpg.prefab)中的动画配置和节点布局
2025-11-04 10:38:05 +08:00
38 changed files with 2480 additions and 947 deletions

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 80 "height": 100
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1003,13 +1003,13 @@
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -2.8, "x": 0,
"y": 19.2 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 45.2, "width": 60,
"height": 68.4 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 80 "height": 100
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1003,13 +1003,13 @@
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -1.6, "x": 0,
"y": 22.8 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 47.7, "width": 60,
"height": 67.5 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 90 "height": 100
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1003,13 +1003,13 @@
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -1.2, "x": 0,
"y": 22.5 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 48.5, "width": 60,
"height": 70 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 80 "height": 100
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1003,13 +1003,13 @@
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -0.8, "x": 0,
"y": 22.6 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 49.3, "width": 60,
"height": 60.9 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 90 "height": 100
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1003,13 +1003,13 @@
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -1.1, "x": 0,
"y": 29.2 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 48.6, "width": 60,
"height": 76.8 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 60, "width": 60,
"height": 80 "height": 100
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1003,13 +1003,13 @@
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -2, "x": 0,
"y": 21.7 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 46.8, "width": 60,
"height": 63.4 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 90 "height": 10
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1003,13 +1003,13 @@
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -1.1, "x": 0,
"y": 28.3 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 48.6, "width": 60,
"height": 78.4 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -894,12 +894,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 70 "height": 90
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -993,20 +993,20 @@
"__id__": 62 "__id__": 62
}, },
"tag": 0, "tag": 0,
"_group": 2, "_group": 4,
"_density": 1, "_density": 1,
"_sensor": true, "_sensor": true,
"_friction": 0.2, "_friction": 0.2,
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -2, "x": 0,
"y": 18.7 "y": 45
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 46.8, "width": 60,
"height": 64.2 "height": 90
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 70 "height": 80
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -996,20 +996,20 @@
"__id__": 62 "__id__": 62
}, },
"tag": 0, "tag": 0,
"_group": 2, "_group": 4,
"_density": 1, "_density": 1,
"_sensor": true, "_sensor": true,
"_friction": 0.2, "_friction": 0.2,
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -2.4, "x": 0,
"y": 18 "y": 40
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 46, "width": 60,
"height": 55.9 "height": 80
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -897,12 +897,12 @@
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 80, "width": 80,
"height": 80 "height": 100
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.2 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -996,20 +996,20 @@
"__id__": 62 "__id__": 62
}, },
"tag": 0, "tag": 0,
"_group": 2, "_group": 4,
"_density": 1, "_density": 1,
"_sensor": true, "_sensor": true,
"_friction": 0.2, "_friction": 0.2,
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -1.3, "x": 0,
"y": 22.9 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 48.6, "width": 60,
"height": 64.2 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -154,8 +154,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 128, "width": 192,
"height": 128 "height": 192
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
@@ -902,7 +902,7 @@
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.15 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -996,20 +996,20 @@
"__id__": 62 "__id__": 62
}, },
"tag": 0, "tag": 0,
"_group": 2, "_group": 4,
"_density": 1, "_density": 1,
"_sensor": true, "_sensor": true,
"_friction": 0.2, "_friction": 0.2,
"_restitution": 0, "_restitution": 0,
"_offset": { "_offset": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": -3.2, "x": 0,
"y": 27.5 "y": 50
}, },
"_size": { "_size": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 52.9, "width": 60,
"height": 80.1 "height": 100
}, },
"_id": "" "_id": ""
}, },

View File

@@ -0,0 +1,246 @@
[
{
"__type__": "cc.AnimationClip",
"_name": "lr",
"_objFlags": 0,
"__editorExtras__": {
"embeddedPlayerGroups": []
},
"_native": "",
"sample": 15,
"speed": 1,
"wrapMode": 2,
"enableTrsBlending": false,
"_duration": 5.333333333333333,
"_hash": 500763545,
"_tracks": [
{
"__id__": 1
}
],
"_exoticAnimation": null,
"_events": [],
"_embeddedPlayers": [],
"_additiveSettings": {
"__id__": 11
},
"_auxiliaryCurveEntries": []
},
{
"__type__": "cc.animation.VectorTrack",
"_binding": {
"__type__": "cc.animation.TrackBinding",
"path": {
"__id__": 2
},
"proxy": null
},
"_channels": [
{
"__id__": 3
},
{
"__id__": 5
},
{
"__id__": 7
},
{
"__id__": 9
}
],
"_nComponents": 3
},
{
"__type__": "cc.animation.TrackPath",
"_paths": [
"position"
]
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 4
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
2.6666666666666665,
5.333333333333333
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -0.7820000052452087,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 4.2179999351501465,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -0.7820000052452087,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 6
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
2.6666666666666665,
5.333333333333333
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 61.987998962402344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 61.987998962402344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 61.987998962402344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 8
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
2.6666666666666665,
5.333333333333333
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 10
}
},
{
"__type__": "cc.RealCurve",
"_times": [],
"_values": [],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.AnimationClipAdditiveSettings",
"enabled": false,
"refClip": null
}
]

View File

@@ -0,0 +1,13 @@
{
"ver": "2.0.3",
"importer": "animation-clip",
"imported": true,
"uuid": "c6a6bc5a-9f6d-404d-947f-e90df0e4d909",
"files": [
".cconb"
],
"subMetas": {},
"userData": {
"name": "lr"
}
}

View File

@@ -0,0 +1,246 @@
[
{
"__type__": "cc.AnimationClip",
"_name": "lr2",
"_objFlags": 0,
"__editorExtras__": {
"embeddedPlayerGroups": []
},
"_native": "",
"sample": 15,
"speed": 1,
"wrapMode": 2,
"enableTrsBlending": false,
"_duration": 5.333333333333333,
"_hash": 500763545,
"_tracks": [
{
"__id__": 1
}
],
"_exoticAnimation": null,
"_events": [],
"_embeddedPlayers": [],
"_additiveSettings": {
"__id__": 11
},
"_auxiliaryCurveEntries": []
},
{
"__type__": "cc.animation.VectorTrack",
"_binding": {
"__type__": "cc.animation.TrackBinding",
"path": {
"__id__": 2
},
"proxy": null
},
"_channels": [
{
"__id__": 3
},
{
"__id__": 5
},
{
"__id__": 7
},
{
"__id__": 9
}
],
"_nComponents": 3
},
{
"__type__": "cc.animation.TrackPath",
"_paths": [
"position"
]
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 4
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
2.6666666666666665,
5.333333333333333
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -0.7820000052452087,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -3.7820000648498535,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -0.7820000052452087,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 6
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
2.6666666666666665,
5.333333333333333
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 61.987998962402344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 61.987998962402344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 61.987998962402344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 8
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
2.6666666666666665,
5.333333333333333
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 10
}
},
{
"__type__": "cc.RealCurve",
"_times": [],
"_values": [],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.AnimationClipAdditiveSettings",
"enabled": false,
"refClip": null
}
]

View File

@@ -0,0 +1,13 @@
{
"ver": "2.0.3",
"importer": "animation-clip",
"imported": true,
"uuid": "c525e212-96b0-4977-9d73-a57d3cf396f4",
"files": [
".cconb"
],
"subMetas": {},
"userData": {
"name": "lr2"
}
}

View File

@@ -0,0 +1,291 @@
[
{
"__type__": "cc.AnimationClip",
"_name": "lr3",
"_objFlags": 0,
"__editorExtras__": {
"embeddedPlayerGroups": []
},
"_native": "",
"sample": 5,
"speed": 1,
"wrapMode": 2,
"enableTrsBlending": false,
"_duration": 24,
"_hash": 500763545,
"_tracks": [
{
"__id__": 1
}
],
"_exoticAnimation": null,
"_events": [],
"_embeddedPlayers": [],
"_additiveSettings": {
"__id__": 11
},
"_auxiliaryCurveEntries": []
},
{
"__type__": "cc.animation.VectorTrack",
"_binding": {
"__type__": "cc.animation.TrackBinding",
"path": {
"__id__": 2
},
"proxy": null
},
"_channels": [
{
"__id__": 3
},
{
"__id__": 5
},
{
"__id__": 7
},
{
"__id__": 9
}
],
"_nComponents": 3
},
{
"__type__": "cc.animation.TrackPath",
"_paths": [
"position"
]
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 4
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
12,
19.8,
24
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -422.0780029296875,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -422.0780029296875,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 91.625732421875,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 420.9230041503906,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 6
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
12,
19.8,
24
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 99.77200317382812,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 99.77200317382812,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 99.77200317382812,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 99.77200317382812,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 8
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
12,
19.8,
24
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 10
}
},
{
"__type__": "cc.RealCurve",
"_times": [],
"_values": [],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.AnimationClipAdditiveSettings",
"enabled": false,
"refClip": null
}
]

View File

@@ -0,0 +1,13 @@
{
"ver": "2.0.3",
"importer": "animation-clip",
"imported": true,
"uuid": "c31b3fc6-b326-42f0-9680-a76de510e2e4",
"files": [
".cconb"
],
"subMetas": {},
"userData": {
"name": "lr3"
}
}

View File

@@ -0,0 +1,252 @@
[
{
"__type__": "cc.AnimationClip",
"_name": "lr4",
"_objFlags": 0,
"__editorExtras__": {
"embeddedPlayerGroups": []
},
"_native": "",
"sample": 5,
"speed": 1,
"wrapMode": 2,
"enableTrsBlending": false,
"_duration": 20,
"_hash": 500763545,
"_tracks": [
{
"__id__": 1
}
],
"_exoticAnimation": null,
"_events": [],
"_embeddedPlayers": [],
"_additiveSettings": {
"__id__": 11
},
"_auxiliaryCurveEntries": []
},
{
"__type__": "cc.animation.VectorTrack",
"_binding": {
"__type__": "cc.animation.TrackBinding",
"path": {
"__id__": 2
},
"proxy": null
},
"_channels": [
{
"__id__": 3
},
{
"__id__": 5
},
{
"__id__": 7
},
{
"__id__": 9
}
],
"_nComponents": 3
},
{
"__type__": "cc.animation.TrackPath",
"_paths": [
"position"
]
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 4
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
12,
20
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -419.2349853515625,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 89.82899475097656,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 429.2049865722656,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 6
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
12,
20
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 152.56700134277344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 152.56700134277344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 152.56700134277344,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 8
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
12,
20
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"broken": null
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 10
}
},
{
"__type__": "cc.RealCurve",
"_times": [],
"_values": [],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.AnimationClipAdditiveSettings",
"enabled": false,
"refClip": null
}
]

View File

@@ -0,0 +1,13 @@
{
"ver": "2.0.3",
"importer": "animation-clip",
"imported": true,
"uuid": "755c82ed-e604-41c3-8944-c6c7df6dc089",
"files": [
".cconb"
],
"subMetas": {},
"userData": {
"name": "lr4"
}
}

View File

@@ -0,0 +1,214 @@
[
{
"__type__": "cc.AnimationClip",
"_name": "map",
"_objFlags": 0,
"__editorExtras__": {
"embeddedPlayerGroups": []
},
"_native": "",
"sample": 10,
"speed": 1,
"wrapMode": 2,
"enableTrsBlending": false,
"_duration": 9.9,
"_hash": 500763545,
"_tracks": [
{
"__id__": 1
}
],
"_exoticAnimation": null,
"_events": [],
"_embeddedPlayers": [],
"_additiveSettings": {
"__id__": 12
},
"_auxiliaryCurveEntries": []
},
{
"__type__": "cc.animation.VectorTrack",
"_binding": {
"__type__": "cc.animation.TrackBinding",
"path": {
"__id__": 2
},
"proxy": null
},
"_channels": [
{
"__id__": 4
},
{
"__id__": 6
},
{
"__id__": 8
},
{
"__id__": 10
}
],
"_nComponents": 3
},
{
"__type__": "cc.animation.TrackPath",
"_paths": [
{
"__id__": 3
},
"position"
]
},
{
"__type__": "cc.animation.HierarchyPath",
"path": "2l3_clouds"
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 5
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
9.9
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -422.078,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 397.518,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 7
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
9.9
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 99.772,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 99.772,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 9
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
9.9
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": null
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 11
}
},
{
"__type__": "cc.RealCurve",
"_times": [],
"_values": [],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.AnimationClipAdditiveSettings",
"enabled": false,
"refClip": null
}
]

View File

@@ -0,0 +1,13 @@
{
"ver": "2.0.3",
"importer": "animation-clip",
"imported": true,
"uuid": "e5523482-12c7-46ed-8a1a-1e6b84baa92e",
"files": [
".cconb"
],
"subMetas": {},
"userData": {
"name": "map"
}
}

View File

@@ -28,17 +28,17 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 94 "__id__": 110
}, },
{ {
"__id__": 96 "__id__": 112
}, },
{ {
"__id__": 98 "__id__": 114
} }
], ],
"_prefab": { "_prefab": {
"__id__": 100 "__id__": 116
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -197,17 +197,17 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 87 "__id__": 103
}, },
{ {
"__id__": 89 "__id__": 105
}, },
{ {
"__id__": 91 "__id__": 107
} }
], ],
"_prefab": { "_prefab": {
"__id__": 93 "__id__": 109
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -251,23 +251,23 @@
"__id__": 8 "__id__": 8
}, },
{ {
"__id__": 68 "__id__": 84
}, },
{ {
"__id__": 72 "__id__": 88
}, },
{ {
"__id__": 78 "__id__": 94
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 84 "__id__": 100
} }
], ],
"_prefab": { "_prefab": {
"__id__": 86 "__id__": 102
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -314,14 +314,14 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 63 "__id__": 79
}, },
{ {
"__id__": 65 "__id__": 81
} }
], ],
"_prefab": { "_prefab": {
"__id__": 67 "__id__": 83
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -365,20 +365,20 @@
"__id__": 10 "__id__": 10
}, },
{ {
"__id__": 52 "__id__": 68
}, },
{ {
"__id__": 56 "__id__": 72
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 60 "__id__": 76
} }
], ],
"_prefab": { "_prefab": {
"__id__": 62 "__id__": 78
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -431,25 +431,31 @@
"__id__": 31 "__id__": 31
}, },
{ {
"__id__": 37 "__id__": 39
}, },
{ {
"__id__": 43 "__id__": 47
},
{
"__id__": 55
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 49 "__id__": 63
},
{
"__id__": 65
} }
], ],
"_prefab": { "_prefab": {
"__id__": 51 "__id__": 67
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
"x": 0, "x": 0,
"y": 50, "y": 60,
"z": 0 "z": 0
}, },
"_lrot": { "_lrot": {
@@ -461,8 +467,8 @@
}, },
"_lscale": { "_lscale": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
"x": 0.8, "x": 1.1,
"y": 0.8, "y": 1.1,
"z": 1 "z": 1
}, },
"_mobility": 0, "_mobility": 0,
@@ -749,7 +755,7 @@
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "2l3_clouds", "_name": "2l3_clouds-001",
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"_parent": { "_parent": {
@@ -773,8 +779,8 @@
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
"x": -549.066, "x": -400.627,
"y": 204.558, "y": 152.567,
"z": 0 "z": 0
}, },
"_lrot": { "_lrot": {
@@ -826,7 +832,7 @@
}, },
{ {
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "1dUTzFSqBLApMkxtNTF4sU" "fileId": "02ZQp8CUZAlIW4zoRY8Qyn"
}, },
{ {
"__type__": "cc.Sprite", "__type__": "cc.Sprite",
@@ -871,10 +877,10 @@
}, },
{ {
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "122kjHp3NGw7w4oXqaHutJ" "fileId": "feOn3xrWJPSL25rn5PBJot"
}, },
{ {
"__type__": "c6876fGUVRN4pfliVp2+fjq", "__type__": "cc.Animation",
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
@@ -885,16 +891,22 @@
"__prefab": { "__prefab": {
"__id__": 29 "__id__": 29
}, },
"speed": 2, "playOnLoad": true,
"maxX": 550, "_clips": [
"minX": -490, {
"sc": 2, "__uuid__": "755c82ed-e604-41c3-8944-c6c7df6dc089",
"isMove": true, "__expectedType__": "cc.AnimationClip"
}
],
"_defaultClip": {
"__uuid__": "755c82ed-e604-41c3-8944-c6c7df6dc089",
"__expectedType__": "cc.AnimationClip"
},
"_id": "" "_id": ""
}, },
{ {
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "e6RsHZsEhGeZnju879Cnhr" "fileId": "53C49x9kdCIq9J3gVbu2qO"
}, },
{ {
"__type__": "cc.PrefabInfo", "__type__": "cc.PrefabInfo",
@@ -904,7 +916,7 @@
"asset": { "asset": {
"__id__": 0 "__id__": 0
}, },
"fileId": "fe+y6cqGNEyKFqyFbuq1WZ", "fileId": "91kVmL7qdMxry51cnTzQHO",
"instance": null, "instance": null,
"targetOverrides": null, "targetOverrides": null,
"nestedPrefabInstanceRoots": null "nestedPrefabInstanceRoots": null
@@ -925,14 +937,17 @@
}, },
{ {
"__id__": 34 "__id__": 34
},
{
"__id__": 36
} }
], ],
"_prefab": { "_prefab": {
"__id__": 36 "__id__": 38
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
"x": 0, "x": -0.782,
"y": 61.988, "y": 61.988,
"z": 0 "z": 0
}, },
@@ -1032,6 +1047,35 @@
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "a7ze9z73tEnIuHmyeUi2AG" "fileId": "a7ze9z73tEnIuHmyeUi2AG"
}, },
{
"__type__": "cc.Animation",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 31
},
"_enabled": true,
"__prefab": {
"__id__": 37
},
"playOnLoad": true,
"_clips": [
{
"__uuid__": "c525e212-96b0-4977-9d73-a57d3cf396f4",
"__expectedType__": "cc.AnimationClip"
}
],
"_defaultClip": {
"__uuid__": "c525e212-96b0-4977-9d73-a57d3cf396f4",
"__expectedType__": "cc.AnimationClip"
},
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "deA+FHQJhLC46JSTxs5SbB"
},
{ {
"__type__": "cc.PrefabInfo", "__type__": "cc.PrefabInfo",
"root": { "root": {
@@ -1057,14 +1101,17 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 38 "__id__": 40
}, },
{ {
"__id__": 40 "__id__": 42
},
{
"__id__": 44
} }
], ],
"_prefab": { "_prefab": {
"__id__": 42 "__id__": 46
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -1101,11 +1148,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 37 "__id__": 39
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 39 "__id__": 41
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1129,11 +1176,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 37 "__id__": 39
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 41 "__id__": 43
}, },
"_customMaterial": null, "_customMaterial": null,
"_srcBlendFactor": 2, "_srcBlendFactor": 2,
@@ -1168,6 +1215,35 @@
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "04OMvturJDAY/YvkWePasX" "fileId": "04OMvturJDAY/YvkWePasX"
}, },
{
"__type__": "cc.Animation",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 39
},
"_enabled": true,
"__prefab": {
"__id__": 45
},
"playOnLoad": true,
"_clips": [
{
"__uuid__": "c6a6bc5a-9f6d-404d-947f-e90df0e4d909",
"__expectedType__": "cc.AnimationClip"
}
],
"_defaultClip": {
"__uuid__": "c6a6bc5a-9f6d-404d-947f-e90df0e4d909",
"__expectedType__": "cc.AnimationClip"
},
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "5eaZNiIatN/qDKSC5r14e3"
},
{ {
"__type__": "cc.PrefabInfo", "__type__": "cc.PrefabInfo",
"root": { "root": {
@@ -1183,7 +1259,7 @@
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "2l6_ground", "_name": "2l3_clouds",
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"_parent": { "_parent": {
@@ -1193,19 +1269,22 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 44 "__id__": 48
}, },
{ {
"__id__": 46 "__id__": 50
},
{
"__id__": 52
} }
], ],
"_prefab": { "_prefab": {
"__id__": 48 "__id__": 54
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
"x": 0, "x": -422.078,
"y": 20, "y": 99.772,
"z": 0 "z": 0
}, },
"_lrot": { "_lrot": {
@@ -1237,11 +1316,179 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 43 "__id__": 47
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 45 "__id__": 49
},
"_contentSize": {
"__type__": "cc.Size",
"width": 502,
"height": 86
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "1dUTzFSqBLApMkxtNTF4sU"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 47
},
"_enabled": true,
"__prefab": {
"__id__": 51
},
"_customMaterial": null,
"_srcBlendFactor": 2,
"_dstBlendFactor": 4,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_spriteFrame": {
"__uuid__": "3752062a-bfde-4ec3-a6fe-8739612cbe58@df9b5",
"__expectedType__": "cc.SpriteFrame"
},
"_type": 0,
"_fillType": 0,
"_sizeMode": 1,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_useGrayscale": false,
"_atlas": null,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "122kjHp3NGw7w4oXqaHutJ"
},
{
"__type__": "cc.Animation",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 47
},
"_enabled": true,
"__prefab": {
"__id__": 53
},
"playOnLoad": true,
"_clips": [
{
"__uuid__": "c31b3fc6-b326-42f0-9680-a76de510e2e4",
"__expectedType__": "cc.AnimationClip"
}
],
"_defaultClip": {
"__uuid__": "c31b3fc6-b326-42f0-9680-a76de510e2e4",
"__expectedType__": "cc.AnimationClip"
},
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "d4yMBizrdCS5yUgGgmgBBK"
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__id__": 0
},
"fileId": "fe+y6cqGNEyKFqyFbuq1WZ",
"instance": null,
"targetOverrides": null,
"nestedPrefabInstanceRoots": null
},
{
"__type__": "cc.Node",
"_name": "2l6_ground",
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 10
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 56
},
{
"__id__": 58
},
{
"__id__": 60
}
],
"_prefab": {
"__id__": 62
},
"_lpos": {
"__type__": "cc.Vec3",
"x": 0,
"y": -67.366,
"z": 0
},
"_lrot": {
"__type__": "cc.Quat",
"x": 0,
"y": 0,
"z": 0,
"w": 1
},
"_lscale": {
"__type__": "cc.Vec3",
"x": 1,
"y": 1,
"z": 1
},
"_mobility": 0,
"_layer": 1,
"_euler": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_id": ""
},
{
"__type__": "cc.UITransform",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 55
},
"_enabled": true,
"__prefab": {
"__id__": 57
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1251,7 +1498,7 @@
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
"x": 0.5, "x": 0.5,
"y": 0.5 "y": 0
}, },
"_id": "" "_id": ""
}, },
@@ -1265,11 +1512,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 43 "__id__": 55
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 47 "__id__": 59
}, },
"_customMaterial": null, "_customMaterial": null,
"_srcBlendFactor": 2, "_srcBlendFactor": 2,
@@ -1304,6 +1551,35 @@
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "9fXxAjsMJMIpTZEsYPi/dD" "fileId": "9fXxAjsMJMIpTZEsYPi/dD"
}, },
{
"__type__": "cc.Animation",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 55
},
"_enabled": true,
"__prefab": {
"__id__": 61
},
"playOnLoad": false,
"_clips": [
{
"__uuid__": "d3639e74-7140-40f1-b3c2-30d6326337d9",
"__expectedType__": "cc.AnimationClip"
}
],
"_defaultClip": {
"__uuid__": "d3639e74-7140-40f1-b3c2-30d6326337d9",
"__expectedType__": "cc.AnimationClip"
},
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "e8PwYczw5KvrbceFLazVrX"
},
{ {
"__type__": "cc.PrefabInfo", "__type__": "cc.PrefabInfo",
"root": { "root": {
@@ -1327,7 +1603,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 50 "__id__": 64
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1345,6 +1621,27 @@
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "2ezXyOm7ZMK64/C8po79GA" "fileId": "2ezXyOm7ZMK64/C8po79GA"
}, },
{
"__type__": "cc.Animation",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 10
},
"_enabled": true,
"__prefab": {
"__id__": 66
},
"playOnLoad": true,
"_clips": [],
"_defaultClip": null,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "b6BtRdPK1JMLEV3OhYQH0E"
},
{ {
"__type__": "cc.PrefabInfo", "__type__": "cc.PrefabInfo",
"root": { "root": {
@@ -1370,11 +1667,11 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 53 "__id__": 69
} }
], ],
"_prefab": { "_prefab": {
"__id__": 55 "__id__": 71
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -1411,11 +1708,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 52 "__id__": 68
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 54 "__id__": 70
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1458,11 +1755,11 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 57 "__id__": 73
} }
], ],
"_prefab": { "_prefab": {
"__id__": 59 "__id__": 75
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -1499,11 +1796,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 56 "__id__": 72
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 58 "__id__": 74
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1544,7 +1841,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 61 "__id__": 77
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1585,7 +1882,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 64 "__id__": 80
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1613,7 +1910,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 66 "__id__": 82
}, },
"bgImg": null, "bgImg": null,
"_id": "" "_id": ""
@@ -1647,11 +1944,11 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 69 "__id__": 85
} }
], ],
"_prefab": { "_prefab": {
"__id__": 71 "__id__": 87
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -1688,11 +1985,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 68 "__id__": 84
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 70 "__id__": 86
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1735,14 +2032,14 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 73 "__id__": 89
}, },
{ {
"__id__": 75 "__id__": 91
} }
], ],
"_prefab": { "_prefab": {
"__id__": 77 "__id__": 93
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -1779,11 +2076,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 72 "__id__": 88
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 74 "__id__": 90
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1807,11 +2104,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 72 "__id__": 88
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 76 "__id__": 92
}, },
"_id": "" "_id": ""
}, },
@@ -1844,14 +2141,14 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 79 "__id__": 95
}, },
{ {
"__id__": 81 "__id__": 97
} }
], ],
"_prefab": { "_prefab": {
"__id__": 83 "__id__": 99
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -1888,11 +2185,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 78 "__id__": 94
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 80 "__id__": 96
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1916,11 +2213,11 @@
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {}, "__editorExtras__": {},
"node": { "node": {
"__id__": 78 "__id__": 94
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 82 "__id__": 98
}, },
"light": null, "light": null,
"_id": "" "_id": ""
@@ -1952,7 +2249,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 85 "__id__": 101
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -1993,7 +2290,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 88 "__id__": 104
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -2021,7 +2318,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 90 "__id__": 106
}, },
"camera": { "camera": {
"__id__": 3 "__id__": 3
@@ -2030,16 +2327,16 @@
"__id__": 7 "__id__": 7
}, },
"mapLayer": { "mapLayer": {
"__id__": 65 "__id__": 81
}, },
"floorLayer": { "floorLayer": {
"__id__": 68 "__id__": 84
}, },
"entityLayer": { "entityLayer": {
"__id__": 75 "__id__": 91
}, },
"SkillLayer": { "SkillLayer": {
"__id__": 81 "__id__": 97
}, },
"isFollowPlayer": true, "isFollowPlayer": true,
"_id": "" "_id": ""
@@ -2058,7 +2355,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 92 "__id__": 108
}, },
"_id": "" "_id": ""
}, },
@@ -2089,7 +2386,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 95 "__id__": 111
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
@@ -2117,7 +2414,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 97 "__id__": 113
}, },
"_cameraComponent": { "_cameraComponent": {
"__id__": 3 "__id__": 3
@@ -2139,7 +2436,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 99 "__id__": 115
}, },
"_alignFlags": 45, "_alignFlags": 45,
"_target": null, "_target": null,

View File

@@ -0,0 +1,575 @@
[
{
"__type__": "cc.AnimationClip",
"_name": "zd",
"_objFlags": 0,
"__editorExtras__": {
"embeddedPlayerGroups": []
},
"_native": "",
"sample": 10,
"speed": 1,
"wrapMode": 2,
"enableTrsBlending": false,
"_duration": 0.3,
"_hash": 500763545,
"_tracks": [
{
"__id__": 1
},
{
"__id__": 11
}
],
"_exoticAnimation": null,
"_events": [],
"_embeddedPlayers": [],
"_additiveSettings": {
"__id__": 21
},
"_auxiliaryCurveEntries": []
},
{
"__type__": "cc.animation.VectorTrack",
"_binding": {
"__type__": "cc.animation.TrackBinding",
"path": {
"__id__": 2
},
"proxy": null
},
"_channels": [
{
"__id__": 3
},
{
"__id__": 5
},
{
"__id__": 7
},
{
"__id__": 9
}
],
"_nComponents": 3
},
{
"__type__": "cc.animation.TrackPath",
"_paths": [
"position"
]
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 4
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
0.1,
0.2,
0.3
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 6
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
0.1,
0.2,
0.3
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -67.366,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -66.366,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -67.366,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": -68.366,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 8
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
0.1,
0.2,
0.3
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 0,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 10
}
},
{
"__type__": "cc.RealCurve",
"_times": [],
"_values": [],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.VectorTrack",
"_binding": {
"__type__": "cc.animation.TrackBinding",
"path": {
"__id__": 12
},
"proxy": null
},
"_channels": [
{
"__id__": 13
},
{
"__id__": 15
},
{
"__id__": 17
},
{
"__id__": 19
}
],
"_nComponents": 3
},
{
"__type__": "cc.animation.TrackPath",
"_paths": [
"scale"
]
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 14
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
0.1,
0.2,
0.3
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1.01,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 16
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
0.1,
0.2,
0.3
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1.01,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 18
}
},
{
"__type__": "cc.RealCurve",
"_times": [
0,
0.1,
0.2,
0.3
],
"_values": [
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
},
{
"__type__": "cc.RealKeyframeValue",
"interpolationMode": 0,
"tangentWeightMode": 0,
"value": 1,
"rightTangent": 0,
"rightTangentWeight": 1,
"leftTangent": 0,
"leftTangentWeight": 1,
"easingMethod": 0,
"__editorExtras__": {
"tangentMode": 0
}
}
],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.animation.Channel",
"_curve": {
"__id__": 20
}
},
{
"__type__": "cc.RealCurve",
"_times": [],
"_values": [],
"preExtrapolation": 1,
"postExtrapolation": 1
},
{
"__type__": "cc.AnimationClipAdditiveSettings",
"enabled": false,
"refClip": null
}
]

View File

@@ -0,0 +1,13 @@
{
"ver": "2.0.3",
"importer": "animation-clip",
"imported": true,
"uuid": "d3639e74-7140-40f1-b3c2-30d6326337d9",
"files": [
".cconb"
],
"subMetas": {},
"userData": {
"name": "zd"
}
}

View File

@@ -337,6 +337,7 @@
"__type__": "57aabs7TE1J5obTAZczc+64", "__type__": "57aabs7TE1J5obTAZczc+64",
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"__editorExtras__": {},
"node": { "node": {
"__id__": 1 "__id__": 1
}, },
@@ -346,7 +347,7 @@
}, },
"atk_x": 0, "atk_x": 0,
"atk_y": 0, "atk_y": 0,
"_id": "a1y6MJDfVD1o+ESVz7sAtv" "_id": ""
}, },
{ {
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",

View File

@@ -41,13 +41,10 @@
}, },
{ {
"__id__": 22 "__id__": 22
},
{
"__id__": 24
} }
], ],
"_prefab": { "_prefab": {
"__id__": 26 "__id__": 24
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -430,40 +427,6 @@
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "60LInmZXxDtKu79AshRG9j" "fileId": "60LInmZXxDtKu79AshRG9j"
}, },
{
"__type__": "f680dkagx9PmbfqtF463/Ua",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 1
},
"_enabled": true,
"__prefab": {
"__id__": 21
},
"speed": 600,
"controlPointSide": 1,
"controlPointOffset": 0.5,
"controlPointRandomness": 0.3,
"autoRotate": false,
"showTrajectory": false,
"trajectoryColor": {
"__type__": "cc.Color",
"r": 0,
"g": 255,
"b": 0,
"a": 255
},
"trajectoryWidth": 3,
"easing": "linear",
"rotationSmoothness": 0.6,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "65YLwe9t9EXo5kI3HQEGhs"
},
{ {
"__type__": "cc.RigidBody2D", "__type__": "cc.RigidBody2D",
"_name": "", "_name": "",
@@ -474,7 +437,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 23 "__id__": 21
}, },
"enabledContactListener": true, "enabledContactListener": true,
"bullet": false, "bullet": false,
@@ -508,7 +471,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 25 "__id__": 23
}, },
"tag": 0, "tag": 0,
"_group": 1, "_group": 1,

View File

@@ -41,13 +41,10 @@
}, },
{ {
"__id__": 22 "__id__": 22
},
{
"__id__": 24
} }
], ],
"_prefab": { "_prefab": {
"__id__": 26 "__id__": 24
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -433,40 +430,6 @@
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "60LInmZXxDtKu79AshRG9j" "fileId": "60LInmZXxDtKu79AshRG9j"
}, },
{
"__type__": "f680dkagx9PmbfqtF463/Ua",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 1
},
"_enabled": true,
"__prefab": {
"__id__": 21
},
"speed": 600,
"controlPointSide": 1,
"controlPointOffset": 0.5,
"controlPointRandomness": 0.3,
"autoRotate": false,
"showTrajectory": false,
"trajectoryColor": {
"__type__": "cc.Color",
"r": 0,
"g": 255,
"b": 0,
"a": 255
},
"trajectoryWidth": 3,
"easing": "linear",
"rotationSmoothness": 0.6,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "65YLwe9t9EXo5kI3HQEGhs"
},
{ {
"__type__": "cc.RigidBody2D", "__type__": "cc.RigidBody2D",
"_name": "", "_name": "",
@@ -477,7 +440,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 23 "__id__": 21
}, },
"enabledContactListener": true, "enabledContactListener": true,
"bullet": false, "bullet": false,
@@ -511,7 +474,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 25 "__id__": 23
}, },
"tag": 0, "tag": 0,
"_group": 1, "_group": 1,

View File

@@ -41,13 +41,10 @@
}, },
{ {
"__id__": 22 "__id__": 22
},
{
"__id__": 24
} }
], ],
"_prefab": { "_prefab": {
"__id__": 26 "__id__": 24
}, },
"_lpos": { "_lpos": {
"__type__": "cc.Vec3", "__type__": "cc.Vec3",
@@ -433,40 +430,6 @@
"__type__": "cc.CompPrefabInfo", "__type__": "cc.CompPrefabInfo",
"fileId": "60LInmZXxDtKu79AshRG9j" "fileId": "60LInmZXxDtKu79AshRG9j"
}, },
{
"__type__": "f680dkagx9PmbfqtF463/Ua",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 1
},
"_enabled": true,
"__prefab": {
"__id__": 21
},
"speed": 600,
"controlPointSide": 1,
"controlPointOffset": 0.5,
"controlPointRandomness": 0.3,
"autoRotate": false,
"showTrajectory": false,
"trajectoryColor": {
"__type__": "cc.Color",
"r": 0,
"g": 255,
"b": 0,
"a": 255
},
"trajectoryWidth": 3,
"easing": "linear",
"rotationSmoothness": 0.6,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "65YLwe9t9EXo5kI3HQEGhs"
},
{ {
"__type__": "cc.RigidBody2D", "__type__": "cc.RigidBody2D",
"_name": "", "_name": "",
@@ -477,7 +440,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 23 "__id__": 21
}, },
"enabledContactListener": true, "enabledContactListener": true,
"bullet": false, "bullet": false,
@@ -511,7 +474,7 @@
}, },
"_enabled": true, "_enabled": true,
"__prefab": { "__prefab": {
"__id__": 25 "__id__": 23
}, },
"tag": 0, "tag": 0,
"_group": 1, "_group": 1,

View File

@@ -1,9 +0,0 @@
{
"ver": "1.2.0",
"importer": "directory",
"imported": true,
"uuid": "6c227a87-4bae-4eb8-b109-39b5444eb904",
"files": [],
"subMetas": {},
"userData": {}
}

View File

@@ -1,572 +0,0 @@
import { _decorator, Component, Node, view, UITransform, Vec3, math, EventHandler, Graphics, Color, TweenEasing, Enum } from 'cc';
import { smc } from '../common/SingletonModuleComp';
const { ccclass, property } = _decorator;
// 定义缓动类型枚举
export enum EasingType {
linear = 'linear',
smooth = 'smooth',
fade = 'fade',
quadIn = 'quadIn',
quadOut = 'quadOut',
quadInOut = 'quadInOut',
quadOutIn = 'quadOutIn',
cubicIn = 'cubicIn',
cubicOut = 'cubicOut',
cubicInOut = 'cubicInOut',
cubicOutIn = 'cubicOutIn',
quartIn = 'quartIn',
quartOut = 'quartOut',
quartInOut = 'quartInOut',
quartOutIn = 'quartOutIn',
quintIn = 'quintIn',
quintOut = 'quintOut',
quintInOut = 'quintInOut',
quintOutIn = 'quintOutIn',
sineIn = 'sineIn',
sineOut = 'sineOut',
sineInOut = 'sineInOut',
sineOutIn = 'sineOutIn',
expoIn = 'expoIn',
expoOut = 'expoOut',
expoInOut = 'expoInOut',
expoOutIn = 'expoOutIn',
circIn = 'circIn',
circOut = 'circOut',
circInOut = 'circInOut',
circOutIn = 'circOutIn',
elasticIn = 'elasticIn',
elasticOut = 'elasticOut',
elasticInOut = 'elasticInOut',
elasticOutIn = 'elasticOutIn',
backIn = 'backIn',
backOut = 'backOut',
backInOut = 'backInOut',
backOutIn = 'backOutIn',
bounceIn = 'bounceIn',
bounceOut = 'bounceOut',
bounceInOut = 'bounceInOut',
bounceOutIn = 'bounceOutIn',
}
export enum ControlPointSideType {
Left = 1,
Right = -1,
Random = 0,
}
@ccclass('BezierMove')
export class BezierMove extends Component {
@property({ displayName: '速度' })
speed: number = 600; // 移动速度,单位:像素/秒
@property({ displayName: '控制点方向', tooltip: '0=随机, 1=左侧,-1=右侧(相对于从起点到终点的方向)' })
controlPointSide: ControlPointSideType = ControlPointSideType.Left; // 控制点位置0=随机1=左侧,-1=右侧(相对于从起点到终点的方向)
@property({ displayName: '控制点偏移系数', tooltip: '0~1之间,控制点偏移系数,值越大曲线越弯曲' })
controlPointOffset: number = 0.5; // 控制点偏移系数,值越大曲线越弯曲
@property({ displayName: '控制点随机性', tooltip: '0~1之间,控制点随机性,值越大随机性越强' })
controlPointRandomness: number = 0.3; // 控制点随机性,值越大随机性越强
@property({ displayName: '自动旋转' })
autoRotate: boolean = true; // 是否自动旋转以面向移动方向
@property({ displayName: '显示轨迹' })
showTrajectory: boolean = true; // 是否显示移动轨迹
@property({ displayName: '轨迹颜色' })
trajectoryColor: Color = new Color(0, 255, 0, 255); // 轨迹颜色,默认绿色
@property({ displayName: '轨迹宽度' })
trajectoryWidth: number = 3; // 轨迹宽度
@property({ displayName: '缓动函数', type: Enum(EasingType) })
easing: TweenEasing = EasingType.linear; // 缓动效果类型,默认为线性
@property({ displayName: '角度平滑系数', tooltip: '0~1之间,值越小旋转越平滑,0表示不旋转,1表示立即旋转' })
rotationSmoothness: number = 0.6; // 角度平滑系数,值越小旋转越平滑
private _graphics: Graphics | null = null; // Graphics组件引用
private _currentAngle: number = 0; // 当前角度
private _startPoint: Vec3 = new Vec3();
private _endPoint: Vec3 = new Vec3();
private _controlPoint: Vec3 = new Vec3();
private _t: number = 0; // Bezier曲线参数 (0 到 1)
private _totalTime: number = 0; // 完成当前曲线所需的时间
private _isMoving: boolean = false; // 是否正在移动
private _moveEndCallback: Function = null; // 移动完成回调函数
private _moveEndTarget: any; // 移动完成回调函数的目标对象
private _moveStartCallback: Function = null; // 移动开始回调函数, (totalTime: number) => void
private _moveStartTarget: any; // 移动开始回调函数的目标对象
onEnable() {
// 初始化起点为当前位置
this._startPoint.set(this.node.position);
// 初始化当前角度为节点当前角度
this._currentAngle = this.node.angle;
// 初始化Graphics组件用于绘制轨迹
this._initGraphics();
}
onDisable() {
// 清理Graphics资源
if (this._graphics) {
this._graphics.clear();
// 确保Graphics节点也被销毁
if (this._graphics.node && this._graphics.node.isValid) {
// 查找并销毁与当前实例关联的唯一轨迹节点
const uniqueNodeName = `TrajectoryGraphics_${this.node.uuid}`;
this._graphics.node.destroy();
}
}
}
onMoveComplete(callback: Function, target: any) {
this._moveEndCallback = callback;
this._moveEndTarget = target;
}
onMoveStart(callback: Function, target: any) {
this._moveStartCallback = callback;
this._moveStartTarget = target;
}
update(deltaTime: number) {
if (!this._isMoving || this._totalTime <= 0||smc.mission.pause||!smc.mission.play) return; // 如果没有移动或路径生成失败,则返回
// 更新进度
this._t += deltaTime / this._totalTime;
// 应用缓动效果
let easedT = this._applyEasing(this._t);
if (this._t >= 1.0) {
// 到达终点
this.node.setPosition(this._endPoint);
this._isMoving = false;
// 触发移动完成事件
// console.log("onMoveComplete")
this._moveEndCallback && this._moveEndCallback.apply(this._moveEndTarget);
// 清除轨迹
if (this.showTrajectory && this._graphics) {
this._graphics.clear();
// 确保Graphics节点回到原始父节点
if (this._graphics.node.parent !== this.node) {
const graphicsNode = this._graphics.node;
if (graphicsNode.parent) {
graphicsNode.removeFromParent();
}
this.node.addChild(graphicsNode);
}
}
} else {
// 计算贝塞尔曲线上的当前位置使用缓动后的t值
const currentPos = this._calculateQuadraticBezierPoint(easedT, this._startPoint, this._controlPoint, this._endPoint);
this.node.setPosition(currentPos);
// 如果启用了自动旋转,计算切线(方向)进行旋转
if (this.autoRotate) {
const tangent = this._calculateQuadraticBezierTangent(easedT, this._startPoint, this._controlPoint, this._endPoint);
if (tangent.lengthSqr() > 0.001) { // 避免除以零或NaN角度
// 计算角度。Atan2给出弧度。
// 加90度是因为角度0指向上方在Cocos Creator 2D中沿Y轴
const targetAngle = math.toDegree(Math.atan2(tangent.y, tangent.x)) - 90;
// 使用平滑插值方法计算新角度
this._currentAngle = this._smoothAngle(this._currentAngle, targetAngle, this.rotationSmoothness);
this.node.angle = this._currentAngle;
}
}
}
}
/**
* 移动到指定位置
* @param targetPos 目标位置
*/
public moveTo(targetPos: Vec3): void {
// 设置起点为当前位置
this._startPoint.set(this.node.position);
// 设置终点为目标位置
this._endPoint.set(targetPos);
// 记录当前角度,用于平滑过渡
this._currentAngle = this.node.angle;
// 自动生成控制点
this._generateControlPoint();
// 估算曲线长度以计算总时间
const approxLength = Vec3.distance(this._startPoint, this._controlPoint) + Vec3.distance(this._controlPoint, this._endPoint);
this._totalTime = approxLength / this.speed;
if (this._totalTime < 0.1) { // 确保最小持续时间
this._totalTime = 0.1;
}
// 如果启用了轨迹显示,绘制轨迹
if (this.showTrajectory) {
this._drawTrajectory();
}
// 重置进度并开始移动
this._t = 0;
this._isMoving = true;
this._moveStartCallback && this._moveStartCallback.apply(this._moveStartTarget, [this._totalTime]);
}
/**
* 自动生成控制点
*/
private _generateControlPoint(): void {
// 计算起点和终点的中点
const midPoint = new Vec3();
Vec3.lerp(midPoint, this._startPoint, this._endPoint, 0.5);
// 计算从起点到终点的向量
const direction = new Vec3();
Vec3.subtract(direction, this._endPoint, this._startPoint);
// 计算垂直于方向的向量在2D中交换x和y并取反其中一个
const perpendicular = new Vec3(-direction.y, direction.x, 0);
Vec3.normalize(perpendicular, perpendicular);
// 根据controlPointSide参数决定控制点在哪一侧
let sideMultiplier = 1;
if (this.controlPointSide === ControlPointSideType.Random) {
// 随机选择一侧(与原来的行为一致)
sideMultiplier = Math.random() < 0.5 ? 1 : -1;
} else {
// 使用指定的侧面
sideMultiplier = this.controlPointSide;
}
// 根据控制点偏移系数和随机性计算控制点
const distance = Vec3.distance(this._startPoint, this._endPoint);
const offset = distance * this.controlPointOffset;
const randomFactor = (Math.random() * 2 - 1) * this.controlPointRandomness;
// 设置控制点 = 中点 + 垂直向量 * 偏移 * (1 + 随机因子) * 侧面乘数
this._controlPoint.set(
midPoint.x + perpendicular.x * offset * (1 + randomFactor) * sideMultiplier,
midPoint.y + perpendicular.y * offset * (1 + randomFactor) * sideMultiplier,
0
);
}
/**
* 停止当前移动
*/
stopMoving(): void {
this._isMoving = false;
}
/**
* 计算二次贝塞尔曲线上的点
*/
private _calculateQuadraticBezierPoint(t: number, p0: Vec3, p1: Vec3, p2: Vec3): Vec3 {
const u = 1 - t;
const tt = t * t;
const uu = u * u;
const p = new Vec3();
// p = (u^2 * p0) + (2 * u * t * p1) + (t^2 * p2)
Vec3.multiplyScalar(p, p0, uu);
const temp1 = new Vec3();
Vec3.multiplyScalar(temp1, p1, 2 * u * t);
Vec3.add(p, p, temp1);
const temp2 = new Vec3();
Vec3.multiplyScalar(temp2, p2, tt);
Vec3.add(p, p, temp2);
return p;
}
/**
* 计算二次贝塞尔曲线的切线(导数)
*/
private _calculateQuadraticBezierTangent(t: number, p0: Vec3, p1: Vec3, p2: Vec3): Vec3 {
const u = 1 - t;
const tangent = new Vec3();
// tangent = 2 * (1 - t) * (p1 - p0) + 2 * t * (p2 - p1)
const term1 = new Vec3();
Vec3.subtract(term1, p1, p0);
Vec3.multiplyScalar(term1, term1, 2 * u);
const term2 = new Vec3();
Vec3.subtract(term2, p2, p1);
Vec3.multiplyScalar(term2, term2, 2 * t);
Vec3.add(tangent, term1, term2);
return tangent;
}
/**
* 应用缓动效果到t值
* @param t 原始t值0-1之间
* @returns 应用缓动后的t值
*/
private _applyEasing(t: number): number {
// 确保t在0-1范围内
t = Math.max(0, Math.min(1, t));
// 使用tween.easing函数应用缓动
switch (this.easing) {
case EasingType.linear:
return t; // 线性不需要额外处理
case EasingType.smooth:
return t * t * (3 - 2 * t); // 平滑过渡
case EasingType.fade:
return t * t * (3 - 2 * t); // 平滑过渡
case EasingType.quadIn:
return t * t; // 二次方加速
case EasingType.quadOut:
return t * (2 - t); // 二次方减速
case EasingType.quadInOut:
return t < 0.5 ? 2 * t * t : -1 + (4 - 2 * t) * t; // 二次方加速然后减速
case EasingType.quadOutIn:
return t < 0.5 ? 0.5 * (1 - Math.pow(-2 * t + 1, 2)) : 0.5 * Math.pow(2 * t - 1, 2) + 0.5; // 二次方减速然后加速
case EasingType.cubicIn:
return t * t * t; // 三次方加速
case EasingType.cubicOut:
return (--t) * t * t + 1; // 三次方减速
case EasingType.cubicInOut:
return t < 0.5 ? 4 * t * t * t : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1; // 三次方加速然后减速
case EasingType.cubicOutIn:
return t < 0.5 ? 0.5 * ((t = t * 2 - 1) * t * t + 1) : 0.5 * (t = t * 2 - 1) * t * t + 0.5; // 三次方减速然后加速
case EasingType.quartIn:
return t * t * t * t; // 四次方加速
case EasingType.quartOut:
return 1 - (--t) * t * t * t; // 四次方减速
case EasingType.quartInOut:
return t < 0.5 ? 8 * t * t * t * t : 1 - 8 * (--t) * t * t * t; // 四次方加速然后减速
case EasingType.quartOutIn:
return t < 0.5 ? 0.5 * (1 - Math.pow(-2 * t + 1, 4)) : 0.5 * Math.pow(2 * t - 1, 4) + 0.5; // 四次方减速然后加速
case EasingType.quintIn:
return t * t * t * t * t; // 五次方加速
case EasingType.quintOut:
return 1 + (--t) * t * t * t * t; // 五次方减速
case EasingType.quintInOut:
return t < 0.5 ? 16 * t * t * t * t * t : 1 + 16 * (--t) * t * t * t * t; // 五次方加速然后减速
case EasingType.quintOutIn:
return t < 0.5 ? 0.5 * (1 - Math.pow(-2 * t + 1, 5)) : 0.5 * Math.pow(2 * t - 1, 5) + 0.5; // 五次方减速然后加速
case EasingType.sineIn:
return 1 - Math.cos(t * Math.PI / 2); // 正弦加速
case EasingType.sineOut:
return Math.sin(t * Math.PI / 2); // 正弦减速
case EasingType.sineInOut:
return 0.5 * (1 - Math.cos(Math.PI * t)); // 正弦加速然后减速
case EasingType.sineOutIn:
return t < 0.5 ? 0.5 * Math.sin(t * Math.PI) : 0.5 - 0.5 * Math.cos((t * 2 - 1) * Math.PI / 2); // 正弦减速然后加速
case EasingType.circIn:
return 1 - Math.sqrt(1 - t * t); // 圆形加速
case EasingType.circOut:
return Math.sqrt(1 - (t - 1) * (t - 1)); // 圆形减速
case EasingType.circInOut:
return t < 0.5
? (1 - Math.sqrt(1 - 4 * t * t)) / 2
: (Math.sqrt(1 - Math.pow(-2 * t + 2, 2)) + 1) / 2; // 圆形加速然后减速
case EasingType.circOutIn:
return t < 0.5 ? 0.5 * Math.sqrt(1 - Math.pow(-2 * t + 1, 2)) : 0.5 * (2 - Math.sqrt(1 - Math.pow(2 * t - 1, 2))); // 圆形减速然后加速
case EasingType.expoIn:
return t === 0 ? 0 : Math.pow(2, 10 * t - 10); // 指数加速
case EasingType.expoOut:
return t === 1 ? 1 : 1 - Math.pow(2, -10 * t); // 指数减速
case EasingType.expoInOut:
return t === 0 ? 0 : t === 1 ? 1 : t < 0.5
? Math.pow(2, 20 * t - 10) / 2
: (2 - Math.pow(2, -20 * t + 10)) / 2; // 指数加速然后减速
case EasingType.expoOutIn:
return t === 0 ? 0 : t === 1 ? 1 : t < 0.5
? 0.5 * (1 - Math.pow(2, -20 * t))
: 0.5 * Math.pow(2, 20 * (t - 0.5) - 10) + 0.5; // 指数减速然后加速
case EasingType.backIn:
const s = 1.70158;
return t * t * ((s + 1) * t - s); // 回弹加速
case EasingType.backOut:
const s2 = 1.70158;
return (t = t - 1) * t * ((s2 + 1) * t + s2) + 1; // 回弹减速
case EasingType.backInOut:
const s3 = 1.70158 * 1.525;
if (t < 0.5) {
return (t * 2) * (t * 2) * ((s3 + 1) * (t * 2) - s3) / 2;
} else {
return ((t * 2 - 2) * (t * 2 - 2) * ((s3 + 1) * (t * 2 - 2) + s3) + 2) / 2;
} // 回弹加速然后减速
case EasingType.backOutIn:
const s4 = 1.70158;
return t < 0.5
? 0.5 * ((t = t * 2 - 1) * t * ((s4 + 1) * t + s4) + 1)
: 0.5 * (t = t * 2 - 1) * t * ((s4 + 1) * t - s4) + 0.5; // 回弹减速然后加速
case EasingType.elasticIn:
return t === 0 ? 0 : t === 1 ? 1 : -Math.pow(2, 10 * (t - 1)) * Math.sin((t - 1.1) * 5 * Math.PI); // 弹性加速
case EasingType.elasticOut:
return t === 0 ? 0 : t === 1 ? 1 : Math.pow(2, -10 * t) * Math.sin((t - 0.1) * 5 * Math.PI) + 1; // 弹性减速
case EasingType.elasticInOut:
if (t === 0) return 0;
if (t === 1) return 1;
if (t < 0.5) {
return -0.5 * Math.pow(2, 20 * t - 10) * Math.sin((20 * t - 11.125) * Math.PI / 2.25);
} else {
return 0.5 * Math.pow(2, -20 * t + 10) * Math.sin((20 * t - 11.125) * Math.PI / 2.25) + 1;
} // 弹性加速然后减速
case EasingType.elasticOutIn:
if (t === 0) return 0;
if (t === 1) return 1;
if (t < 0.5) {
return 0.5 * Math.pow(2, -20 * t) * Math.sin((20 * t - 0.5) * 5 * Math.PI) + 0.5;
} else {
return 0.5 * -Math.pow(2, 10 * (2 * t - 1.5)) * Math.sin((2 * t - 1.6) * 5 * Math.PI) + 0.5;
} // 弹性减速然后加速
case EasingType.bounceIn:
return 1 - this._bounceOut(1 - t); // 弹跳加速
case EasingType.bounceOut:
return this._bounceOut(t); // 弹跳减速
case EasingType.bounceInOut:
return t < 0.5
? (1 - this._bounceOut(1 - 2 * t)) / 2
: (1 + this._bounceOut(2 * t - 1)) / 2; // 弹跳加速然后减速
case EasingType.bounceOutIn:
return t < 0.5
? this._bounceOut(t * 2) / 2
: (1 - this._bounceOut(2 - 2 * t)) / 2 + 0.5; // 弹跳减速然后加速
default:
return t; // 默认线性
}
}
/**
* 辅助函数:弹跳减速效果
*/
private _bounceOut(t: number): number {
if (t < 1 / 2.75) {
return 7.5625 * t * t;
} else if (t < 2 / 2.75) {
return 7.5625 * (t -= 1.5 / 2.75) * t + 0.75;
} else if (t < 2.5 / 2.75) {
return 7.5625 * (t -= 2.25 / 2.75) * t + 0.9375;
} else {
return 7.5625 * (t -= 2.625 / 2.75) * t + 0.984375;
}
}
/**
* 初始化Graphics组件
*/
private _initGraphics(): void {
// 为每个MovingTarget实例创建唯一的轨迹节点名称避免多个实例共享同一个轨迹节点
const uniqueNodeName = `TrajectoryGraphics_${this.node.uuid}`;
// 尝试查找已存在的轨迹节点基于唯一ID
let graphicsNode = this.node.parent?.getChildByName(uniqueNodeName);
// 如果不存在,则创建新的轨迹节点
if (!graphicsNode) {
graphicsNode = new Node(uniqueNodeName);
// 初始时先添加到场景中但不设置父节点会在_drawTrajectory中设置
if (this.node.parent) {
this.node.parent.addChild(graphicsNode);
} else {
this.node.addChild(graphicsNode);
}
}
// 获取或添加Graphics组件到节点
this._graphics = graphicsNode.getComponent(Graphics);
if (!this._graphics) {
this._graphics = graphicsNode.addComponent(Graphics);
}
}
/**
* 清除轨迹
*/
public clearTrajectory(): void {
if (!this._graphics) return;
// 清除之前的轨迹
this._graphics.clear();
}
/**
* 绘制轨迹
*/
private _drawTrajectory(): void {
if (!this.showTrajectory) return;
if (!this._graphics) return;
// 清除之前的轨迹
this._graphics.clear();
// 设置轨迹样式
this._graphics.lineWidth = this.trajectoryWidth;
this._graphics.strokeColor = this.trajectoryColor;
// 获取Graphics所在节点
const graphicsNode = this._graphics.node;
// 将Graphics节点设置为与主节点的父节点相同确保轨迹在世界坐标系中绘制
if (this.node.parent) {
graphicsNode.parent = this.node.parent;
// 移动到起点(世界坐标系中的实际位置)
this._graphics.moveTo(this._startPoint.x, this._startPoint.y);
// 直接使用控制点和终点的世界坐标绘制贝塞尔曲线
this._graphics.quadraticCurveTo(
this._controlPoint.x, this._controlPoint.y,
this._endPoint.x, this._endPoint.y
);
}
// 应用绘制
this._graphics.stroke();
}
/**
* 平滑角度插值,确保选择最短路径旋转
* @param currentAngle 当前角度
* @param targetAngle 目标角度
* @param smoothFactor 平滑系数0-1值越小越平滑
* @returns 插值后的新角度
*/
private _smoothAngle(currentAngle: number, targetAngle: number, smoothFactor: number): number {
// 确保平滑系数在有效范围内
smoothFactor = Math.max(0.001, Math.min(1, smoothFactor));
// 标准化角度到 0-360 范围
const normalizeAngle = (angle: number): number => {
angle = angle % 360;
return angle < 0 ? angle + 360 : angle;
};
// 标准化当前角度和目标角度
const normCurrent = normalizeAngle(currentAngle);
const normTarget = normalizeAngle(targetAngle);
// 计算最短路径旋转方向
let delta = normTarget - normCurrent;
// 如果角度差大于180度选择另一个方向旋转最短路径
if (delta > 180) {
delta -= 360;
} else if (delta < -180) {
delta += 360;
}
// 应用平滑系数进行插值
return currentAngle + delta * smoothFactor;
}
}

View File

@@ -1,9 +0,0 @@
{
"ver": "4.0.24",
"importer": "typescript",
"imported": true,
"uuid": "f680d91a-831f-4f99-b7ea-b45e3adff51a",
"files": [],
"subMetas": {},
"userData": {}
}

View File

@@ -46,19 +46,30 @@ export const getMonList = ()=>{
} }
export const HeroPos={ export const HeroPos={
0:{pos:v3(-240,100,0)}, 0:{pos:v3(-240,120,0)},
1:{pos:v3(0,100,0)}, 1:{pos:v3(0,120,0)},
2:{pos:v3(0,100,0)}, 2:{pos:v3(0,120,0)},
} }
export const MonSet = { export const MonSet = {
0:{pos:v3(240,110,0)}, 0:{pos:v3(240,130,0)},
1:{pos:v3(240,90,0)}, 1:{pos:v3(240,110,0)},
2:{pos:v3(320,110,0)}, 2:{pos:v3(300,130,0)},
3:{pos:v3(320,90,0)}, 3:{pos:v3(300,110,0)},
4:{pos:v3(360,110,0)}, 4:{pos:v3(320,130,0)},
5:{pos:v3(360,90,0)}, 5:{pos:v3(320,110,0)},
6:{pos:v3(400,110,0)}, 6:{pos:v3(360,130,0)},
7:{pos:v3(400,90,0)}, 7:{pos:v3(360,110,0)},
8:{pos:v3(400,130,0)},
9:{pos:v3(400,110,0)},
10:{pos:v3(440,130,0)},
11:{pos:v3(440,110,0)},
}
export enum MonStart {
SLINE_1=130, //上线y
SLINE_2=110, //下线y
START_X=240, //x起始点
START_I=60, //x轴间隔
} }
export enum HeroConf{ export enum HeroConf{

View File

@@ -41,7 +41,7 @@ export class Hero extends ecs.Entity {
// console.log("英雄加载:",uuid,pos,scale,info) // console.log("英雄加载:",uuid,pos,scale,info)
scale = 1 scale = 1
// 查找空闲英雄槽位 // 查找空闲英雄槽位
let size=1
var path = "game/heros/"+HeroInfo[uuid].path; var path = "game/heros/"+HeroInfo[uuid].path;
var prefab: Prefab = oops.res.get(path, Prefab)!; var prefab: Prefab = oops.res.get(path, Prefab)!;
var node = instantiate(prefab); var node = instantiate(prefab);
@@ -49,12 +49,14 @@ export class Hero extends ecs.Entity {
node.parent = scene.entityLayer!.node! node.parent = scene.entityLayer!.node!
const collider = node.getComponent(BoxCollider2D); const collider = node.getComponent(BoxCollider2D);
if (collider) collider.enabled = false; // 先禁用 if (collider) collider.enabled = false; // 先禁用
node.setScale(size*node.scale.x,size*node.scale.y);
node.setPosition(pos) node.setPosition(pos)
// 🔥 设置初始 SiblingIndex - 英雄基础层级 + 位置偏移 // 🔥 设置初始 SiblingIndex - 英雄基础层级 + 位置偏移
const initialSiblingIndex = IndexSet.HERO; const initialSiblingIndex = IndexSet.HERO;
node.setSiblingIndex(initialSiblingIndex); node.setSiblingIndex(initialSiblingIndex);
console.log("hero",node.getSiblingIndex());
// console.log("hero load",pos) // console.log("hero load",pos)
var hv = node.getComponent(HeroViewComp)!; var hv = node.getComponent(HeroViewComp)!;
const model = this.get(HeroAttrsComp); const model = this.get(HeroAttrsComp);

View File

@@ -144,12 +144,12 @@ export class HeroMoveSystem extends ecs.ComblockSystem implements ecs.ISystemUpd
// 只有当朝向真正改变时才更新 // 只有当朝向真正改变时才更新
if (move.currentFacing !== newFacing) { if (move.currentFacing !== newFacing) {
move.currentFacing = newFacing; move.currentFacing = newFacing;
view.node.setScale(newFacing, 1, 1); view.node.setScale(newFacing*view.node.scale.x, 1*view.node.scale.y);
// 安全获取top节点 // 安全获取top节点
const topNode = view.node.getChildByName("top"); const topNode = view.node.getChildByName("top");
if (topNode) { if (topNode) {
topNode.setScale(newFacing, 1, 1); topNode.setScale(newFacing*topNode.scale.x, 1*topNode.scale.y);
} }
} }
} }

View File

@@ -81,8 +81,8 @@ export class HeroViewComp extends CCComp {
this.initUINodes(); this.initUINodes();
/** 方向 */ /** 方向 */
this.node.setScale(this.scale,1); this.node.setScale(this.scale*this.node.scale.x,1*this.node.scale.y);
this.top_node.setScale(this.scale,1); this.top_node.setScale(this.scale*this.top_node.scale.x,1*this.top_node.scale.y);
// if(this.model && this.model.is_boss){ // if(this.model && this.model.is_boss){
// this.top_node.position=v3(this.node.position.x,this.node.position.y+70,0) // this.top_node.position=v3(this.node.position.x,this.node.position.y+70,0)
// } // }

View File

@@ -37,6 +37,7 @@ export class Monster extends ecs.Entity {
/** 加载角色 */ /** 加载角色 */
load(pos: Vec3 = Vec3.ZERO,scale:number = 1,uuid:number=1001,lv:number=1,monType:MonType=MonType.NORMAL, buffs: BuffConf[] = [],is_call=false, lane: number = 0, spawnOrder: number = 0) { load(pos: Vec3 = Vec3.ZERO,scale:number = 1,uuid:number=1001,lv:number=1,monType:MonType=MonType.NORMAL, buffs: BuffConf[] = [],is_call=false, lane: number = 0, spawnOrder: number = 0) {
scale=-1 scale=-1
let size=1
var scene = smc.map.MapView.scene; var scene = smc.map.MapView.scene;
var path = "game/heros/"+HeroInfo[uuid].path; var path = "game/heros/"+HeroInfo[uuid].path;
var prefab: Prefab = oops.res.get(path, Prefab)!; var prefab: Prefab = oops.res.get(path, Prefab)!;
@@ -45,6 +46,7 @@ export class Monster extends ecs.Entity {
node.parent = scene.entityLayer!.node! node.parent = scene.entityLayer!.node!
const collider = node.getComponent(BoxCollider2D); const collider = node.getComponent(BoxCollider2D);
if (collider) collider.enabled = false; // 先禁用 // 延迟一帧启用碰撞体 if (collider) collider.enabled = false; // 先禁用 // 延迟一帧启用碰撞体
node.setScale(size*node.scale.x,size*node.scale.y);
node.setPosition(pos) node.setPosition(pos)
// 🔥 设置初始 SiblingIndex - 防止溢出 // 🔥 设置初始 SiblingIndex - 防止溢出
@@ -53,7 +55,7 @@ export class Monster extends ecs.Entity {
const safeSpawnOrder = spawnOrder % 999; // 限制在999以内避免溢出到其他层级 const safeSpawnOrder = spawnOrder % 999; // 限制在999以内避免溢出到其他层级
const initialSiblingIndex = baseLane + safeSpawnOrder; const initialSiblingIndex = baseLane + safeSpawnOrder;
node.setSiblingIndex(initialSiblingIndex); node.setSiblingIndex(initialSiblingIndex);
console.log("mon",node.getSiblingIndex());
var view = node.getComponent(HeroViewComp)!; var view = node.getComponent(HeroViewComp)!;
const model = this.get(HeroAttrsComp); const model = this.get(HeroAttrsComp);
const skillsComp = this.get(HeroSkillsComp); const skillsComp = this.get(HeroSkillsComp);

View File

@@ -25,13 +25,13 @@ export class HInfoComp extends CCComp {
// 英雄位置定义 // 英雄位置定义
hero_pos:any={ hero_pos:any={
0:v3(420,-57,0), // 不在屏幕内 0:v3(420,-30,0), // 不在屏幕内
1:v3(280,-57,0), 1:v3(280,-30,0),
2:v3(160,-57,0), 2:v3(160,-33,0),
3:v3(0,-67,0), 3:v3(0,-40,0),
4:v3(-160,-57,0), 4:v3(-160,-33,0),
5:v3(-280,-57,0), 5:v3(-280,-30,0),
6:v3(-420,-57,0), // 不在屏幕内 6:v3(-420,-30,0), // 不在屏幕内
} }
// 动画锁定标志:防止快速点击导致的动画冲突 // 动画锁定标志:防止快速点击导致的动画冲突
@@ -43,6 +43,23 @@ export class HInfoComp extends CCComp {
} }
// 位置索引常量 // 位置索引常量
private static center_pos = 3; private static center_pos = 3;
/**
* 根据位置索引获取英雄缩放值
* @param posIndex 位置索引 (0-6)
* @returns Vec3 缩放向量
*/
private getHeroScale(posIndex: number): Vec3 {
switch(posIndex) {
case 2:
case 4:
return v3(-1.6, 1.6, 1); // 2、4位置1.2倍缩放
case 3:
return v3(-1.8, 1.8, 1); // 3位置中心1.5倍缩放
default:
return v3(-1.4, 1.4, 1); // 其他位置1倍缩放
}
}
start() { start() {
this.name_node=this.node.getChildByName("hero").getChildByName("hname").getChildByName("name") this.name_node=this.node.getChildByName("hero").getChildByName("hname").getChildByName("name")
@@ -105,10 +122,11 @@ export class HInfoComp extends CCComp {
// 载入英雄预制体并设置位置 // 载入英雄预制体并设置位置
this.heroNodes[i] = this.load_hui(heroUuid, i); this.heroNodes[i] = this.load_hui(heroUuid, i);
// 添加初始缩放动画,确保3号位是1.5倍 // 添加初始缩放动画,根据位置设置不同的缩放值
if (this.heroNodes[i] && i === 3) { if (this.heroNodes[i]) {
let targetScale = this.getHeroScale(i);
tween(this.heroNodes[i]) tween(this.heroNodes[i])
.to(0.2, { scale: v3(-1.5, 1.5, 1) }) .to(0.2, { scale: targetScale })
.start(); .start();
} }
} }
@@ -124,12 +142,8 @@ export class HInfoComp extends CCComp {
// 设置节点位置 // 设置节点位置
node.setPosition(this.hero_pos[pos_index]); node.setPosition(this.hero_pos[pos_index]);
node.setSiblingIndex(0); node.setSiblingIndex(0);
// 设置缩放3号位1.5倍其他位置1倍 // 根据位置设置不同的缩放值
if(pos_index==3){ node.setScale(this.getHeroScale(pos_index));
node.setScale(v3(-1.5,1.5,1))
} else {
node.setScale(v3(-1,1,1))
}
// 加载并播放动画 // 加载并播放动画
let anm_path=HeroInfo[uuid].path; let anm_path=HeroInfo[uuid].path;
resources.load("game/heros/hero/"+anm_path+"/idle", AnimationClip, (err, clip) => { resources.load("game/heros/hero/"+anm_path+"/idle", AnimationClip, (err, clip) => {
@@ -240,7 +254,7 @@ export class HInfoComp extends CCComp {
let targetPos = this.hero_pos[i + 1]; let targetPos = this.hero_pos[i + 1];
// 使用Tween执行平滑移动和缩放动画 // 使用Tween执行平滑移动和缩放动画
let targetScale = (i + 1) === 3 ? v3(-1.5, 1.5, 1) : v3(-1, 1, 1); let targetScale = this.getHeroScale(i + 1);
tween(this.heroNodes[i]) tween(this.heroNodes[i])
.to(0.2, { position: targetPos, scale: targetScale }) .to(0.2, { position: targetPos, scale: targetScale })
@@ -267,9 +281,9 @@ export class HInfoComp extends CCComp {
this.heroNodes[0] = this.load_hui(heros[newIndex], 0); this.heroNodes[0] = this.load_hui(heros[newIndex], 0);
// 确保新创建的节点初始缩放为1倍因为0号位不是中心位置 // 确保新创建的节点使用正确的缩放值
if (this.heroNodes[0]) { if (this.heroNodes[0]) {
this.heroNodes[0].setScale(v3(-1, 1, 1)); this.heroNodes[0].setScale(this.getHeroScale(0));
} }
// 动画完成,解除锁定 // 动画完成,解除锁定
@@ -300,7 +314,7 @@ export class HInfoComp extends CCComp {
let targetPos = this.hero_pos[i - 1]; let targetPos = this.hero_pos[i - 1];
// 使用Tween执行平滑移动和缩放动画 // 使用Tween执行平滑移动和缩放动画
let targetScale = (i - 1) === 3 ? v3(-1.5, 1.5, 1) : v3(-1, 1, 1); let targetScale = this.getHeroScale(i - 1);
tween(this.heroNodes[i]) tween(this.heroNodes[i])
.to(0.2, { position: targetPos, scale: targetScale }) .to(0.2, { position: targetPos, scale: targetScale })
@@ -327,9 +341,9 @@ export class HInfoComp extends CCComp {
this.heroNodes[6] = this.load_hui(heros[newIndex], 6); this.heroNodes[6] = this.load_hui(heros[newIndex], 6);
// 确保新创建的节点初始缩放为1倍因为6号位不是中心位置 // 确保新创建的节点使用正确的缩放值
if (this.heroNodes[6]) { if (this.heroNodes[6]) {
this.heroNodes[6].setScale(v3(-1, 1, 1)); this.heroNodes[6].setScale(this.getHeroScale(6));
} }
// 动画完成,解除锁定 // 动画完成,解除锁定

View File

@@ -2,7 +2,7 @@ import { _decorator, v3, Vec3 } from "cc";
import { ecs } from "../../../../extensions/oops-plugin-framework/assets/libs/ecs/ECS"; import { ecs } from "../../../../extensions/oops-plugin-framework/assets/libs/ecs/ECS";
import { CCComp } from "../../../../extensions/oops-plugin-framework/assets/module/common/CCComp"; import { CCComp } from "../../../../extensions/oops-plugin-framework/assets/module/common/CCComp";
import { Monster } from "../hero/Mon"; import { Monster } from "../hero/Mon";
import { MonSet } from "../common/config/heroSet"; import { MonStart } from "../common/config/heroSet";
import { smc } from "../common/SingletonModuleComp"; import { smc } from "../common/SingletonModuleComp";
import { GameEvent } from "../common/config/GameEvent"; import { GameEvent } from "../common/config/GameEvent";
// 导入肉鸽配置 // 导入肉鸽配置
@@ -189,10 +189,15 @@ export class MissionMonCompComp extends CCComp {
) { ) {
let mon = ecs.getEntity<Monster>(Monster); let mon = ecs.getEntity<Monster>(Monster);
let scale = -1; let scale = -1;
let pos: Vec3 = v3(MonSet[i].pos); // 使用 MonStart 计算怪物出生位置:
// x 从 START_X 开始,按 START_I 的间隔递增;
// y 在线路之间交替:偶数索引为 SLINE_1奇数索引为 SLINE_2。
const x = MonStart.START_X + Math.floor(i / 2) * MonStart.START_I;
const y = (i % 2 === 0) ? MonStart.SLINE_1 : MonStart.SLINE_2;
let pos: Vec3 = v3(x, y, 0);
// 根据位置判断线路y=110为一线(lane=0)y=80为二线(lane=1) // 根据位置判断线路y=SLINE_1 为一线(lane=0)y=SLINE_2 为二线(lane=1)
const lane = pos.y === 110 ? 0 : 1; const lane = y === MonStart.SLINE_1 ? 0 : 1;
// 递增全局生成顺序 - 🔥 添加溢出保护 // 递增全局生成顺序 - 🔥 添加溢出保护
this.globalSpawnOrder = (this.globalSpawnOrder + 1) % 999; // 防止无限增长在999处循环重置 this.globalSpawnOrder = (this.globalSpawnOrder + 1) % 999; // 防止无限增长在999处循环重置