perf: 删除不必要的代码

This commit is contained in:
richarjiang
2025-09-23 17:22:31 +08:00
parent 924862598a
commit 5bb83ddd86
7 changed files with 83 additions and 654 deletions

View File

@@ -52,7 +52,7 @@
},
"autoReleaseAssets": false,
"_globals": {
"__id__": 80
"__id__": 70
},
"_id": "58132e64-0171-4c7f-89be-a2984ca7de6b"
},
@@ -75,19 +75,16 @@
"__id__": 29
},
{
"__id__": 39
"__id__": 33
},
{
"__id__": 43
"__id__": 36
},
{
"__id__": 46
"__id__": 50
},
{
"__id__": 60
},
{
"__id__": 69
"__id__": 59
},
{
"__id__": 6
@@ -96,13 +93,13 @@
"_active": true,
"_components": [
{
"__id__": 78
"__id__": 68
},
{
"__id__": 42
"__id__": 32
},
{
"__id__": 79
"__id__": 69
}
],
"_prefab": null,
@@ -1074,322 +1071,6 @@
"tileSize": 32,
"_id": "1dgMYdcURInZC/UJAogJZH"
},
{
"__type__": "cc.Node",
"_name": "TiledMap",
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 30
},
{
"__id__": 33
}
],
"_active": false,
"_components": [
{
"__id__": 36
},
{
"__id__": 37
},
{
"__id__": 38
}
],
"_prefab": null,
"_lpos": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"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": 33554432,
"_euler": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_id": "05FcfqWLRCTLU2Pon+/5lM"
},
{
"__type__": "cc.Node",
"_name": "bg",
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 29
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 31
},
{
"__id__": 32
}
],
"_prefab": null,
"_lpos": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"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": 33554432,
"_euler": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_id": "dcjO1Ab2tDIbg6VVr9YHdO"
},
{
"__type__": "cc.UITransform",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 30
},
"_enabled": true,
"__prefab": null,
"_contentSize": {
"__type__": "cc.Size",
"width": 1080,
"height": 2560
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_id": "8aW0b4lGxCVbal8zQBKbyB"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 30
},
"_enabled": true,
"__prefab": null,
"_customMaterial": null,
"_srcBlendFactor": 2,
"_dstBlendFactor": 4,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_spriteFrame": {
"__uuid__": "361c5873-d797-420e-be65-81c5a8f91215@f9941",
"__expectedType__": "cc.SpriteFrame"
},
"_type": 0,
"_fillType": 0,
"_sizeMode": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_useGrayscale": false,
"_atlas": null,
"_id": "37daNZffxGSq/F3WV+F0Y5"
},
{
"__type__": "cc.Node",
"_name": "WalkableLayer",
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 29
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 34
},
{
"__id__": 35
}
],
"_prefab": null,
"_lpos": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"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": 33554432,
"_euler": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_id": "23cuMKDVtPs71LOAe7QMgZ"
},
{
"__type__": "cc.UITransform",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 33
},
"_enabled": true,
"__prefab": null,
"_contentSize": {
"__type__": "cc.Size",
"width": 1056,
"height": 2560
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_id": "e8IRovTjZNga4GC6wNHoIP"
},
{
"__type__": "cc.TiledLayer",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 33
},
"_enabled": true,
"__prefab": null,
"_customMaterial": null,
"_srcBlendFactor": 2,
"_dstBlendFactor": 4,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 0
},
"_id": "30V2VyJEZCsKfZxqWiSZMJ"
},
{
"__type__": "cc.UITransform",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 29
},
"_enabled": true,
"__prefab": null,
"_contentSize": {
"__type__": "cc.Size",
"width": 1080,
"height": 2560
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_id": "8c+XCMydFC9JqNb2Ygm4wJ"
},
{
"__type__": "cc.TiledMap",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 29
},
"_enabled": true,
"__prefab": null,
"_tmxFile": {
"__uuid__": "dc1135fd-3f97-4e7d-84bd-b4fa0cc5bab2",
"__expectedType__": "cc.TiledMapAsset"
},
"_enableCulling": true,
"cleanupImageCache": true,
"_id": "af4s2K0x1MH5srzPTEFKZE"
},
{
"__type__": "9f9f8e8d-3b4c-5d6e-9f0e-2b3c4d5e6f7g",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 29
},
"_enabled": true,
"__prefab": null,
"tiledMap": {
"__id__": 37
},
"walkableLayerName": "WalkableLayer",
"tileSize": 32,
"_id": "b7cmI9hyJG85zE5AHvozc+"
},
{
"__type__": "cc.Node",
"_name": "PlayerController",
@@ -1402,10 +1083,10 @@
"_active": true,
"_components": [
{
"__id__": 40
"__id__": 30
},
{
"__id__": 41
"__id__": 31
}
],
"_prefab": null,
@@ -1444,7 +1125,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 39
"__id__": 29
},
"_enabled": true,
"__prefab": null,
@@ -1466,12 +1147,12 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 39
"__id__": 29
},
"_enabled": true,
"__prefab": null,
"canvas": {
"__id__": 42
"__id__": 32
},
"player": {
"__id__": 6
@@ -1515,10 +1196,10 @@
"_active": true,
"_components": [
{
"__id__": 44
"__id__": 34
},
{
"__id__": 45
"__id__": 35
}
],
"_prefab": null,
@@ -1557,7 +1238,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 43
"__id__": 33
},
"_enabled": true,
"__prefab": null,
@@ -1579,7 +1260,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 43
"__id__": 33
},
"_enabled": true,
"__prefab": null,
@@ -1601,22 +1282,22 @@
},
"_children": [
{
"__id__": 47
"__id__": 37
},
{
"__id__": 50
"__id__": 40
},
{
"__id__": 53
"__id__": 43
},
{
"__id__": 56
"__id__": 46
}
],
"_active": true,
"_components": [
{
"__id__": 59
"__id__": 49
}
],
"_prefab": null,
@@ -1655,16 +1336,16 @@
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 46
"__id__": 36
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 48
"__id__": 38
},
{
"__id__": 49
"__id__": 39
}
],
"_prefab": null,
@@ -1703,7 +1384,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 47
"__id__": 37
},
"_enabled": true,
"__prefab": null,
@@ -1725,7 +1406,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 47
"__id__": 37
},
"_enabled": true,
"__prefab": null,
@@ -1764,16 +1445,16 @@
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 46
"__id__": 36
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 51
"__id__": 41
},
{
"__id__": 52
"__id__": 42
}
],
"_prefab": null,
@@ -1812,7 +1493,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 50
"__id__": 40
},
"_enabled": true,
"__prefab": null,
@@ -1834,7 +1515,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 50
"__id__": 40
},
"_enabled": true,
"__prefab": null,
@@ -1873,16 +1554,16 @@
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 46
"__id__": 36
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 54
"__id__": 44
},
{
"__id__": 55
"__id__": 45
}
],
"_prefab": null,
@@ -1921,7 +1602,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 53
"__id__": 43
},
"_enabled": true,
"__prefab": null,
@@ -1943,7 +1624,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 53
"__id__": 43
},
"_enabled": true,
"__prefab": null,
@@ -1982,16 +1663,16 @@
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 46
"__id__": 36
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 57
"__id__": 47
},
{
"__id__": 58
"__id__": 48
}
],
"_prefab": null,
@@ -2030,7 +1711,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 56
"__id__": 46
},
"_enabled": true,
"__prefab": null,
@@ -2052,7 +1733,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 56
"__id__": 46
},
"_enabled": true,
"__prefab": null,
@@ -2091,7 +1772,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 46
"__id__": 36
},
"_enabled": true,
"__prefab": null,
@@ -2117,25 +1798,25 @@
},
"_children": [
{
"__id__": 61
"__id__": 51
}
],
"_active": true,
"_components": [
{
"__id__": 64
"__id__": 54
},
{
"__id__": 65
"__id__": 55
},
{
"__id__": 66
"__id__": 56
},
{
"__id__": 67
"__id__": 57
},
{
"__id__": 68
"__id__": 58
}
],
"_prefab": null,
@@ -2174,16 +1855,16 @@
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 60
"__id__": 50
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 62
"__id__": 52
},
{
"__id__": 63
"__id__": 53
}
],
"_prefab": null,
@@ -2222,7 +1903,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 61
"__id__": 51
},
"_enabled": true,
"__prefab": null,
@@ -2244,7 +1925,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 61
"__id__": 51
},
"_enabled": true,
"__prefab": null,
@@ -2306,7 +1987,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 60
"__id__": 50
},
"_enabled": true,
"__prefab": null,
@@ -2328,7 +2009,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 60
"__id__": 50
},
"_enabled": true,
"__prefab": null,
@@ -2367,7 +2048,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 60
"__id__": 50
},
"_enabled": true,
"__prefab": null,
@@ -2398,7 +2079,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 60
"__id__": 50
},
"_enabled": true,
"__prefab": null,
@@ -2426,7 +2107,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 60
"__id__": 50
},
"_enabled": true,
"__prefab": null,
@@ -2458,25 +2139,25 @@
},
"_children": [
{
"__id__": 70
"__id__": 60
}
],
"_active": true,
"_components": [
{
"__id__": 73
"__id__": 63
},
{
"__id__": 74
"__id__": 64
},
{
"__id__": 75
"__id__": 65
},
{
"__id__": 76
"__id__": 66
},
{
"__id__": 77
"__id__": 67
}
],
"_prefab": null,
@@ -2515,16 +2196,16 @@
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 69
"__id__": 59
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 71
"__id__": 61
},
{
"__id__": 72
"__id__": 62
}
],
"_prefab": null,
@@ -2563,7 +2244,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 70
"__id__": 60
},
"_enabled": true,
"__prefab": null,
@@ -2585,7 +2266,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 70
"__id__": 60
},
"_enabled": true,
"__prefab": null,
@@ -2647,7 +2328,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 69
"__id__": 59
},
"_enabled": true,
"__prefab": null,
@@ -2669,7 +2350,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 69
"__id__": 59
},
"_enabled": true,
"__prefab": null,
@@ -2708,7 +2389,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 69
"__id__": 59
},
"_enabled": true,
"__prefab": null,
@@ -2739,7 +2420,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 69
"__id__": 59
},
"_enabled": true,
"__prefab": null,
@@ -2767,7 +2448,7 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 69
"__id__": 59
},
"_enabled": true,
"__prefab": null,
@@ -2844,28 +2525,28 @@
{
"__type__": "cc.SceneGlobals",
"ambient": {
"__id__": 81
"__id__": 71
},
"shadows": {
"__id__": 82
"__id__": 72
},
"_skybox": {
"__id__": 83
"__id__": 73
},
"fog": {
"__id__": 84
"__id__": 74
},
"octree": {
"__id__": 85
"__id__": 75
},
"skin": {
"__id__": 86
"__id__": 76
},
"lightProbeInfo": {
"__id__": 87
"__id__": 77
},
"postSettings": {
"__id__": 88
"__id__": 78
},
"bakedWithStationaryMainLight": false,
"bakedWithHighpLightmap": false