You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
1.0 KiB
35 lines
1.0 KiB
using System.Collections; |
|
using System.Collections.Generic; |
|
using UnityEngine; |
|
using UnityEditor; |
|
|
|
[CustomEditor(typeof(DataLanguageUI))] |
|
public class DataLanguageUIEditor : Editor |
|
{ |
|
public TypeLanguage typeLanguage = TypeLanguage.KOR; |
|
public override void OnInspectorGUI() |
|
{ |
|
DrawDefaultInspector(); |
|
|
|
DataLanguageUI script = target as DataLanguageUI; |
|
|
|
typeLanguage = (TypeLanguage)EditorGUILayout.EnumPopup("언어선택 : ", typeLanguage); |
|
if (GUILayout.Button($"Language Table Reload")) |
|
{ |
|
DataManager.Instance.dataLanguage.typeLanguage = typeLanguage; |
|
DataManager.Instance.dataLanguage.TableLoad(); |
|
} |
|
|
|
if (GUILayout.Button($"Language Setting")) |
|
{ |
|
if (script.type != string.Empty && script.idx != string.Empty) |
|
script.Setting(); |
|
} |
|
} |
|
|
|
void Setting(DataLanguageUI textLanguage) |
|
{ |
|
if (textLanguage.type != string.Empty && textLanguage.idx != string.Empty) |
|
textLanguage.Setting(); |
|
} |
|
}
|
|
|