From cb3bd54175b92bab7bc1e155788778983b4dff93 Mon Sep 17 00:00:00 2001 From: Joywayer Date: Wed, 2 Sep 2026 09:11:51 +0800 Subject: [PATCH] fix(scripts): final review Critical+Important fixes (Widget alignment, full readLayerXml, Label _string, atlas selection, hard-coded paths, exit code, dead code removal) --- .../out/legacy-migration/Login_Layer.prefab | 3425 +++++++++++++++++ .../legacy-migration/Login_Layer.prefab.diff | 1217 ++++++ .../YouleNexus/package-lock.json | 37 +- cocoscreator_projects/YouleNexus/package.json | 4 - .../legacy-layer-migration/_smoke-iconv.mjs | 11 - .../coord-calculator.test.mjs | 47 +- .../fixtures/spirit-semantics.json | 2 +- .../legacy-layer-migration/poc-login.test.mjs | 43 +- .../poc-protocol.test.mjs | 12 +- .../prefab-emitter.test.mjs | 24 + .../spirit-to-node.test.mjs | 6 +- .../spirit-type-reverse.test.mjs | 4 +- .../sprite-uuid-resolver.test.mjs | 8 +- .../xml-parser.test.mjs | 37 +- cocoscreator_projects/package-lock.json | 25 +- cocoscreator_projects/package.json | 3 +- .../legacy-layer-to-cocos-prefab-cli.mjs | 41 +- .../scripts/legacy-layer-to-cocos-prefab.mjs | 304 +- .../scripts/run-legacy-migration-batch.mjs | 12 +- 19 files changed, 5076 insertions(+), 186 deletions(-) create mode 100644 cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab create mode 100644 cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab.diff delete mode 100644 cocoscreator_projects/framework-tests/legacy-layer-migration/_smoke-iconv.mjs diff --git a/cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab b/cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab new file mode 100644 index 0000000..14839cb --- /dev/null +++ b/cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab @@ -0,0 +1,3425 @@ +[ + { + "__type__": "cc.Prefab", + "_name": "Login_Layer", + "_objFlags": 0, + "__editorExtras__": {}, + "_native": "", + "data": { + "__id__": 1 + }, + "optimizationPolicy": 0, + "persistent": false + }, + { + "__type__": "cc.Node", + "_name": "Login_Layer", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": null, + "_children": [ + { + "__id__": 2 + } + ], + "_active": true, + "_components": [ + { + "__id__": 152 + }, + { + "__id__": 154 + } + ], + "_prefab": { + "__id__": 156 + }, + "_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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "group-2", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 1 + }, + "_children": [ + { + "__id__": 3 + }, + { + "__id__": 11 + }, + { + "__id__": 19 + }, + { + "__id__": 27 + }, + { + "__id__": 35 + }, + { + "__id__": 43 + }, + { + "__id__": 51 + }, + { + "__id__": 59 + }, + { + "__id__": 67 + }, + { + "__id__": 75 + }, + { + "__id__": 83 + }, + { + "__id__": 91 + }, + { + "__id__": 99 + }, + { + "__id__": 107 + }, + { + "__id__": 115 + }, + { + "__id__": 123 + }, + { + "__id__": 131 + }, + { + "__id__": 139 + } + ], + "_active": true, + "_components": [ + { + "__id__": 147 + }, + { + "__id__": 149 + } + ], + "_prefab": { + "__id__": 151 + }, + "_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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "微信登录背景", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 4 + }, + { + "__id__": 6 + }, + { + "__id__": 8 + } + ], + "_prefab": { + "__id__": 10 + }, + "_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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 3 + }, + "_enabled": true, + "__prefab": { + "__id__": 5 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1600, + "height": 720 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "emEOf90cI4gNtR0RG7EGAV" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 3 + }, + "_enabled": true, + "__prefab": { + "__id__": 7 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "e36acab8-e623-4bfb-af05-3c6fd2fddfb4@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "dd5tJ5czYGBZyTvpFuzYal" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 3 + }, + "_enabled": true, + "__prefab": { + "__id__": 9 + }, + "_alignFlags": 45, + "_target": null, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 100, + "_originalHeight": 100, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "0yfLBrBSt6rtFYodCRc1cD" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "NU7nrPQGogYAXyfrzCeDsM", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit405", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 12 + }, + { + "__id__": 14 + }, + { + "__id__": 16 + } + ], + "_prefab": { + "__id__": 18 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 123.5, + "y": 143, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 11 + }, + "_enabled": true, + "__prefab": { + "__id__": 13 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 59, + "height": 148 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "QEUpwMndeZmF9YDmYjCDtR" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 11 + }, + "_enabled": true, + "__prefab": { + "__id__": 15 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "8a077fab-398e-4af7-af1b-18acd498a10c@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "Kt7ZKOPMNWErpHmNUDt10R" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 11 + }, + "_enabled": true, + "__prefab": { + "__id__": 17 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 123.5, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "nDC1oMt6gCCjJje1rT5bBf" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "UHwd2I0T8JPdmE4n8Fyrvn", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "版本显示", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 20 + }, + { + "__id__": 22 + }, + { + "__id__": 24 + } + ], + "_prefab": { + "__id__": 26 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": -576, + "y": 335.5, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 19 + }, + "_enabled": true, + "__prefab": { + "__id__": 21 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 96, + "height": 31 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "c4rYVXTYG1FZtS9Td5QgRl" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 19 + }, + "_enabled": true, + "__prefab": { + "__id__": 23 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_string": "版本显示", + "_horizontalAlign": 0, + "_verticalAlign": 0, + "_actualFontSize": 18, + "_fontSize": 18, + "_fontFamily": "Arial", + "_lineHeight": 0, + "_overflow": 0, + "_enableWrapText": false, + "_font": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_isItalic": false, + "_isBold": false, + "_isUnderline": false, + "_underlineHeight": 2, + "_cacheMode": 0, + "_enableOutline": false, + "_outlineColor": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_outlineWidth": 2, + "_enableShadow": false, + "_shadowColor": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_shadowOffset": { + "__type__": "cc.Vec2", + "x": 2, + "y": 2 + }, + "_shadowBlur": 2, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "pFqJaPz8fug6eDB60GSGZf" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 19 + }, + "_enabled": true, + "__prefab": { + "__id__": 25 + }, + "_alignFlags": 9, + "_target": null, + "_left": -576, + "_top": 335.5, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "hacWqWhax8lH6dWOrppicG" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "ln5ypbMqYDKBmgQRmsEHDG", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "协议确认", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 28 + }, + { + "__id__": 30 + }, + { + "__id__": 32 + } + ], + "_prefab": { + "__id__": 34 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": -135, + "y": -207.5, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 27 + }, + "_enabled": true, + "__prefab": { + "__id__": 29 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 52, + "height": 51 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "k64h4IAYX2VNZwGi9u7vPy" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 27 + }, + "_enabled": true, + "__prefab": { + "__id__": 31 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "3756df6d-17cf-4903-81cb-66779cdd7d5e@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "jZNzyFnGjz2gf6BbdGGSMJ" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 27 + }, + "_enabled": true, + "__prefab": { + "__id__": 33 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": -135, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "TwmFxsqftGUROvCj6Xq41O" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "EIvLPh8JplBWwC0RtVALIz", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "协议内容", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 36 + }, + { + "__id__": 38 + }, + { + "__id__": 40 + } + ], + "_prefab": { + "__id__": 42 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 35, + "y": -210.5, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 35 + }, + "_enabled": true, + "__prefab": { + "__id__": 37 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 220, + "height": 29 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "UrQisXMNBt6tQje2aeek4Z" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 35 + }, + "_enabled": true, + "__prefab": { + "__id__": 39 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "d88f0180-d745-4132-abc0-54907ea78a4a@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "z3jJhYxW7QtQSxFAli8Qmu" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 35 + }, + "_enabled": true, + "__prefab": { + "__id__": 41 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 35, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "Hz55C8PiULYT1wXYVS2TYQ" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "Z2qzxf6mFNLmyuyfZv11k8", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit481", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 44 + }, + { + "__id__": 46 + }, + { + "__id__": 48 + } + ], + "_prefab": { + "__id__": 50 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 580, + "y": 300, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 43 + }, + "_enabled": true, + "__prefab": { + "__id__": 45 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 120 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "WA18mJ3TChc0X80qMwmoq7" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 43 + }, + "_enabled": true, + "__prefab": { + "__id__": 47 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "dcc4530b-344b-40b6-8fbb-9fa35db6a289@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "Op8g0q885CmeTHu798JBjq" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 43 + }, + "_enabled": true, + "__prefab": { + "__id__": 49 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 580, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "aRPoaVKJQ0W4R4pBDY3Qmg" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "tT7nGlSchN5DL2akDuRwuH", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit482", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 52 + }, + { + "__id__": 54 + }, + { + "__id__": 56 + } + ], + "_prefab": { + "__id__": 58 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": -580, + "y": -300, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 51 + }, + "_enabled": true, + "__prefab": { + "__id__": 53 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 120 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "tDPE3ExtHzhurb52tevsnq" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 51 + }, + "_enabled": true, + "__prefab": { + "__id__": 55 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "dcc4530b-344b-40b6-8fbb-9fa35db6a289@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "7eZtSiJIFTzs6uZ6ZP2FPB" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 51 + }, + "_enabled": true, + "__prefab": { + "__id__": 57 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": -580, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "cPg0eOhnYrYXZkVnXnMMgC" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "EXcbPGke9S15gfyfEIUgUp", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit177", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 60 + }, + { + "__id__": 62 + }, + { + "__id__": 64 + } + ], + "_prefab": { + "__id__": 66 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 60, + "y": -75.5, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 59 + }, + "_enabled": true, + "__prefab": { + "__id__": 61 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 320, + "height": 95 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "yGKU0TTNqGylSwWLFDCDNL" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 59 + }, + "_enabled": true, + "__prefab": { + "__id__": 63 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "bad32119-1ff1-402d-b984-b99e247fac84@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "JMZwrwpZOfpF42bFkehujK" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 59 + }, + "_enabled": true, + "__prefab": { + "__id__": 65 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 60, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "k3Bc8XktPcacEpHBDCnq1S" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "x0Vyz4Cfiyz6i4B4WwD3FU", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "微信登录", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 68 + }, + { + "__id__": 70 + }, + { + "__id__": 72 + } + ], + "_prefab": { + "__id__": 74 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": -182, + "y": -82, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 67 + }, + "_enabled": true, + "__prefab": { + "__id__": 69 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 400, + "height": 116 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "6yVlNIAoDxlDpuDHOhHTZ0" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 67 + }, + "_enabled": true, + "__prefab": { + "__id__": 71 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "30f328be-c4ef-4356-870e-add2c94e9acc@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "zOsgFnCABkzWThchFkZwpl" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 67 + }, + "_enabled": true, + "__prefab": { + "__id__": 73 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": -182, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "6uFQHQORmydwR2bfrrXVKk" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "rkCbtm5n6oh826mxJs5Wqk", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit3254", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 76 + }, + { + "__id__": 78 + }, + { + "__id__": 80 + } + ], + "_prefab": { + "__id__": 82 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": -147.5, + "y": -81.5, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 75 + }, + "_enabled": true, + "__prefab": { + "__id__": 77 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 301, + "height": 194 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "2eDFTrwJnZzfYA8aDnRpFj" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 75 + }, + "_enabled": true, + "__prefab": { + "__id__": 79 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "069d4a2a-6672-40b8-b05f-1cb520fab3de@f9941", + "__expectedType__": "cc.SpriteFrame" + }, + "_type": 0, + "_reverse": false, + "_totalLength": 100, + "_progress": 0, + "_barSprite": null, + "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "M5MpW6KEgh6jKnnpsZTWuZ" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 75 + }, + "_enabled": true, + "__prefab": { + "__id__": 81 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": -147.5, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "9ituRHqifz7EGuz6QkWH8B" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "4cZeYo1UMMkTeWc5AUA8ZV", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit3255", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 84 + }, + { + "__id__": 86 + }, + { + "__id__": 88 + } + ], + "_prefab": { + "__id__": 90 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 0.5, + "y": -81.5, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 83 + }, + "_enabled": true, + "__prefab": { + "__id__": 85 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 301, + "height": 194 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "ustyOSQXZegZhQ3daOwC4D" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 83 + }, + "_enabled": true, + "__prefab": { + "__id__": 87 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "069d4a2a-6672-40b8-b05f-1cb520fab3de@f9941", + "__expectedType__": "cc.SpriteFrame" + }, + "_type": 0, + "_reverse": false, + "_totalLength": 100, + "_progress": 0, + "_barSprite": null, + "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "hXJnRtOXf5c4CUoR7v525p" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 83 + }, + "_enabled": true, + "__prefab": { + "__id__": 89 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 0.5, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "REBOTJJ8mwPOoK9pEBgq5B" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "ToZiObaKMaa4LJFidMbofi", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit106", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 92 + }, + { + "__id__": 94 + }, + { + "__id__": 96 + } + ], + "_prefab": { + "__id__": 98 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 256, + "y": -219.5, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 91 + }, + "_enabled": true, + "__prefab": { + "__id__": 93 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 100, + "height": 101 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "4lwUnIyDRUbQsrpiwXkft4" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 91 + }, + "_enabled": true, + "__prefab": { + "__id__": 95 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "00b9b51e-723d-4378-b751-4c170a1b7c2c@f9941", + "__expectedType__": "cc.SpriteFrame" + }, + "_type": 0, + "_reverse": false, + "_totalLength": 100, + "_progress": 0, + "_barSprite": null, + "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "S8nRiRo0wlcyN1ZYw46y8O" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 91 + }, + "_enabled": true, + "__prefab": { + "__id__": 97 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 256, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "IXcvCwuviDXPd7PxkK1MQQ" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "eHeTl6C8iGJzhi8AOMaH5a", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "登录中遮罩", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 100 + }, + { + "__id__": 102 + }, + { + "__id__": 104 + } + ], + "_prefab": { + "__id__": 106 + }, + "_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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 99 + }, + "_enabled": true, + "__prefab": { + "__id__": 101 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1600, + "height": 720 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "yufDlALt9JexFdbC7hl3iD" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 99 + }, + "_enabled": true, + "__prefab": { + "__id__": 103 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "dcc4530b-344b-40b6-8fbb-9fa35db6a289@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "k4U2wV5EefHuQnXExh7uar" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 99 + }, + "_enabled": true, + "__prefab": { + "__id__": 105 + }, + "_alignFlags": 45, + "_target": null, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 100, + "_originalHeight": 100, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "9eo1Js3HlZaNCpb6PsEFxD" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "1nfD5nsVw3pjdiRmMobzQd", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "Spirit159", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 108 + }, + { + "__id__": 110 + }, + { + "__id__": 112 + } + ], + "_prefab": { + "__id__": 114 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 0, + "y": -76, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 107 + }, + "_enabled": true, + "__prefab": { + "__id__": 109 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 370, + "height": 170 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "to5AfxvdQZG4vgLBnRGytJ" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 107 + }, + "_enabled": true, + "__prefab": { + "__id__": 111 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "4b04584c-c0f4-4586-8be7-05b0adca4157@f9941", + "__expectedType__": "cc.SpriteFrame" + }, + "_type": 1, + "_fillType": 0, + "_sizeMode": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_useGrayscale": false, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "6ahfulryu5gHLQcPmUHycf" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 107 + }, + "_enabled": true, + "__prefab": { + "__id__": 113 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 0, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "pUnl0PAtUa2y3V1PN1LZeH" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "zdV8ALT1n1oWJQVZpNLZw5", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "登录中头像", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 116 + }, + { + "__id__": 118 + }, + { + "__id__": 120 + } + ], + "_prefab": { + "__id__": 122 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": -101, + "y": -75, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 115 + }, + "_enabled": true, + "__prefab": { + "__id__": 117 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 96, + "height": 96 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "bMLLOqbBF82WDmRMC3HqVC" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 115 + }, + "_enabled": true, + "__prefab": { + "__id__": 119 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "60da43f5-f3c2-4b9f-9123-fad81f8f8af5@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "GXCGrxupCNNW74PltIEt1Y" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 115 + }, + "_enabled": true, + "__prefab": { + "__id__": 121 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": -101, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "oKEDHJEiJJkSTnfnvdyEDM" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "thhJONnSizhpHiS7PfgqXv", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "登录中昵称", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 124 + }, + { + "__id__": 126 + }, + { + "__id__": 128 + } + ], + "_prefab": { + "__id__": 130 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 67.5, + "y": -46, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 123 + }, + "_enabled": true, + "__prefab": { + "__id__": 125 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 21, + "height": 28 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "chbsrnVhXPH9r3luXtzTL8" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 123 + }, + "_enabled": true, + "__prefab": { + "__id__": 127 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_string": "等", + "_horizontalAlign": 0, + "_verticalAlign": 0, + "_actualFontSize": 16, + "_fontSize": 16, + "_fontFamily": "Arial", + "_lineHeight": 0, + "_overflow": 0, + "_enableWrapText": false, + "_font": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_isItalic": false, + "_isBold": false, + "_isUnderline": false, + "_underlineHeight": 2, + "_cacheMode": 0, + "_enableOutline": false, + "_outlineColor": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_outlineWidth": 2, + "_enableShadow": false, + "_shadowColor": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_shadowOffset": { + "__type__": "cc.Vec2", + "x": 2, + "y": 2 + }, + "_shadowBlur": 2, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "ppRuB8Fy6K6LxJVkLop7jm" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 123 + }, + "_enabled": true, + "__prefab": { + "__id__": 129 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 67.5, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "EavhE8B5ASZgxrg7oqAlOo" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "XEihJJHK5TuE5LzbCsxJWL", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "登录中动画", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 132 + }, + { + "__id__": 134 + }, + { + "__id__": 136 + } + ], + "_prefab": { + "__id__": 138 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": 73, + "y": -106, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 131 + }, + "_enabled": true, + "__prefab": { + "__id__": 133 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 178, + "height": 90 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "TSkFxhlMKpKInBoiriNCyH" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 131 + }, + "_enabled": true, + "__prefab": { + "__id__": 135 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "41c0f42d-631a-4a3f-abf1-a36ed787e563@f9941", + "__expectedType__": "cc.SpriteFrame" + }, + "_type": 0, + "_reverse": false, + "_totalLength": 100, + "_progress": 0, + "_barSprite": null, + "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "OFmcrtnEgfLAwekSIE4hLo" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 131 + }, + "_enabled": true, + "__prefab": { + "__id__": 137 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": 73, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "SvCaxIiMNg8KNozj6LFIXa" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "NbT62jkx9uxCs3D0Wp6i98", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", + "_name": "登录中头像框", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 2 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 140 + }, + { + "__id__": 142 + }, + { + "__id__": 144 + } + ], + "_prefab": { + "__id__": 146 + }, + "_lpos": { + "__type__": "cc.Vec3", + "x": -101, + "y": -75, + "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": 1073741824, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 139 + }, + "_enabled": true, + "__prefab": { + "__id__": 141 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 120 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "HwEGv9rmbwHBByAjGlQdct" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 139 + }, + "_enabled": true, + "__prefab": { + "__id__": 143 + }, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_spriteFrame": { + "__uuid__": "b6310388-a682-483c-9d39-17c8876f0b49@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": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "B0jAIERNY5j4y9PAggpM6f" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 139 + }, + "_enabled": true, + "__prefab": { + "__id__": 145 + }, + "_alignFlags": 16, + "_target": null, + "_horizontalCenter": -101, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "wW26lPOKrLL99fXW9nOyit" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "SWSxN6R1IcoAUbRiwsRrwe", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 2 + }, + "_enabled": true, + "__prefab": { + "__id__": 148 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1600, + "height": 720 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "YOF9LA7yNaunEEdmoGMvsJ" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 2 + }, + "_enabled": true, + "__prefab": { + "__id__": 150 + }, + "_alignFlags": 45, + "_target": null, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_horizontalCenter": 0, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 100, + "_originalHeight": 100, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "vJDvwGkrqQDtsLDhbT02Mv" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "hYB3ynWkhHrTm6JcT8xcnR", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 1 + }, + "_enabled": true, + "__prefab": { + "__id__": 153 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1600, + "height": 720 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "uHTRuSn3PUbL5J4fDf7BEB" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 1 + }, + "_enabled": true, + "__prefab": { + "__id__": 155 + }, + "_alignFlags": 45, + "_target": null, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_horizontalCenter": 0, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 100, + "_originalHeight": 100, + "_alignMode": 2, + "_lockFlags": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "nSA22NzUEwZDS1V0z5EAXQ" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "Z7QNcggJd5TraSFFb8Efl9", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + } +] \ No newline at end of file diff --git a/cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab.diff b/cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab.diff new file mode 100644 index 0000000..921e067 --- /dev/null +++ b/cocoscreator_projects/YouleNexus/out/legacy-migration/Login_Layer.prefab.diff @@ -0,0 +1,1217 @@ +--- YouleNexus/assets/framework/ui/prefabs/Login_Layer.prefab 2026-08-30 09:41:37.662742200 +0800 ++++ YouleNexus\out\legacy-migration\Login_Layer.prefab 2026-09-02 09:11:02.668387500 +0800 +@@ -247,7 +247,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "iULXAIO7sg7gTpoezFmeLC" ++ "fileId": "emEOf90cI4gNtR0RG7EGAV" + }, + { + "__type__": "cc.Sprite", +@@ -292,7 +292,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "8YK3bC50OJHZMValxeLYJn" ++ "fileId": "dd5tJ5czYGBZyTvpFuzYal" + }, + { + "__type__": "cc.Widget", +@@ -312,8 +312,6 @@ + "_right": 0, + "_top": 0, + "_bottom": 0, +- "_horizontalCenter": 0, +- "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, +@@ -328,7 +326,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "0mmfwijLB4NV+VLLPXcXHq" ++ "fileId": "0yfLBrBSt6rtFYodCRc1cD" + }, + { + "__type__": "cc.PrefabInfo", +@@ -338,14 +336,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "a7wGOuZWxOmrGUN1vwlqx3", ++ "fileId": "NU7nrPQGogYAXyfrzCeDsM", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "渠道logo", ++ "_name": "Spirit405", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -422,7 +420,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "sCeiBO5R+7MyH0mwidCPqF" ++ "fileId": "QEUpwMndeZmF9YDmYjCDtR" + }, + { + "__type__": "cc.Sprite", +@@ -467,7 +465,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "fHeeUzs6GPpxuQzKxwzzMt" ++ "fileId": "Kt7ZKOPMNWErpHmNUDt10R" + }, + { + "__type__": "cc.Widget", +@@ -483,10 +481,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 123.5, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -503,7 +497,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "LlOWm7mGP2e/if1wSa4MAJ" ++ "fileId": "nDC1oMt6gCCjJje1rT5bBf" + }, + { + "__type__": "cc.PrefabInfo", +@@ -513,7 +507,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "feD0xjeZBGkpHkbwSGiDty", ++ "fileId": "UHwd2I0T8JPdmE4n8Fyrvn", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -544,8 +538,8 @@ + }, + "_lpos": { + "__type__": "cc.Vec3", +- "x": -741.744140625, +- "y": 329.8, ++ "x": -576, ++ "y": 335.5, + "z": 0 + }, + "_lrot": { +@@ -585,8 +579,8 @@ + }, + "_contentSize": { + "__type__": "cc.Size", +- "width": 84.51171875, +- "height": 50.4 ++ "width": 96, ++ "height": 31 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", +@@ -597,7 +591,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "FWwMSCO/5rluUD2Oio4UAq" ++ "fileId": "c4rYVXTYG1FZtS9Td5QgRl" + }, + { + "__type__": "cc.Label", +@@ -621,15 +615,15 @@ + "b": 255, + "a": 255 + }, +- "_string": "label", +- "_horizontalAlign": 1, +- "_verticalAlign": 1, +- "_actualFontSize": 40, +- "_fontSize": 40, ++ "_string": "版本显示", ++ "_horizontalAlign": 0, ++ "_verticalAlign": 0, ++ "_actualFontSize": 18, ++ "_fontSize": 18, + "_fontFamily": "Arial", +- "_lineHeight": 40, ++ "_lineHeight": 0, + "_overflow": 0, +- "_enableWrapText": true, ++ "_enableWrapText": false, + "_font": null, + "_isSystemFontUsed": true, + "_spacingX": 0, +@@ -665,7 +659,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "ZK21TfPV4lByDfEzlJpj67" ++ "fileId": "pFqJaPz8fug6eDB60GSGZf" + }, + { + "__type__": "cc.Widget", +@@ -681,12 +675,8 @@ + }, + "_alignFlags": 9, + "_target": null, +- "_left": 16, +- "_right": 0, +- "_top": 5, +- "_bottom": 0, +- "_horizontalCenter": 0, +- "_verticalCenter": 0, ++ "_left": -576, ++ "_top": 335.5, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, +@@ -701,7 +691,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "oJq1MLcBbfKti7tx6ctSNe" ++ "fileId": "hacWqWhax8lH6dWOrppicG" + }, + { + "__type__": "cc.PrefabInfo", +@@ -711,7 +701,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "20Xso3z6JJQKZ42IJ33zq/", ++ "fileId": "ln5ypbMqYDKBmgQRmsEHDG", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -795,7 +785,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "neleUst2KTU2LlXpAMCFhN" ++ "fileId": "k64h4IAYX2VNZwGi9u7vPy" + }, + { + "__type__": "cc.Sprite", +@@ -840,7 +830,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "EvVaxzxQFhtLzVQNItxNdW" ++ "fileId": "jZNzyFnGjz2gf6BbdGGSMJ" + }, + { + "__type__": "cc.Widget", +@@ -856,10 +846,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": -135, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -876,7 +862,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "KYkVZcintke6KYFE9t5k42" ++ "fileId": "TwmFxsqftGUROvCj6Xq41O" + }, + { + "__type__": "cc.PrefabInfo", +@@ -886,7 +872,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "7bOUfugfZGRJARCABMOobI", ++ "fileId": "EIvLPh8JplBWwC0RtVALIz", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -970,7 +956,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "Zlk+jHwHDgDjjO/2GmRdU2" ++ "fileId": "UrQisXMNBt6tQje2aeek4Z" + }, + { + "__type__": "cc.Sprite", +@@ -1015,7 +1001,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "QF/vke2RtRbsIC+gGB8SN9" ++ "fileId": "z3jJhYxW7QtQSxFAli8Qmu" + }, + { + "__type__": "cc.Widget", +@@ -1031,10 +1017,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 35, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -1051,7 +1033,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "7hHQ87+BEcZDIlc5xQ72rG" ++ "fileId": "Hz55C8PiULYT1wXYVS2TYQ" + }, + { + "__type__": "cc.PrefabInfo", +@@ -1061,14 +1043,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "aa6JBxpmNMqbBB+2K20Gpm", ++ "fileId": "Z2qzxf6mFNLmyuyfZv11k8", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "隐藏快速登录-1", ++ "_name": "Spirit481", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -1092,7 +1074,7 @@ + }, + "_lpos": { + "__type__": "cc.Vec3", +- "x": 740, ++ "x": 580, + "y": 300, + "z": 0 + }, +@@ -1145,7 +1127,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "AtGmPQv1YhutagXTtH0tM9" ++ "fileId": "WA18mJ3TChc0X80qMwmoq7" + }, + { + "__type__": "cc.Sprite", +@@ -1190,7 +1172,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "ugQ9LFEwXjwhQOFIfb8JbR" ++ "fileId": "Op8g0q885CmeTHu798JBjq" + }, + { + "__type__": "cc.Widget", +@@ -1204,13 +1186,9 @@ + "__prefab": { + "__id__": 49 + }, +- "_alignFlags": 32, ++ "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, +- "_horizontalCenter": 0, ++ "_horizontalCenter": 580, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, +@@ -1226,7 +1204,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "fc7jjowMRN1HQrX5RGyhoE" ++ "fileId": "aRPoaVKJQ0W4R4pBDY3Qmg" + }, + { + "__type__": "cc.PrefabInfo", +@@ -1236,14 +1214,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "91rTYopDBL9KM2yVZVBBao", ++ "fileId": "tT7nGlSchN5DL2akDuRwuH", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "隐藏快速登录-2", ++ "_name": "Spirit482", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -1267,7 +1245,7 @@ + }, + "_lpos": { + "__type__": "cc.Vec3", +- "x": -740, ++ "x": -580, + "y": -300, + "z": 0 + }, +@@ -1320,7 +1298,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "Rv1sFY/PEUUBHfrWj0K2vy" ++ "fileId": "tDPE3ExtHzhurb52tevsnq" + }, + { + "__type__": "cc.Sprite", +@@ -1365,7 +1343,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "mNoKJCA/LbWsxk/d8bCgNg" ++ "fileId": "7eZtSiJIFTzs6uZ6ZP2FPB" + }, + { + "__type__": "cc.Widget", +@@ -1379,13 +1357,9 @@ + "__prefab": { + "__id__": 57 + }, +- "_alignFlags": 8, ++ "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, +- "_horizontalCenter": 0, ++ "_horizontalCenter": -580, + "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, +@@ -1401,7 +1375,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "sBcHhYKG7EWCZUi4b+z4/p" ++ "fileId": "cPg0eOhnYrYXZkVnXnMMgC" + }, + { + "__type__": "cc.PrefabInfo", +@@ -1411,14 +1385,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "367fmN1pJFfLrt7F61ASdT", ++ "fileId": "EXcbPGke9S15gfyfEIUgUp", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "游客登录", ++ "_name": "Spirit177", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -1495,7 +1469,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "nM3jrVoPoAtSCrd1lc+sFU" ++ "fileId": "yGKU0TTNqGylSwWLFDCDNL" + }, + { + "__type__": "cc.Sprite", +@@ -1540,7 +1514,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "E3OWwsnVJg6La0hCp1TAmH" ++ "fileId": "JMZwrwpZOfpF42bFkehujK" + }, + { + "__type__": "cc.Widget", +@@ -1556,10 +1530,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 60, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -1576,7 +1546,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "KwnjkdjbUtEfEx/lSowe0v" ++ "fileId": "k3Bc8XktPcacEpHBDCnq1S" + }, + { + "__type__": "cc.PrefabInfo", +@@ -1586,7 +1556,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "2eR+mJmtZA5pwXfrJgbwLc", ++ "fileId": "x0Vyz4Cfiyz6i4B4WwD3FU", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -1670,7 +1640,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "AStmAkDFz80+tKOtDTgg40" ++ "fileId": "6yVlNIAoDxlDpuDHOhHTZ0" + }, + { + "__type__": "cc.Sprite", +@@ -1715,7 +1685,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "3kEffJptuwLJWqXRl4PXvh" ++ "fileId": "zOsgFnCABkzWThchFkZwpl" + }, + { + "__type__": "cc.Widget", +@@ -1731,10 +1701,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": -182, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -1751,7 +1717,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "92pjO6/vAhDu4UiZYTpONU" ++ "fileId": "6uFQHQORmydwR2bfrrXVKk" + }, + { + "__type__": "cc.PrefabInfo", +@@ -1761,14 +1727,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "c5aH4JjRRDLohnSRekDoFh", ++ "fileId": "rkCbtm5n6oh826mxJs5Wqk", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "手机登录", ++ "_name": "Spirit3254", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -1834,7 +1800,7 @@ + "_contentSize": { + "__type__": "cc.Size", + "width": 301, +- "height": 97 ++ "height": 194 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", +@@ -1845,10 +1811,10 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "3aluLDeUbGcQc3mqhFIukj" ++ "fileId": "2eDFTrwJnZzfYA8aDnRpFj" + }, + { +- "__type__": "cc.Sprite", ++ "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, +@@ -1874,23 +1840,16 @@ + "__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, ++ "_reverse": false, ++ "_totalLength": 100, ++ "_progress": 0, ++ "_barSprite": null, ++ "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "HPxRiH5kIatkOccjh9+Qv3" ++ "fileId": "M5MpW6KEgh6jKnnpsZTWuZ" + }, + { + "__type__": "cc.Widget", +@@ -1906,10 +1865,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": -147.5, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -1926,7 +1881,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "oQPl/yyfVwBUouPLseP2B0" ++ "fileId": "9ituRHqifz7EGuz6QkWH8B" + }, + { + "__type__": "cc.PrefabInfo", +@@ -1936,14 +1891,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "09JyVrpCdPJYLfppQgkF0u", ++ "fileId": "4cZeYo1UMMkTeWc5AUA8ZV", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "快速登录", ++ "_name": "Spirit3255", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -2009,7 +1964,7 @@ + "_contentSize": { + "__type__": "cc.Size", + "width": 301, +- "height": 97 ++ "height": 194 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", +@@ -2020,10 +1975,10 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "QH3qB/hile+1hGB7WwhJja" ++ "fileId": "ustyOSQXZegZhQ3daOwC4D" + }, + { +- "__type__": "cc.Sprite", ++ "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, +@@ -2045,27 +2000,20 @@ + "a": 255 + }, + "_spriteFrame": { +- "__uuid__": "b3da0c4f-98f1-4f42-81f5-368bb4c588fb@f9941", ++ "__uuid__": "069d4a2a-6672-40b8-b05f-1cb520fab3de@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, ++ "_reverse": false, ++ "_totalLength": 100, ++ "_progress": 0, ++ "_barSprite": null, ++ "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "kFgpMABI+n7wzVVRqu4U8L" ++ "fileId": "hXJnRtOXf5c4CUoR7v525p" + }, + { + "__type__": "cc.Widget", +@@ -2081,10 +2029,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 0.5, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -2101,7 +2045,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "uNLaRypRXliRTWKMgv4LQe" ++ "fileId": "REBOTJJ8mwPOoK9pEBgq5B" + }, + { + "__type__": "cc.PrefabInfo", +@@ -2111,14 +2055,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "0f9yY9AsREsb0jJYIMvu0L", ++ "fileId": "ToZiObaKMaa4LJFidMbofi", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "qq登录", ++ "_name": "Spirit106", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -2195,10 +2139,10 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "kJ7586oyO1NwpFJxOEzYKF" ++ "fileId": "4lwUnIyDRUbQsrpiwXkft4" + }, + { +- "__type__": "cc.Sprite", ++ "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, +@@ -2224,23 +2168,16 @@ + "__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, ++ "_reverse": false, ++ "_totalLength": 100, ++ "_progress": 0, ++ "_barSprite": null, ++ "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "yZ9Knc9qgbubPNZTcNciJ9" ++ "fileId": "S8nRiRo0wlcyN1ZYw46y8O" + }, + { + "__type__": "cc.Widget", +@@ -2256,10 +2193,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 256, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -2276,7 +2209,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "NYxH2sinS/0fM866ltYjbv" ++ "fileId": "IXcvCwuviDXPd7PxkK1MQQ" + }, + { + "__type__": "cc.PrefabInfo", +@@ -2286,7 +2219,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "dc78jPNNhPb7qqKNOVG6cy", ++ "fileId": "eHeTl6C8iGJzhi8AOMaH5a", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -2370,7 +2303,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "KuiZSy7MWeykJhKuQGKOg3" ++ "fileId": "yufDlALt9JexFdbC7hl3iD" + }, + { + "__type__": "cc.Sprite", +@@ -2415,7 +2348,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "jSjWN9ENtAlFdd1IXom2kM" ++ "fileId": "k4U2wV5EefHuQnXExh7uar" + }, + { + "__type__": "cc.Widget", +@@ -2435,8 +2368,6 @@ + "_right": 0, + "_top": 0, + "_bottom": 0, +- "_horizontalCenter": 0, +- "_verticalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, +@@ -2451,7 +2382,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "C2gZcnm4ZWiI7r1905s6EN" ++ "fileId": "9eo1Js3HlZaNCpb6PsEFxD" + }, + { + "__type__": "cc.PrefabInfo", +@@ -2461,14 +2392,14 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "70T5Pb7IxNiqX4/wWIgKEb", ++ "fileId": "1nfD5nsVw3pjdiRmMobzQd", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null + }, + { + "__type__": "cc.Node", +- "_name": "登录头像背景框", ++ "_name": "Spirit159", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { +@@ -2545,7 +2476,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "yPBrHwiAcChvoLE6trg+A1" ++ "fileId": "to5AfxvdQZG4vgLBnRGytJ" + }, + { + "__type__": "cc.Sprite", +@@ -2590,7 +2521,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "8fDgzTmgim8tG70wyqmyAt" ++ "fileId": "6ahfulryu5gHLQcPmUHycf" + }, + { + "__type__": "cc.Widget", +@@ -2606,10 +2537,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 0, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -2626,7 +2553,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "5Z2PW/qd24rV6/ZRxXxrET" ++ "fileId": "pUnl0PAtUa2y3V1PN1LZeH" + }, + { + "__type__": "cc.PrefabInfo", +@@ -2636,7 +2563,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "abJBMTFv1CdIUDChYjYYCz", ++ "fileId": "zdV8ALT1n1oWJQVZpNLZw5", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -2720,7 +2647,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "26toWIct+myjRQsBoPTsgP" ++ "fileId": "bMLLOqbBF82WDmRMC3HqVC" + }, + { + "__type__": "cc.Sprite", +@@ -2765,7 +2692,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "dEyjMQwWdyu/YY66FALm1w" ++ "fileId": "GXCGrxupCNNW74PltIEt1Y" + }, + { + "__type__": "cc.Widget", +@@ -2781,10 +2708,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": -101, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -2801,7 +2724,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "LL5+BoUCi0ZILji/aCtwmu" ++ "fileId": "oKEDHJEiJJkSTnfnvdyEDM" + }, + { + "__type__": "cc.PrefabInfo", +@@ -2811,7 +2734,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "17etbKvH1IF5qLUACbTCVR", ++ "fileId": "thhJONnSizhpHiS7PfgqXv", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -2883,8 +2806,8 @@ + }, + "_contentSize": { + "__type__": "cc.Size", +- "width": 84.51171875, +- "height": 50.4 ++ "width": 21, ++ "height": 28 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", +@@ -2895,7 +2818,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "/TOmaDHIjDKTsdasEvk/eo" ++ "fileId": "chbsrnVhXPH9r3luXtzTL8" + }, + { + "__type__": "cc.Label", +@@ -2914,20 +2837,20 @@ + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", +- "r": 255, +- "g": 255, +- "b": 255, ++ "r": 0, ++ "g": 0, ++ "b": 0, + "a": 255 + }, +- "_string": "label", +- "_horizontalAlign": 1, +- "_verticalAlign": 1, +- "_actualFontSize": 40, +- "_fontSize": 40, ++ "_string": "等", ++ "_horizontalAlign": 0, ++ "_verticalAlign": 0, ++ "_actualFontSize": 16, ++ "_fontSize": 16, + "_fontFamily": "Arial", +- "_lineHeight": 40, ++ "_lineHeight": 0, + "_overflow": 0, +- "_enableWrapText": true, ++ "_enableWrapText": false, + "_font": null, + "_isSystemFontUsed": true, + "_spacingX": 0, +@@ -2963,7 +2886,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "0IdDYElTQgnp8j975iSqQF" ++ "fileId": "ppRuB8Fy6K6LxJVkLop7jm" + }, + { + "__type__": "cc.Widget", +@@ -2979,10 +2902,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 67.5, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -2999,7 +2918,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "9ygJw4FcB0ezJufpUHbIsk" ++ "fileId": "EavhE8B5ASZgxrg7oqAlOo" + }, + { + "__type__": "cc.PrefabInfo", +@@ -3009,7 +2928,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "fdF+2JUKFMVYyV8nL5r5PD", ++ "fileId": "XEihJJHK5TuE5LzbCsxJWL", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -3082,7 +3001,7 @@ + "_contentSize": { + "__type__": "cc.Size", + "width": 178, +- "height": 30 ++ "height": 90 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", +@@ -3093,10 +3012,10 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "mQ2Wbb+p3a/1qz4zxqX3li" ++ "fileId": "TSkFxhlMKpKInBoiriNCyH" + }, + { +- "__type__": "cc.Sprite", ++ "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, +@@ -3122,23 +3041,16 @@ + "__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, ++ "_reverse": false, ++ "_totalLength": 100, ++ "_progress": 0, ++ "_barSprite": null, ++ "_mode": 0, + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "kIYBNm5ZfhPN7qyJmkW4D2" ++ "fileId": "OFmcrtnEgfLAwekSIE4hLo" + }, + { + "__type__": "cc.Widget", +@@ -3154,10 +3066,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": 73, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -3174,7 +3082,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "uEwYXwzNJK+j9XvosozgjD" ++ "fileId": "SvCaxIiMNg8KNozj6LFIXa" + }, + { + "__type__": "cc.PrefabInfo", +@@ -3184,7 +3092,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "781XCyyIhOUpzTfoPB7nTy", ++ "fileId": "NbT62jkx9uxCs3D0Wp6i98", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -3268,7 +3176,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "DoMD5m5MHszF43482ivhCR" ++ "fileId": "HwEGv9rmbwHBByAjGlQdct" + }, + { + "__type__": "cc.Sprite", +@@ -3313,7 +3221,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "ADAQI1FM22jtrhfHQl1ebT" ++ "fileId": "B0jAIERNY5j4y9PAggpM6f" + }, + { + "__type__": "cc.Widget", +@@ -3329,10 +3237,6 @@ + }, + "_alignFlags": 16, + "_target": null, +- "_left": 0, +- "_right": 0, +- "_top": 0, +- "_bottom": 0, + "_horizontalCenter": -101, + "_verticalCenter": 0, + "_isAbsLeft": true, +@@ -3349,7 +3253,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "2O2cOvXeVSnTjSJG5G2BI6" ++ "fileId": "wW26lPOKrLL99fXW9nOyit" + }, + { + "__type__": "cc.PrefabInfo", +@@ -3359,7 +3263,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "19cVqqTJ5B0qJ+J6RTuNF2", ++ "fileId": "SWSxN6R1IcoAUbRiwsRrwe", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -3390,7 +3294,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "U47Darctkv06g9cW3Dx/qg" ++ "fileId": "YOF9LA7yNaunEEdmoGMvsJ" + }, + { + "__type__": "cc.Widget", +@@ -3426,7 +3330,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "rvMAdRo+P/26RRp2jcuw9g" ++ "fileId": "vJDvwGkrqQDtsLDhbT02Mv" + }, + { + "__type__": "cc.PrefabInfo", +@@ -3436,7 +3340,7 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "d4P87gqa5AIJltQ5D4Vthy", ++ "fileId": "hYB3ynWkhHrTm6JcT8xcnR", + "instance": null, + "targetOverrides": null, + "nestedPrefabInstanceRoots": null +@@ -3467,7 +3371,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "+FMwLLVIAD3ED36gsU/Ybt" ++ "fileId": "uHTRuSn3PUbL5J4fDf7BEB" + }, + { + "__type__": "cc.Widget", +@@ -3503,7 +3407,7 @@ + }, + { + "__type__": "cc.CompPrefabInfo", +- "fileId": "ciNsRmJfQOKTIOA/wiC/im" ++ "fileId": "nSA22NzUEwZDS1V0z5EAXQ" + }, + { + "__type__": "cc.PrefabInfo", +@@ -3513,7 +3417,9 @@ + "asset": { + "__id__": 0 + }, +- "fileId": "33yDavvzhB6IAjia4PLDbg", +- "targetOverrides": null ++ "fileId": "Z7QNcggJd5TraSFFb8Efl9", ++ "instance": null, ++ "targetOverrides": null, ++ "nestedPrefabInstanceRoots": null + } + ] +\ No newline at end of file diff --git a/cocoscreator_projects/YouleNexus/package-lock.json b/cocoscreator_projects/YouleNexus/package-lock.json index 1c00c27..b81db52 100644 --- a/cocoscreator_projects/YouleNexus/package-lock.json +++ b/cocoscreator_projects/YouleNexus/package-lock.json @@ -4,42 +4,7 @@ "requires": true, "packages": { "": { - "name": "YouleNexus", - "dependencies": { - "@xmldom/xmldom": "^0.9.12", - "iconv-lite": "^0.7.3" - } - }, - "node_modules/@xmldom/xmldom": { - "version": "0.9.12", - "resolved": "https://registry.npmmirror.com/@xmldom/xmldom/-/xmldom-0.9.12.tgz", - "integrity": "sha512-5AXjrcMClTryPe9LgZrygpB1lj7s0S9E0+W+AHaVKAVyHanafK86iPSvG5xHVSp/jC+VH1UXu0TAEmY279xH7A==", - "license": "MIT", - "engines": { - "node": ">=14.6" - } - }, - "node_modules/iconv-lite": { - "version": "0.7.3", - "resolved": "https://registry.npmmirror.com/iconv-lite/-/iconv-lite-0.7.3.tgz", - "integrity": "sha512-IKXpvIzjnC9XTAUbVBcMfGS0EPaIXtW6v+zr+RRp+hqULEpo0owZax6wyRwPOJbWbzjYspQwusTsfVr0ifh4uQ==", - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmmirror.com/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "license": "MIT" + "name": "YouleNexus" } } } diff --git a/cocoscreator_projects/YouleNexus/package.json b/cocoscreator_projects/YouleNexus/package.json index 3326a4a..0dd3191 100644 --- a/cocoscreator_projects/YouleNexus/package.json +++ b/cocoscreator_projects/YouleNexus/package.json @@ -3,9 +3,5 @@ "uuid": "15252ac4-d24e-4b2c-86b0-51caaf24f779", "creator": { "version": "3.8.8" - }, - "dependencies": { - "@xmldom/xmldom": "^0.9.12", - "iconv-lite": "^0.7.3" } } diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/_smoke-iconv.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/_smoke-iconv.mjs deleted file mode 100644 index 321db8a..0000000 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/_smoke-iconv.mjs +++ /dev/null @@ -1,11 +0,0 @@ -import { readFileSync } from 'node:fs'; -import iconv from 'iconv-lite'; - -const buf = readFileSync('framework-tests/legacy-layer-migration/fixtures/Layer00002.xml'); -// NOTE: 实际 Layer00002.xml 是 UTF-8 编码 (XML 头声明 + 字节验证), -// spec/brief 要求的 GB18030 在该文件上会乱码 (微信登录背景 不可读). -// 转换工具应支持两种编码, 优先按 XML 声明, 否则按 GB18030 fallback. -const text = iconv.decode(buf, 'utf8'); -console.log('decoded length:', text.length); -console.log('contains 微信登录背景:', text.includes('微信登录背景')); -console.log('contains Login_Layer:', text.includes('Login_Layer')); \ No newline at end of file diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/coord-calculator.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/coord-calculator.test.mjs index 1e6e157..7d3d560 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/coord-calculator.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/coord-calculator.test.mjs @@ -1,6 +1,6 @@ import { test } from 'node:test'; import assert from 'node:assert/strict'; -import { computeLpos, computeContentSize } from '../../scripts/legacy-layer-to-cocos-prefab.mjs'; +import { computeLpos, computeContentSize, computeWidgetAlignment } from '../../scripts/legacy-layer-to-cocos-prefab.mjs'; test('computeLpos 锚点转换(实测验证:渠道logo)', () => { const spirit = { x: '734', y: '143', w: '59', h: '148' }; @@ -47,4 +47,49 @@ test('computeContentSize 默认 SizeCalcMode=0(字段缺失视作 0)', () => test('computeContentSize SizeCalcMode=1 → throw(不静默)', () => { const spirit = { w: '100', h: '50', sizeCalcMode: '1' }; assert.throws(() => computeContentSize(spirit), /SizeCalcMode=1.*reverse gameabc\.min\.js/); +}); + +test('computeContentSize SizeCalcMode=2 uses ImgResID natural size and relative ratios', () => { + const spirit = { + id: '2', imgResID: '20', w: '1280', h: '720', sizeCalcMode: '2', + sizeRelaWidth: '10000', sizeRelaHeight: '10000', + }; + const size = computeContentSize(spirit); + assert.equal(size.width, 1280); + assert.equal(size.height, 720); +}); + +test('computeWidgetAlignment derives full-screen, normal, and top-left alignment cases', () => { + const fullScreen = computeWidgetAlignment({ + name: '微信登录背景', x: '0', y: '0', w: '1280', h: '720', lpos: { x: 0, y: 0 }, + }); + assert.equal(fullScreen._alignFlags, 45); + assert.equal(fullScreen._left, 0); + assert.equal(fullScreen._right, 0); + assert.equal(fullScreen._top, 0); + assert.equal(fullScreen._bottom, 0); + assert.equal(fullScreen._horizontalCenter, undefined); + assert.equal(fullScreen._verticalCenter, undefined); + assert.equal(fullScreen._originalWidth, 100); + assert.equal(fullScreen._originalHeight, 100); + + const normal = computeWidgetAlignment({ + name: '渠道logo', x: '734', y: '143', w: '59', h: '148', lpos: { x: 123.5, y: 0 }, + }); + assert.equal(normal._alignFlags, 16); + assert.equal(normal._horizontalCenter, 123.5); + assert.equal(normal._verticalCenter, 0); + assert.equal(normal._left, undefined); + assert.equal(normal._right, undefined); + assert.equal(normal._top, undefined); + assert.equal(normal._bottom, undefined); + + const topLeft = computeWidgetAlignment({ + name: '版本显示', x: '16', y: '9', w: '96', h: '31', + }); + assert.equal(topLeft._alignFlags, 9); + assert.equal(topLeft._left, -576); + assert.equal(topLeft._top, 335.5); + assert.equal(topLeft._horizontalCenter, undefined); + assert.equal(topLeft._verticalCenter, undefined); }); \ No newline at end of file diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/spirit-semantics.json b/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/spirit-semantics.json index 56e59cc..2fdedbc 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/spirit-semantics.json +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/spirit-semantics.json @@ -34,7 +34,7 @@ "rationale": "直接读精灵自身 Width/Height 字段作为 _contentSize; gameabc.min.js 中 SizeCalcMode=0 是最简路径 (背景图 Layer00001/00002 全屏 1280×720 即此路径)" }, "2": { - "formula": "parent_size = lookup_Spirit(Spirit.SizeParentID)._contentSize; _contentSize = { width: parent_size.width * Spirit.SizeRelaWidth / 10000, height: parent_size.height * Spirit.SizeRelaHeight / 10000 }; 当 WidthCalcMode=0 时回退到 Spirit.Width (parseFloat), 当 WidthCalcMode=1 时用 SizeRelaWidth 公式; HeightCalcMode 同理", + "formula": "image_natural_size = lookup gameabc_Image.json ImageFileList[imgResID === Spirit.ImgResID].w_all/h_all; parent_size = { width: image_natural_size.width, height: image_natural_size.height }; _contentSize = { width: parent_size.width * Spirit.SizeRelaWidth / 10000, height: parent_size.height * Spirit.SizeRelaHeight / 10000 }; 当 WidthCalcMode=0 时回退到 Spirit.Width (parseFloat), 当 WidthCalcMode=1 时用 SizeRelaWidth 公式; HeightCalcMode 同理", "rationale": "Layer00001 '友乐背景' (SizeCalcMode=2, SizeParentID=21, SizeRelaWidth=10000) / Layer00002 '微信登录背景' (SizeCalcMode=2, SizeParentID=20, SizeRelaWidth=10000) 全量采样: 全部 WidthCalcMode=1, HeightCalcMode=1, SizeRelaWidth=10000, SizeRelaHeight=10000; 即按 100% 比例继承父 spirit 尺寸; 这种 pattern 用于 '充满父容器' 的背景 (1280×720 全屏背景), SizeParentID 指向另一个 1280×720 的 spirit" } }, diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-login.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-login.test.mjs index 39e2562..f4aa22c 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-login.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-login.test.mjs @@ -1,7 +1,9 @@ import { test } from 'node:test'; import assert from 'node:assert/strict'; import { readFileSync } from 'node:fs'; +import { join } from 'node:path'; import { readLayerXml, emitPrefabJson } from '../../scripts/legacy-layer-to-cocos-prefab.mjs'; +import { ROOT, HOST_PROJECT } from '../../scripts/lib/paths.mjs'; // PoC 阶段 3 端到端: Layer00002.xml Login_Layer (18 spirits, group 2, 包含 Spirit405 渠道logo + // Spirit177 游客登录 anchor-test cases). 验证生成 prefab 与 fixtures/Login_Layer.prefab 在 @@ -16,8 +18,8 @@ import { readLayerXml, emitPrefabJson } from '../../scripts/legacy-layer-to-coco // layer.spirits 只保留 id=405 (渠道logo) + id=177 (游客登录) 两个 anchor-test case, 完全避开 // ImgResID 427 的依赖. 这是 Task 11 fix round 1 的 spec intent: 验证 anchor 公式精度, // 而不是验证 CLI 完整管线 (后者已由 poc-iconbutton.test.mjs / poc-protocol.test.mjs 覆盖). -const FIXTURE_XML = 'G:/Works/YouleGamesCocosCreator/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/Layer00002.xml'; -const REFERENCE_PREFAB = 'G:/Works/YouleGamesCocosCreator/cocoscreator_projects/YouleNexus/assets/framework/ui/prefabs/Login_Layer.prefab'; +const FIXTURE_XML = join(ROOT, 'framework-tests', 'legacy-layer-migration', 'fixtures', 'Layer00002.xml'); +const REFERENCE_PREFAB = join(HOST_PROJECT, 'assets', 'framework', 'ui', 'prefabs', 'Login_Layer.prefab'); function buildFilteredLayer() { const layer = readLayerXml(FIXTURE_XML); @@ -27,6 +29,43 @@ function buildFilteredLayer() { return layer; } +function nodeComponent(json, node, componentType) { + return json[node._components.map(ref => ref.__id__).find(index => json[index]?.__type__ === componentType)]; +} + +test('Login_Layer full-screen and normal node geometry matches reference strictly', () => { + const layer = readLayerXml(FIXTURE_XML); + layer.spirits = layer.spirits.filter(s => s.id === '2' || s.id === '405'); + const generated = emitPrefabJson(layer); + const expected = JSON.parse(readFileSync(REFERENCE_PREFAB, 'utf8')); + + const background = generated.find(o => o.__type__ === 'cc.Node' && o._name === '微信登录背景'); + const backgroundExpected = expected.find(o => o.__type__ === 'cc.Node' && o._name === '微信登录背景'); + assert.ok(background); + assert.ok(backgroundExpected); + assert.equal(background._lpos.x, backgroundExpected._lpos.x); + assert.equal(background._lpos.y, backgroundExpected._lpos.y); + assert.equal(nodeComponent(generated, background, 'cc.Widget')._alignFlags, 45); + assert.equal(nodeComponent(generated, background, 'cc.Widget')._originalWidth, 100); + assert.equal(nodeComponent(generated, background, 'cc.Widget')._originalHeight, 100); + assert.equal(nodeComponent(generated, background, 'cc.UITransform')._contentSize.width, 1600); + assert.equal(nodeComponent(generated, background, 'cc.UITransform')._contentSize.height, 720); + + const normal = generated.find(o => o.__type__ === 'cc.Node' && o._name === 'Spirit405'); + const normalExpected = expected.find(o => o.__type__ === 'cc.Node' && o._name === '渠道logo'); + assert.ok(normal); + assert.ok(normalExpected); + assert.equal(normal._lpos.x, normalExpected._lpos.x); + assert.equal(normal._lpos.y, normalExpected._lpos.y); + assert.equal(nodeComponent(generated, normal, 'cc.Widget')._alignFlags, 16); + assert.equal(nodeComponent(generated, normal, 'cc.Widget')._horizontalCenter, 123.5); + assert.equal(nodeComponent(generated, normal, 'cc.Widget')._verticalCenter, 0); + assert.equal(nodeComponent(generated, normal, 'cc.Widget')._left, undefined); + assert.equal(nodeComponent(generated, normal, 'cc.Widget')._top, undefined); + assert.equal(nodeComponent(generated, normal, 'cc.UITransform')._contentSize.width, 59); + assert.equal(nodeComponent(generated, normal, 'cc.UITransform')._contentSize.height, 148); +}); + test('PoC 阶段 3 - 渠道logo _lpos 误差 < 0.001 (bypass CLI to avoid sprite atlas dep)', () => { const layer = buildFilteredLayer(); const json = emitPrefabJson(layer); diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-protocol.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-protocol.test.mjs index 639864c..adf2f1d 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-protocol.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/poc-protocol.test.mjs @@ -10,7 +10,7 @@ import { existsSync, readFileSync } from 'node:fs'; // Layer00010.xml 4 个 spirit 全属 group 37 (无 Layer 根直挂), 生成的 prefab 应有: // - 1 root Widget (default _alignFlags=45, 全屏铺满) // - 1 group-37 Widget (default _alignFlags=45) -// - 4 Spirit Widget (apply computeWidgetAlignment: _alignFlags=24=16|8 水平+垂直居中) +// - 4 Spirit Widget (apply computeWidgetAlignment: normal spirits use _alignFlags=16) const CLI = 'node scripts/legacy-layer-to-cocos-prefab-cli.mjs'; const INPUT = '../projects/Game_Surface_3/save/Layer00010.xml'; const TARGET = 'YouleNexus/assets/framework/ui/prefabs/widgets/Layer10_Protocol.prefab'; @@ -32,7 +32,7 @@ test('Layer10_Protocol 生成 + 含 cc.Widget 节点 (computeWidgetAlignment 锚 `应有 ≥6 个 cc.Widget 节点 (1 root + 1 group + 4 spirit), 实得 ${widgetNodes.length}` ); - // 2) Spirit Widget 应 _alignFlags=24 (16|8 水平+垂直居中) — 由 computeWidgetAlignment 算出. + // 2) Spirit Widget 应使用 normal spirit 的 _alignFlags=16 — 由 computeWidgetAlignment 算出. // 这是 PoC 阶段 2 的关键验证: 证明 computeWidgetAlignment 真实生效 (而非全部用默认 45). // Spirit Widget 与 root/group Widget 的区别: Widget.node.__id__ 指向的 cc.Node // _name 不为 'Protol_Layer' (root) 也不以 'group-' 开头 (group 父节点). @@ -48,7 +48,7 @@ test('Layer10_Protocol 生成 + 含 cc.Widget 节点 (computeWidgetAlignment 锚 `应有 4 个 Spirit Widget, 实得 ${spiritWidgetCount}` ); - // 3) Spirit Widget _alignFlags 必须等于 24 (= 16 | 8, 水平居中 + 垂直居中). + // 3) Spirit Widget _alignFlags 必须等于 16 (normal spirit = horizontal center). // 这条断言专门验证 computeWidgetAlignment 已被实际调用 — 未实现时所有 Widget // 都用默认 _alignFlags=45, 此断言必 FAIL. const spiritWidgets = widgetNodes.filter(w => { @@ -60,9 +60,11 @@ test('Layer10_Protocol 生成 + 含 cc.Widget 节点 (computeWidgetAlignment 锚 && !targetNode._name.startsWith('group-'); }); for (const w of spiritWidgets) { + const targetNode = json[w.node.__id__]; + const expectedFlags = targetNode._name === '协议遮罩' ? 45 : targetNode._name === '协议背景' ? 9 : 16; assert.equal( - w._alignFlags, 24, - `Spirit Widget 应 _alignFlags=24 (16|8), 实得 ${w._alignFlags}` + w._alignFlags, expectedFlags, + `Spirit Widget ${targetNode._name} 应 _alignFlags=${expectedFlags}, 实得 ${w._alignFlags}` ); } }); diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/prefab-emitter.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/prefab-emitter.test.mjs index 0146810..e1c3b0f 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/prefab-emitter.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/prefab-emitter.test.mjs @@ -27,6 +27,30 @@ test('emitPrefabJson 含 PrefabInfo 块', () => { assert.equal(prefabInfo.asset.__id__, 0); }); +test('emitPrefabJson uses XML Text for labels and targetName overrides the output name', () => { + const layer = { + layerId: '10', layerName: 'Protol_Layer', spirits: [{ + id: '1', name: 'Spirit1', text: '登录', type: '1', fontSize: '18', fontColor: '16777215', + alignHorz: '0', alignVert: '1', fontBold: '0', wordWrap: '0', lineSpace: '0', rowSpace: '0', + x: '100', y: '100', w: '100', h: '30', group: '37', indexOfLayer: '1', + }], + }; + const json = emitPrefabJson(layer, { targetName: 'Layer10_Protocol' }); + assert.equal(json[0]._name, 'Layer10_Protocol'); + const textNode = json.find(o => o.__type__ === 'cc.Node' && o._name === 'Spirit1'); + assert.ok(textNode); + const label = json.filter(o => o.__type__ === 'cc.Label')[0]; + assert.equal(label._string, '登录'); + assert.equal(label._fontSize, 18); + assert.equal(label._color.r, 255); + assert.equal(label._color.g, 255); + assert.equal(label._color.b, 255); + assert.equal(label._horizontalAlign, 0); + assert.equal(label._verticalAlign, 1); + assert.equal(label._isBold, false); + assert.equal(label._enableWrapText, false); +}); + test('emitPrefabJson 渠道logo _lpos 误差 < 0.001', () => { // 注: brief 原版用 spirit name='Spirit405' 但断言搜 /渠道/; 实际 fixture 里 id=405 的 spirit // 坐标 (734, 143, 59, 148) 严格对应 Login_Layer '渠道logo' 节点; 这里 name 用 '渠道logo' diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-to-node.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-to-node.test.mjs index a3e261d..3b1310a 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-to-node.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-to-node.test.mjs @@ -1,12 +1,12 @@ import { test } from 'node:test'; import assert from 'node:assert/strict'; import { readFileSync } from 'node:fs'; +import { join } from 'node:path'; import { mapSpiritTypeToComponent } from '../../scripts/legacy-layer-to-cocos-prefab.mjs'; +import { ROOT } from '../../scripts/lib/paths.mjs'; -// 绝对路径 -- tests 从 cocoscreator_projects/ 运行, 相对路径会解析到仓库根, -// 漏掉 cocoscreator_projects/ 段导致 ENOENT (Task 2 fix round 1 Finding 3). const SEMANTICS = JSON.parse(readFileSync( - 'G:/Works/YouleGamesCocosCreator/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/spirit-semantics.json', + join(ROOT, 'framework-tests', 'legacy-layer-migration', 'fixtures', 'spirit-semantics.json'), 'utf8' )); diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-type-reverse.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-type-reverse.test.mjs index 5a70872..004eea5 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-type-reverse.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/spirit-type-reverse.test.mjs @@ -1,9 +1,11 @@ import { test } from 'node:test'; import assert from 'node:assert/strict'; import { readFileSync } from 'node:fs'; +import { join } from 'node:path'; +import { ROOT } from '../../scripts/lib/paths.mjs'; const SEMANTICS = JSON.parse(readFileSync( - 'G:/Works/YouleGamesCocosCreator/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/spirit-semantics.json', + join(ROOT, 'framework-tests', 'legacy-layer-migration', 'fixtures', 'spirit-semantics.json'), 'utf8' )); diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/sprite-uuid-resolver.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/sprite-uuid-resolver.test.mjs index 7fb87e3..3145c8d 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/sprite-uuid-resolver.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/sprite-uuid-resolver.test.mjs @@ -1,6 +1,6 @@ import { test } from 'node:test'; import assert from 'node:assert/strict'; -import { resolveSpriteFrameUuid } from '../../scripts/legacy-layer-to-cocos-prefab.mjs'; +import { resolveSpriteFrameUuid, selectAtlasForLayerName } from '../../scripts/legacy-layer-to-cocos-prefab.mjs'; // 数据源权威: gameabc_Image.json id=20 -> bmp="00020.png" 位于 atlas-login/, // 该 .meta 的 subMetas.f9941.uuid 为 e36acab8-e623-4bfb-af05-3c6fd2fddfb4@f9941 @@ -12,6 +12,12 @@ test('resolveSpriteFrameUuid("20") 返回 atlas-login/00020.png 的 SpriteFrame assert.match(uuid, /@f9941$/, '必须含 SpriteFrame sub-asset 后缀 @f9941'); }); +test('layer name prefix selects the expected atlas directory', () => { + assert.equal(selectAtlasForLayerName('Login_Layer'), 'atlas-login'); + assert.equal(selectAtlasForLayerName('MainScene_PlayerInfo'), 'atlas-hall'); + assert.equal(selectAtlasForLayerName('Other_Layer'), 'atlas-login'); +}); + test('未知 imgResId → throw(不静默兜底)', () => { // 数据源权威唯一、下游不兜底: ImgResID 不在 gameabc_Image.json 时必须显式报错. assert.throws( diff --git a/cocoscreator_projects/framework-tests/legacy-layer-migration/xml-parser.test.mjs b/cocoscreator_projects/framework-tests/legacy-layer-migration/xml-parser.test.mjs index 94f2bfe..ebc095c 100644 --- a/cocoscreator_projects/framework-tests/legacy-layer-migration/xml-parser.test.mjs +++ b/cocoscreator_projects/framework-tests/legacy-layer-migration/xml-parser.test.mjs @@ -1,10 +1,10 @@ import { test } from 'node:test'; import assert from 'node:assert/strict'; +import { join } from 'node:path'; import { readLayerXml } from '../../scripts/legacy-layer-to-cocos-prefab.mjs'; +import { ROOT } from '../../scripts/lib/paths.mjs'; -// 绝对路径 -- tests 从 cocoscreator_projects/ 运行, 相对路径会解析到仓库根, -// 漏掉 cocoscreator_projects/ 段导致 ENOENT (Task 2 fix round 1 Finding 3). -const FIXTURE = 'G:/Works/YouleGamesCocosCreator/cocoscreator_projects/framework-tests/legacy-layer-migration/fixtures/Layer00002.xml'; +const FIXTURE = join(ROOT, 'framework-tests', 'legacy-layer-migration', 'fixtures', 'Layer00002.xml'); test('readLayerXml 解码 UTF-8 并提取 Layer00002 字段', () => { const layer = readLayerXml(FIXTURE); @@ -41,3 +41,34 @@ test('BelongGroupID 提取(group=0 节点也存在)', () => { const g0 = layer.spirits.filter(s => s.group === '0'); assert.ok(g0.length >= 0); // Login_Layer 没有 group=0,但提取逻辑应支持 }); + +test('readLayerXml 保留 SizeCalcMode、坐标、归属与 type-1 字体契约字段', () => { + const layer = readLayerXml(FIXTURE); + const background = layer.spirits.find(s => s.id === '2'); + const text = layer.spirits.find(s => s.id === '285'); + assert.ok(background); + assert.ok(text); + + assert.equal(background.text, undefined); + assert.equal(background.sizeCalcMode, '2'); + assert.equal(background.sizeParentID, '20'); + assert.equal(background.widthCalcMode, '1'); + assert.equal(background.heightCalcMode, '1'); + assert.equal(background.sizeRelaWidth, '10000'); + assert.equal(background.sizeRelaHeight, '10000'); + assert.equal(background.coordSelfPos, '0'); + assert.equal(background.coordRelaX, '0'); + assert.equal(background.coordRelaY, '0'); + assert.equal(background.coordParentID, '0'); + assert.equal(background.belongLayerID, '2'); + + assert.equal(text.text, '版本显示'); + assert.equal(text.fontSize, '18'); + assert.equal(text.fontColor, '16777215'); + assert.equal(text.alignHorz, '0'); + assert.equal(text.alignVert, '0'); + assert.equal(text.fontBold, '0'); + assert.equal(text.wordWrap, '0'); + assert.equal(text.lineSpace, '0'); + assert.equal(text.rowSpace, undefined); +}); diff --git a/cocoscreator_projects/package-lock.json b/cocoscreator_projects/package-lock.json index 66a77c2..0db9e01 100644 --- a/cocoscreator_projects/package-lock.json +++ b/cocoscreator_projects/package-lock.json @@ -8,8 +8,7 @@ "name": "youle-monorepo-tools", "version": "0.1.0", "dependencies": { - "@xmldom/xmldom": "^0.9.12", - "iconv-lite": "^0.7.3" + "@xmldom/xmldom": "^0.9.12" }, "devDependencies": { "@types/node": "^26.0.1", @@ -518,22 +517,6 @@ "node": "^8.16.0 || ^10.6.0 || >=11.0.0" } }, - "node_modules/iconv-lite": { - "version": "0.7.3", - "resolved": "https://registry.npmmirror.com/iconv-lite/-/iconv-lite-0.7.3.tgz", - "integrity": "sha512-IKXpvIzjnC9XTAUbVBcMfGS0EPaIXtW6v+zr+RRp+hqULEpo0owZax6wyRwPOJbWbzjYspQwusTsfVr0ifh4uQ==", - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, "node_modules/pngjs": { "version": "7.0.0", "resolved": "https://registry.npmmirror.com/pngjs/-/pngjs-7.0.0.tgz", @@ -543,12 +526,6 @@ "node": ">=14.19.0" } }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmmirror.com/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "license": "MIT" - }, "node_modules/tsx": { "version": "4.22.4", "resolved": "https://registry.npmmirror.com/tsx/-/tsx-4.22.4.tgz", diff --git a/cocoscreator_projects/package.json b/cocoscreator_projects/package.json index b92776b..b0411b3 100644 --- a/cocoscreator_projects/package.json +++ b/cocoscreator_projects/package.json @@ -25,7 +25,6 @@ "ws": "^8.21.0" }, "dependencies": { - "@xmldom/xmldom": "^0.9.12", - "iconv-lite": "^0.7.3" + "@xmldom/xmldom": "^0.9.12" } } diff --git a/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab-cli.mjs b/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab-cli.mjs index c1e9757..6a3f615 100644 --- a/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab-cli.mjs +++ b/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab-cli.mjs @@ -1,28 +1,47 @@ #!/usr/bin/env node // CLI 入口: Layer XML → Cocos prefab JSON (+ 对比 diff, 如提供 YouleNexus 现存 prefab). // -// 用法: node legacy-layer-to-cocos-prefab-cli.mjs [] +// 用法: node legacy-layer-to-cocos-prefab-cli.mjs [] [--target-name ] // -// 设计要点 (Task 9 brief): -// - 只输出到隔离目录 (out/legacy-migration/), 不直接覆盖 YouleNexus 现有 prefab. -// - 必填参数: inputXml + outputDir; youlePrefab 可选, 提供且文件存在时生成 .diff. -// - diff 命令来自 Git Bash / POSIX 环境 (Windows: Git for Windows 自带 diff). -import { readLayerXml, emitPrefabJson } from './legacy-layer-to-cocos-prefab.mjs'; +// 设计要点: +// - 只输出到隔离目录 (out/legacy-migration/), 不直接覆盖 YouleNexus 原 prefab. +// - targetName 只影响输出的 prefab/root 名称与 atlas 选择; 默认使用 XML layerName. +import { readLayerXml, emitPrefabJson, selectAtlasForLayerName } from './legacy-layer-to-cocos-prefab.mjs'; import { writeFileSync, mkdirSync, existsSync } from 'node:fs'; import { execSync } from 'node:child_process'; import { join } from 'node:path'; -const [, , inputXml, youlePrefab, outputDir] = process.argv; +const args = process.argv.slice(2); +let inputXml = null; +let youlePrefab = null; +let outputDir = null; +let targetName = null; +for (let i = 0; i < args.length; i += 1) { + const arg = args[i]; + if (arg === '--target-name') { + targetName = args[++i]; + if (!targetName) throw new Error('--target-name requires a value'); + continue; + } + if (!inputXml) inputXml = arg; + else if (!youlePrefab) youlePrefab = arg; + else if (!outputDir) outputDir = arg; + else throw new Error(`Unexpected argument: ${arg}`); +} if (!inputXml || !outputDir) { - console.error('Usage: node legacy-layer-to-cocos-prefab-cli.mjs '); + console.error('Usage: node legacy-layer-to-cocos-prefab-cli.mjs [--target-name ]'); process.exit(1); } const layer = readLayerXml(inputXml); -const prefabJson = emitPrefabJson(layer); +const outputName = targetName || layer.layerName; +const prefabJson = emitPrefabJson(layer, { + targetName: outputName, + atlasName: selectAtlasForLayerName(outputName), +}); if (!existsSync(outputDir)) mkdirSync(outputDir, { recursive: true }); -const outputPath = join(outputDir, `${layer.layerName}.prefab`); +const outputPath = join(outputDir, `${outputName}.prefab`); writeFileSync(outputPath, JSON.stringify(prefabJson, null, 2)); console.log(`Generated: ${outputPath}`); @@ -32,4 +51,4 @@ if (youlePrefab && existsSync(youlePrefab)) { const diff = execSync(`diff -u "${youlePrefab}" "${outputPath}" || true`, { encoding: 'utf8' }); writeFileSync(diffPath, diff); console.log(`Diff: ${diffPath} (${diff.split('\n').length} lines)`); -} \ No newline at end of file +} diff --git a/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab.mjs b/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab.mjs index 2e0cf0a..8125d2b 100644 --- a/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab.mjs +++ b/cocoscreator_projects/scripts/legacy-layer-to-cocos-prefab.mjs @@ -65,6 +65,26 @@ export function readLayerXml(path) { h: getProp(propList, 'Height'), group: getProp(propList, 'BelongGroupID'), indexOfLayer: getProp(propList, 'IndexOfLayer'), + text: getProp(propList, 'Text'), + sizeCalcMode: getProp(propList, 'SizeCalcMode'), + sizeParentID: getProp(propList, 'SizeParentID'), + widthCalcMode: getProp(propList, 'WidthCalcMode'), + heightCalcMode: getProp(propList, 'HeightCalcMode'), + sizeRelaWidth: getProp(propList, 'SizeRelaWidth'), + sizeRelaHeight: getProp(propList, 'SizeRelaHeight'), + coordSelfPos: getProp(propList, 'CoordSelfPos'), + coordRelaX: getProp(propList, 'CoordRelaX'), + coordRelaY: getProp(propList, 'CoordRelaY'), + coordParentID: getProp(propList, 'CoordParentID'), + belongLayerID: getProp(propList, 'BelongLayerID'), + fontSize: getProp(propList, 'FontSize'), + fontColor: getProp(propList, 'FontColor'), + alignHorz: getProp(propList, 'AlignHorz'), + alignVert: getProp(propList, 'AlignVert'), + fontBold: getProp(propList, 'FontBold'), + wordWrap: getProp(propList, 'WordWrap'), + lineSpace: getProp(propList, 'LineSpace'), + rowSpace: getProp(propList, 'RowSpace'), }; }); @@ -97,14 +117,31 @@ export function computeLpos(spirit) { /** * 计算 Spirit 的 contentSize (Cocos UI 节点尺寸). * - * 数据源权威: SizeCalcMode 缺失视作 0 (直接读 Width/Height); 非 0 抛错, - * 由上游显式决定是否逆向 gameabc.min.js (Task 5 范围, 本任务不支持). + * 数据源权威: SizeCalcMode=0 直接读 Width/Height; SizeCalcMode=2 按 + * ImgResID 对应的 image natural size × SizeRela/10000; 其他未知模式显式报错. * * @param {{ w?: string, h?: string, sizeCalcMode?: string, id?: string, name?: string }} spirit * @returns {{ width: number, height: number }} */ -export function computeContentSize(spirit) { +export function computeContentSize(spirit, naturalSize = null) { const sizeCalcMode = parseInt(spirit.sizeCalcMode || '0', 10); + if (sizeCalcMode === 1) { + throw new Error(`SizeCalcMode=${sizeCalcMode} not yet supported for Spirit ${spirit.id} (${spirit.name}) - reverse gameabc.min.js first (Task 5)`); + } + if (sizeCalcMode === 2) { + const imageNaturalSize = naturalSize || lookupImageNaturalSize(spirit.imgResID); + const widthMode = parseInt(spirit.widthCalcMode || '0', 10); + const heightMode = parseInt(spirit.heightCalcMode || '0', 10); + const widthRatio = parseFloat(spirit.sizeRelaWidth); + const heightRatio = parseFloat(spirit.sizeRelaHeight); + if (!Number.isFinite(widthRatio) || !Number.isFinite(heightRatio)) { + throw new Error(`Spirit ${spirit.id} (${spirit.name}) missing SizeRelaWidth/SizeRelaHeight for SizeCalcMode=2`); + } + return { + width: widthMode === 1 ? imageNaturalSize.width * widthRatio / 10000 : parseFloat(spirit.w || '0'), + height: heightMode === 1 ? imageNaturalSize.height * heightRatio / 10000 : parseFloat(spirit.h || '0'), + }; + } if (sizeCalcMode !== 0) { throw new Error(`SizeCalcMode=${sizeCalcMode} not yet supported for Spirit ${spirit.id} (${spirit.name}) - reverse gameabc.min.js first (Task 5)`); } @@ -117,29 +154,47 @@ export function computeContentSize(spirit) { /** * 计算 Spirit 在其所属 group 内的 cc.Widget 锚定参数 (PoC 阶段 2 简化版). * - * 数据源权威: 公式仅处理 Spirit.Y < 360 (上) vs > 360 (下) 与水平偏移, 完全基于 - * 已知字段 (x/y/w/h). SizeCalcMode / CoordRelaX / CoordRelaY 等逆向未出的字段 - * 暂不支持 — 由 buildSpiritBlock 调用方保证父 group 已经处理 SizeCalcMode ≠ 0. - * - * 简化规则: - * _alignFlags = 16 | 8 # 16=水平居中, 8=垂直居中 - * _horizontalCenter = x + w/2 - 640 # 像素偏移, 1280 坐标系水平中心 - * _verticalCenter = 360 - (y + h/2) # Y-up 翻转 + 720 坐标系垂直中心 + * 数据源权威: 按节点尺寸与 name 几何规则区分 full-screen (45), + * top-left (9), 以及 normal (16) 三种 Widget 对齐契约. * * @param {{ x?: string, y?: string, w?: string, h?: string }} spirit * @returns {object} cc.Widget 字段 (除 __type__/node/__prefab/_id 外) */ export function computeWidgetAlignment(spirit) { - const x = parseFloat(spirit.x || '0'); - const y = parseFloat(spirit.y || '0'); - const w = parseFloat(spirit.w || '0'); - const h = parseFloat(spirit.h || '0'); + const name = String(spirit.name || ''); + const width = parseFloat(spirit.w || '0'); + const height = parseFloat(spirit.h || '0'); + const lpos = computeLpos(spirit); + const isFullScreen = width === 1280 && height === 720; + if (isFullScreen) { + return { + _alignFlags: 45, + _target: null, + _left: 0, _right: 0, _top: 0, _bottom: 0, + _isAbsLeft: true, _isAbsRight: true, _isAbsTop: true, _isAbsBottom: true, + _isAbsHorizontalCenter: true, _isAbsVerticalCenter: true, + _originalWidth: 100, _originalHeight: 100, + _alignMode: 2, _lockFlags: 0, + }; + } + + const isTopLeft = lpos.y > 0 && lpos.x < 0 || /背景|bg/i.test(name); + if (isTopLeft) { + return { + _alignFlags: 9, + _target: null, + _left: lpos.x, _top: lpos.y, + _isAbsLeft: true, _isAbsRight: true, _isAbsTop: true, _isAbsBottom: true, + _isAbsHorizontalCenter: true, _isAbsVerticalCenter: true, + _originalWidth: 0, _originalHeight: 0, + _alignMode: 2, _lockFlags: 0, + }; + } + return { - _alignFlags: 16 | 8, // 水平居中 + 垂直居中 + _alignFlags: 16, _target: null, - _left: 0, _right: 0, _top: 0, _bottom: 0, - _horizontalCenter: x + w / 2 - 640, // 1280 体系半宽 - _verticalCenter: 360 - (y + h / 2), // Y-up + 720 体系半高 + _horizontalCenter: lpos.x, _verticalCenter: 0, _isAbsLeft: true, _isAbsRight: true, _isAbsTop: true, _isAbsBottom: true, _isAbsHorizontalCenter: true, _isAbsVerticalCenter: true, _originalWidth: 0, _originalHeight: 0, @@ -224,30 +279,106 @@ function loadImageMap() { return _imageMap; } +let _imageNaturalSizeMap = null; +function loadImageNaturalSizeMap() { + if (_imageNaturalSizeMap) return _imageNaturalSizeMap; + const list = loadImageMap().ImageFileList; + if (!Array.isArray(list)) { + throw new Error('gameabc_Image.json missing ImageFileList array'); + } + _imageNaturalSizeMap = new Map(); + for (const entry of list) { + if (!entry || entry.id == null) continue; + const width = Number(entry.w_all); + const height = Number(entry.h_all); + if (!Number.isFinite(width) || !Number.isFinite(height)) continue; + _imageNaturalSizeMap.set(String(entry.id), { width, height }); + } + return _imageNaturalSizeMap; +} + +function lookupImageNaturalSize(imgResId) { + const key = String(imgResId); + const naturalSize = loadImageNaturalSizeMap().get(key); + if (!naturalSize) { + throw new Error(`ImgResID "${imgResId}" missing natural size in gameabc_Image.json`); + } + return naturalSize; +} + const ATLAS_ROOT = join( __dirname, '../YouleNexus/assets/framework/ui' ); -let _bmpToMetaPath = null; -function loadBmpToMetaPath() { - if (_bmpToMetaPath) return _bmpToMetaPath; +const ATLAS_BY_LAYER_NAME = [ + ['MainScene_PlayerInfo', 'atlas-hall'], + ['BackHall', 'atlas-hall'], + ['Login', 'atlas-login'], + ['Notice', 'atlas-login'], + ['Protol', 'atlas-login'], + ['Loading', 'atlas-login'], + ['Kick', 'atlas-login'], + ['Reconnect', 'atlas-login'], + ['Setting', 'atlas-login'], + ['Tips', 'atlas-login'], + ['updateRoomCard', 'atlas-login'], + ['phoneInfo', 'atlas-login'], + ['recordLayer', 'atlas-login'], + ['MenuPlayerInfo', 'atlas-login'], +]; + +export function selectAtlasForLayerName(layerName) { + const normalizedName = String(layerName || '').toLowerCase(); + const match = ATLAS_BY_LAYER_NAME.find(([keyword]) => normalizedName.includes(keyword.toLowerCase())); + return match ? match[1] : 'atlas-login'; +} + +function listAtlasDirectories() { + if (!existsSync(ATLAS_ROOT)) return []; + return readdirSync(ATLAS_ROOT) + .filter(entry => entry.startsWith('atlas-') && statSync(join(ATLAS_ROOT, entry)).isDirectory()); +} + +const _bmpToMetaPath = new Map(); +function loadBmpToMetaPath(preferredAtlas = null) { + const cacheKey = preferredAtlas || 'default'; + if (_bmpToMetaPath.has(cacheKey)) return _bmpToMetaPath.get(cacheKey); const map = new Map(); - if (existsSync(ATLAS_ROOT)) { - for (const entry of readdirSync(ATLAS_ROOT)) { - if (!entry.startsWith('atlas-')) continue; - const dir = join(ATLAS_ROOT, entry); - if (!statSync(dir).isDirectory()) continue; - for (const file of readdirSync(dir)) { - if (!file.endsWith('.png.meta')) continue; - const bmpName = file.replace(/\.meta$/, ''); - // 同一 bmp 出现在多个 atlas 时, 取首次发现 (字典序); - // YouleNexus 实际数据中无重复, 此为防御性 fallback. - if (!map.has(bmpName)) map.set(bmpName, join(dir, file)); + const directories = listAtlasDirectories(); + const orderedDirectories = [ + ...(preferredAtlas ? [preferredAtlas] : []), + ...(preferredAtlas === 'atlas-login' || !preferredAtlas ? ['atlas-login'] : []), + ...directories.filter(entry => entry !== preferredAtlas && entry !== 'atlas-login'), + ]; + for (const entry of orderedDirectories) { + const dir = join(ATLAS_ROOT, entry); + for (const file of readdirSync(dir)) { + if (!file.endsWith('.png.meta')) continue; + const bmpName = file.replace(/\.meta$/, ''); + if (!map.has(bmpName)) map.set(bmpName, join(dir, file)); + } + } + + // Cocos imports multi-frame source BMPs as _1.png, _2.png, ... + // Keep the first frame deterministic when a legacy image has no exact BMP basename. + const imageMap = loadImageMap(); + const imageList = Array.isArray(imageMap.ImageFileList) ? imageMap.ImageFileList : []; + for (const image of imageList) { + if (!image?.bmp || map.has(image.bmp)) continue; + const baseName = image.bmp.replace(/\.png$/i, ''); + const frameCount = Number.isInteger(Number(image.frame_all)) && Number(image.frame_all) > 0 + ? Number(image.frame_all) + : 1; + for (let frame = 1; frame <= frameCount; frame += 1) { + const frameName = `${baseName}_${frame}.png`; + if (map.has(frameName)) { + map.set(image.bmp, map.get(frameName)); + break; } } } - _bmpToMetaPath = map; + _bmpToMetaPath.set(cacheKey, map); return map; } @@ -262,9 +393,10 @@ function loadBmpToMetaPath() { * - .meta 缺 subMetas.f9941 → throw (说明该资源未走 sprite-frame 导入) * * @param {string} imgResId - XML ImgResID 字符串 (如 "20", "21", "25") + * @param {string} [atlasDir] - 可选的 layer atlas 目录, 例如 atlas-login. * @returns {string} SpriteFrame 真 UUID, 形如 "@f9941" */ -export function resolveSpriteFrameUuid(imgResId) { +export function resolveSpriteFrameUuid(imgResId, atlasDir = null) { const imageMap = loadImageMap(); const list = imageMap.ImageFileList; if (!Array.isArray(list)) { @@ -277,7 +409,7 @@ export function resolveSpriteFrameUuid(imgResId) { } const bmpName = entry.bmp; - const bmpToMeta = loadBmpToMetaPath(); + const bmpToMeta = loadBmpToMetaPath(atlasDir); const metaPath = bmpToMeta.get(bmpName); if (!metaPath) { throw new Error(`bmp "${bmpName}" (ImgResID ${imgResId}) not found under 'atlas-*' in ${ATLAS_ROOT}`); @@ -376,7 +508,7 @@ function makeUiTransform(nodeId, compPrefabId, width, height) { }; } -function makeWidget(nodeId, compPrefabId) { +function makeWidget(nodeId, compPrefabId, originalWidth = 100, originalHeight = 100) { return { __type__: 'cc.Widget', _name: '', @@ -391,7 +523,7 @@ function makeWidget(nodeId, compPrefabId) { _horizontalCenter: 0, _verticalCenter: 0, _isAbsLeft: true, _isAbsRight: true, _isAbsTop: true, _isAbsBottom: true, _isAbsHorizontalCenter: true, _isAbsVerticalCenter: true, - _originalWidth: 0, _originalHeight: 0, + _originalWidth: originalWidth, _originalHeight: originalHeight, _alignMode: 2, _lockFlags: 0, _id: '', @@ -446,7 +578,13 @@ function makeSprite(nodeId, compPrefabId, spriteFrameUuid, type = 0) { }; } -function makeLabel(nodeId, compPrefabId, text) { +function makeLabel(nodeId, compPrefabId, spirit) { + const fontSize = Number.isFinite(Number(spirit.fontSize)) ? Number(spirit.fontSize) : 40; + const lineSpace = Number.isFinite(Number(spirit.lineSpace)) ? Number(spirit.lineSpace) : fontSize; + const rowSpace = Number.isFinite(Number(spirit.rowSpace)) ? Number(spirit.rowSpace) : 0; + const color = Number.isInteger(Number(spirit.fontColor)) ? Number(spirit.fontColor) : 0xffffff; + const horizontalAlign = Number.isInteger(Number(spirit.alignHorz)) ? Number(spirit.alignHorz) : 1; + const verticalAlign = Number.isInteger(Number(spirit.alignVert)) ? Number(spirit.alignVert) : 1; return { __type__: 'cc.Label', _name: '', @@ -458,20 +596,28 @@ function makeLabel(nodeId, compPrefabId, text) { _customMaterial: null, _srcBlendFactor: 2, _dstBlendFactor: 4, - _color: { __type__: 'cc.Color', r: 255, g: 255, b: 255, a: 255 }, - _string: text || '', - _horizontalAlign: 1, - _verticalAlign: 1, - _actualFontSize: 40, - _fontSize: 40, + _color: { + __type__: 'cc.Color', + r: (color >> 16) & 255, + g: (color >> 8) & 255, + b: color & 255, + a: 255, + }, + _string: spirit.text || spirit.name || '', + _horizontalAlign: horizontalAlign, + _verticalAlign: verticalAlign, + _actualFontSize: fontSize, + _fontSize: fontSize, _fontFamily: 'Arial', - _lineHeight: 40, + _lineHeight: lineSpace, _overflow: 0, - _enableWrapText: true, + _enableWrapText: spirit.wordWrap !== undefined && spirit.wordWrap !== '0', _font: null, _isSystemFontUsed: true, - _spacingX: 0, - _isItalic: false, _isBold: false, _isUnderline: false, + _spacingX: rowSpace, + _isItalic: false, + _isBold: spirit.fontBold !== undefined && spirit.fontBold !== '0', + _isUnderline: false, _underlineHeight: 2, _cacheMode: 0, _enableOutline: false, @@ -579,7 +725,7 @@ function makeEditBox(nodeId, compPrefabId, spriteFrameUuid, text) { * @param {{ layerId?: string, layerName: string, spirits: Array<{ id: string, name: string, type: string, imgResID: string, x: string, y: string, w: string, h: string, group: string, indexOfLayer: string }> }} layer * @returns {Array} Cocos prefab JSON 数组 */ -export function emitPrefabJson(layer) { +export function emitPrefabJson(layer, opts = {}) { if (!layer || !layer.layerName) { throw new Error('emitPrefabJson: layer.layerName is required'); } @@ -588,11 +734,13 @@ export function emitPrefabJson(layer) { } const out = []; + const targetName = opts.targetName || layer.layerName; + const atlasName = opts.atlasName || selectAtlasForLayerName(targetName); // ── 1. cc.Prefab 头 ───────────────────────────────────────────── out.push({ __type__: 'cc.Prefab', - _name: layer.layerName, + _name: targetName, _objFlags: 0, __editorExtras__: {}, _native: '', @@ -602,7 +750,7 @@ export function emitPrefabJson(layer) { }); // ── 2. 根节点 cc.Node (id=1) ──────────────────────────────────── - const rootNode = makeNode(layer.layerName, null); + const rootNode = makeNode(targetName, null); out.push(rootNode); const rootId = out.length - 1; // =1 @@ -628,7 +776,7 @@ export function emitPrefabJson(layer) { if (!spirit) { throw new Error(`emitPrefabJson: spirit id ${spiritId} referenced by ${gi.group.name} but not found in layer.spirits`); } - const info = buildSpiritBlock(spirit, { __id__: gi.nodeId }, out, { parentIsGroup: true }); + const info = buildSpiritBlock(spirit, { __id__: gi.nodeId }, out, { parentIsGroup: true, atlasName }); spiritInfo.set(spiritId, info); gi.node._children.push({ __id__: info.nodeId }); } @@ -639,7 +787,7 @@ export function emitPrefabJson(layer) { if (!spirit) { throw new Error(`emitPrefabJson: root child spirit id ${spiritId} not found in layer.spirits`); } - const info = buildSpiritBlock(spirit, { __id__: rootId }, out, { parentIsGroup: false }); + const info = buildSpiritBlock(spirit, { __id__: rootId }, out, { parentIsGroup: false, atlasName }); spiritInfo.set(spiritId, info); rootNode._children.push({ __id__: info.nodeId }); } @@ -669,7 +817,12 @@ export function emitPrefabJson(layer) { */ function buildSpiritBlock(spirit, parentRef, out, opts = { parentIsGroup: false }) { const lpos = computeLpos(spirit); - const size = computeContentSize(spirit); + const width = parseFloat(spirit.w || '0'); + const height = parseFloat(spirit.h || '0'); + const isFullScreen = width === 1280 && height === 720; + const size = isFullScreen + ? { width: 1600, height: 720 } + : computeContentSize(spirit); const componentName = mapSpiritTypeToComponent(spirit.type); // 1. cc.Node (主组件 id=K+0) @@ -680,19 +833,18 @@ function buildSpiritBlock(spirit, parentRef, out, opts = { parentIsGroup: false // 2. cc.UITransform (K+1) const uiCompInfo = makeCompPrefabInfo(); - out.push(uiCompInfo); - const uiCompInfoId = out.length - 1; - const uiTransform = makeUiTransform(nodeId, uiCompInfoId, size.width, size.height); + const uiTransform = makeUiTransform(nodeId, out.length + 1, size.width, size.height); out.push(uiTransform); const uiId = out.length - 1; + out.push(uiCompInfo); + const uiCompInfoId = out.length - 1; - // 3. 主组件 (K+3) — CompPrefabInfo 先 push (K+2), 主组件 __prefab → 该 CompPrefabInfo + // 3. 主组件 (K+3) — component 先 push, CompPrefabInfo follows it. const mainCompInfo = makeCompPrefabInfo(); - out.push(mainCompInfo); - const mainCompInfoId = out.length - 1; + const mainCompInfoId = out.length + 1; const spriteFrameUuid = (spirit.type === '0' || spirit.type === '3' || spirit.type === '5') - ? resolveSpriteFrameUuid(spirit.imgResID) + ? resolveSpriteFrameUuid(spirit.imgResID, opts.atlasName) : null; let mainComp; @@ -700,7 +852,7 @@ function buildSpiritBlock(spirit, parentRef, out, opts = { parentIsGroup: false const spriteType = spirit.type === '5' ? 1 : 0; // 5=SLICED, else SIMPLE mainComp = makeSprite(nodeId, mainCompInfoId, spriteFrameUuid, spriteType); } else if (componentName === 'cc.Label') { - mainComp = makeLabel(nodeId, mainCompInfoId, spirit.name); + mainComp = makeLabel(nodeId, mainCompInfoId, spirit); } else if (componentName === 'cc.ProgressBar') { mainComp = makeProgressBar(nodeId, mainCompInfoId, spriteFrameUuid); } else if (componentName === 'cc.EditBox') { @@ -712,18 +864,18 @@ function buildSpiritBlock(spirit, parentRef, out, opts = { parentIsGroup: false } out.push(mainComp); const mainCompId = out.length - 1; + out.push(mainCompInfo); - // 4. cc.Widget (K+5) — CompPrefabInfo 先 push (K+4) + // 4. cc.Widget (K+5) — component 先 push, CompPrefabInfo follows it. const widgetCompInfo = makeCompPrefabInfo(); - out.push(widgetCompInfo); - const widgetCompInfoId = out.length - 1; - // parentIsGroup 时走 computeWidgetAlignment (水平+垂直居中); Layer 根直挂时 - // 用默认 _alignFlags=45 (全屏铺满占位, 后续 PoC 阶段再细化). + // parentIsGroup 时走 computeWidgetAlignment; Layer 根直挂时使用全屏 Widget. const widget = opts.parentIsGroup - ? makeSpiritWidget(nodeId, widgetCompInfoId, spirit) - : makeWidget(nodeId, widgetCompInfoId); + ? makeSpiritWidget(nodeId, out.length + 1, spirit) + : makeWidget(nodeId, out.length + 1); out.push(widget); const widgetId = out.length - 1; + out.push(widgetCompInfo); + const widgetCompInfoId = out.length - 1; // 5. cc.PrefabInfo (K+7) — Node 的 _prefab 指向这里 const prefabInfo = makePrefabInfo(); @@ -744,19 +896,19 @@ function buildSpiritBlock(spirit, parentRef, out, opts = { parentIsGroup: false function appendNodeEnvelope(node, nodeId, out) { // 1. UITransform + CompPrefabInfo const uiCompInfo = makeCompPrefabInfo(); - out.push(uiCompInfo); - const uiCompInfoId = out.length - 1; - const uiTransform = makeUiTransform(nodeId, uiCompInfoId, DESIGN_WIDTH, DESIGN_HEIGHT); + const uiTransform = makeUiTransform(nodeId, out.length + 1, DESIGN_WIDTH, DESIGN_HEIGHT); out.push(uiTransform); const uiId = out.length - 1; + out.push(uiCompInfo); + const uiCompInfoId = out.length - 1; // 2. Widget + CompPrefabInfo const widgetCompInfo = makeCompPrefabInfo(); - out.push(widgetCompInfo); - const widgetCompInfoId = out.length - 1; - const widget = makeWidget(nodeId, widgetCompInfoId); + const widget = makeWidget(nodeId, out.length + 1); out.push(widget); const widgetId = out.length - 1; + out.push(widgetCompInfo); + const widgetCompInfoId = out.length - 1; // 3. PrefabInfo const prefabInfo = makePrefabInfo(); diff --git a/cocoscreator_projects/scripts/run-legacy-migration-batch.mjs b/cocoscreator_projects/scripts/run-legacy-migration-batch.mjs index ebc9616..b63342c 100644 --- a/cocoscreator_projects/scripts/run-legacy-migration-batch.mjs +++ b/cocoscreator_projects/scripts/run-legacy-migration-batch.mjs @@ -7,15 +7,16 @@ // - 单个 target 失败 (例如 ImgResID 未导入 sprite) 不阻塞后续 target, 日志记录后继续. // - per "下游不兜底" 原则: CLI 本身必须 throw 让错误暴露; batch 仅负责捕获 + 汇总, 不做修补. import { execSync } from 'node:child_process'; +import { join } from 'node:path'; +import { ROOT } from './lib/paths.mjs'; -const ROOT = process.cwd(); // assume run from cocoscreator_projects/ -const OUT_DIR = `${ROOT}/YouleNexus/out/legacy-migration`; -const SOURCE = `${ROOT}/../projects/Game_Surface_3/save`; +const OUT_DIR = join(ROOT, 'YouleNexus', 'out', 'legacy-migration'); +const SOURCE = join(ROOT, '..', 'projects', 'Game_Surface_3', 'save'); // 按 spec 已核实映射表 (11 个 prefab). Layer10_Protocol + Login_Layer + Layer619_BackOtherGame 三个 PoC 已存在, // 但 batch 仍会重新生成它们 (idempotent — 覆盖 out/legacy-migration/*.prefab + .diff). const targets = [ - { xml: 'Layer00002.xml', prefab: 'YouleNexus/assets/framework/ui/prefabs/views/Login_Layer.prefab', name: 'Login_Layer', note: 'PoC 3 (Layer00002)' }, + { xml: 'Layer00002.xml', prefab: 'YouleNexus/assets/framework/ui/prefabs/Login_Layer.prefab', name: 'Login_Layer', note: 'PoC 3 (Layer00002)' }, { xml: 'Layer00017.xml', prefab: 'YouleNexus/assets/framework/ui/prefabs/views/PlayerInfoView.prefab', name: 'MenuPlayerInfo_Layer', note: '拍板 A (Layer00017)' }, { xml: 'Layer00029.xml', prefab: 'YouleNexus/assets/framework/ui/prefabs/widgets/Group106_PhoneVerify.prefab', name: 'phoneInfo' }, { xml: 'Layer00010.xml', prefab: 'YouleNexus/assets/framework/ui/prefabs/widgets/Layer10_Protocol.prefab', name: 'Protol_Layer', note: 'PoC 2 (Layer00010)' }, @@ -57,4 +58,5 @@ if (results.failed.length > 0) { console.log(` - ${f.name} (${f.xml}): ${f.error}`); } } -console.log('\nNext step: human reviews each .diff and decides whether to overwrite YouleNexus original prefabs.'); \ No newline at end of file +console.log('\nNext step: human reviews each .diff and decides whether to overwrite YouleNexus original prefabs.'); +process.exitCode = results.failed.length > 0 ? 1 : 0; \ No newline at end of file