구글 시트 연동 기능 확장2
This commit is contained in:
parent
624b4373b4
commit
635e2ece17
@ -290,8 +290,8 @@ MonoBehaviour:
|
||||
_googleSheetUrl: https://script.google.com/macros/s/AKfycbw8TRSl_OuY2S-RX0yvOJi1SqNqoflG0R3pWxk9GC9u_wvGQeuABZc0VH7YJ5lMrAl4/exec
|
||||
_availSheets: Food/Monster
|
||||
_generateFolderPath: /0.Datas/02.Scripts/GenerateGoogleSheet/AutoCreated
|
||||
_lastUpdated: 2025-05-12 03:32:27
|
||||
_restoreIndex: 0
|
||||
_lastUpdated: 2025-05-12 20:31:48
|
||||
_restoreIndex: 1
|
||||
_editorName:
|
||||
_refreshTrigger: 1
|
||||
--- !u!4 &383092898
|
||||
@ -307,7 +307,7 @@ Transform:
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 1788462582}
|
||||
m_Father: {fileID: 0}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &410087039
|
||||
GameObject:
|
||||
@ -479,38 +479,6 @@ Transform:
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &1788462581
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1788462582}
|
||||
m_Layer: 0
|
||||
m_Name: GameObject
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &1788462582
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1788462581}
|
||||
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:
|
||||
- {fileID: 383092898}
|
||||
m_Father: {fileID: 0}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1660057539 &9223372036854775807
|
||||
SceneRoots:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -518,4 +486,4 @@ SceneRoots:
|
||||
- {fileID: 330585546}
|
||||
- {fileID: 410087041}
|
||||
- {fileID: 832575519}
|
||||
- {fileID: 1788462582}
|
||||
- {fileID: 383092898}
|
||||
|
@ -1,76 +0,0 @@
|
||||
{
|
||||
"$개요": [
|
||||
{
|
||||
"": "시트 생성"
|
||||
}
|
||||
],
|
||||
"Food": [
|
||||
{
|
||||
"Id": "식별ID",
|
||||
"Name": "이름",
|
||||
"Ingredient1": "재료1",
|
||||
"Ingredient2": "재료2",
|
||||
"Taste1:Taste_Enum": "맛1",
|
||||
"Taste2:Taste_Enum": "맛2"
|
||||
},
|
||||
{
|
||||
"Id": "Food001",
|
||||
"Name": "햇빛수프",
|
||||
"Ingredient1": "극락쌀",
|
||||
"Ingredient2": "햇빛당근",
|
||||
"Taste1:Taste_Enum": "Bitter",
|
||||
"Taste2:Taste_Enum": "Sweet"
|
||||
},
|
||||
{
|
||||
"Id": "Food002",
|
||||
"Name": "B",
|
||||
"Ingredient1": 1,
|
||||
"Ingredient2": 11,
|
||||
"Taste1:Taste_Enum": "Spicy",
|
||||
"Taste2:Taste_Enum": "Bitter"
|
||||
},
|
||||
{
|
||||
"Id": "Food003",
|
||||
"Name": "C",
|
||||
"Ingredient1": 2,
|
||||
"Ingredient2": 22,
|
||||
"Taste1:Taste_Enum": "Fresh",
|
||||
"Taste2:Taste_Enum": "None"
|
||||
},
|
||||
{
|
||||
"Id": "Food004",
|
||||
"Name": "D",
|
||||
"Ingredient1": 3,
|
||||
"Ingredient2": 33,
|
||||
"Taste1:Taste_Enum": "Sour",
|
||||
"Taste2:Taste_Enum": "Salty"
|
||||
}
|
||||
],
|
||||
"Monster": [
|
||||
{
|
||||
"Id": "식별번호",
|
||||
"Name": "이름",
|
||||
"T1": "테스트1"
|
||||
},
|
||||
{
|
||||
"Id": "Test001",
|
||||
"Name": "A",
|
||||
"T1": 1
|
||||
},
|
||||
{
|
||||
"Id": "Test002",
|
||||
"Name": "B",
|
||||
"T1": 2
|
||||
},
|
||||
{
|
||||
"Id": "Test003",
|
||||
"Name": "C",
|
||||
"T1": 3
|
||||
},
|
||||
{
|
||||
"Id": "Test004",
|
||||
"Name": "D",
|
||||
"T1": 4
|
||||
}
|
||||
]
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5657779a278b799488c5a53a4ae7d508
|
||||
guid: b602c44d9fb135241aa54fff866bb6ee
|
||||
TextScriptImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
@ -11,6 +11,8 @@
|
||||
using System.Linq;
|
||||
using Sirenix.OdinInspector;
|
||||
using UnityEditor;
|
||||
using UnityEngine.AddressableAssets;
|
||||
using UnityEngine.ResourceManagement.AsyncOperations;
|
||||
|
||||
public class GoogleSheetManager : Singleton<GoogleSheetManager>
|
||||
{
|
||||
@ -55,39 +57,19 @@ public class GoogleSheetManager : Singleton<GoogleSheetManager>
|
||||
private bool _refreshTrigger;
|
||||
private bool _alreadyCreatedSo;
|
||||
|
||||
public static T So<T>() where T : ScriptableObject
|
||||
public static async Task<T> LoadSo<T>() where T : ScriptableObject
|
||||
{
|
||||
#if UNITY_EDITOR
|
||||
string soName = typeof(T).Name;
|
||||
string path = $"Assets{Instance._generateFolderPath}/So/{soName}.asset";
|
||||
T so = AssetDatabase.LoadAssetAtPath<T>(path);
|
||||
if (so == null)
|
||||
{
|
||||
Debug.LogError($"[GoogleSheetManager] {soName}.asset 파일을 찾을 수 없습니다. 먼저 데이터를 생성하세요.");
|
||||
}
|
||||
await Addressables.InitializeAsync().Task;
|
||||
|
||||
return so;
|
||||
#else
|
||||
// 런타임 시에는 Resources 로 로드하거나 Addressables 등을 사용할 수 있음
|
||||
Debug.LogError("[GoogleSheetManager] 런타임에서 SO를 로드하려면 별도 로딩 로직이 필요합니다.");
|
||||
string key = typeof(T).Name;
|
||||
var handle = Addressables.LoadAssetAsync<T>(key);
|
||||
await handle.Task;
|
||||
|
||||
if (handle.Status == AsyncOperationStatus.Succeeded)
|
||||
return handle.Result;
|
||||
|
||||
Debug.LogError($"[GoogleSheetManager] Addressable 로드 실패: {key}");
|
||||
return null;
|
||||
#endif
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 시트 이름으로 개별 SO를 불러옵니다.
|
||||
/// 사용 예: GoogleSheetManager.LoadSo<Sheet1So>("Sheet1")
|
||||
/// </summary>
|
||||
public static T LoadSo<T>(string sheetName) where T : ScriptableObject
|
||||
{
|
||||
string path = $"Assets{Instance._generateFolderPath}/So/{sheetName}So.asset";
|
||||
T so = AssetDatabase.LoadAssetAtPath<T>(path);
|
||||
if (so == null)
|
||||
{
|
||||
Debug.LogError($"[GoogleSheetManager] 해당 SO를 찾을 수 없습니다: {sheetName}So.asset");
|
||||
}
|
||||
|
||||
return so;
|
||||
}
|
||||
|
||||
#if UNITY_EDITOR || DEVELOPMENT_BUILD
|
||||
@ -219,12 +201,11 @@ private void CompareWithSelectedVersion()
|
||||
string restoreJson = log.Logs[_restoreIndex].JsonSnapshot;
|
||||
string currentJson = File.Exists(JsonPath) ? File.ReadAllText(JsonPath) : "";
|
||||
|
||||
List<(string Sheet, string Field, int RowIndex, string OldValue, string NewValue)> diffs =
|
||||
GoogleSheetFetchHelper.CompareJsonDiff(currentJson, restoreJson);
|
||||
List<GoogleSheetDiff> diffs = GoogleSheetFetchHelper.CompareJsonDiff(currentJson, restoreJson);
|
||||
|
||||
if (diffs.Count > 0)
|
||||
{
|
||||
GoogleSheetDiffViewer.ShowWindow(diffs);
|
||||
GoogleSheetDiffViewer.ShowWindow(diffs, true); // 현재 → 선택 버전
|
||||
Debug.Log("[GoogleSheetManager] 선택한 버전과 현재 버전 간의 변경점을 표시합니다.");
|
||||
}
|
||||
else
|
||||
@ -247,12 +228,10 @@ private void RestoreSelectedVersion()
|
||||
string restoreJson = log.Logs[_restoreIndex].JsonSnapshot;
|
||||
string currentJson = File.Exists(JsonPath) ? File.ReadAllText(JsonPath) : "";
|
||||
|
||||
// ✅ 변경점 시각화
|
||||
List<(string Sheet, string Field, int RowIndex, string OldValue, string NewValue)> diffs =
|
||||
GoogleSheetFetchHelper.CompareJsonDiff(currentJson, restoreJson);
|
||||
List<GoogleSheetDiff> diffs = GoogleSheetFetchHelper.CompareJsonDiff(currentJson, restoreJson);
|
||||
|
||||
if (diffs.Count > 0)
|
||||
GoogleSheetDiffViewer.ShowWindow(diffs);
|
||||
GoogleSheetDiffViewer.ShowWindow(diffs); // 변경 전 → 변경 후
|
||||
|
||||
// 복원 처리
|
||||
_json = restoreJson;
|
||||
@ -557,6 +536,7 @@ private bool CreateGoogleSheetSo()
|
||||
soInstance = ScriptableObject.CreateInstance(soType);
|
||||
AssetDatabase.CreateAsset(soInstance, soPath);
|
||||
}
|
||||
GoogleSheetAddressableAutoSetup.AutoRegisterSo(soPath);
|
||||
|
||||
// 3. 데이터 파싱
|
||||
IList list = (IList)Activator.CreateInstance(typeof(List<>).MakeGenericType(dataType));
|
||||
|
@ -0,0 +1,66 @@
|
||||
#if UNITY_EDITOR
|
||||
using System.IO;
|
||||
using UnityEditor;
|
||||
using UnityEditor.AddressableAssets;
|
||||
using UnityEditor.AddressableAssets.Settings;
|
||||
using UnityEditor.AddressableAssets.Settings.GroupSchemas;
|
||||
using UnityEngine;
|
||||
|
||||
public static class GoogleSheetAddressableAutoSetup
|
||||
{
|
||||
private const string TargetGroupName = "GoogleSheetSo_Group";
|
||||
private const string TargetLabel = "GoogleSheetSo";
|
||||
|
||||
public static void AutoRegisterSo(string assetPath)
|
||||
{
|
||||
var settings = AddressableAssetSettingsDefaultObject.Settings;
|
||||
if (settings == null)
|
||||
{
|
||||
Debug.LogError("Addressable 설정을 찾을 수 없습니다.");
|
||||
return;
|
||||
}
|
||||
|
||||
string guid = AssetDatabase.AssetPathToGUID(assetPath);
|
||||
if (string.IsNullOrEmpty(guid)) return;
|
||||
|
||||
// 그룹 가져오기 또는 생성
|
||||
var group = settings.FindGroup(TargetGroupName);
|
||||
if (group == null)
|
||||
{
|
||||
group = settings.CreateGroup(TargetGroupName, false, false, false, null,
|
||||
typeof(BundledAssetGroupSchema), typeof(ContentUpdateGroupSchema));
|
||||
|
||||
var bundledSchema = group.GetSchema<BundledAssetGroupSchema>();
|
||||
bundledSchema.BundleMode = BundledAssetGroupSchema.BundlePackingMode.PackTogether;
|
||||
}
|
||||
|
||||
// 엔트리 추가
|
||||
var entry = settings.FindAssetEntry(guid);
|
||||
if (entry == null)
|
||||
{
|
||||
entry = settings.CreateOrMoveEntry(guid, group);
|
||||
}
|
||||
else if (entry.parentGroup != group)
|
||||
{
|
||||
settings.MoveEntry(entry, group);
|
||||
}
|
||||
|
||||
// Address 설정
|
||||
string name = Path.GetFileNameWithoutExtension(assetPath);
|
||||
entry.address = name;
|
||||
|
||||
// Label 설정
|
||||
if (!entry.labels.Contains(TargetLabel))
|
||||
{
|
||||
entry.SetLabel(TargetLabel, true, true);
|
||||
}
|
||||
|
||||
// 저장
|
||||
EditorUtility.SetDirty(settings);
|
||||
settings.SetDirty(AddressableAssetSettings.ModificationEvent.EntryMoved, entry, true);
|
||||
AssetDatabase.SaveAssets();
|
||||
|
||||
Debug.Log($"✅ Addressables에 등록 완료: {name}, 그룹: {TargetGroupName}, 라벨: {TargetLabel}");
|
||||
}
|
||||
}
|
||||
#endif
|
@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 91161e8df06b9734ca03d579aceaa508
|
@ -0,0 +1,11 @@
|
||||
using System;
|
||||
|
||||
[Serializable]
|
||||
public class GoogleSheetDiff
|
||||
{
|
||||
public string Sheet;
|
||||
public string Field;
|
||||
public int RowIndex;
|
||||
public string OldValue;
|
||||
public string NewValue;
|
||||
}
|
@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 855de14226eddeb44be60c144dab8e70
|
@ -3,9 +3,9 @@
|
||||
|
||||
public static class GoogleSheetDiffHelper
|
||||
{
|
||||
public static List<(string Sheet, string Field, int RowIndex, string OldValue, string NewValue)> CompareJsonDiff(string oldJson, string newJson)
|
||||
public static List<GoogleSheetDiff> CompareJsonDiff(string oldJson, string newJson)
|
||||
{
|
||||
var diffs = new List<(string, string, int, string, string)>();
|
||||
var diffs = new List<GoogleSheetDiff>();
|
||||
|
||||
if (string.IsNullOrEmpty(oldJson) || string.IsNullOrEmpty(newJson))
|
||||
return diffs;
|
||||
@ -22,7 +22,6 @@ public static class GoogleSheetDiffHelper
|
||||
var oldArray = oldSheetToken as JArray;
|
||||
var newArray = sheet.Value as JArray;
|
||||
|
||||
// Row-by-row 비교 (1번 줄부터 데이터 시작)
|
||||
for (int i = 1; i < newArray.Count; i++)
|
||||
{
|
||||
if (i >= oldArray.Count)
|
||||
@ -39,7 +38,14 @@ public static class GoogleSheetDiffHelper
|
||||
|
||||
if (oldValue != newValue)
|
||||
{
|
||||
diffs.Add((sheetName, field, i, oldValue, newValue));
|
||||
diffs.Add(new GoogleSheetDiff
|
||||
{
|
||||
Sheet = sheetName,
|
||||
Field = field,
|
||||
RowIndex = i,
|
||||
OldValue = oldValue,
|
||||
NewValue = newValue
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -57,9 +63,9 @@ public static string GenerateDiff(string oldJson, string newJson)
|
||||
var sb = new System.Text.StringBuilder();
|
||||
sb.AppendLine("[GoogleSheetManager] 변경된 필드들:");
|
||||
|
||||
foreach (var (sheet, field, rowIndex, oldVal, newVal) in diffs)
|
||||
foreach (var diff in diffs)
|
||||
{
|
||||
sb.AppendLine($"{sheet} / Row {rowIndex} / {field} : '{oldVal}' → '{newVal}'");
|
||||
sb.AppendLine($"{diff.Sheet} / Row {diff.RowIndex} / {diff.Field} : '{diff.OldValue}' → '{diff.NewValue}'");
|
||||
}
|
||||
|
||||
return sb.ToString();
|
||||
|
@ -5,41 +5,64 @@
|
||||
|
||||
public class GoogleSheetDiffViewer : EditorWindow
|
||||
{
|
||||
private List<(string Sheet, string Field, int RowIndex, string OldValue, string NewValue) > _diffs;
|
||||
|
||||
public static void ShowWindow(List<(string Sheet, string Field, int RowIndex, string OldValue, string NewValue) > diffs)
|
||||
{
|
||||
var window = GetWindow<GoogleSheetDiffViewer>("Google Sheet 변경점");
|
||||
window._diffs = diffs;
|
||||
window.Show();
|
||||
}
|
||||
private List<GoogleSheetDiff> _diffs;
|
||||
private bool _isReversed; // true: 현재 → 선택버전, false: 변경 전 → 변경 후
|
||||
|
||||
private Vector2 _scroll;
|
||||
|
||||
private void OnGUI()
|
||||
public static void ShowWindow(List<GoogleSheetDiff> diffs, bool isReversed = false)
|
||||
{
|
||||
if (_diffs == null || _diffs.Count == 0)
|
||||
{
|
||||
EditorGUILayout.LabelField("변경 사항이 없습니다.");
|
||||
return;
|
||||
var window = GetWindow<GoogleSheetDiffViewer>("Google Sheet 변경점");
|
||||
window._diffs = diffs;
|
||||
window._isReversed = isReversed;
|
||||
window.Show();
|
||||
}
|
||||
|
||||
private void OnGUI()
|
||||
{
|
||||
EditorGUILayout.LabelField("변경된 항목", EditorStyles.boldLabel);
|
||||
EditorGUILayout.Space();
|
||||
|
||||
if (_diffs == null || _diffs.Count == 0)
|
||||
{
|
||||
EditorGUILayout.HelpBox("변경 사항이 없습니다.", MessageType.Info);
|
||||
return;
|
||||
}
|
||||
|
||||
// 헤더
|
||||
EditorGUILayout.BeginHorizontal("box");
|
||||
EditorGUILayout.LabelField("시트", EditorStyles.boldLabel, GUILayout.Width(80));
|
||||
EditorGUILayout.LabelField("행", EditorStyles.boldLabel, GUILayout.Width(40));
|
||||
EditorGUILayout.LabelField("필드", EditorStyles.boldLabel, GUILayout.Width(100));
|
||||
|
||||
GUIStyle oldStyle = new GUIStyle(EditorStyles.label);
|
||||
oldStyle.normal.textColor = Color.green;
|
||||
EditorGUILayout.LabelField(_isReversed ? "현재 버전" : "변경 전", oldStyle, GUILayout.Width(100));
|
||||
|
||||
GUIStyle newStyle = new GUIStyle(EditorStyles.label);
|
||||
newStyle.normal.textColor = new Color(0.3f, 0.75f, 1.0f);
|
||||
EditorGUILayout.LabelField(_isReversed ? "선택한 버전" : "변경 후", newStyle, GUILayout.Width(100));
|
||||
EditorGUILayout.EndHorizontal();
|
||||
|
||||
_scroll = EditorGUILayout.BeginScrollView(_scroll);
|
||||
EditorGUILayout.BeginVertical("box");
|
||||
|
||||
foreach (var diff in _diffs)
|
||||
{
|
||||
EditorGUILayout.LabelField($"시트: {diff.Sheet}");
|
||||
EditorGUILayout.LabelField($"행: {diff.RowIndex + 1}");
|
||||
EditorGUILayout.LabelField($"필드: {diff.Field}");
|
||||
EditorGUILayout.LabelField($"기존 값: {diff.OldValue} → 변경 값: {diff.NewValue}", EditorStyles.helpBox);
|
||||
EditorGUILayout.Space();
|
||||
EditorGUILayout.BeginHorizontal("box");
|
||||
|
||||
EditorGUILayout.LabelField(diff.Sheet, GUILayout.Width(80));
|
||||
EditorGUILayout.LabelField(diff.RowIndex.ToString(), GUILayout.Width(40));
|
||||
EditorGUILayout.LabelField(diff.Field, GUILayout.Width(100));
|
||||
|
||||
string left = _isReversed ? diff.NewValue : diff.OldValue;
|
||||
string right = _isReversed ? diff.OldValue : diff.NewValue;
|
||||
|
||||
EditorGUILayout.LabelField(left, oldStyle, GUILayout.Width(100));
|
||||
EditorGUILayout.LabelField(right, newStyle, GUILayout.Width(100));
|
||||
|
||||
EditorGUILayout.EndHorizontal();
|
||||
}
|
||||
|
||||
EditorGUILayout.EndVertical();
|
||||
EditorGUILayout.EndScrollView();
|
||||
}
|
||||
}
|
||||
|
@ -4,9 +4,9 @@
|
||||
|
||||
public static class GoogleSheetFetchHelper
|
||||
{
|
||||
public static List<(string Sheet, string Field, int RowIndex, string OldValue, string NewValue)> CompareJsonDiff(string oldJson, string newJson)
|
||||
public static List<GoogleSheetDiff> CompareJsonDiff(string oldJson, string newJson)
|
||||
{
|
||||
var result = new List<(string, string, int, string, string)>();
|
||||
var result = new List<GoogleSheetDiff>();
|
||||
|
||||
if (string.IsNullOrEmpty(oldJson) || string.IsNullOrEmpty(newJson))
|
||||
return result;
|
||||
@ -24,7 +24,7 @@ public static class GoogleSheetFetchHelper
|
||||
|
||||
int minCount = Mathf.Min(oldSheetArray.Count, newSheetData.Count);
|
||||
|
||||
for (int i = 1; i < minCount; i++) // i = 1부터: 첫 줄은 주석
|
||||
for (int i = 1; i < minCount; i++)
|
||||
{
|
||||
var oldRow = (JObject)oldSheetArray[i];
|
||||
var newRow = (JObject)newSheetData[i];
|
||||
@ -35,11 +35,19 @@ public static class GoogleSheetFetchHelper
|
||||
string newVal = prop.Value.ToString();
|
||||
|
||||
if (oldVal != newVal)
|
||||
result.Add((sheet.Key, prop.Name, i + 1, oldVal, newVal)); // i+1: 실제 시트에서의 행 번호 (1-based)
|
||||
{
|
||||
result.Add(new GoogleSheetDiff
|
||||
{
|
||||
Sheet = sheet.Key,
|
||||
Field = prop.Name,
|
||||
RowIndex = i + 1,
|
||||
OldValue = oldVal,
|
||||
NewValue = newVal
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
@ -59,4 +59,50 @@ MonoBehaviour:
|
||||
\"Name\": \"B\",\n \"T1\": 2\n },\n {\n \"Id\": \"Test003\",\n
|
||||
\"Name\": \"C\",\n \"T1\": 3\n },\n {\n \"Id\": \"Test004\",\n
|
||||
\"Name\": \"D\",\n \"T1\": 4\n }\n ]\n}"
|
||||
- Editor: NTG
|
||||
Timestamp: 2025-05-12 20:26:43
|
||||
JsonSnapshot: "{\n \"$\uAC1C\uC694\": [\n {\n \"\": \"\uC2DC\uD2B8 \uC0DD\uC131\"\n
|
||||
}\n ],\n \"Food\": [\n {\n \"Id\": \"\uC2DD\uBCC4ID\",\n \"Name\":
|
||||
\"\uC774\uB984\",\n \"Ingredient1\": \"\uC7AC\uB8CC1\",\n \"Ingredient2\":
|
||||
\"\uC7AC\uB8CC2\",\n \"Taste1:Taste_Enum\": \"\uB9DB1\",\n \"Taste2:Taste_Enum\":
|
||||
\"\uB9DB2\"\n },\n {\n \"Id\": \"Food001\",\n \"Name\": \"\uD587\uBE5B\uC218\uD504\",\n
|
||||
\"Ingredient1\": \"\uADF9\uB77D\uC300\",\n \"Ingredient2\": \"\uD587\uBE5B\uB2F9\uADFC\",\n
|
||||
\"Taste1:Taste_Enum\": \"Bitter\",\n \"Taste2:Taste_Enum\": \"Sweet\"\n
|
||||
},\n {\n \"Id\": \"Food002\",\n \"Name\": \"B\",\n \"Ingredient1\":
|
||||
1,\n \"Ingredient2\": 4,\n \"Taste1:Taste_Enum\": \"Spicy\",\n
|
||||
\"Taste2:Taste_Enum\": \"Bitter\"\n },\n {\n \"Id\": \"Food003\",\n
|
||||
\"Name\": \"C\",\n \"Ingredient1\": 2,\n \"Ingredient2\": 5,\n
|
||||
\"Taste1:Taste_Enum\": \"Fresh\",\n \"Taste2:Taste_Enum\": \"None\"\n
|
||||
},\n {\n \"Id\": \"Food004\",\n \"Name\": \"D\",\n \"Ingredient1\":
|
||||
3,\n \"Ingredient2\": 6,\n \"Taste1:Taste_Enum\": \"Sour\",\n
|
||||
\"Taste2:Taste_Enum\": \"Salty\"\n }\n ],\n \"Monster\": [\n {\n
|
||||
\"Id\": \"\uC2DD\uBCC4\uBC88\uD638\",\n \"Name\": \"\uC774\uB984\",\n
|
||||
\"T1\": \"\uD14C\uC2A4\uD2B81\"\n },\n {\n \"Id\": \"Test001\",\n
|
||||
\"Name\": \"A\",\n \"T1\": 1\n },\n {\n \"Id\": \"Test002\",\n
|
||||
\"Name\": \"B\",\n \"T1\": 2\n },\n {\n \"Id\": \"Test003\",\n
|
||||
\"Name\": \"C\",\n \"T1\": 3\n },\n {\n \"Id\": \"Test004\",\n
|
||||
\"Name\": \"D\",\n \"T1\": 4\n }\n ]\n}"
|
||||
- Editor: NTG
|
||||
Timestamp: 2025-05-12 20:31:48
|
||||
JsonSnapshot: "{\n \"$\uAC1C\uC694\": [\n {\n \"\": \"\uC2DC\uD2B8 \uC0DD\uC131\"\n
|
||||
}\n ],\n \"Food\": [\n {\n \"Id\": \"\uC2DD\uBCC4ID\",\n \"Name\":
|
||||
\"\uC774\uB984\",\n \"Ingredient1\": \"\uC7AC\uB8CC1\",\n \"Ingredient2\":
|
||||
\"\uC7AC\uB8CC2\",\n \"Taste1:Taste_Enum\": \"\uB9DB1\",\n \"Taste2:Taste_Enum\":
|
||||
\"\uB9DB2\"\n },\n {\n \"Id\": \"Food001\",\n \"Name\": \"\uD587\uBE5B\uC218\uD504\",\n
|
||||
\"Ingredient1\": \"\uADF9\uB77D\uC300\",\n \"Ingredient2\": \"\uD587\uBE5B\uB2F9\uADFC\",\n
|
||||
\"Taste1:Taste_Enum\": \"Bitter\",\n \"Taste2:Taste_Enum\": \"Sweet\"\n
|
||||
},\n {\n \"Id\": \"Food002\",\n \"Name\": \"B\",\n \"Ingredient1\":
|
||||
1,\n \"Ingredient2\": 4,\n \"Taste1:Taste_Enum\": \"Spicy\",\n
|
||||
\"Taste2:Taste_Enum\": \"Bitter\"\n },\n {\n \"Id\": \"Food003\",\n
|
||||
\"Name\": \"C\",\n \"Ingredient1\": 2,\n \"Ingredient2\": 5,\n
|
||||
\"Taste1:Taste_Enum\": \"Fresh\",\n \"Taste2:Taste_Enum\": \"None\"\n
|
||||
},\n {\n \"Id\": \"Food004\",\n \"Name\": \"D\",\n \"Ingredient1\":
|
||||
3,\n \"Ingredient2\": 6,\n \"Taste1:Taste_Enum\": \"Sour\",\n
|
||||
\"Taste2:Taste_Enum\": \"Salty\"\n }\n ],\n \"Monster\": [\n {\n
|
||||
\"Id\": \"\uC2DD\uBCC4\uBC88\uD638\",\n \"Name\": \"\uC774\uB984\",\n
|
||||
\"T1\": \"\uD14C\uC2A4\uD2B81\"\n },\n {\n \"Id\": \"Test001\",\n
|
||||
\"Name\": \"A\",\n \"T1\": 1\n },\n {\n \"Id\": \"Test002\",\n
|
||||
\"Name\": \"B\",\n \"T1\": 2\n },\n {\n \"Id\": \"Test003\",\n
|
||||
\"Name\": \"C\",\n \"T1\": 3\n },\n {\n \"Id\": \"Test004\",\n
|
||||
\"Name\": \"D\",\n \"T1\": 4\n }\n ]\n}"
|
||||
MaxLogs: 100
|
||||
|
8
Assets/AddressableAssetsData.meta
Normal file
8
Assets/AddressableAssetsData.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a3141095d51714d47a27d37c5af6ffc8
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,16 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: dea69d41f90c6ea4fa55c27c1d60c145, type: 3}
|
||||
m_Name: AddressableAssetGroupSortSettings
|
||||
m_EditorClassIdentifier:
|
||||
sortOrder:
|
||||
- 7fe0c33d351391a45a0ea3c93ecef42e
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5f7974e57d37b3143b6c1d44c71364db
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
115
Assets/AddressableAssetsData/AddressableAssetSettings.asset
Normal file
115
Assets/AddressableAssetsData/AddressableAssetSettings.asset
Normal file
@ -0,0 +1,115 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 468a46d0ae32c3544b7d98094e6448a9, type: 3}
|
||||
m_Name: AddressableAssetSettings
|
||||
m_EditorClassIdentifier:
|
||||
m_DefaultGroup: 929eb052721483043b12b85e5d4bdc84
|
||||
m_currentHash:
|
||||
serializedVersion: 2
|
||||
Hash: 00000000000000000000000000000000
|
||||
m_OptimizeCatalogSize: 0
|
||||
m_BuildRemoteCatalog: 1
|
||||
m_CatalogRequestsTimeout: 0
|
||||
m_DisableCatalogUpdateOnStart: 0
|
||||
m_InternalIdNamingMode: 0
|
||||
m_InternalBundleIdMode: 1
|
||||
m_AssetLoadMode: 0
|
||||
m_BundledAssetProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.BundledAssetProvider
|
||||
m_AssetBundleProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.AssetBundleProvider
|
||||
m_IgnoreUnsupportedFilesInBuild: 0
|
||||
m_UniqueBundleIds: 1
|
||||
m_EnableJsonCatalog: 0
|
||||
m_NonRecursiveBuilding: 1
|
||||
m_CCDEnabled: 0
|
||||
m_maxConcurrentWebRequests: 3
|
||||
m_UseUWRForLocalBundles: 0
|
||||
m_BundleTimeout: 0
|
||||
m_BundleRetryCount: 0
|
||||
m_BundleRedirectLimit: -1
|
||||
m_SharedBundleSettings: 0
|
||||
m_SharedBundleSettingsCustomGroupIndex: 0
|
||||
m_ContiguousBundles: 1
|
||||
m_StripUnityVersionFromBundleBuild: 0
|
||||
m_DisableVisibleSubAssetRepresentations: 0
|
||||
m_BuiltInBundleNaming: 0
|
||||
mBuiltInBundleCustomNaming:
|
||||
m_MonoScriptBundleNaming: 0
|
||||
m_CheckForContentUpdateRestrictionsOption: 0
|
||||
m_MonoScriptBundleCustomNaming:
|
||||
m_RemoteCatalogBuildPath:
|
||||
m_Id: cb8a3716c5e5eae4c968a7c055b25814
|
||||
m_RemoteCatalogLoadPath:
|
||||
m_Id: 9b57c3bf4ae74bd408f442d8caaa93c1
|
||||
m_ContentStateBuildPathProfileVariableName: <default settings path>
|
||||
m_CustomContentStateBuildPath:
|
||||
m_ContentStateBuildPath:
|
||||
m_BuildAddressablesWithPlayerBuild: 0
|
||||
m_overridePlayerVersion: '[UnityEditor.PlayerSettings.bundleVersion]'
|
||||
m_GroupAssets:
|
||||
- {fileID: 11400000, guid: 5b7b9bd594e863849bf5e512f59ba0fc, type: 2}
|
||||
m_BuildSettings:
|
||||
m_LogResourceManagerExceptions: 1
|
||||
m_BundleBuildPath: Temp/com.unity.addressables/AssetBundles
|
||||
m_ProfileSettings:
|
||||
m_Profiles:
|
||||
- m_InheritedParent:
|
||||
m_Id: 75896f5773c4a5f458767e6c9fb0bf23
|
||||
m_ProfileName: Default
|
||||
m_Values:
|
||||
- m_Id: 30b8e03fd76b09f46850a05b2650884d
|
||||
m_Value: '[UnityEngine.AddressableAssets.Addressables.BuildPath]/[BuildTarget]'
|
||||
- m_Id: 7852182deca226a488adf0342a6f6c9a
|
||||
m_Value: '{UnityEngine.AddressableAssets.Addressables.RuntimePath}/[BuildTarget]'
|
||||
- m_Id: 9b57c3bf4ae74bd408f442d8caaa93c1
|
||||
m_Value: <undefined>
|
||||
- m_Id: ae555660b5fcc6b468e21d8de2e932bc
|
||||
m_Value: '[UnityEditor.EditorUserBuildSettings.activeBuildTarget]'
|
||||
- m_Id: cb8a3716c5e5eae4c968a7c055b25814
|
||||
m_Value: 'ServerData/[BuildTarget]'
|
||||
m_ProfileEntryNames:
|
||||
- m_Id: 30b8e03fd76b09f46850a05b2650884d
|
||||
m_Name: Local.BuildPath
|
||||
m_InlineUsage: 0
|
||||
- m_Id: 7852182deca226a488adf0342a6f6c9a
|
||||
m_Name: Local.LoadPath
|
||||
m_InlineUsage: 0
|
||||
- m_Id: 9b57c3bf4ae74bd408f442d8caaa93c1
|
||||
m_Name: Remote.LoadPath
|
||||
m_InlineUsage: 0
|
||||
- m_Id: ae555660b5fcc6b468e21d8de2e932bc
|
||||
m_Name: BuildTarget
|
||||
m_InlineUsage: 0
|
||||
- m_Id: cb8a3716c5e5eae4c968a7c055b25814
|
||||
m_Name: Remote.BuildPath
|
||||
m_InlineUsage: 0
|
||||
m_ProfileVersion: 1
|
||||
m_LabelTable:
|
||||
m_LabelNames:
|
||||
- default
|
||||
- GoogleSheetSo
|
||||
m_SchemaTemplates: []
|
||||
m_GroupTemplateObjects:
|
||||
- {fileID: 11400000, guid: f804fe78e7005554f9ba60273aade35b, type: 2}
|
||||
m_InitializationObjects: []
|
||||
m_CertificateHandlerType:
|
||||
m_AssemblyName:
|
||||
m_ClassName:
|
||||
m_ActivePlayerDataBuilderIndex: 2
|
||||
m_DataBuilders:
|
||||
- {fileID: 11400000, guid: 08e47763d1d3ddc49a7fcb10ebe3b33e, type: 2}
|
||||
- {fileID: 11400000, guid: 3ee9e3ad901c06e43af50dbd33b132b1, type: 2}
|
||||
- {fileID: 11400000, guid: b90bfb60ccafb7e4cb8900f9a52b89d7, type: 2}
|
||||
m_ActiveProfileId: 75896f5773c4a5f458767e6c9fb0bf23
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d12ffbb6f886d48418efb0b6d15ccb88
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/AddressableAssetsData/AssetGroupTemplates.meta
Normal file
8
Assets/AddressableAssetsData/AssetGroupTemplates.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: aae35240a94dde0429e214ff4f327227
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,78 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &-6241946435647084036
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 5834b5087d578d24c926ce20cd31e6d6, type: 3}
|
||||
m_Name: ContentUpdateGroupSchema
|
||||
m_EditorClassIdentifier:
|
||||
m_Group: {fileID: 0}
|
||||
m_StaticContent: 0
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 1a3c5d64ac83548c09dd1678b9f6f1cd, type: 3}
|
||||
m_Name: Packed Assets
|
||||
m_EditorClassIdentifier:
|
||||
m_SchemaObjects:
|
||||
- {fileID: 5319039760134505080}
|
||||
- {fileID: -6241946435647084036}
|
||||
m_Description: Pack assets into asset bundles.
|
||||
m_Settings: {fileID: 11400000, guid: d12ffbb6f886d48418efb0b6d15ccb88, type: 2}
|
||||
--- !u!114 &5319039760134505080
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: e5d17a21594effb4e9591490b009e7aa, type: 3}
|
||||
m_Name: BundledAssetGroupSchema
|
||||
m_EditorClassIdentifier:
|
||||
m_Group: {fileID: 0}
|
||||
m_InternalBundleIdMode: 1
|
||||
m_Compression: 1
|
||||
m_IncludeAddressInCatalog: 1
|
||||
m_IncludeGUIDInCatalog: 1
|
||||
m_IncludeLabelsInCatalog: 1
|
||||
m_InternalIdNamingMode: 0
|
||||
m_CacheClearBehavior: 0
|
||||
m_IncludeInBuild: 1
|
||||
m_BundledAssetProviderType:
|
||||
m_AssemblyName:
|
||||
m_ClassName:
|
||||
m_ForceUniqueProvider: 0
|
||||
m_UseAssetBundleCache: 1
|
||||
m_UseAssetBundleCrc: 1
|
||||
m_UseAssetBundleCrcForCachedBundles: 1
|
||||
m_UseUWRForLocalBundles: 0
|
||||
m_Timeout: 0
|
||||
m_ChunkedTransfer: 0
|
||||
m_RedirectLimit: -1
|
||||
m_RetryCount: 0
|
||||
m_BuildPath:
|
||||
m_Id:
|
||||
m_LoadPath:
|
||||
m_Id:
|
||||
m_BundleMode: 0
|
||||
m_AssetBundleProviderType:
|
||||
m_AssemblyName:
|
||||
m_ClassName:
|
||||
m_UseDefaultSchemaSettings: 0
|
||||
m_SelectedPathPairIndex: 0
|
||||
m_BundleNaming: 0
|
||||
m_AssetLoadMode: 0
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f804fe78e7005554f9ba60273aade35b
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/AddressableAssetsData/AssetGroups.meta
Normal file
8
Assets/AddressableAssetsData/AssetGroups.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 012f657ef2322a6499255e9c9c78a5a3
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,35 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: bbb281ee3bf0b054c82ac2347e9e782c, type: 3}
|
||||
m_Name: GoogleSheetSo_Group
|
||||
m_EditorClassIdentifier:
|
||||
m_GroupName: GoogleSheetSo_Group
|
||||
m_GUID: 7fe0c33d351391a45a0ea3c93ecef42e
|
||||
m_SerializeEntries:
|
||||
- m_GUID: 2a1b86f3356293441bcfca705fff3b85
|
||||
m_Address: MonsterSo
|
||||
m_ReadOnly: 0
|
||||
m_SerializedLabels:
|
||||
- GoogleSheetSo
|
||||
FlaggedDuringContentUpdateRestriction: 0
|
||||
- m_GUID: 8f6a170dcd0a88d47939e70db303af14
|
||||
m_Address: FoodSo
|
||||
m_ReadOnly: 0
|
||||
m_SerializedLabels:
|
||||
- GoogleSheetSo
|
||||
FlaggedDuringContentUpdateRestriction: 0
|
||||
m_ReadOnly: 0
|
||||
m_Settings: {fileID: 11400000, guid: d12ffbb6f886d48418efb0b6d15ccb88, type: 2}
|
||||
m_SchemaSet:
|
||||
m_Schemas:
|
||||
- {fileID: 11400000, guid: b62ed1f0bfb9f704db4e9af0e9637977, type: 2}
|
||||
- {fileID: 11400000, guid: 7bdd4a50a9f431c4ba9120737ec7c9f4, type: 2}
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5b7b9bd594e863849bf5e512f59ba0fc
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/AddressableAssetsData/AssetGroups/Schemas.meta
Normal file
8
Assets/AddressableAssetsData/AssetGroups/Schemas.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3c1920f73ace47b4694675ed31a1a112
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,47 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: e5d17a21594effb4e9591490b009e7aa, type: 3}
|
||||
m_Name: GoogleSheetSo_Group_BundledAssetGroupSchema
|
||||
m_EditorClassIdentifier:
|
||||
m_Group: {fileID: 11400000, guid: 5b7b9bd594e863849bf5e512f59ba0fc, type: 2}
|
||||
m_InternalBundleIdMode: 1
|
||||
m_Compression: 1
|
||||
m_IncludeAddressInCatalog: 1
|
||||
m_IncludeGUIDInCatalog: 1
|
||||
m_IncludeLabelsInCatalog: 1
|
||||
m_InternalIdNamingMode: 0
|
||||
m_CacheClearBehavior: 0
|
||||
m_IncludeInBuild: 1
|
||||
m_BundledAssetProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.BundledAssetProvider
|
||||
m_ForceUniqueProvider: 0
|
||||
m_UseAssetBundleCache: 1
|
||||
m_UseAssetBundleCrc: 1
|
||||
m_UseAssetBundleCrcForCachedBundles: 1
|
||||
m_UseUWRForLocalBundles: 0
|
||||
m_Timeout: 0
|
||||
m_ChunkedTransfer: 0
|
||||
m_RedirectLimit: -1
|
||||
m_RetryCount: 0
|
||||
m_BuildPath:
|
||||
m_Id: 30b8e03fd76b09f46850a05b2650884d
|
||||
m_LoadPath:
|
||||
m_Id: 7852182deca226a488adf0342a6f6c9a
|
||||
m_BundleMode: 0
|
||||
m_AssetBundleProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.AssetBundleProvider
|
||||
m_UseDefaultSchemaSettings: 0
|
||||
m_SelectedPathPairIndex: 0
|
||||
m_BundleNaming: 0
|
||||
m_AssetLoadMode: 0
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b62ed1f0bfb9f704db4e9af0e9637977
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,16 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 5834b5087d578d24c926ce20cd31e6d6, type: 3}
|
||||
m_Name: GoogleSheetSo_Group_ContentUpdateGroupSchema
|
||||
m_EditorClassIdentifier:
|
||||
m_Group: {fileID: 11400000, guid: 5b7b9bd594e863849bf5e512f59ba0fc, type: 2}
|
||||
m_StaticContent: 0
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7bdd4a50a9f431c4ba9120737ec7c9f4
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/AddressableAssetsData/DataBuilders.meta
Normal file
8
Assets/AddressableAssetsData/DataBuilders.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: bc395fca191c52b4ea851fe83a40f16a
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,20 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 88d21199f5d473f4db36845f2318f180, type: 3}
|
||||
m_Name: BuildScriptFastMode
|
||||
m_EditorClassIdentifier:
|
||||
instanceProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.InstanceProvider
|
||||
sceneProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.SceneProvider
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 08e47763d1d3ddc49a7fcb10ebe3b33e
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,20 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 3e2e0ffa088c91d41a086d0b8cb16bdc, type: 3}
|
||||
m_Name: BuildScriptPackedMode
|
||||
m_EditorClassIdentifier:
|
||||
instanceProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.InstanceProvider
|
||||
sceneProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.SceneProvider
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b90bfb60ccafb7e4cb8900f9a52b89d7
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,20 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: ad8c280d42ee0ed41a27db23b43dd2bf, type: 3}
|
||||
m_Name: BuildScriptPackedPlayMode
|
||||
m_EditorClassIdentifier:
|
||||
instanceProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.InstanceProvider
|
||||
sceneProviderType:
|
||||
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.SceneProvider
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3ee9e3ad901c06e43af50dbd33b132b1
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
15
Assets/AddressableAssetsData/DefaultObject.asset
Normal file
15
Assets/AddressableAssetsData/DefaultObject.asset
Normal file
@ -0,0 +1,15 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 3a189bb168d8d90478a09ea08c2f3d72, type: 3}
|
||||
m_Name: DefaultObject
|
||||
m_EditorClassIdentifier:
|
||||
m_AddressableAssetSettingsGuid: d12ffbb6f886d48418efb0b6d15ccb88
|
8
Assets/AddressableAssetsData/DefaultObject.asset.meta
Normal file
8
Assets/AddressableAssetsData/DefaultObject.asset.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8aedbecfee36f6f47b57e6359672a64f
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
28
Assets/AddressableAssetsData/ProfileDataSourceSettings.asset
Normal file
28
Assets/AddressableAssetsData/ProfileDataSourceSettings.asset
Normal file
@ -0,0 +1,28 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 7e3976da977cb49238499ea3b4c237ae, type: 3}
|
||||
m_Name: ProfileDataSourceSettings
|
||||
m_EditorClassIdentifier:
|
||||
profileGroupTypes:
|
||||
- m_GroupTypePrefix: Built-In
|
||||
m_Variables:
|
||||
- m_Suffix: BuildPath
|
||||
m_Value: '[UnityEngine.AddressableAssets.Addressables.BuildPath]/[BuildTarget]'
|
||||
- m_Suffix: LoadPath
|
||||
m_Value: '{UnityEngine.AddressableAssets.Addressables.RuntimePath}/[BuildTarget]'
|
||||
environments: []
|
||||
currentEnvironment:
|
||||
id:
|
||||
projectId:
|
||||
projectGenesisId:
|
||||
name:
|
||||
isDefault: 0
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d9a4d86327d0e384886ef63152a4778d
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/AddressableAssetsData/Windows.meta
Normal file
8
Assets/AddressableAssetsData/Windows.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0b182ffdf506f3247a6c27b5196f69c6
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -15,5 +15,7 @@ MonoBehaviour:
|
||||
configurations:
|
||||
- ID: Unity.Mathematics
|
||||
ActivationSettings: 0
|
||||
- ID: Unity.Addressables
|
||||
ActivationSettings: 0
|
||||
ModuleTogglingSettings: 1
|
||||
ModuleUpdateSettings: 1
|
||||
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f66f5db86b687a041a36cd49f3d460d0
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ba1664ec1a0467641a742eaadae146d4
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,3 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 6384593779a7421881db64cdb25db4c5
|
||||
timeCreated: 1718984862
|
@ -0,0 +1,30 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="OdinAddressableReflection.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR
|
||||
|
||||
#if !SIRENIX_INTERNAL
|
||||
#pragma warning disable
|
||||
#endif
|
||||
|
||||
using System.Reflection;
|
||||
using UnityEditor.AddressableAssets.Settings;
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor.Internal
|
||||
{
|
||||
internal static class OdinAddressableReflection
|
||||
{
|
||||
public static FieldInfo AddressableAssetEntry_mGUID_Field;
|
||||
|
||||
static OdinAddressableReflection()
|
||||
{
|
||||
AddressableAssetEntry_mGUID_Field = typeof(AddressableAssetEntry).GetField("m_GUID", BindingFlags.Instance | BindingFlags.NonPublic);
|
||||
}
|
||||
|
||||
internal static void EnsureConstructed() { }
|
||||
}
|
||||
}
|
||||
#endif
|
@ -0,0 +1,3 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c1a8e9ae60bf4edebd0ec6052eb9064e
|
||||
timeCreated: 1718984883
|
@ -0,0 +1,46 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="OdinAddressableReflectionValidator.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR
|
||||
#if SIRENIX_INTERNAL
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
using Sirenix.OdinInspector.Editor.Validation;
|
||||
using Sirenix.OdinInspector.Modules.Addressables.Editor.Internal;
|
||||
|
||||
[assembly: RegisterValidator(typeof(OdinAddressableReflectionValidator))]
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor.Internal
|
||||
{
|
||||
public class OdinAddressableReflectionValidator : GlobalValidator
|
||||
{
|
||||
public override IEnumerable RunValidation(ValidationResult result)
|
||||
{
|
||||
OdinAddressableReflection.EnsureConstructed();
|
||||
|
||||
FieldInfo[] fields = typeof(OdinAddressableReflection).GetFields(BindingFlags.Static | BindingFlags.Public);
|
||||
|
||||
for (var i = 0; i < fields.Length; i++)
|
||||
{
|
||||
if (fields[i].IsLiteral)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if (fields[i].GetValue(null) != null)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
result.AddError($"[Odin Addressable Module]: {fields[i].Name} was not found.");
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#endif
|
@ -0,0 +1,3 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 97bf306f5a4249b192921db9152934f6
|
||||
timeCreated: 1718984873
|
@ -0,0 +1,29 @@
|
||||
{
|
||||
"name": "Sirenix.OdinInspector.Modules.Unity.Addressables",
|
||||
"references": [
|
||||
"Unity.Addressables",
|
||||
"Unity.Addressables.Editor",
|
||||
"Sirenix.Serialization",
|
||||
"Sirenix.OdinInspector.Attributes",
|
||||
"Sirenix.OdinInspector.Editor",
|
||||
"Sirenix.Utilities.Editor",
|
||||
"Sirenix.Utilities",
|
||||
"Sirenix.OdinValidator.Editor"
|
||||
],
|
||||
"includePlatforms": [],
|
||||
"excludePlatforms": [],
|
||||
"allowUnsafeCode": true,
|
||||
"overrideReferences": false,
|
||||
"precompiledReferences": [
|
||||
"Sirenix.Serialization.dll",
|
||||
"Sirenix.OdinInspector.Attributes.dll",
|
||||
"Sirenix.OdinInspector.Editor.dll",
|
||||
"Sirenix.Utilities.Editor.dll",
|
||||
"Sirenix.Utilities.dll",
|
||||
"Sirenix.OdinValidator.Editor.dll"
|
||||
],
|
||||
"autoReferenced": true,
|
||||
"defineConstraints": [],
|
||||
"versionDefines": [],
|
||||
"noEngineReferences": false
|
||||
}
|
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3b4d8e09c665bfa47849130d8695171e
|
||||
AssemblyDefinitionImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b568c1d508ce0b74eb0025b8501d1c1e
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,98 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="AssetLabelReferenceValidator.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR
|
||||
|
||||
#if !SIRENIX_INTERNAL
|
||||
#pragma warning disable
|
||||
#endif
|
||||
|
||||
using UnityEngine;
|
||||
using UnityEditor.AddressableAssets;
|
||||
using Sirenix.OdinInspector.Editor.Validation;
|
||||
using UnityEngine.AddressableAssets;
|
||||
using Sirenix.OdinInspector.Modules.Addressables.Editor;
|
||||
|
||||
#if ODIN_VALIDATOR_3_1
|
||||
[assembly: RegisterValidationRule(typeof(AssetLabelReferenceValidator), Description =
|
||||
"This validator ensures that AssetLabelReferences marked with the Required attribute display an error " +
|
||||
"message if they are not set. It can also be configured to require that all AssetLabelReferences be set " +
|
||||
"by default; the Optional attribute can then be used to exclude specific AssetLabelReferences from " +
|
||||
"validation.")]
|
||||
#else
|
||||
[assembly: RegisterValidator(typeof(AssetLabelReferenceValidator))]
|
||||
#endif
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor
|
||||
{
|
||||
/// <summary>
|
||||
/// Validator for AssetLabelReference values.
|
||||
/// </summary>
|
||||
public class AssetLabelReferenceValidator : ValueValidator<AssetLabelReference>
|
||||
{
|
||||
[Tooltip("If enabled, the validator will display an error message if the AssetLabelReference is not set. " +
|
||||
"If disabled, the validator will only display an error message if the AssetLabelReference is set, but the " +
|
||||
"assigned label does not exist.")]
|
||||
[ToggleLeft]
|
||||
public bool RequiredByDefault;
|
||||
|
||||
private bool required;
|
||||
private bool optional;
|
||||
private string requiredMessage;
|
||||
|
||||
protected override void Initialize()
|
||||
{
|
||||
var requiredAttr = this.Property.GetAttribute<RequiredAttribute>();
|
||||
|
||||
this.requiredMessage = requiredAttr?.ErrorMessage ?? $"<b>{this.Property.NiceName}</b> is required.";
|
||||
|
||||
if (this.RequiredByDefault)
|
||||
{
|
||||
required = true;
|
||||
optional = Property.GetAttribute<OptionalAttribute>() != null;
|
||||
}
|
||||
else
|
||||
{
|
||||
required = requiredAttr != null;
|
||||
optional = false;
|
||||
}
|
||||
}
|
||||
|
||||
protected override void Validate(ValidationResult result)
|
||||
{
|
||||
// If the Addressables settings have not been created, nothing else is really valid.
|
||||
if (AddressableAssetSettingsDefaultObject.SettingsExists == false)
|
||||
{
|
||||
result.AddError("Addressables Settings have not been created.")
|
||||
.WithButton("Open Settings Window", () => OdinAddressableUtility.OpenGroupsWindow());
|
||||
return;
|
||||
}
|
||||
|
||||
var value = Value?.labelString;
|
||||
|
||||
if (string.IsNullOrEmpty(value))
|
||||
{
|
||||
if (optional == false && required) // Optional == false & required? Nice.
|
||||
{
|
||||
result.AddError(requiredMessage).EnableRichText();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
var labels = AddressableAssetSettingsDefaultObject.Settings.GetLabels();
|
||||
|
||||
if (labels.Contains(value) == false)
|
||||
{
|
||||
result.AddError($"Label <i>{value}</i> has not been created as a label.")
|
||||
.WithButton("Open Label Settings", () => OdinAddressableUtility.OpenLabelsWindow());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fcaf7dc3b9a98a545b301a1ea175055b
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,284 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="AssetReferenceValidator.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR
|
||||
|
||||
#if !SIRENIX_INTERNAL
|
||||
#pragma warning disable
|
||||
#endif
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using UnityEngine;
|
||||
using UnityEditor;
|
||||
using UnityEditor.AddressableAssets;
|
||||
using Sirenix.OdinInspector.Editor.Validation;
|
||||
using Sirenix.Utilities;
|
||||
using Sirenix.Utilities.Editor;
|
||||
using UnityEditor.AddressableAssets.Settings;
|
||||
using UnityEngine.AddressableAssets;
|
||||
using Sirenix.OdinInspector.Modules.Addressables.Editor;
|
||||
|
||||
#if ODIN_VALIDATOR_3_1
|
||||
[assembly: RegisterValidationRule(typeof(AssetReferenceValidator), Description =
|
||||
"This validator provides robust integrity checks for your asset references within Unity. " +
|
||||
"It validates whether an asset reference has been assigned, and if it's missing, raises an error. " +
|
||||
"It further checks the existence of the main asset at the assigned path, ensuring it hasn't been " +
|
||||
"inadvertently deleted or moved. The validator also verifies if the assigned asset is addressable " +
|
||||
"and, if not, offers a fix to make it addressable. Moreover, it ensures the asset adheres to " +
|
||||
"specific label restrictions set through the AssetReferenceUILabelRestriction attribute. " +
|
||||
"Lastly, it performs checks on any sub-object linked to the asset, making sure it hasn't gone missing. " +
|
||||
"This comprehensive validation system prevents hard-to-spot bugs and errors, " +
|
||||
"fostering a more robust and efficient development workflow.")]
|
||||
#else
|
||||
[assembly: RegisterValidator(typeof(AssetReferenceValidator))]
|
||||
#endif
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor
|
||||
{
|
||||
public class AssetReferenceValidator : ValueValidator<AssetReference>
|
||||
{
|
||||
[Tooltip("If true and the AssetReference is not marked with the Optional attribute, " +
|
||||
"the validator will display an error message if the AssetReference is not set. " +
|
||||
"If false, the validator will only display an error message if the AssetReference is set, " +
|
||||
"but the assigned asset does not exist.")]
|
||||
[ToggleLeft]
|
||||
public bool RequiredByDefault;
|
||||
|
||||
private bool required;
|
||||
private bool optional;
|
||||
private string requiredMessage;
|
||||
|
||||
private List<AssetReferenceUIRestriction> restrictions;
|
||||
|
||||
protected override void Initialize()
|
||||
{
|
||||
var requiredAttr = this.Property.GetAttribute<RequiredAttribute>();
|
||||
|
||||
this.requiredMessage = requiredAttr?.ErrorMessage ?? $"<b>{this.Property.NiceName}</b> is required.";
|
||||
|
||||
if (this.RequiredByDefault)
|
||||
{
|
||||
this.required = true;
|
||||
this.optional = this.Property.GetAttribute<OptionalAttribute>() != null;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.required = requiredAttr != null;
|
||||
this.optional = false;
|
||||
}
|
||||
|
||||
this.restrictions = new List<AssetReferenceUIRestriction>();
|
||||
foreach (var attr in this.Property.Attributes)
|
||||
{
|
||||
if (attr is AssetReferenceUIRestriction r)
|
||||
{
|
||||
this.restrictions.Add(r);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected override void Validate(ValidationResult result)
|
||||
{
|
||||
// If the Addressables settings have not been created, nothing else is really valid.
|
||||
if (AddressableAssetSettingsDefaultObject.SettingsExists == false)
|
||||
{
|
||||
result.AddError("Addressables Settings have not been created.")
|
||||
.WithButton("Open Settings Window", () => OdinAddressableUtility.OpenGroupsWindow());
|
||||
return;
|
||||
}
|
||||
|
||||
var assetReference = this.Value;
|
||||
var assetReferenceHasBeenAssigned = !string.IsNullOrEmpty(assetReference?.AssetGUID);
|
||||
|
||||
// No item has been assigned.
|
||||
if (!assetReferenceHasBeenAssigned)
|
||||
{
|
||||
if (optional == false && required) // Optional == false & required? Nice.
|
||||
{
|
||||
result.AddError(this.requiredMessage).EnableRichText();
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
var assetPath = AssetDatabase.GUIDToAssetPath(assetReference.AssetGUID);
|
||||
var mainAsset = AssetDatabase.LoadMainAssetAtPath(assetPath);
|
||||
|
||||
// The item has been assigned, but is now missing.
|
||||
if (mainAsset == null)
|
||||
{
|
||||
result.AddError($"The previously assigned main asset with path <b>'{assetPath}'</b> is missing. GUID <b>'{assetReference.AssetGUID}'</b>");
|
||||
return;
|
||||
}
|
||||
|
||||
var addressableAssetEntry = AddressableAssetSettingsDefaultObject.Settings.FindAssetEntry(assetReference.AssetGUID, true);
|
||||
var isAddressable = addressableAssetEntry != null;
|
||||
|
||||
// Somehow an item sneaked through all of unity's validation measures and ended up not being addressable
|
||||
// while still ending up in the asset reference object field.
|
||||
if (!isAddressable)
|
||||
{
|
||||
result.AddError("Assigned item is not addressable.")
|
||||
.WithFix<MakeAddressableFixArgs>("Make Addressable", args => OdinAddressableUtility.MakeAddressable(mainAsset, args.Group));
|
||||
}
|
||||
// Check the assigned item against any and all label restrictions.
|
||||
else
|
||||
{
|
||||
if (OdinAddressableUtility.ValidateAssetReferenceRestrictions(restrictions, mainAsset, out var failedRestriction) == false)
|
||||
{
|
||||
if (failedRestriction is AssetReferenceUILabelRestriction labelRestriction)
|
||||
{
|
||||
result.AddError($"Asset reference is restricted to items with these specific labels <b>'{string.Join(", ", labelRestriction.m_AllowedLabels)}'</b>. The currently assigned item has none of them.")
|
||||
.WithFix<AddLabelsFixArgs>("Add Labels", args => SetLabels(mainAsset, args.AssetLabels));
|
||||
}
|
||||
else
|
||||
{
|
||||
result.AddError("Restriction failed: " + failedRestriction.ToString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// The assigned item had a sub object, but it's missing.
|
||||
if (!string.IsNullOrEmpty(assetReference.SubObjectName))
|
||||
{
|
||||
var subObjects = OdinAddressableUtility.EnumerateAllActualAndVirtualSubAssets(mainAsset, assetPath);
|
||||
|
||||
var hasMissingSubObject = true;
|
||||
|
||||
foreach (var subObject in subObjects)
|
||||
{
|
||||
if (subObject.name == assetReference.SubObjectName)
|
||||
{
|
||||
hasMissingSubObject = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (hasMissingSubObject)
|
||||
{
|
||||
result.AddError($"The previously assigned sub asset with name <b>'{assetReference.SubObjectName}'</b> is missing.").EnableRichText();
|
||||
}
|
||||
}
|
||||
|
||||
if (assetReference.ValidateAsset(mainAsset) || assetReference.ValidateAsset(assetPath))
|
||||
return;
|
||||
|
||||
if (assetReference is AssetReferenceSprite && assetReference.editorAsset is Sprite)
|
||||
return;
|
||||
|
||||
result.AddError($"{assetReference.GetType().GetNiceFullName()}.ValidateAsset failed to validate assigned asset.");
|
||||
}
|
||||
|
||||
private static void SetLabels(UnityEngine.Object obj, List<AssetLabel> assetLabels)
|
||||
{
|
||||
if (!AddressableAssetSettingsDefaultObject.SettingsExists) return;
|
||||
|
||||
var settings = AddressableAssetSettingsDefaultObject.Settings;
|
||||
var guid = AssetDatabase.AssetPathToGUID(AssetDatabase.GetAssetPath(obj));
|
||||
var entry = settings.FindAssetEntry(guid, false);
|
||||
|
||||
foreach (var assetLabel in assetLabels.Where(a => a.Toggled))
|
||||
{
|
||||
entry.SetLabel(assetLabel.Label, true, false, false);
|
||||
}
|
||||
|
||||
settings.SetDirty(AddressableAssetSettings.ModificationEvent.LabelAdded, entry, false, true);
|
||||
}
|
||||
|
||||
private class MakeAddressableFixArgs
|
||||
{
|
||||
[ValueDropdown(nameof(GetGroups))]
|
||||
[OnInspectorInit(nameof(SelectDefault))]
|
||||
public AddressableAssetGroup Group;
|
||||
|
||||
private void SelectDefault()
|
||||
{
|
||||
this.Group = AddressableAssetSettingsDefaultObject.SettingsExists
|
||||
? AddressableAssetSettingsDefaultObject.Settings.DefaultGroup
|
||||
: null;
|
||||
}
|
||||
|
||||
private static IEnumerable<ValueDropdownItem> GetGroups()
|
||||
{
|
||||
return !AddressableAssetSettingsDefaultObject.SettingsExists
|
||||
? Enumerable.Empty<ValueDropdownItem>()
|
||||
: AddressableAssetSettingsDefaultObject.Settings.groups
|
||||
.Where(group => !group.ReadOnly)
|
||||
.Select(group => new ValueDropdownItem(group.Name, group));
|
||||
}
|
||||
|
||||
[Button(SdfIconType.ListNested), PropertySpace(8f)]
|
||||
private void OpenAddressablesGroups() => OdinAddressableUtility.OpenGroupsWindow();
|
||||
}
|
||||
|
||||
private class AddLabelsFixArgs
|
||||
{
|
||||
[HideIf("@true")]
|
||||
public List<AssetLabel> AssetLabels
|
||||
{
|
||||
get
|
||||
{
|
||||
if (!AddressableAssetSettingsDefaultObject.SettingsExists) return this.assetLabels;
|
||||
|
||||
var settings = AddressableAssetSettingsDefaultObject.Settings;
|
||||
var labels = settings
|
||||
.GetLabels()
|
||||
.Select(l => new AssetLabel { Label = l, Toggled = false })
|
||||
.ToList();
|
||||
|
||||
foreach (var assetLabel in this.assetLabels)
|
||||
{
|
||||
var label = labels.FirstOrDefault(l => l.Label == assetLabel.Label);
|
||||
|
||||
if (label != null)
|
||||
{
|
||||
label.Toggled = assetLabel.Toggled;
|
||||
}
|
||||
}
|
||||
|
||||
this.assetLabels = labels;
|
||||
return this.assetLabels;
|
||||
}
|
||||
}
|
||||
|
||||
private List<AssetLabel> assetLabels = new List<AssetLabel>();
|
||||
|
||||
[OnInspectorGUI]
|
||||
private void Draw()
|
||||
{
|
||||
var togglesRect = EditorGUILayout.GetControlRect(false, Mathf.CeilToInt(this.AssetLabels.Count / 2f) * 20f);
|
||||
|
||||
for (var i = 0; i < this.AssetLabels.Count; i++)
|
||||
{
|
||||
var assetLabel = this.AssetLabels[i];
|
||||
var toggleRect = togglesRect.SplitGrid(togglesRect.width / 2f, 20, i);
|
||||
assetLabel.Toggled = GUI.Toggle(toggleRect, assetLabel.Toggled, assetLabel.Label);
|
||||
}
|
||||
|
||||
if (!AddressableAssetSettingsDefaultObject.SettingsExists) return;
|
||||
|
||||
GUILayout.Space(8f);
|
||||
|
||||
var buttonsRect = EditorGUILayout.GetControlRect(false, 20f);
|
||||
|
||||
if (SirenixEditorGUI.SDFIconButton(buttonsRect, "Open Addressables Labels", SdfIconType.TagsFill))
|
||||
{
|
||||
OdinAddressableUtility.OpenLabelsWindow();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private class AssetLabel
|
||||
{
|
||||
public bool Toggled;
|
||||
public string Label;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b44b08a1f58a83149988fde5ac600fe4
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,205 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="CheckDuplicateBundleDependenciesValidator.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR && ODIN_VALIDATOR_3_1
|
||||
|
||||
#if !SIRENIX_INTERNAL
|
||||
#pragma warning disable
|
||||
#endif
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using UnityEngine;
|
||||
using UnityEditor;
|
||||
using UnityEditor.AddressableAssets;
|
||||
using Sirenix.OdinInspector.Editor.Validation;
|
||||
using Sirenix.Utilities;
|
||||
using Sirenix.Utilities.Editor;
|
||||
using UnityEditor.AddressableAssets.Settings;
|
||||
using System.Collections;
|
||||
using System;
|
||||
using Sirenix.OdinValidator.Editor;
|
||||
using Sirenix.OdinInspector.Modules.Addressables.Editor;
|
||||
|
||||
[assembly: RegisterValidationRule(typeof(CheckDuplicateBundleDependenciesValidator),
|
||||
Description = "This validator detects potential duplicate asset dependencies in an addressable group, without the need for a build. " +
|
||||
"For instance, imagine two prefabs in separate groups, both referencing the same material. Each group would then include the material " +
|
||||
"and all its associated dependencies. " +
|
||||
"To address this, the material should be marked as Addressable, either with one of the prefabs or in a distinct group.\n\n" +
|
||||
"<b>Fixes: </b>Executing the fix will make the dependency addressable and move it to the specified group.\n\n" +
|
||||
"<b>Exceptions: </b>It's important to note that duplicate assets aren't inherently problematic. For example, if certain assets are " +
|
||||
"never accessed by the same user group, such as region-specific assets, these duplications might be desired or at least inconsequential. " +
|
||||
"As every project is unique, decisions concerning duplicate asset dependencies should be considered on a case-by-case basis.")]
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor
|
||||
{
|
||||
public class CheckDuplicateBundleDependenciesValidator : GlobalValidator
|
||||
{
|
||||
private static Dictionary<GUID, List<string>> dependencyGroupMap = new Dictionary<GUID, List<string>>();
|
||||
|
||||
[Tooltip("The severity of the validation result.")]
|
||||
public ValidatorSeverity ValidatorSeverity = ValidatorSeverity.Warning;
|
||||
|
||||
[Tooltip("Assets to ignore when validating.")]
|
||||
[LabelText("Ignored GUIDs"), CustomValueDrawer(nameof(DrawGUIDEntry))]
|
||||
public List<string> IgnoredGUIDs = new List<string>();
|
||||
|
||||
public override IEnumerable RunValidation(ValidationResult result)
|
||||
{
|
||||
dependencyGroupMap.Clear();
|
||||
|
||||
var addressableAssetSettings = AddressableAssetSettingsDefaultObject.Settings;
|
||||
|
||||
if (addressableAssetSettings == null) yield break;
|
||||
|
||||
foreach (var addressableAssetGroup in addressableAssetSettings.groups)
|
||||
{
|
||||
if (addressableAssetGroup == null) continue;
|
||||
|
||||
foreach (var addressableAssetEntry in addressableAssetGroup.entries)
|
||||
{
|
||||
var dependencyAssetPaths = AssetDatabase.GetDependencies(addressableAssetEntry.AssetPath)
|
||||
.Where(assetPath => !assetPath.EndsWith(".cs", StringComparison.OrdinalIgnoreCase) &&
|
||||
!assetPath.EndsWith(".dll", StringComparison.OrdinalIgnoreCase));
|
||||
|
||||
foreach (var dependencyAssetPath in dependencyAssetPaths)
|
||||
{
|
||||
var dependencyGUID = new GUID(AssetDatabase.AssetPathToGUID(dependencyAssetPath));
|
||||
|
||||
if (this.IgnoredGUIDs.Contains(dependencyGUID.ToString())) continue;
|
||||
|
||||
var dependencyAddressableAssetEntry = addressableAssetSettings.FindAssetEntry(dependencyGUID.ToString());
|
||||
|
||||
var isAddressable = dependencyAddressableAssetEntry != null;
|
||||
if (isAddressable) continue;
|
||||
|
||||
if (!dependencyGroupMap.ContainsKey(dependencyGUID))
|
||||
{
|
||||
dependencyGroupMap.Add(dependencyGUID, new List<string>());
|
||||
}
|
||||
|
||||
if (!dependencyGroupMap[dependencyGUID].Contains(addressableAssetGroup.Name))
|
||||
{
|
||||
dependencyGroupMap[dependencyGUID].Add(addressableAssetGroup.Name);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var kvp in dependencyGroupMap)
|
||||
{
|
||||
var dependencyGUID = kvp.Key;
|
||||
var groups = kvp.Value;
|
||||
|
||||
if (groups.Count > 1)
|
||||
{
|
||||
var assetPath = AssetDatabase.GUIDToAssetPath(dependencyGUID.ToString());
|
||||
var message = $"{assetPath} is duplicated in these groups: {string.Join(", ", groups)}";
|
||||
|
||||
result.Add(this.ValidatorSeverity, message).WithFix<FixArgs>(args =>
|
||||
{
|
||||
if (args.FixChoice == FixChoice.Ignore)
|
||||
{
|
||||
var sourceType = args.IgnoreForEveryone ? ConfigSourceType.Project : ConfigSourceType.Local;
|
||||
var data = RuleConfig.Instance.GetRuleData<CheckDuplicateBundleDependenciesValidator>(sourceType);
|
||||
data.IgnoredGUIDs.Add(dependencyGUID.ToString());
|
||||
RuleConfig.Instance.SetAndSaveRuleData(data, sourceType);
|
||||
return;
|
||||
}
|
||||
|
||||
var obj = AssetDatabase.LoadAssetAtPath(assetPath, typeof(UnityEngine.Object));
|
||||
AddressableAssetGroup group;
|
||||
|
||||
if (args.Group == "Create New Group")
|
||||
{
|
||||
if (args.GroupName.IsNullOrWhitespace()) return;
|
||||
|
||||
group = addressableAssetSettings.FindGroup(args.GroupName);
|
||||
|
||||
if (group == null)
|
||||
{
|
||||
group = addressableAssetSettings.CreateGroup(args.GroupName, false, false, false, null);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
group = addressableAssetSettings.FindGroup(args.Group);
|
||||
|
||||
if (group == null)
|
||||
{
|
||||
group = addressableAssetSettings.CreateGroup(args.Group, false, false, false, null);
|
||||
}
|
||||
}
|
||||
|
||||
OdinAddressableUtility.MakeAddressable(obj, group);
|
||||
}, false).WithModifyRuleDataContextClick<CheckDuplicateBundleDependenciesValidator>("Ignore", data =>
|
||||
{
|
||||
data.IgnoredGUIDs.Add(dependencyGUID.ToString());
|
||||
}).SetSelectionObject(AssetDatabase.LoadAssetAtPath<UnityEngine.Object>(AssetDatabase.GUIDToAssetPath(dependencyGUID.ToString())));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private string DrawGUIDEntry(string guid)
|
||||
{
|
||||
var assetPath = AssetDatabase.GUIDToAssetPath(guid);
|
||||
EditorGUILayout.TextArea(assetPath, SirenixGUIStyles.MultiLineLabel);
|
||||
EditorGUILayout.TextField(guid);
|
||||
return guid;
|
||||
}
|
||||
|
||||
private enum FixChoice
|
||||
{
|
||||
AddToGroup,
|
||||
Ignore,
|
||||
}
|
||||
|
||||
private class FixArgs
|
||||
{
|
||||
[EnumToggleButtons, HideLabel]
|
||||
public FixChoice FixChoice;
|
||||
|
||||
[PropertySpace(10)]
|
||||
[ValueDropdown("Groups")]
|
||||
//[Title("Group To Add To", TitleAlignment = TitleAlignments.Centered)]
|
||||
[ShowIf(nameof(FixChoice), FixChoice.AddToGroup, Animate = false)]
|
||||
public string Group = "Duplicate Asset Isolation";
|
||||
|
||||
[ValidateInput(nameof(ValidateGroupName), "The group name cannot be empty")]
|
||||
[ShowIf(nameof(ShowNewGroupName), Animate = false)]
|
||||
public string GroupName;
|
||||
|
||||
[LabelWidth(120f)]
|
||||
[PropertySpace(10)]
|
||||
[ShowIf("FixChoice", FixChoice.Ignore, Animate = false)]
|
||||
public bool IgnoreForEveryone = true;
|
||||
|
||||
[OnInspectorGUI]
|
||||
[PropertySpace(10)]
|
||||
[DetailedInfoBox("Note that duplicate assets may not always be an issue", "Note that duplicate assets may not always be an issue. If assets will never be requested by the same set of users (for example, region-specific assets), then duplicate dependencies may be desired, or at least inconsequential. Each Project is unique, so fixing duplicate asset dependencies should be evaluated on a case by case basis")]
|
||||
private void Dummy() { }
|
||||
|
||||
private bool ShowNewGroupName => this.FixChoice != FixChoice.Ignore && this.Group == "Create New Group";
|
||||
|
||||
private bool ValidateGroupName() => !this.GroupName.IsNullOrWhitespace();
|
||||
|
||||
private IEnumerable<string> Groups()
|
||||
{
|
||||
var addressableAssetSettings = AddressableAssetSettingsDefaultObject.Settings;
|
||||
|
||||
return addressableAssetSettings == null
|
||||
? Enumerable.Empty<string>()
|
||||
: addressableAssetSettings.groups
|
||||
.Where(group => group != null && group.Name != "Built In Data")
|
||||
.Select(group => group.Name)
|
||||
.Append("Duplicate Asset Isolation")
|
||||
.Prepend("Create New Group");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: bdc8ee2cf75a17644a0bd81a965cc2e0
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,175 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="CheckResourcesToAddressableDuplicateDependenciesValidator.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR && ODIN_VALIDATOR_3_1
|
||||
|
||||
#if !SIRENIX_INTERNAL
|
||||
#pragma warning disable
|
||||
#endif
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using UnityEngine;
|
||||
using UnityEditor;
|
||||
using UnityEditor.AddressableAssets;
|
||||
using Sirenix.OdinInspector.Editor.Validation;
|
||||
using Sirenix.Utilities.Editor;
|
||||
using System.Collections;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Sirenix.OdinValidator.Editor;
|
||||
using Sirenix.OdinInspector.Modules.Addressables.Editor;
|
||||
|
||||
[assembly: RegisterValidationRule(typeof(CheckResourcesToAddressableDuplicateDependenciesValidator),
|
||||
Description = "This validator identifies dependencies that are duplicated in both addressable groups and the \"Resources\" folder.\n\n" +
|
||||
"These duplications mean that data will be included in both the application build and the addressables build.\n\n" +
|
||||
"You can decide to simply ignore these duplicated dependencies if this behavior is desired, or use the provided fix " +
|
||||
"to move the asset outside of the \"Resources\" folder.")]
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor
|
||||
{
|
||||
public class CheckResourcesToAddressableDuplicateDependenciesValidator : GlobalValidator
|
||||
{
|
||||
[Tooltip("The severity of the validation result.")]
|
||||
public ValidatorSeverity ValidatorSeverity = ValidatorSeverity.Warning;
|
||||
|
||||
[Tooltip("Assets to ignore when validating.")]
|
||||
[LabelText("Ignored GUIDs"), CustomValueDrawer(nameof(DrawGUIDEntry))]
|
||||
public List<string> IgnoredGUIDs = new List<string>();
|
||||
|
||||
public override IEnumerable RunValidation(ValidationResult result)
|
||||
{
|
||||
var addressableAssetSettings = AddressableAssetSettingsDefaultObject.Settings;
|
||||
|
||||
if (addressableAssetSettings == null) yield break;
|
||||
|
||||
foreach (var addressableAssetGroup in addressableAssetSettings.groups)
|
||||
{
|
||||
if (addressableAssetGroup == null) continue;
|
||||
|
||||
foreach (var addressableAssetEntry in addressableAssetGroup.entries)
|
||||
{
|
||||
var dependencyAssetPaths = AssetDatabase.GetDependencies(addressableAssetEntry.AssetPath)
|
||||
.Where(assetPath => !assetPath.EndsWith(".cs", StringComparison.OrdinalIgnoreCase) &&
|
||||
!assetPath.EndsWith(".dll", StringComparison.OrdinalIgnoreCase));
|
||||
|
||||
foreach (var dependencyAssetPath in dependencyAssetPaths)
|
||||
{
|
||||
var dependencyGUID = new GUID(AssetDatabase.AssetPathToGUID(dependencyAssetPath));
|
||||
|
||||
if (this.IgnoredGUIDs.Contains(dependencyGUID.ToString())) continue;
|
||||
|
||||
var dependencyAddressableAssetEntry = addressableAssetSettings.FindAssetEntry(dependencyGUID.ToString());
|
||||
|
||||
var isAddressable = dependencyAddressableAssetEntry != null;
|
||||
if (isAddressable) continue;
|
||||
if (!IsInsideResourcesFolder(dependencyAssetPath)) continue;
|
||||
|
||||
result.Add(this.ValidatorSeverity, $"{dependencyAssetPath} is duplicated in addressable data and resource folders.")
|
||||
.WithFix<FixArgs>(args =>
|
||||
{
|
||||
if (args.FixChoice == FixChoice.Ignore)
|
||||
{
|
||||
var sourceType = args.IgnoreForEveryone ? ConfigSourceType.Project : ConfigSourceType.Local;
|
||||
var data = RuleConfig.Instance.GetRuleData<CheckResourcesToAddressableDuplicateDependenciesValidator>(sourceType);
|
||||
data.IgnoredGUIDs.Add(dependencyGUID.ToString());
|
||||
RuleConfig.Instance.SetAndSaveRuleData(data, sourceType);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!ValidNewFolder(args.NewFolder, out _)) return;
|
||||
|
||||
if (!AssetDatabase.IsValidFolder(args.NewFolder))
|
||||
{
|
||||
Directory.CreateDirectory(new DirectoryInfo(args.NewFolder).FullName);
|
||||
AssetDatabase.Refresh();
|
||||
}
|
||||
|
||||
var newPath = $"{args.NewFolder}/{Path.GetFileName(dependencyAssetPath)}";
|
||||
AssetDatabase.MoveAsset(dependencyAssetPath, newPath);
|
||||
}, false).WithModifyRuleDataContextClick<CheckResourcesToAddressableDuplicateDependenciesValidator>("Ignore", data =>
|
||||
{
|
||||
data.IgnoredGUIDs.Add(dependencyGUID.ToString());
|
||||
}).SetSelectionObject(AssetDatabase.LoadAssetAtPath<UnityEngine.Object>(AssetDatabase.GUIDToAssetPath(dependencyGUID.ToString())));
|
||||
|
||||
yield break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private string DrawGUIDEntry(string guid)
|
||||
{
|
||||
var assetPath = AssetDatabase.GUIDToAssetPath(guid);
|
||||
EditorGUILayout.TextArea(assetPath, SirenixGUIStyles.MultiLineLabel);
|
||||
EditorGUILayout.TextField(guid);
|
||||
return guid;
|
||||
}
|
||||
|
||||
private static bool IsInsideResourcesFolder(string path)
|
||||
{
|
||||
var pathElements = path.Split('/');
|
||||
|
||||
foreach (var pathElement in pathElements)
|
||||
{
|
||||
if (pathElement.Equals("Resources", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
private static bool ValidNewFolder(string path, out string message)
|
||||
{
|
||||
if (IsInsideResourcesFolder(path))
|
||||
{
|
||||
message = "The asset cannot be moved into a 'Resources' folder";
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!path.StartsWith("Assets/"))
|
||||
{
|
||||
message = "The asset must be inside the 'Assets' folder";
|
||||
return false;
|
||||
}
|
||||
|
||||
message = "The folder is valid";
|
||||
return true;
|
||||
}
|
||||
|
||||
private enum FixChoice
|
||||
{
|
||||
MoveAsset,
|
||||
Ignore,
|
||||
}
|
||||
private class FixArgs
|
||||
{
|
||||
[HideLabel]
|
||||
[EnumToggleButtons]
|
||||
public FixChoice FixChoice;
|
||||
|
||||
[FolderPath]
|
||||
[PropertySpace(10)]
|
||||
[ValidateInput(nameof(ValidateFolderPath))]
|
||||
[ShowIf("FixChoice", FixChoice.MoveAsset, Animate = false)]
|
||||
public string NewFolder = "Assets/Resources_moved";
|
||||
|
||||
[LabelWidth(120f)]
|
||||
[PropertySpace(10)]
|
||||
[ShowIf("FixChoice", FixChoice.Ignore, Animate = false)]
|
||||
public bool IgnoreForEveryone = true;
|
||||
|
||||
private bool ValidateFolderPath(string path, ref string message)
|
||||
{
|
||||
return ValidNewFolder(path, out message);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f75aebe03a9aa4a4b82d2b54dcc34de5
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,38 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="DisallowAddressableSubAssetFieldAttributeValidator.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR
|
||||
|
||||
#if !SIRENIX_INTERNAL
|
||||
#pragma warning disable
|
||||
#endif
|
||||
|
||||
using Sirenix.OdinInspector.Editor.Validation;
|
||||
using Sirenix.OdinInspector.Modules.Addressables.Editor;
|
||||
using UnityEngine.AddressableAssets;
|
||||
|
||||
[assembly: RegisterValidator(typeof(DisallowAddressableSubAssetFieldAttributeValidator))]
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor
|
||||
{
|
||||
/// <summary>
|
||||
/// Validator for the DisallowAddressableSubAssetFieldAttribute.
|
||||
/// </summary>
|
||||
public class DisallowAddressableSubAssetFieldAttributeValidator : AttributeValidator<DisallowAddressableSubAssetFieldAttribute, AssetReference>
|
||||
{
|
||||
protected override void Validate(ValidationResult result)
|
||||
{
|
||||
if (this.Value != null && string.IsNullOrEmpty(this.Value.SubObjectName) == false)
|
||||
{
|
||||
result.AddError("Sub-asset references is not allowed on this field.")
|
||||
.WithFix("Remove Sub-Asset", () => this.Value.SubObjectName = null, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5775d33ffc1143149c4f425f693b04b6
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,59 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="MissingAddressableGroupReferenceValidator.cs" company="Sirenix ApS">
|
||||
// Copyright (c) Sirenix ApS. All rights reserved.
|
||||
// </copyright>
|
||||
//-----------------------------------------------------------------------
|
||||
|
||||
#if UNITY_EDITOR && ODIN_VALIDATOR_3_1
|
||||
|
||||
#if !SIRENIX_INTERNAL
|
||||
#pragma warning disable
|
||||
#endif
|
||||
|
||||
using System.Collections.Generic;
|
||||
using UnityEditor.AddressableAssets;
|
||||
using Sirenix.OdinInspector.Editor.Validation;
|
||||
using UnityEditor.AddressableAssets.Settings;
|
||||
using System.Collections;
|
||||
using Sirenix.OdinInspector.Modules.Addressables.Editor;
|
||||
|
||||
[assembly: RegisterValidator(typeof(MissingAddressableGroupReferenceValidator))]
|
||||
|
||||
namespace Sirenix.OdinInspector.Modules.Addressables.Editor
|
||||
{
|
||||
public class MissingAddressableGroupReferenceValidator : GlobalValidator
|
||||
{
|
||||
public override IEnumerable RunValidation(ValidationResult result)
|
||||
{
|
||||
var addressableAssetSettings = AddressableAssetSettingsDefaultObject.Settings;
|
||||
|
||||
if (addressableAssetSettings == null) yield break;
|
||||
|
||||
var missingGroupIndices = new List<int>();
|
||||
|
||||
for (var i = 0; i < addressableAssetSettings.groups.Count; i++)
|
||||
{
|
||||
var group = addressableAssetSettings.groups[i];
|
||||
|
||||
if (group == null)
|
||||
{
|
||||
missingGroupIndices.Add(i);
|
||||
}
|
||||
}
|
||||
|
||||
if (missingGroupIndices.Count > 0)
|
||||
{
|
||||
result.Add(ValidatorSeverity.Error, "Addressable groups contains missing references").WithFix("Delete missing reference", () =>
|
||||
{
|
||||
for (var i = missingGroupIndices.Count - 1; i >= 0; i--)
|
||||
{
|
||||
addressableAssetSettings.groups.RemoveAt(missingGroupIndices[i]);
|
||||
addressableAssetSettings.SetDirty(AddressableAssetSettings.ModificationEvent.GroupRemoved, null, true, true);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4ae55abdaf19ef4498d1a2fbe1bd9f9b
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,26 @@
|
||||
ManifestVersion: 1
|
||||
ModuleID: Unity.Addressables
|
||||
ModuleVersion: 1.1.0.11
|
||||
ModuleFiles:
|
||||
AddressablesInspectors.cs
|
||||
AddressablesInspectors.cs.meta
|
||||
Internal.meta
|
||||
Sirenix.OdinInspector.Modules.Unity.Addressables.asmdef
|
||||
Sirenix.OdinInspector.Modules.Unity.Addressables.asmdef.meta
|
||||
Validators.meta
|
||||
Internal/OdinAddressableReflection.cs
|
||||
Internal/OdinAddressableReflection.cs.meta
|
||||
Internal/OdinAddressableReflectionValidator.cs
|
||||
Internal/OdinAddressableReflectionValidator.cs.meta
|
||||
Validators/AssetLabelReferenceValidator.cs
|
||||
Validators/AssetLabelReferenceValidator.cs.meta
|
||||
Validators/AssetReferenceValidator.cs
|
||||
Validators/AssetReferenceValidator.cs.meta
|
||||
Validators/CheckDuplicateBundleDependenciesValidator.cs
|
||||
Validators/CheckDuplicateBundleDependenciesValidator.cs.meta
|
||||
Validators/CheckResourcesToAddressableDuplicateDependenciesValidator.cs
|
||||
Validators/CheckResourcesToAddressableDuplicateDependenciesValidator.cs.meta
|
||||
Validators/DisallowAddressableSubAssetFieldAttributeValidator.cs
|
||||
Validators/DisallowAddressableSubAssetFieldAttributeValidator.cs.meta
|
||||
Validators/MissingAddressableGroupReferenceValidator.cs
|
||||
Validators/MissingAddressableGroupReferenceValidator.cs.meta
|
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e5ce26639cbf46447a2b1298c436a485
|
||||
guid: 26ad4dcfe6d4d1049816f9511d46fe4d
|
||||
TextScriptImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
8
Assets/TextMesh Pro.meta
Normal file
8
Assets/TextMesh Pro.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f54d1bd14bd3ca042bd867b519fee8cc
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/TextMesh Pro/Fonts.meta
Normal file
8
Assets/TextMesh Pro/Fonts.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 6ab70aee4d56447429c680537fbf93ed
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
46
Assets/TextMesh Pro/Fonts/LiberationSans - OFL.txt
Normal file
46
Assets/TextMesh Pro/Fonts/LiberationSans - OFL.txt
Normal file
@ -0,0 +1,46 @@
|
||||
Digitized data copyright (c) 2010 Google Corporation
|
||||
with Reserved Font Arimo, Tinos and Cousine.
|
||||
Copyright (c) 2012 Red Hat, Inc.
|
||||
with Reserved Font Name Liberation.
|
||||
|
||||
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
||||
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
|
||||
|
||||
-----------------------------------------------------------
|
||||
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
||||
-----------------------------------------------------------
|
||||
|
||||
PREAMBLE
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
|
||||
|
||||
DEFINITIONS
|
||||
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
|
||||
|
||||
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
|
||||
|
||||
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
|
||||
|
||||
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
|
||||
|
||||
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
|
||||
|
||||
PERMISSION & CONDITIONS
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
|
||||
|
||||
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
|
||||
|
||||
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
|
||||
|
||||
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
|
||||
|
||||
TERMINATION
|
||||
This license becomes null and void if any of the above conditions are not met.
|
||||
|
||||
DISCLAIMER
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.
|
8
Assets/TextMesh Pro/Fonts/LiberationSans - OFL.txt.meta
Normal file
8
Assets/TextMesh Pro/Fonts/LiberationSans - OFL.txt.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 6e59c59b81ab47f9b6ec5781fa725d2c
|
||||
timeCreated: 1484171296
|
||||
licenseType: Pro
|
||||
TextScriptImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/TextMesh Pro/Fonts/LiberationSans.ttf
Normal file
BIN
Assets/TextMesh Pro/Fonts/LiberationSans.ttf
Normal file
Binary file not shown.
19
Assets/TextMesh Pro/Fonts/LiberationSans.ttf.meta
Normal file
19
Assets/TextMesh Pro/Fonts/LiberationSans.ttf.meta
Normal file
@ -0,0 +1,19 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e3265ab4bf004d28a9537516768c1c75
|
||||
timeCreated: 1484171297
|
||||
licenseType: Pro
|
||||
TrueTypeFontImporter:
|
||||
serializedVersion: 2
|
||||
fontSize: 16
|
||||
forceTextureCase: -2
|
||||
characterSpacing: 1
|
||||
characterPadding: 0
|
||||
includeFontData: 1
|
||||
use2xBehaviour: 0
|
||||
fontNames: []
|
||||
fallbackFontReferences: []
|
||||
customCharacters:
|
||||
fontRenderingMode: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/TextMesh Pro/Resources.meta
Normal file
8
Assets/TextMesh Pro/Resources.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 243e06394e614e5d99fab26083b707fa
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
9
Assets/TextMesh Pro/Resources/Fonts & Materials.meta
Normal file
9
Assets/TextMesh Pro/Resources/Fonts & Materials.meta
Normal file
@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 731f1baa9d144a9897cb1d341c2092b8
|
||||
folderAsset: yes
|
||||
timeCreated: 1442040525
|
||||
licenseType: Pro
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,106 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: LiberationSans SDF - Drop Shadow
|
||||
m_Shader: {fileID: 4800000, guid: fe393ace9b354375a9cb14cdbbc28be4, type: 3}
|
||||
m_ShaderKeywords: OUTLINE_ON UNDERLAY_ON
|
||||
m_LightmapFlags: 5
|
||||
m_EnableInstancingVariants: 0
|
||||
m_DoubleSidedGI: 0
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
disabledShaderPasses: []
|
||||
m_SavedProperties:
|
||||
serializedVersion: 3
|
||||
m_TexEnvs:
|
||||
- _BumpMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _Cube:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _FaceTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _MainTex:
|
||||
m_Texture: {fileID: 28684132378477856, guid: 8f586378b4e144a9851e7b34d9b748ee,
|
||||
type: 2}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _OutlineTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- _Ambient: 0.5
|
||||
- _Bevel: 0.5
|
||||
- _BevelClamp: 0
|
||||
- _BevelOffset: 0
|
||||
- _BevelRoundness: 0
|
||||
- _BevelWidth: 0
|
||||
- _BumpFace: 0
|
||||
- _BumpOutline: 0
|
||||
- _ColorMask: 15
|
||||
- _Diffuse: 0.5
|
||||
- _DiffusePower: 1
|
||||
- _FaceDilate: 0.1
|
||||
- _FaceUVSpeedX: 0
|
||||
- _FaceUVSpeedY: 0
|
||||
- _GlowInner: 0.05
|
||||
- _GlowOffset: 0
|
||||
- _GlowOuter: 0.05
|
||||
- _GlowPower: 0.75
|
||||
- _GradientScale: 10
|
||||
- _LightAngle: 3.1416
|
||||
- _MaskSoftnessX: 0
|
||||
- _MaskSoftnessY: 0
|
||||
- _OutlineSoftness: 0
|
||||
- _OutlineUVSpeedX: 0
|
||||
- _OutlineUVSpeedY: 0
|
||||
- _OutlineWidth: 0.1
|
||||
- _PerspectiveFilter: 0.875
|
||||
- _Reflectivity: 10
|
||||
- _ScaleRatioA: 0.9
|
||||
- _ScaleRatioB: 0.73125
|
||||
- _ScaleRatioC: 0.64125
|
||||
- _ScaleX: 1
|
||||
- _ScaleY: 1
|
||||
- _ShaderFlags: 0
|
||||
- _Sharpness: 0
|
||||
- _SpecularPower: 2
|
||||
- _Stencil: 0
|
||||
- _StencilComp: 8
|
||||
- _StencilOp: 0
|
||||
- _StencilReadMask: 255
|
||||
- _StencilWriteMask: 255
|
||||
- _TextureHeight: 1024
|
||||
- _TextureWidth: 1024
|
||||
- _UnderlayDilate: 0
|
||||
- _UnderlayOffsetX: 0.5
|
||||
- _UnderlayOffsetY: -0.5
|
||||
- _UnderlaySoftness: 0.05
|
||||
- _VertexOffsetX: 0
|
||||
- _VertexOffsetY: 0
|
||||
- _WeightBold: 0.75
|
||||
- _WeightNormal: 0
|
||||
m_Colors:
|
||||
- _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767}
|
||||
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _EnvMatrixRotation: {r: 0, g: 0, b: 0, a: 0}
|
||||
- _FaceColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _GlowColor: {r: 0, g: 1, b: 0, a: 0.5}
|
||||
- _MaskCoord: {r: 0, g: 0, b: 32767, a: 32767}
|
||||
- _OutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectFaceColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectOutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _SpecularColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _UnderlayColor: {r: 0, g: 0, b: 0, a: 0.5}
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e73a58f6e2794ae7b1b7e50b7fb811b0
|
||||
timeCreated: 1484172806
|
||||
licenseType: Pro
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,348 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2180264
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: LiberationSans SDF Material
|
||||
m_Shader: {fileID: 4800000, guid: fe393ace9b354375a9cb14cdbbc28be4, type: 3}
|
||||
m_ShaderKeywords:
|
||||
m_LightmapFlags: 1
|
||||
m_EnableInstancingVariants: 0
|
||||
m_DoubleSidedGI: 0
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
disabledShaderPasses: []
|
||||
m_SavedProperties:
|
||||
serializedVersion: 3
|
||||
m_TexEnvs:
|
||||
- _BumpMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _Cube:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _DetailAlbedoMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _DetailMask:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _DetailNormalMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _EmissionMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _FaceTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _MainTex:
|
||||
m_Texture: {fileID: 28268798066460806}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _MetallicGlossMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _OcclusionMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _OutlineTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ParallaxMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- _Ambient: 0.5
|
||||
- _Bevel: 0.5
|
||||
- _BevelClamp: 0
|
||||
- _BevelOffset: 0
|
||||
- _BevelRoundness: 0
|
||||
- _BevelWidth: 0
|
||||
- _BumpFace: 0
|
||||
- _BumpOutline: 0
|
||||
- _BumpScale: 1
|
||||
- _ColorMask: 15
|
||||
- _CullMode: 0
|
||||
- _Cutoff: 0.5
|
||||
- _DetailNormalMapScale: 1
|
||||
- _Diffuse: 0.5
|
||||
- _DstBlend: 0
|
||||
- _FaceDilate: 0
|
||||
- _FaceUVSpeedX: 0
|
||||
- _FaceUVSpeedY: 0
|
||||
- _GlossMapScale: 1
|
||||
- _Glossiness: 0.5
|
||||
- _GlossyReflections: 1
|
||||
- _GlowInner: 0.05
|
||||
- _GlowOffset: 0
|
||||
- _GlowOuter: 0.05
|
||||
- _GlowPower: 0.75
|
||||
- _GradientScale: 10
|
||||
- _LightAngle: 3.1416
|
||||
- _MaskSoftnessX: 0
|
||||
- _MaskSoftnessY: 0
|
||||
- _Metallic: 0
|
||||
- _Mode: 0
|
||||
- _OcclusionStrength: 1
|
||||
- _OutlineSoftness: 0
|
||||
- _OutlineUVSpeedX: 0
|
||||
- _OutlineUVSpeedY: 0
|
||||
- _OutlineWidth: 0
|
||||
- _Parallax: 0.02
|
||||
- _PerspectiveFilter: 0.875
|
||||
- _Reflectivity: 10
|
||||
- _ScaleRatioA: 0.90909094
|
||||
- _ScaleRatioB: 0.73125
|
||||
- _ScaleRatioC: 0.7386364
|
||||
- _ScaleX: 1
|
||||
- _ScaleY: 1
|
||||
- _ShaderFlags: 0
|
||||
- _Sharpness: 0
|
||||
- _SmoothnessTextureChannel: 0
|
||||
- _SpecularHighlights: 1
|
||||
- _SpecularPower: 2
|
||||
- _SrcBlend: 1
|
||||
- _Stencil: 0
|
||||
- _StencilComp: 8
|
||||
- _StencilOp: 0
|
||||
- _StencilReadMask: 255
|
||||
- _StencilWriteMask: 255
|
||||
- _TextureHeight: 512
|
||||
- _TextureWidth: 512
|
||||
- _UVSec: 0
|
||||
- _UnderlayDilate: 0
|
||||
- _UnderlayOffsetX: 0
|
||||
- _UnderlayOffsetY: 0
|
||||
- _UnderlaySoftness: 0
|
||||
- _VertexOffsetX: 0
|
||||
- _VertexOffsetY: 0
|
||||
- _WeightBold: 0.75
|
||||
- _WeightNormal: 0
|
||||
- _ZWrite: 1
|
||||
m_Colors:
|
||||
- _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767}
|
||||
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _EnvMatrixRotation: {r: 0, g: 0, b: 0, a: 0}
|
||||
- _FaceColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _GlowColor: {r: 0, g: 1, b: 0, a: 0.5}
|
||||
- _MaskCoord: {r: 0, g: 0, b: 32767, a: 32767}
|
||||
- _OutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectFaceColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectOutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _SpecularColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _UnderlayColor: {r: 0, g: 0, b: 0, a: 0.5}
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 71c1514a6bd24e1e882cebbe1904ce04, type: 3}
|
||||
m_Name: LiberationSans SDF - Fallback
|
||||
m_EditorClassIdentifier:
|
||||
m_Version: 1.1.0
|
||||
m_Material: {fileID: 2180264}
|
||||
m_SourceFontFileGUID: e3265ab4bf004d28a9537516768c1c75
|
||||
m_SourceFontFile: {fileID: 12800000, guid: e3265ab4bf004d28a9537516768c1c75, type: 3}
|
||||
m_AtlasPopulationMode: 1
|
||||
InternalDynamicOS: 0
|
||||
m_FaceInfo:
|
||||
m_FaceIndex: 0
|
||||
m_FamilyName: Liberation Sans
|
||||
m_StyleName: Regular
|
||||
m_PointSize: 86
|
||||
m_Scale: 1
|
||||
m_UnitsPerEM: 2048
|
||||
m_LineHeight: 98.8916
|
||||
m_AscentLine: 77.853516
|
||||
m_CapLine: 59
|
||||
m_MeanLine: 45
|
||||
m_Baseline: 0
|
||||
m_DescentLine: -18.22461
|
||||
m_SuperscriptOffset: 77.853516
|
||||
m_SuperscriptSize: 0.5
|
||||
m_SubscriptOffset: -18.22461
|
||||
m_SubscriptSize: 0.5
|
||||
m_UnderlineOffset: -12.261719
|
||||
m_UnderlineThickness: 6.298828
|
||||
m_StrikethroughOffset: 18
|
||||
m_StrikethroughThickness: 6.298828
|
||||
m_TabWidth: 24
|
||||
m_GlyphTable: []
|
||||
m_CharacterTable: []
|
||||
m_AtlasTextures:
|
||||
- {fileID: 28268798066460806}
|
||||
m_AtlasTextureIndex: 0
|
||||
m_IsMultiAtlasTexturesEnabled: 1
|
||||
m_ClearDynamicDataOnBuild: 1
|
||||
m_UsedGlyphRects: []
|
||||
m_FreeGlyphRects:
|
||||
- m_X: 0
|
||||
m_Y: 0
|
||||
m_Width: 511
|
||||
m_Height: 511
|
||||
m_fontInfo:
|
||||
Name: Liberation Sans
|
||||
PointSize: 86
|
||||
Scale: 1
|
||||
CharacterCount: 250
|
||||
LineHeight: 98.90625
|
||||
Baseline: 0
|
||||
Ascender: 77.84375
|
||||
CapHeight: 59.1875
|
||||
Descender: -18.21875
|
||||
CenterLine: 0
|
||||
SuperscriptOffset: 77.84375
|
||||
SubscriptOffset: -12.261719
|
||||
SubSize: 0.5
|
||||
Underline: -12.261719
|
||||
UnderlineThickness: 6.298828
|
||||
strikethrough: 23.675
|
||||
strikethroughThickness: 0
|
||||
TabWidth: 239.0625
|
||||
Padding: 9
|
||||
AtlasWidth: 1024
|
||||
AtlasHeight: 1024
|
||||
atlas: {fileID: 0}
|
||||
m_AtlasWidth: 512
|
||||
m_AtlasHeight: 512
|
||||
m_AtlasPadding: 9
|
||||
m_AtlasRenderMode: 4169
|
||||
m_glyphInfoList: []
|
||||
m_KerningTable:
|
||||
kerningPairs: []
|
||||
m_FontFeatureTable:
|
||||
m_MultipleSubstitutionRecords: []
|
||||
m_LigatureSubstitutionRecords: []
|
||||
m_GlyphPairAdjustmentRecords: []
|
||||
m_MarkToBaseAdjustmentRecords: []
|
||||
m_MarkToMarkAdjustmentRecords: []
|
||||
fallbackFontAssets: []
|
||||
m_FallbackFontAssetTable: []
|
||||
m_CreationSettings:
|
||||
sourceFontFileName:
|
||||
sourceFontFileGUID: e3265ab4bf004d28a9537516768c1c75
|
||||
faceIndex: 0
|
||||
pointSizeSamplingMode: 0
|
||||
pointSize: 86
|
||||
padding: 9
|
||||
paddingMode: 0
|
||||
packingMode: 4
|
||||
atlasWidth: 512
|
||||
atlasHeight: 512
|
||||
characterSetSelectionMode: 1
|
||||
characterSequence: 32 - 126, 160 - 255, 8192 - 8303, 8364, 8482, 9633
|
||||
referencedFontAssetGUID: 8f586378b4e144a9851e7b34d9b748ee
|
||||
referencedTextAssetGUID:
|
||||
fontStyle: 0
|
||||
fontStyleModifier: 0
|
||||
renderMode: 4169
|
||||
includeFontFeatures: 1
|
||||
m_FontWeightTable:
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
fontWeights:
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
- regularTypeface: {fileID: 0}
|
||||
italicTypeface: {fileID: 0}
|
||||
normalStyle: 0
|
||||
normalSpacingOffset: 0
|
||||
boldStyle: 0.75
|
||||
boldSpacing: 7
|
||||
italicStyle: 35
|
||||
tabSize: 10
|
||||
--- !u!28 &28268798066460806
|
||||
Texture2D:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: LiberationSans SDF Atlas
|
||||
m_ImageContentsHash:
|
||||
serializedVersion: 2
|
||||
Hash: 00000000000000000000000000000000
|
||||
m_ForcedFallbackFormat: 4
|
||||
m_DownscaleFallback: 0
|
||||
serializedVersion: 2
|
||||
m_Width: 0
|
||||
m_Height: 0
|
||||
m_CompleteImageSize: 0
|
||||
m_TextureFormat: 1
|
||||
m_MipCount: 1
|
||||
m_IsReadable: 1
|
||||
m_StreamingMipmaps: 0
|
||||
m_StreamingMipmapsPriority: 0
|
||||
m_AlphaIsTransparency: 0
|
||||
m_ImageCount: 1
|
||||
m_TextureDimension: 2
|
||||
m_TextureSettings:
|
||||
serializedVersion: 2
|
||||
m_FilterMode: 1
|
||||
m_Aniso: 1
|
||||
m_MipBias: 0
|
||||
m_WrapU: 0
|
||||
m_WrapV: 0
|
||||
m_WrapW: 0
|
||||
m_LightmapFormat: 0
|
||||
m_ColorSpace: 0
|
||||
image data: 0
|
||||
_typelessdata:
|
||||
m_StreamData:
|
||||
offset: 0
|
||||
size: 0
|
||||
path:
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2e498d1c8094910479dc3e1b768306a4
|
||||
timeCreated: 1484171803
|
||||
licenseType: Pro
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,104 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: LiberationSans SDF - Outline
|
||||
m_Shader: {fileID: 4800000, guid: fe393ace9b354375a9cb14cdbbc28be4, type: 3}
|
||||
m_ShaderKeywords: OUTLINE_ON
|
||||
m_LightmapFlags: 5
|
||||
m_EnableInstancingVariants: 0
|
||||
m_DoubleSidedGI: 0
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
disabledShaderPasses: []
|
||||
m_SavedProperties:
|
||||
serializedVersion: 3
|
||||
m_TexEnvs:
|
||||
- _BumpMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _Cube:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _FaceTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _MainTex:
|
||||
m_Texture: {fileID: 28684132378477856, guid: 8f586378b4e144a9851e7b34d9b748ee,
|
||||
type: 2}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _OutlineTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- _Ambient: 0.5
|
||||
- _Bevel: 0.5
|
||||
- _BevelClamp: 0
|
||||
- _BevelOffset: 0
|
||||
- _BevelRoundness: 0
|
||||
- _BevelWidth: 0
|
||||
- _BumpFace: 0
|
||||
- _BumpOutline: 0
|
||||
- _ColorMask: 15
|
||||
- _Diffuse: 0.5
|
||||
- _FaceDilate: 0.1
|
||||
- _FaceUVSpeedX: 0
|
||||
- _FaceUVSpeedY: 0
|
||||
- _GlowInner: 0.05
|
||||
- _GlowOffset: 0
|
||||
- _GlowOuter: 0.05
|
||||
- _GlowPower: 0.75
|
||||
- _GradientScale: 10
|
||||
- _LightAngle: 3.1416
|
||||
- _MaskSoftnessX: 0
|
||||
- _MaskSoftnessY: 0
|
||||
- _OutlineSoftness: 0
|
||||
- _OutlineUVSpeedX: 0
|
||||
- _OutlineUVSpeedY: 0
|
||||
- _OutlineWidth: 0.1
|
||||
- _PerspectiveFilter: 0.875
|
||||
- _Reflectivity: 10
|
||||
- _ScaleRatioA: 0.9
|
||||
- _ScaleRatioB: 0.73125
|
||||
- _ScaleRatioC: 0.64125
|
||||
- _ScaleX: 1
|
||||
- _ScaleY: 1
|
||||
- _ShaderFlags: 0
|
||||
- _Sharpness: 0
|
||||
- _SpecularPower: 2
|
||||
- _Stencil: 0
|
||||
- _StencilComp: 8
|
||||
- _StencilOp: 0
|
||||
- _StencilReadMask: 255
|
||||
- _StencilWriteMask: 255
|
||||
- _TextureHeight: 1024
|
||||
- _TextureWidth: 1024
|
||||
- _UnderlayDilate: 0
|
||||
- _UnderlayOffsetX: 0
|
||||
- _UnderlayOffsetY: 0
|
||||
- _UnderlaySoftness: 0
|
||||
- _VertexOffsetX: 0
|
||||
- _VertexOffsetY: 0
|
||||
- _WeightBold: 0.75
|
||||
- _WeightNormal: 0
|
||||
m_Colors:
|
||||
- _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767}
|
||||
- _EnvMatrixRotation: {r: 0, g: 0, b: 0, a: 0}
|
||||
- _FaceColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _GlowColor: {r: 0, g: 1, b: 0, a: 0.5}
|
||||
- _MaskCoord: {r: 0, g: 0, b: 32767, a: 32767}
|
||||
- _OutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectFaceColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectOutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _SpecularColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _UnderlayColor: {r: 0, g: 0, b: 0, a: 0.5}
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 79459efec17a4d00a321bdcc27bbc385
|
||||
timeCreated: 1484172856
|
||||
licenseType: Pro
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
File diff suppressed because one or more lines are too long
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8f586378b4e144a9851e7b34d9b748ee
|
||||
timeCreated: 1484171803
|
||||
licenseType: Pro
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1 @@
|
||||
)]}〕〉》」』】〙〗〟’”⦆»ヽヾーァィゥェォッャュョヮヵヶぁぃぅぇぉっゃゅょゎゕゖㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇺㇻㇼㇽㇾㇿ々〻‐゠–〜?!‼⁇⁈⁉・、%,.:;。!?]):;=}¢°"†‡℃〆%,.
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fade42e8bc714b018fac513c043d323b
|
||||
timeCreated: 1425440388
|
||||
licenseType: Store
|
||||
TextScriptImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1 @@
|
||||
([{〔〈《「『【〘〖〝‘“⦅«$—…‥〳〴〵\[({£¥"々〇$¥₩ #
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d82c1b31c7e74239bff1220585707d2b
|
||||
timeCreated: 1425440388
|
||||
licenseType: Store
|
||||
TextScriptImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
9
Assets/TextMesh Pro/Resources/Sprite Assets.meta
Normal file
9
Assets/TextMesh Pro/Resources/Sprite Assets.meta
Normal file
@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 512a49d95c0c4332bdd98131869c23c9
|
||||
folderAsset: yes
|
||||
timeCreated: 1441876896
|
||||
licenseType: Pro
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
659
Assets/TextMesh Pro/Resources/Sprite Assets/EmojiOne.asset
Normal file
659
Assets/TextMesh Pro/Resources/Sprite Assets/EmojiOne.asset
Normal file
@ -0,0 +1,659 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2103686
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: TextMeshPro/Sprite
|
||||
m_Shader: {fileID: 4800000, guid: cf81c85f95fe47e1a27f6ae460cf182c, type: 3}
|
||||
m_ShaderKeywords: UNITY_UI_CLIP_RECT
|
||||
m_LightmapFlags: 5
|
||||
m_EnableInstancingVariants: 0
|
||||
m_DoubleSidedGI: 0
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
disabledShaderPasses: []
|
||||
m_SavedProperties:
|
||||
serializedVersion: 3
|
||||
m_TexEnvs:
|
||||
- _MainTex:
|
||||
m_Texture: {fileID: 2800000, guid: dffef66376be4fa480fb02b19edbe903, type: 3}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- _ColorMask: 15
|
||||
- _CullMode: 0
|
||||
- _Stencil: 0
|
||||
- _StencilComp: 8
|
||||
- _StencilOp: 0
|
||||
- _StencilReadMask: 255
|
||||
- _StencilWriteMask: 255
|
||||
- _UseUIAlphaClip: 0
|
||||
m_Colors:
|
||||
- _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767}
|
||||
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 84a92b25f83d49b9bc132d206b370281, type: 3}
|
||||
m_Name: EmojiOne
|
||||
m_EditorClassIdentifier:
|
||||
hashCode: -1836805472
|
||||
material: {fileID: 2103686}
|
||||
materialHashCode: 0
|
||||
m_Version: 1.1.0
|
||||
m_FaceInfo:
|
||||
m_FamilyName:
|
||||
m_StyleName:
|
||||
m_PointSize: 0
|
||||
m_Scale: 0
|
||||
m_LineHeight: 0
|
||||
m_AscentLine: 0
|
||||
m_CapLine: 0
|
||||
m_MeanLine: 0
|
||||
m_Baseline: 0
|
||||
m_DescentLine: 0
|
||||
m_SuperscriptOffset: 0
|
||||
m_SuperscriptSize: 0
|
||||
m_SubscriptOffset: 0
|
||||
m_SubscriptSize: 0
|
||||
m_UnderlineOffset: 0
|
||||
m_UnderlineThickness: 0
|
||||
m_StrikethroughOffset: 0
|
||||
m_StrikethroughThickness: 0
|
||||
m_TabWidth: 0
|
||||
spriteSheet: {fileID: 2800000, guid: dffef66376be4fa480fb02b19edbe903, type: 3}
|
||||
m_SpriteCharacterTable:
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128522
|
||||
m_GlyphIndex: 0
|
||||
m_Scale: 1
|
||||
m_Name: Smiling face with smiling eyes
|
||||
m_HashCode: -1318250903
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128523
|
||||
m_GlyphIndex: 1
|
||||
m_Scale: 1
|
||||
m_Name: 1f60b
|
||||
m_HashCode: 57188339
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128525
|
||||
m_GlyphIndex: 2
|
||||
m_Scale: 1
|
||||
m_Name: 1f60d
|
||||
m_HashCode: 57188341
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128526
|
||||
m_GlyphIndex: 3
|
||||
m_Scale: 1
|
||||
m_Name: 1f60e
|
||||
m_HashCode: 57188340
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128512
|
||||
m_GlyphIndex: 4
|
||||
m_Scale: 1
|
||||
m_Name: Grinning face
|
||||
m_HashCode: -95541379
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128513
|
||||
m_GlyphIndex: 5
|
||||
m_Scale: 1
|
||||
m_Name: 1f601
|
||||
m_HashCode: 57188256
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128514
|
||||
m_GlyphIndex: 6
|
||||
m_Scale: 1
|
||||
m_Name: Face with tears of joy
|
||||
m_HashCode: 239522663
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128515
|
||||
m_GlyphIndex: 7
|
||||
m_Scale: 1
|
||||
m_Name: 1f603
|
||||
m_HashCode: 57188258
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128516
|
||||
m_GlyphIndex: 8
|
||||
m_Scale: 1
|
||||
m_Name: 1f604
|
||||
m_HashCode: 57188261
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128517
|
||||
m_GlyphIndex: 9
|
||||
m_Scale: 1
|
||||
m_Name: 1f605
|
||||
m_HashCode: 57188260
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128518
|
||||
m_GlyphIndex: 10
|
||||
m_Scale: 1
|
||||
m_Name: 1f606
|
||||
m_HashCode: 57188263
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 128521
|
||||
m_GlyphIndex: 11
|
||||
m_Scale: 1
|
||||
m_Name: 1f609
|
||||
m_HashCode: 57188264
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 0
|
||||
m_GlyphIndex: 12
|
||||
m_Scale: 1
|
||||
m_Name: .notdef
|
||||
m_HashCode: -600915428
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 129315
|
||||
m_GlyphIndex: 13
|
||||
m_Scale: 1
|
||||
m_Name: 1f923
|
||||
m_HashCode: 57200239
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 9786
|
||||
m_GlyphIndex: 14
|
||||
m_Scale: 1
|
||||
m_Name: 263a
|
||||
m_HashCode: 1748406
|
||||
- m_ElementType: 2
|
||||
m_Unicode: 9785
|
||||
m_GlyphIndex: 15
|
||||
m_Scale: 1
|
||||
m_Name: 2639
|
||||
m_HashCode: 1748462
|
||||
m_SpriteGlyphTable:
|
||||
- m_Index: 0
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 0
|
||||
m_Y: 384
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 1
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 128
|
||||
m_Y: 384
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 2
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 256
|
||||
m_Y: 384
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 3
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 384
|
||||
m_Y: 384
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 4
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 0
|
||||
m_Y: 256
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 5
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 128
|
||||
m_Y: 256
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 6
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 256
|
||||
m_Y: 256
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 7
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 384
|
||||
m_Y: 256
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 8
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 0
|
||||
m_Y: 128
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 9
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 128
|
||||
m_Y: 128
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 10
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 256
|
||||
m_Y: 128
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 11
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 384
|
||||
m_Y: 128
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 12
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 0
|
||||
m_Y: 0
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 13
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 128
|
||||
m_Y: 0
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 14
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 256
|
||||
m_Y: 0
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
- m_Index: 15
|
||||
m_Metrics:
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_HorizontalBearingX: 0
|
||||
m_HorizontalBearingY: 115.6
|
||||
m_HorizontalAdvance: 128
|
||||
m_GlyphRect:
|
||||
m_X: 384
|
||||
m_Y: 0
|
||||
m_Width: 128
|
||||
m_Height: 128
|
||||
m_Scale: 1
|
||||
m_AtlasIndex: 0
|
||||
sprite: {fileID: 0}
|
||||
spriteInfoList:
|
||||
- id: 0
|
||||
x: 0
|
||||
y: 384
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: Smiling face with smiling eyes
|
||||
hashCode: -1318250903
|
||||
unicode: 128522
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 1
|
||||
x: 128
|
||||
y: 384
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f60b
|
||||
hashCode: 57188339
|
||||
unicode: 128523
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 2
|
||||
x: 256
|
||||
y: 384
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f60d
|
||||
hashCode: 57188341
|
||||
unicode: 128525
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 3
|
||||
x: 384
|
||||
y: 384
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f60e
|
||||
hashCode: 57188340
|
||||
unicode: 128526
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 4
|
||||
x: 0
|
||||
y: 256
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: Grinning face
|
||||
hashCode: -95541379
|
||||
unicode: 128512
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 5
|
||||
x: 128
|
||||
y: 256
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f601
|
||||
hashCode: 57188256
|
||||
unicode: 128513
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 6
|
||||
x: 256
|
||||
y: 256
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: Face with tears of joy
|
||||
hashCode: 239522663
|
||||
unicode: 128514
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 7
|
||||
x: 384
|
||||
y: 256
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f603
|
||||
hashCode: 57188258
|
||||
unicode: 128515
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 8
|
||||
x: 0
|
||||
y: 128
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f604
|
||||
hashCode: 57188261
|
||||
unicode: 128516
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 9
|
||||
x: 128
|
||||
y: 128
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f605
|
||||
hashCode: 57188260
|
||||
unicode: 128517
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 10
|
||||
x: 256
|
||||
y: 128
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f606
|
||||
hashCode: 57188263
|
||||
unicode: 128518
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 11
|
||||
x: 384
|
||||
y: 128
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f609
|
||||
hashCode: 57188264
|
||||
unicode: 128521
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 12
|
||||
x: 0
|
||||
y: 0
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f618
|
||||
hashCode: 57188168
|
||||
unicode: 128536
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 13
|
||||
x: 128
|
||||
y: 0
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 1f923
|
||||
hashCode: 57200239
|
||||
unicode: 129315
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 14
|
||||
x: 256
|
||||
y: 0
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 263a
|
||||
hashCode: 1748406
|
||||
unicode: 9786
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
- id: 15
|
||||
x: 384
|
||||
y: 0
|
||||
width: 128
|
||||
height: 128
|
||||
xOffset: 0
|
||||
yOffset: 115.6
|
||||
xAdvance: 128
|
||||
scale: 1
|
||||
name: 2639
|
||||
hashCode: 1748462
|
||||
unicode: 9785
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
sprite: {fileID: 0}
|
||||
fallbackSpriteAssets: []
|
||||
--- !u!21 &1369835458
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: TextMeshPro/Sprite
|
||||
m_Shader: {fileID: 4800000, guid: cf81c85f95fe47e1a27f6ae460cf182c, type: 3}
|
||||
m_ShaderKeywords:
|
||||
m_LightmapFlags: 5
|
||||
m_EnableInstancingVariants: 0
|
||||
m_DoubleSidedGI: 0
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
disabledShaderPasses: []
|
||||
m_SavedProperties:
|
||||
serializedVersion: 3
|
||||
m_TexEnvs: []
|
||||
m_Floats: []
|
||||
m_Colors: []
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c41005c129ba4d66911b75229fd70b45
|
||||
timeCreated: 1480316912
|
||||
licenseType: Pro
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
9
Assets/TextMesh Pro/Resources/Style Sheets.meta
Normal file
9
Assets/TextMesh Pro/Resources/Style Sheets.meta
Normal file
@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4aecb92fff08436c8303b10eab8da368
|
||||
folderAsset: yes
|
||||
timeCreated: 1441876950
|
||||
licenseType: Pro
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -0,0 +1,81 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: ab2114bdc8544297b417dfefe9f1e410, type: 3}
|
||||
m_Name: Default Style Sheet
|
||||
m_EditorClassIdentifier:
|
||||
m_StyleList:
|
||||
- m_Name: Normal
|
||||
m_HashCode: -1183493901
|
||||
m_OpeningDefinition:
|
||||
m_ClosingDefinition:
|
||||
m_OpeningTagArray:
|
||||
m_ClosingTagArray:
|
||||
- m_Name: H1
|
||||
m_HashCode: 2425
|
||||
m_OpeningDefinition: <size=2em><b><#40ff80>*
|
||||
m_ClosingDefinition: '*</size></b></color>'
|
||||
m_OpeningTagArray: 3c00000073000000690000007a000000650000003d00000032000000650000006d0000003e0000003c000000620000003e0000003c000000230000003400000030000000660000006600000038000000300000003e0000002a000000
|
||||
m_ClosingTagArray: 2a0000003c0000002f00000073000000690000007a000000650000003e0000003c0000002f000000620000003e0000003c0000002f000000630000006f0000006c0000006f000000720000003e000000
|
||||
- m_Name: Quote
|
||||
m_HashCode: 93368250
|
||||
m_OpeningDefinition: <i><size=75%><margin=10%>
|
||||
m_ClosingDefinition: </i></size></width></margin>
|
||||
m_OpeningTagArray: 3c000000690000003e0000003c00000073000000690000007a000000650000003d0000003700000035000000250000003e0000003c0000006d000000610000007200000067000000690000006e0000003d0000003100000030000000250000003e000000
|
||||
m_ClosingTagArray: 3c0000002f000000690000003e0000003c0000002f00000073000000690000007a000000650000003e0000003c0000002f00000077000000690000006400000074000000680000003e0000003c0000002f0000006d000000610000007200000067000000690000006e0000003e000000
|
||||
- m_Name: A
|
||||
m_HashCode: 65
|
||||
m_OpeningDefinition: <color=#40a0ff><u>
|
||||
m_ClosingDefinition: </u></color>
|
||||
m_OpeningTagArray: 3c000000630000006f0000006c0000006f000000720000003d000000230000003400000030000000610000003000000066000000660000003e0000003c000000750000003e000000
|
||||
m_ClosingTagArray: 3c0000002f000000750000003e0000003c0000002f000000630000006f0000006c0000006f000000720000003e000000
|
||||
- m_Name: Link
|
||||
m_HashCode: 2656128
|
||||
m_OpeningDefinition: <u><#40a0ff><link="ID_01">
|
||||
m_ClosingDefinition: </u></color></link>
|
||||
m_OpeningTagArray: 3c000000750000003e0000003c000000230000003400000030000000610000003000000066000000660000003e0000003c0000006c000000690000006e0000006b0000003d0000002200000049000000440000005f0000003000000031000000220000003e000000
|
||||
m_ClosingTagArray: 3c0000002f000000750000003e0000003c0000002f000000630000006f0000006c0000006f000000720000003e0000003c0000002f0000006c000000690000006e0000006b0000003e000000
|
||||
- m_Name: Title
|
||||
m_HashCode: 97690656
|
||||
m_OpeningDefinition: <size=125%><b><align=center>
|
||||
m_ClosingDefinition: </size></b></align>
|
||||
m_OpeningTagArray: 3c00000073000000690000007a000000650000003d000000310000003200000035000000250000003e0000003c000000620000003e0000003c000000610000006c00000069000000670000006e0000003d00000063000000650000006e0000007400000065000000720000003e000000
|
||||
m_ClosingTagArray: 3c0000002f00000073000000690000007a000000650000003e0000003c0000002f000000620000003e0000003c0000002f000000610000006c00000069000000670000006e0000003e000000
|
||||
- m_Name: H2
|
||||
m_HashCode: 2426
|
||||
m_OpeningDefinition: <size=1.5em><b><#4080FF>
|
||||
m_ClosingDefinition: </size></b></color>
|
||||
m_OpeningTagArray: 3c00000073000000690000007a000000650000003d000000310000002e00000035000000650000006d0000003e0000003c000000620000003e0000003c000000230000003400000030000000380000003000000046000000460000003e000000
|
||||
m_ClosingTagArray: 3c0000002f00000073000000690000007a000000650000003e0000003c0000002f000000620000003e0000003c0000002f000000630000006f0000006c0000006f000000720000003e000000
|
||||
- m_Name: H3
|
||||
m_HashCode: 2427
|
||||
m_OpeningDefinition: <size=1.17em><b><#FF8040>
|
||||
m_ClosingDefinition: </size></b></color>
|
||||
m_OpeningTagArray: 3c00000073000000690000007a000000650000003d000000310000002e0000003100000037000000650000006d0000003e0000003c000000620000003e0000003c000000230000004600000046000000380000003000000034000000300000003e000000
|
||||
m_ClosingTagArray: 3c0000002f00000073000000690000007a000000650000003e0000003c0000002f000000620000003e0000003c0000002f000000630000006f0000006c0000006f000000720000003e000000
|
||||
- m_Name: C1
|
||||
m_HashCode: 2194
|
||||
m_OpeningDefinition: <color=#ffff40>
|
||||
m_ClosingDefinition: </color>
|
||||
m_OpeningTagArray: 3c000000630000006f0000006c0000006f000000720000003d000000230000006600000066000000660000006600000034000000300000003e000000
|
||||
m_ClosingTagArray: 3c0000002f000000630000006f0000006c0000006f000000720000003e000000
|
||||
- m_Name: C2
|
||||
m_HashCode: 2193
|
||||
m_OpeningDefinition: <color=#ff40FF><size=125%>
|
||||
m_ClosingDefinition: </color></size>
|
||||
m_OpeningTagArray: 3c000000630000006f0000006c0000006f000000720000003d000000230000006600000066000000340000003000000046000000460000003e0000003c00000073000000690000007a000000650000003d000000310000003200000035000000250000003e000000
|
||||
m_ClosingTagArray: 3c0000002f000000630000006f0000006c0000006f000000720000003e0000003c0000002f00000073000000690000007a000000650000003e000000
|
||||
- m_Name: C3
|
||||
m_HashCode: 2192
|
||||
m_OpeningDefinition: <color=#80A0FF><b>
|
||||
m_ClosingDefinition: </color></b>
|
||||
m_OpeningTagArray: 3c000000630000006f0000006c0000006f000000720000003d000000230000003800000030000000410000003000000046000000460000003e0000003c000000620000003e000000
|
||||
m_ClosingTagArray: 3c0000002f000000630000006f0000006c0000006f000000720000003e0000003c0000002f000000620000003e000000
|
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f952c082cb03451daed3ee968ac6c63e
|
||||
timeCreated: 1432805430
|
||||
licenseType: Store
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
52
Assets/TextMesh Pro/Resources/TMP Settings.asset
Normal file
52
Assets/TextMesh Pro/Resources/TMP Settings.asset
Normal file
@ -0,0 +1,52 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 2705215ac5b84b70bacc50632be6e391, type: 3}
|
||||
m_Name: TMP Settings
|
||||
m_EditorClassIdentifier:
|
||||
assetVersion: 2
|
||||
m_TextWrappingMode: 1
|
||||
m_enableKerning: 1
|
||||
m_ActiveFontFeatures: 00000000
|
||||
m_enableExtraPadding: 0
|
||||
m_enableTintAllSprites: 0
|
||||
m_enableParseEscapeCharacters: 1
|
||||
m_EnableRaycastTarget: 1
|
||||
m_GetFontFeaturesAtRuntime: 1
|
||||
m_missingGlyphCharacter: 0
|
||||
m_ClearDynamicDataOnBuild: 1
|
||||
m_warningsDisabled: 0
|
||||
m_defaultFontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_defaultFontAssetPath: Fonts & Materials/
|
||||
m_defaultFontSize: 36
|
||||
m_defaultAutoSizeMinRatio: 0.5
|
||||
m_defaultAutoSizeMaxRatio: 2
|
||||
m_defaultTextMeshProTextContainerSize: {x: 20, y: 5}
|
||||
m_defaultTextMeshProUITextContainerSize: {x: 200, y: 50}
|
||||
m_autoSizeTextContainer: 0
|
||||
m_IsTextObjectScaleStatic: 0
|
||||
m_fallbackFontAssets: []
|
||||
m_matchMaterialPreset: 1
|
||||
m_HideSubTextObjects: 0
|
||||
m_defaultSpriteAsset: {fileID: 11400000, guid: c41005c129ba4d66911b75229fd70b45,
|
||||
type: 2}
|
||||
m_defaultSpriteAssetPath: Sprite Assets/
|
||||
m_enableEmojiSupport: 1
|
||||
m_MissingCharacterSpriteUnicode: 0
|
||||
m_EmojiFallbackTextAssets: []
|
||||
m_defaultColorGradientPresetsPath: Color Gradient Presets/
|
||||
m_defaultStyleSheet: {fileID: 11400000, guid: f952c082cb03451daed3ee968ac6c63e,
|
||||
type: 2}
|
||||
m_StyleSheetsResourcePath:
|
||||
m_leadingCharacters: {fileID: 4900000, guid: d82c1b31c7e74239bff1220585707d2b, type: 3}
|
||||
m_followingCharacters: {fileID: 4900000, guid: fade42e8bc714b018fac513c043d323b,
|
||||
type: 3}
|
||||
m_UseModernHangulLineBreakingRules: 0
|
8
Assets/TextMesh Pro/Resources/TMP Settings.asset.meta
Normal file
8
Assets/TextMesh Pro/Resources/TMP Settings.asset.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3f5b5dff67a942289a9defa416b206f3
|
||||
timeCreated: 1436653997
|
||||
licenseType: Pro
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/TextMesh Pro/Shaders.meta
Normal file
8
Assets/TextMesh Pro/Shaders.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e9f693669af91aa45ad615fc681ed29f
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
178
Assets/TextMesh Pro/Shaders/SDFFunctions.hlsl
Normal file
178
Assets/TextMesh Pro/Shaders/SDFFunctions.hlsl
Normal file
@ -0,0 +1,178 @@
|
||||
float2 UnpackUV(float uv)
|
||||
{
|
||||
float2 output;
|
||||
output.x = floor(uv / 4096.0);
|
||||
output.y = uv - 4096.0 * output.x;
|
||||
|
||||
return output * 0.001953125;
|
||||
}
|
||||
|
||||
float4 BlendARGB(float4 overlying, float4 underlying)
|
||||
{
|
||||
overlying.rgb *= overlying.a;
|
||||
underlying.rgb *= underlying.a;
|
||||
float3 blended = overlying.rgb + ((1 - overlying.a) * underlying.rgb);
|
||||
float alpha = underlying.a + (1 - underlying.a) * overlying.a;
|
||||
return float4(blended / alpha, alpha);
|
||||
}
|
||||
|
||||
float3 GetSpecular(float3 n, float3 l)
|
||||
{
|
||||
float spec = pow(max(0.0, dot(n, l)), _Reflectivity);
|
||||
return _SpecularColor.rgb * spec * _SpecularPower;
|
||||
}
|
||||
|
||||
void GetSurfaceNormal_float(texture2D atlas, float textureWidth, float textureHeight, float2 uv, bool isFront, out float3 nornmal)
|
||||
{
|
||||
float3 delta = float3(1.0 / textureWidth, 1.0 / textureHeight, 0.0);
|
||||
|
||||
// Read "height field"
|
||||
float4 h = float4(
|
||||
SAMPLE_TEXTURE2D(atlas, SamplerState_Linear_Clamp, uv - delta.xz).a,
|
||||
SAMPLE_TEXTURE2D(atlas, SamplerState_Linear_Clamp, uv + delta.xz).a,
|
||||
SAMPLE_TEXTURE2D(atlas, SamplerState_Linear_Clamp, uv - delta.zy).a,
|
||||
SAMPLE_TEXTURE2D(atlas, SamplerState_Linear_Clamp, uv + delta.zy).a);
|
||||
|
||||
bool raisedBevel = _BevelType;
|
||||
|
||||
h += _BevelOffset;
|
||||
|
||||
float bevelWidth = max(.01, _BevelWidth);
|
||||
|
||||
// Track outline
|
||||
h -= .5;
|
||||
h /= bevelWidth;
|
||||
h = saturate(h + .5);
|
||||
|
||||
if (raisedBevel) h = 1 - abs(h * 2.0 - 1.0);
|
||||
h = lerp(h, sin(h * 3.141592 / 2.0), float4(_BevelRoundness, _BevelRoundness, _BevelRoundness, _BevelRoundness));
|
||||
h = min(h, 1.0 - float4(_BevelClamp, _BevelClamp, _BevelClamp, _BevelClamp));
|
||||
h *= _BevelAmount * bevelWidth * _GradientScale * -2.0;
|
||||
|
||||
float3 va = normalize(float3(-1.0, 0.0, h.y - h.x));
|
||||
float3 vb = normalize(float3(0.0, 1.0, h.w - h.z));
|
||||
|
||||
float3 f = float3(1, 1, 1);
|
||||
if (isFront) f = float3(1, 1, -1);
|
||||
nornmal = cross(va, vb) * f;
|
||||
}
|
||||
|
||||
void EvaluateLight_float(float4 faceColor, float3 n, out float4 color)
|
||||
{
|
||||
n.z = abs(n.z);
|
||||
float3 light = normalize(float3(sin(_LightAngle), cos(_LightAngle), 1.0));
|
||||
|
||||
float3 col = max(faceColor.rgb, 0) + GetSpecular(n, light)* faceColor.a;
|
||||
//faceColor.rgb += col * faceColor.a;
|
||||
col *= 1 - (dot(n, light) * _Diffuse);
|
||||
col *= lerp(_Ambient, 1, n.z * n.z);
|
||||
|
||||
//fixed4 reflcol = texCUBE(_Cube, reflect(input.viewDir, -n));
|
||||
//faceColor.rgb += reflcol.rgb * lerp(_ReflectFaceColor.rgb, _ReflectOutlineColor.rgb, saturate(sd + outline * 0.5)) * faceColor.a;
|
||||
|
||||
color = float4(col, faceColor.a);
|
||||
}
|
||||
|
||||
// Add custom function to handle time in HDRP
|
||||
|
||||
|
||||
//
|
||||
void GenerateUV_float(float2 inUV, float4 transform, float2 animSpeed, out float2 outUV)
|
||||
{
|
||||
outUV = inUV * transform.xy + transform.zw + (animSpeed * _Time.y);
|
||||
}
|
||||
|
||||
void ComputeUVOffset_float(float texWidth, float texHeight, float2 offset, float SDR, out float2 uvOffset)
|
||||
{
|
||||
uvOffset = float2(-offset.x * SDR / texWidth, -offset.y * SDR / texHeight);
|
||||
}
|
||||
|
||||
void ScreenSpaceRatio2_float(float4x4 projection, float4 position, float2 objectScale, float screenWidth, float screenHeight, float fontScale, out float SSR)
|
||||
{
|
||||
float2 pixelSize = position.w;
|
||||
pixelSize /= (objectScale * mul((float2x2)projection, float2(screenWidth, screenHeight)));
|
||||
SSR = rsqrt(dot(pixelSize, pixelSize)*2) * fontScale;
|
||||
}
|
||||
|
||||
// UV : Texture coordinate of the source distance field texture
|
||||
// TextureSize : Size of the source distance field texture
|
||||
// Filter : Enable perspective filter (soften)
|
||||
void ScreenSpaceRatio_float(float2 UV, float TextureSize, bool Filter, out float SSR)
|
||||
{
|
||||
if(Filter)
|
||||
{
|
||||
float2 a = float2(ddx(UV.x), ddy(UV.x));
|
||||
float2 b = float2(ddx(UV.y), ddy(UV.y));
|
||||
float s = lerp(dot(a,a), dot(b,b), 0.5);
|
||||
SSR = rsqrt(s) / TextureSize;
|
||||
}
|
||||
else
|
||||
{
|
||||
float s = rsqrt(abs(ddx(UV.x) * ddy(UV.y) - ddy(UV.x) * ddx(UV.y)));
|
||||
SSR = s / TextureSize;
|
||||
}
|
||||
}
|
||||
|
||||
// SSR : Screen Space Ratio
|
||||
// SD : Signed Distance (encoded : Distance / SDR + .5)
|
||||
// SDR : Signed Distance Ratio
|
||||
//
|
||||
// IsoPerimeter : Dilate / Contract the shape
|
||||
void ComputeSDF_float(float SSR, float SD, float SDR, float isoPerimeter, float softness, out float outAlpha)
|
||||
{
|
||||
softness *= SSR * SDR;
|
||||
float d = (SD - 0.5) * SDR; // Signed distance to edge, in Texture space
|
||||
outAlpha = saturate((d * 2.0 * SSR + 0.5 + isoPerimeter * SDR * SSR + softness * 0.5) / (1.0 + softness)); // Screen pixel coverage (alpha)
|
||||
}
|
||||
|
||||
void ComputeSDF2_float(float SSR, float SD, float SDR, float2 isoPerimeter, float2 softness, out float2 outAlpha)
|
||||
{
|
||||
softness *= SSR * SDR;
|
||||
float d = (SD - 0.5f) * SDR;
|
||||
outAlpha = saturate((d * 2.0f * SSR + 0.5f + isoPerimeter * SDR * SSR + softness * 0.5) / (1.0 + softness));
|
||||
}
|
||||
|
||||
void ComputeSDF4_float(float SSR, float SD, float SDR, float4 isoPerimeter, float4 softness, out float4 outAlpha)
|
||||
{
|
||||
softness *= SSR * SDR;
|
||||
float d = (SD - 0.5f) * SDR;
|
||||
outAlpha = saturate((d * 2.0f * SSR + 0.5f + isoPerimeter * SDR * SSR + softness * 0.5) / (1.0 + softness));
|
||||
}
|
||||
|
||||
void ComputeSDF44_float(float SSR, float4 SD, float SDR, float4 isoPerimeter, float4 softness, bool outline, out float4 outAlpha)
|
||||
{
|
||||
softness *= SSR * SDR;
|
||||
float4 d = (SD - 0.5f) * SDR;
|
||||
if(outline) d.w = max(max(d.x, d.y), d.z);
|
||||
outAlpha = saturate((d * 2.0f * SSR + 0.5f + isoPerimeter * SDR * SSR + softness * 0.5) / (1.0 + softness));
|
||||
}
|
||||
|
||||
void Composite_float(float4 overlying, float4 underlying, out float4 outColor)
|
||||
{
|
||||
outColor = BlendARGB(overlying, underlying);
|
||||
}
|
||||
|
||||
// Face only
|
||||
void Layer1_float(float alpha, float4 color0, out float4 outColor)
|
||||
{
|
||||
color0.a *= alpha;
|
||||
outColor = color0;
|
||||
}
|
||||
|
||||
// Face + 1 Outline
|
||||
void Layer2_float(float2 alpha, float4 color0, float4 color1, out float4 outColor)
|
||||
{
|
||||
color1.a *= alpha.y;
|
||||
color0.rgb *= color0.a; color1.rgb *= color1.a;
|
||||
outColor = lerp(color1, color0, alpha.x);
|
||||
outColor.rgb /= outColor.a;
|
||||
}
|
||||
|
||||
// Face + 3 Outline
|
||||
void Layer4_float(float4 alpha, float4 color0, float4 color1, float4 color2, float4 color3, out float4 outColor)
|
||||
{
|
||||
color3.a *= alpha.w;
|
||||
color0.rgb *= color0.a; color1.rgb *= color1.a; color2.rgb *= color2.a; color3.rgb *= color3.a;
|
||||
outColor = lerp(lerp(lerp(color3, color2, alpha.z), color1, alpha.y), color0, alpha.x);
|
||||
outColor.rgb /= outColor.a;
|
||||
}
|
10
Assets/TextMesh Pro/Shaders/SDFFunctions.hlsl.meta
Normal file
10
Assets/TextMesh Pro/Shaders/SDFFunctions.hlsl.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 96de908384869cd409c75efa351d5edf
|
||||
ShaderImporter:
|
||||
externalObjects: {}
|
||||
defaultTextures: []
|
||||
nonModifiableTextures: []
|
||||
preprocessorOverride: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
145
Assets/TextMesh Pro/Shaders/TMP_Bitmap-Custom-Atlas.shader
Normal file
145
Assets/TextMesh Pro/Shaders/TMP_Bitmap-Custom-Atlas.shader
Normal file
@ -0,0 +1,145 @@
|
||||
Shader "TextMeshPro/Bitmap Custom Atlas" {
|
||||
|
||||
Properties {
|
||||
_MainTex ("Font Atlas", 2D) = "white" {}
|
||||
_FaceTex ("Font Texture", 2D) = "white" {}
|
||||
_FaceColor ("Text Color", Color) = (1,1,1,1)
|
||||
|
||||
_VertexOffsetX ("Vertex OffsetX", float) = 0
|
||||
_VertexOffsetY ("Vertex OffsetY", float) = 0
|
||||
_MaskSoftnessX ("Mask SoftnessX", float) = 0
|
||||
_MaskSoftnessY ("Mask SoftnessY", float) = 0
|
||||
|
||||
_ClipRect ("Clip Rect", vector) = (-32767, -32767, 32767, 32767)
|
||||
_Padding ("Padding", float) = 0
|
||||
|
||||
_StencilComp ("Stencil Comparison", Float) = 8
|
||||
_Stencil ("Stencil ID", Float) = 0
|
||||
_StencilOp ("Stencil Operation", Float) = 0
|
||||
_StencilWriteMask ("Stencil Write Mask", Float) = 255
|
||||
_StencilReadMask ("Stencil Read Mask", Float) = 255
|
||||
|
||||
_CullMode ("Cull Mode", Float) = 0
|
||||
_ColorMask ("Color Mask", Float) = 15
|
||||
}
|
||||
|
||||
SubShader{
|
||||
|
||||
Tags { "Queue" = "Transparent" "IgnoreProjector" = "True" "RenderType" = "Transparent" }
|
||||
|
||||
Stencil
|
||||
{
|
||||
Ref[_Stencil]
|
||||
Comp[_StencilComp]
|
||||
Pass[_StencilOp]
|
||||
ReadMask[_StencilReadMask]
|
||||
WriteMask[_StencilWriteMask]
|
||||
}
|
||||
|
||||
|
||||
Lighting Off
|
||||
Cull [_CullMode]
|
||||
ZTest [unity_GUIZTestMode]
|
||||
ZWrite Off
|
||||
Fog { Mode Off }
|
||||
Blend SrcAlpha OneMinusSrcAlpha
|
||||
ColorMask[_ColorMask]
|
||||
|
||||
Pass {
|
||||
CGPROGRAM
|
||||
#pragma vertex vert
|
||||
#pragma fragment frag
|
||||
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
#include "UnityUI.cginc"
|
||||
|
||||
struct appdata_t
|
||||
{
|
||||
float4 vertex : POSITION;
|
||||
fixed4 color : COLOR;
|
||||
float4 texcoord0 : TEXCOORD0;
|
||||
float2 texcoord1 : TEXCOORD1;
|
||||
};
|
||||
|
||||
struct v2f
|
||||
{
|
||||
float4 vertex : SV_POSITION;
|
||||
fixed4 color : COLOR;
|
||||
float2 texcoord0 : TEXCOORD0;
|
||||
float2 texcoord1 : TEXCOORD1;
|
||||
float4 mask : TEXCOORD2;
|
||||
};
|
||||
|
||||
uniform sampler2D _MainTex;
|
||||
uniform sampler2D _FaceTex;
|
||||
uniform float4 _FaceTex_ST;
|
||||
uniform fixed4 _FaceColor;
|
||||
|
||||
uniform float _VertexOffsetX;
|
||||
uniform float _VertexOffsetY;
|
||||
uniform float4 _ClipRect;
|
||||
uniform float _MaskSoftnessX;
|
||||
uniform float _MaskSoftnessY;
|
||||
uniform float _UIMaskSoftnessX;
|
||||
uniform float _UIMaskSoftnessY;
|
||||
uniform int _UIVertexColorAlwaysGammaSpace;
|
||||
|
||||
v2f vert (appdata_t v)
|
||||
{
|
||||
float4 vert = v.vertex;
|
||||
vert.x += _VertexOffsetX;
|
||||
vert.y += _VertexOffsetY;
|
||||
|
||||
vert.xy += (vert.w * 0.5) / _ScreenParams.xy;
|
||||
|
||||
float4 vPosition = UnityPixelSnap(UnityObjectToClipPos(vert));
|
||||
|
||||
if (_UIVertexColorAlwaysGammaSpace && !IsGammaSpace())
|
||||
{
|
||||
v.color.rgb = UIGammaToLinear(v.color.rgb);
|
||||
}
|
||||
fixed4 faceColor = v.color;
|
||||
faceColor *= _FaceColor;
|
||||
|
||||
v2f OUT;
|
||||
OUT.vertex = vPosition;
|
||||
OUT.color = faceColor;
|
||||
OUT.texcoord0 = v.texcoord0;
|
||||
OUT.texcoord1 = TRANSFORM_TEX(v.texcoord1, _FaceTex);
|
||||
float2 pixelSize = vPosition.w;
|
||||
pixelSize /= abs(float2(_ScreenParams.x * UNITY_MATRIX_P[0][0], _ScreenParams.y * UNITY_MATRIX_P[1][1]));
|
||||
|
||||
// Clamp _ClipRect to 16bit.
|
||||
const float4 clampedRect = clamp(_ClipRect, -2e10, 2e10);
|
||||
const half2 maskSoftness = half2(max(_UIMaskSoftnessX, _MaskSoftnessX), max(_UIMaskSoftnessY, _MaskSoftnessY));
|
||||
OUT.mask = float4(vert.xy * 2 - clampedRect.xy - clampedRect.zw, 0.25 / (0.25 * maskSoftness + pixelSize.xy));
|
||||
|
||||
return OUT;
|
||||
}
|
||||
|
||||
fixed4 frag (v2f IN) : SV_Target
|
||||
{
|
||||
fixed4 color = tex2D(_MainTex, IN.texcoord0) * tex2D(_FaceTex, IN.texcoord1) * IN.color;
|
||||
|
||||
// Alternative implementation to UnityGet2DClipping with support for softness.
|
||||
#if UNITY_UI_CLIP_RECT
|
||||
half2 m = saturate((_ClipRect.zw - _ClipRect.xy - abs(IN.mask.xy)) * IN.mask.zw);
|
||||
color *= m.x * m.y;
|
||||
#endif
|
||||
|
||||
#if UNITY_UI_ALPHACLIP
|
||||
clip(color.a - 0.001);
|
||||
#endif
|
||||
|
||||
return color;
|
||||
}
|
||||
ENDCG
|
||||
}
|
||||
}
|
||||
|
||||
CustomEditor "TMPro.EditorUtilities.TMP_BitmapShaderGUI"
|
||||
}
|
@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 48bb5f55d8670e349b6e614913f9d910
|
||||
ShaderImporter:
|
||||
externalObjects: {}
|
||||
defaultTextures: []
|
||||
nonModifiableTextures: []
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user