From d351b4dc6fd7fd9f225496437a9791801a08db14 Mon Sep 17 00:00:00 2001 From: JenChieh Date: Thu, 18 Jul 2024 22:07:10 -0700 Subject: [PATCH] feat: Add transparent sprite util --- Assets/JCSUnity/Common.meta | 8 ++ .../Extra.meta => Common/Sprites.meta} | 0 .../Sprites}/transparent_256.png | Bin .../Sprites}/transparent_256.png.meta | 0 .../Sprites}/transparent_512.png | Bin .../Sprites}/transparent_512.png.meta | 0 Assets/JCSUnity/Resources/JCS_Managers.prefab | 20 ++-- .../Scripts/Managers/JCS_UtilitiesManager.cs | 8 ++ .../_Project/Scenes/UI/FT_VersionText.unity | 1 - ProjectSettings/SceneTemplateSettings.json | 97 +++++------------- 10 files changed, 53 insertions(+), 81 deletions(-) create mode 100644 Assets/JCSUnity/Common.meta rename Assets/JCSUnity/{Sprites/Extra.meta => Common/Sprites.meta} (100%) rename Assets/JCSUnity/{Sprites/Extra => Common/Sprites}/transparent_256.png (100%) rename Assets/JCSUnity/{Sprites/Extra => Common/Sprites}/transparent_256.png.meta (100%) rename Assets/JCSUnity/{Sprites/Extra => Common/Sprites}/transparent_512.png (100%) rename Assets/JCSUnity/{Sprites/Extra => Common/Sprites}/transparent_512.png.meta (100%) diff --git a/Assets/JCSUnity/Common.meta b/Assets/JCSUnity/Common.meta new file mode 100644 index 000000000..8a3a2a8ef --- /dev/null +++ b/Assets/JCSUnity/Common.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d6b043b767b4f62488bcf180898be19d +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/JCSUnity/Sprites/Extra.meta b/Assets/JCSUnity/Common/Sprites.meta similarity index 100% rename from Assets/JCSUnity/Sprites/Extra.meta rename to Assets/JCSUnity/Common/Sprites.meta diff --git a/Assets/JCSUnity/Sprites/Extra/transparent_256.png b/Assets/JCSUnity/Common/Sprites/transparent_256.png similarity index 100% rename from Assets/JCSUnity/Sprites/Extra/transparent_256.png rename to Assets/JCSUnity/Common/Sprites/transparent_256.png diff --git a/Assets/JCSUnity/Sprites/Extra/transparent_256.png.meta b/Assets/JCSUnity/Common/Sprites/transparent_256.png.meta similarity index 100% rename from Assets/JCSUnity/Sprites/Extra/transparent_256.png.meta rename to Assets/JCSUnity/Common/Sprites/transparent_256.png.meta diff --git a/Assets/JCSUnity/Sprites/Extra/transparent_512.png b/Assets/JCSUnity/Common/Sprites/transparent_512.png similarity index 100% rename from Assets/JCSUnity/Sprites/Extra/transparent_512.png rename to Assets/JCSUnity/Common/Sprites/transparent_512.png diff --git a/Assets/JCSUnity/Sprites/Extra/transparent_512.png.meta b/Assets/JCSUnity/Common/Sprites/transparent_512.png.meta similarity index 100% rename from Assets/JCSUnity/Sprites/Extra/transparent_512.png.meta rename to Assets/JCSUnity/Common/Sprites/transparent_512.png.meta diff --git a/Assets/JCSUnity/Resources/JCS_Managers.prefab b/Assets/JCSUnity/Resources/JCS_Managers.prefab index abb3ad248..6d2ffb547 100644 --- a/Assets/JCSUnity/Resources/JCS_Managers.prefab +++ b/Assets/JCSUnity/Resources/JCS_Managers.prefab @@ -40,6 +40,7 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 135910} + serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} @@ -50,7 +51,6 @@ Transform: - {fileID: 1678435914} - {fileID: 4161427194650725801} m_Father: {fileID: 0} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &11496914 MonoBehaviour: @@ -143,7 +143,6 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 4bbeb25e792087645b19e4cf30c3218a, type: 3} m_Name: m_EditorClassIdentifier: - mGamePause: 0 mGameDoneInitialize: 0 --- !u!114 &11439248 MonoBehaviour: @@ -157,13 +156,13 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 06ceabc1c1c745c44a60262572a8c61b, type: 3} m_Name: m_EditorClassIdentifier: + mNextSceneName: mBlackScreen: {fileID: 0} mBlackSlideScreen: {fileID: 0} mAlign: 0 mPopWhiteScreen: 1 mWhiteScreen: {fileID: 0} mSwitchSceneType: 1 - mPauseGameWhileLoadingScene: 1 mOverrideSetting: 0 mSceneFadeInTime: 1 mSceneFadeOutTime: 1 @@ -190,6 +189,7 @@ AudioSource: serializedVersion: 4 OutputAudioMixerGroup: {fileID: 0} m_audioClip: {fileID: 0} + m_Resource: {fileID: 0} m_PlayOnAwake: 1 m_Volume: 1 m_Pitch: 1 @@ -359,6 +359,7 @@ MonoBehaviour: mMixDamageTextPool: {fileID: 0} mIGLogSystem: {fileID: 0} mDialogueSystem: {fileID: 0} + mSpriteTransparent: {fileID: 21300000, guid: c7eced5e94022104d917659ef2734bf4, type: 3} --- !u!114 &11461692 MonoBehaviour: m_ObjectHideFlags: 0 @@ -403,6 +404,7 @@ MonoBehaviour: mIncTime: 110 mDecTime: 109 mTimeDelta: 5 + mPaused: 0 mTargetTimeScale: 1 mPauseActions: [] mDefaultTimeScale: 1 @@ -434,13 +436,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1678435913} + serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 442828} - m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &4065819051853472555 MonoBehaviour: @@ -481,13 +483,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 2102792923} + serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 442828} - m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &3569791717532981135 MonoBehaviour: @@ -553,13 +555,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1000012022687026} + serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 442828} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &114000014013781274 MonoBehaviour: @@ -615,13 +617,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 4502074130992445992} + serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 442828} - m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &3393683539091338131 MonoBehaviour: @@ -643,11 +645,7 @@ MonoBehaviour: mDragDisplacement: {x: 0, y: 0} mDragging: 0 mTouchTime: 0 - mMultiTouch: 0 - mTouchDistance: 0 - mTouchDistanceDelta: 0 mMouseType: 0 - mDetectTouchCount: 1 --- !u!114 &3255448869455908852 MonoBehaviour: m_ObjectHideFlags: 0 diff --git a/Assets/JCSUnity/Scripts/Managers/JCS_UtilitiesManager.cs b/Assets/JCSUnity/Scripts/Managers/JCS_UtilitiesManager.cs index 7127af9fd..ca25dc214 100644 --- a/Assets/JCSUnity/Scripts/Managers/JCS_UtilitiesManager.cs +++ b/Assets/JCSUnity/Scripts/Managers/JCS_UtilitiesManager.cs @@ -35,6 +35,12 @@ public class JCS_UtilitiesManager : JCS_Manager [ReadOnly] private JCS_DialogueSystem mDialogueSystem = null; + [Separator("Initialize Variables (JCS_UtilitiesManager)")] + + [Tooltip("Trasnparent sprite.")] + [SerializeField] + private Sprite mSpriteTransparent = null; + /* Setter & Getter */ public void SetMixDamageTextPool(JCS_MixDamageTextPool tp) { this.mMixDamageTextPool = tp; } @@ -46,6 +52,8 @@ public class JCS_UtilitiesManager : JCS_Manager public void SetDiaglogueSystem(JCS_DialogueSystem ds) { this.mDialogueSystem = ds; } public JCS_DialogueSystem GetDialogueSystem() { return this.mDialogueSystem; } + public Sprite SpriteTransparent { get { return this.mSpriteTransparent; } } + /* Functions */ private void Awake() diff --git a/Assets/_Project/Scenes/UI/FT_VersionText.unity b/Assets/_Project/Scenes/UI/FT_VersionText.unity index fde4cac28..328bc451f 100644 --- a/Assets/_Project/Scenes/UI/FT_VersionText.unity +++ b/Assets/_Project/Scenes/UI/FT_VersionText.unity @@ -38,7 +38,6 @@ RenderSettings: m_ReflectionIntensity: 1 m_CustomReflection: {fileID: 0} m_Sun: {fileID: 0} - m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1} m_UseRadianceAmbientProbe: 0 --- !u!157 &3 LightmapSettings: diff --git a/ProjectSettings/SceneTemplateSettings.json b/ProjectSettings/SceneTemplateSettings.json index 6f3e60fd8..6ed312ae2 100644 --- a/ProjectSettings/SceneTemplateSettings.json +++ b/ProjectSettings/SceneTemplateSettings.json @@ -4,164 +4,123 @@ { "userAdded": false, "type": "UnityEngine.AnimationClip", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEditor.Animations.AnimatorController", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.AnimatorOverrideController", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEditor.Audio.AudioMixerController", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.ComputeShader", - "ignore": true, - "defaultInstantiationMode": 1, - "supportsModification": true + "defaultInstantiationMode": 1 }, { "userAdded": false, "type": "UnityEngine.Cubemap", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.GameObject", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEditor.LightingDataAsset", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": false + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.LightingSettings", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.Material", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEditor.MonoScript", - "ignore": true, - "defaultInstantiationMode": 1, - "supportsModification": true + "defaultInstantiationMode": 1 }, { "userAdded": false, "type": "UnityEngine.PhysicMaterial", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.PhysicsMaterial", + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.PhysicsMaterial2D", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.Rendering.PostProcessing.PostProcessProfile", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.Rendering.PostProcessing.PostProcessResources", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.Rendering.VolumeProfile", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEditor.SceneAsset", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": false + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.Shader", - "ignore": true, - "defaultInstantiationMode": 1, - "supportsModification": true + "defaultInstantiationMode": 1 }, { "userAdded": false, "type": "UnityEngine.ShaderVariantCollection", - "ignore": true, - "defaultInstantiationMode": 1, - "supportsModification": true + "defaultInstantiationMode": 1 }, { "userAdded": false, "type": "UnityEngine.Texture", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.Texture2D", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 }, { "userAdded": false, "type": "UnityEngine.Timeline.TimelineAsset", - "ignore": false, - "defaultInstantiationMode": 0, - "supportsModification": true + "defaultInstantiationMode": 0 } ], "defaultDependencyTypeInfo": { "userAdded": false, "type": "", - "ignore": false, - "defaultInstantiationMode": 1, - "supportsModification": true + "defaultInstantiationMode": 1 }, "newSceneOverride": 0 } \ No newline at end of file