From 2e0c2601c0cfacbe7061df8b7ad447a6395ce102 Mon Sep 17 00:00:00 2001 From: ruanwujing <1220792244@qq.com> Date: Tue, 30 Jan 2024 18:33:25 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9D=90=E8=B4=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/resources/materials/color_sdf2d.mtl | 12 ++ .../resources/materials/color_sdf2d.mtl.meta | 11 ++ assets/resources/scenes/roundbox.scene | 148 +++++++++++++++--- 3 files changed, 153 insertions(+), 18 deletions(-) create mode 100644 assets/resources/materials/color_sdf2d.mtl create mode 100644 assets/resources/materials/color_sdf2d.mtl.meta diff --git a/assets/resources/materials/color_sdf2d.mtl b/assets/resources/materials/color_sdf2d.mtl new file mode 100644 index 0000000..a674cc2 --- /dev/null +++ b/assets/resources/materials/color_sdf2d.mtl @@ -0,0 +1,12 @@ +{ + "__type__": "cc.Material", + "_name": "", + "_objFlags": 0, + "_native": "", + "_effectAsset": { + "__uuid__": "c8f66d17-351a-48da-a12c-0212d28575c4" + }, + "_techIdx": 0, + "_defines": [], + "_props": [] +} diff --git a/assets/resources/materials/color_sdf2d.mtl.meta b/assets/resources/materials/color_sdf2d.mtl.meta new file mode 100644 index 0000000..d9f7dc7 --- /dev/null +++ b/assets/resources/materials/color_sdf2d.mtl.meta @@ -0,0 +1,11 @@ +{ + "ver": "1.0.21", + "importer": "material", + "imported": true, + "uuid": "850a900c-3c24-42f7-94ee-688c31fedea9", + "files": [ + ".json" + ], + "subMetas": {}, + "userData": {} +} diff --git a/assets/resources/scenes/roundbox.scene b/assets/resources/scenes/roundbox.scene index 66a204a..e48ab10 100644 --- a/assets/resources/scenes/roundbox.scene +++ b/assets/resources/scenes/roundbox.scene @@ -58,7 +58,7 @@ }, "autoReleaseAssets": false, "_globals": { - "__id__": 22 + "__id__": 25 }, "_id": "64bd0402-59ce-4670-ae7d-24b450f09bb9" }, @@ -269,18 +269,21 @@ }, { "__id__": 16 + }, + { + "__id__": 19 } ], "_active": true, "_components": [ { - "__id__": 19 + "__id__": 22 }, { - "__id__": 20 + "__id__": 23 }, { - "__id__": 21 + "__id__": 24 } ], "_prefab": null, @@ -372,7 +375,7 @@ "_priority": 1073741824, "_fov": 45, "_fovAxis": 0, - "_orthoHeight": 459.1304347826087, + "_orthoHeight": 360, "_near": 1, "_far": 2000, "_color": { @@ -716,6 +719,115 @@ "_rightBottom": true, "_id": "f2CeSLb09FPaKE976Tc3TG" }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "__editorExtras__": {}, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 20 + }, + { + "__id__": 21 + } + ], + "_prefab": null, + "_lpos": { + "__type__": "cc.Vec3", + "x": -69.187, + "y": 171.008, + "z": 0 + }, + "_lrot": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_lscale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_mobility": 0, + "_layer": 33554432, + "_euler": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_id": "daHt73Q9xPzY16iZRwJzEs" + }, + { + "__type__": "cc.UITransform", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 19 + }, + "_enabled": true, + "__prefab": null, + "_contentSize": { + "__type__": "cc.Size", + "width": 600, + "height": 130.39999999999998 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_id": "98cda6wV5JLIXYD+NyZ/Ii" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "__editorExtras__": {}, + "node": { + "__id__": 19 + }, + "_enabled": true, + "__prefab": null, + "_customMaterial": null, + "_srcBlendFactor": 2, + "_dstBlendFactor": 4, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_string": "修改顶点实现圆角,不改材质,在合批方面完全可以看做是普通的sprite。", + "_horizontalAlign": 1, + "_verticalAlign": 1, + "_actualFontSize": 40, + "_fontSize": 40, + "_fontFamily": "Arial", + "_lineHeight": 40, + "_overflow": 3, + "_enableWrapText": true, + "_font": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_isItalic": false, + "_isBold": false, + "_isUnderline": false, + "_underlineHeight": 2, + "_cacheMode": 0, + "_id": "fadO2qZxVJT7cg7SzoCeIZ" + }, { "__type__": "cc.UITransform", "_name": "", @@ -787,29 +899,29 @@ { "__type__": "cc.SceneGlobals", "ambient": { - "__id__": 23 - }, - "shadows": { - "__id__": 24 - }, - "_skybox": { - "__id__": 25 - }, - "fog": { "__id__": 26 }, - "octree": { + "shadows": { "__id__": 27 }, - "skin": { + "_skybox": { "__id__": 28 }, - "lightProbeInfo": { + "fog": { "__id__": 29 }, - "postSettings": { + "octree": { "__id__": 30 }, + "skin": { + "__id__": 31 + }, + "lightProbeInfo": { + "__id__": 32 + }, + "postSettings": { + "__id__": 33 + }, "bakedWithStationaryMainLight": false, "bakedWithHighpLightmap": false },