From 66b20533d7f90e10cfd412cd4dda01108c8aa3d8 Mon Sep 17 00:00:00 2001 From: cd <-> Date: Fri, 2 Jun 2023 02:09:50 +0800 Subject: [PATCH] =?UTF-8?q?=E7=9B=B8=E6=9C=BA=E8=A7=92=E5=BA=A6=E8=AE=BE?= =?UTF-8?q?=E7=BD=AE=20sprite=E5=AF=B9=E8=B1=A1=20=E9=80=9A=E7=94=A8?= =?UTF-8?q?=E6=97=8B=E8=BD=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/Assets/Game/Driver.unity | 11 ++++++++--- client/Assets/Game/Scripts/ECS/Util/UtilComponent.cs | 1 + client/Assets/Game/Scripts/_Define/GameConstStatic.cs | 2 ++ client/Assets/Resources/Prefab/Player.prefab | 6 +++--- 4 files changed, 14 insertions(+), 6 deletions(-) diff --git a/client/Assets/Game/Driver.unity b/client/Assets/Game/Driver.unity index f81aea6..52dc805 100644 --- a/client/Assets/Game/Driver.unity +++ b/client/Assets/Game/Driver.unity @@ -475,7 +475,7 @@ Transform: - {fileID: 1679791624} m_Father: {fileID: 2053699350} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 30, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: 35, y: 0, z: 0} --- !u!114 &530533505 MonoBehaviour: m_ObjectHideFlags: 0 @@ -1021,14 +1021,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1481844499} - m_LocalRotation: {x: 0.2588191, y: 0, z: 0, w: 0.9659258} + m_LocalRotation: {x: 0.30070576, y: 0, z: 0, w: 0.953717} m_LocalPosition: {x: 0, y: 6.0000014, z: -9.892304} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - {fileID: 441416963} m_Father: {fileID: 2053699350} m_RootOrder: 1 - m_LocalEulerAnglesHint: {x: 30, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: 35, y: 0, z: 0} --- !u!114 &1481844501 MonoBehaviour: m_ObjectHideFlags: 0 @@ -1456,6 +1456,11 @@ PrefabInstance: m_Modification: m_TransformParent: {fileID: 0} m_Modifications: + - target: {fileID: 89448209117170303, guid: 2ee37d7e6a339064ab6466f552ca0edb, + type: 3} + propertyPath: m_Size.x + value: 2 + objectReference: {fileID: 0} - target: {fileID: 89448209117170303, guid: 2ee37d7e6a339064ab6466f552ca0edb, type: 3} propertyPath: m_Size.y diff --git a/client/Assets/Game/Scripts/ECS/Util/UtilComponent.cs b/client/Assets/Game/Scripts/ECS/Util/UtilComponent.cs index dd35d01..02839ed 100644 --- a/client/Assets/Game/Scripts/ECS/Util/UtilComponent.cs +++ b/client/Assets/Game/Scripts/ECS/Util/UtilComponent.cs @@ -88,6 +88,7 @@ public partial class GameEntity view.Material = view.SpriteRenderer.material; view.Collider = go.GetComponent(); view.LocalPositionOrder = Vector3.forward * GameRandom.Random(0, 0.01f); + view.TransformViewRot.localRotation = GameConst.CommonRot; } public void AddMove() diff --git a/client/Assets/Game/Scripts/_Define/GameConstStatic.cs b/client/Assets/Game/Scripts/_Define/GameConstStatic.cs index 70924bf..ac30a41 100644 --- a/client/Assets/Game/Scripts/_Define/GameConstStatic.cs +++ b/client/Assets/Game/Scripts/_Define/GameConstStatic.cs @@ -16,6 +16,8 @@ namespace Game public static Vector3 DownLeft = new Vector3(-1, 0, -1).normalized; public static Vector3 DownRight = new Vector3(1, 0, -1).normalized; + public static Quaternion CommonRot = Quaternion.AngleAxis(10, Vector3.right); + public static readonly Dictionary MoveCommand2Dir = new Dictionary() { diff --git a/client/Assets/Resources/Prefab/Player.prefab b/client/Assets/Resources/Prefab/Player.prefab index 98f493c..8af70a2 100644 --- a/client/Assets/Resources/Prefab/Player.prefab +++ b/client/Assets/Resources/Prefab/Player.prefab @@ -274,16 +274,16 @@ SpriteRenderer: m_SortingLayerID: -248419617 m_SortingLayer: 3 m_SortingOrder: 0 - m_Sprite: {fileID: 9044786021765537137, guid: 915fdee616812fc41a3f1e169bef3f0f, + m_Sprite: {fileID: 1762012598533887728, guid: a4bf04d287237394b8f4312ef1b32cdf, type: 3} m_Color: {r: 1, g: 1, b: 1, a: 1} m_FlipX: 0 m_FlipY: 0 m_DrawMode: 0 - m_Size: {x: 2, y: 1} + m_Size: {x: 0.89, y: 0.98} m_AdaptiveModeThreshold: 0.5 m_SpriteTileMode: 0 - m_WasSpriteAssigned: 0 + m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 --- !u!95 &4414991602654513556