lvjincheng 3 years ago
parent
commit
36b463725b

+ 77 - 3
Assets/BowArrow/Resources/Prefabs/Views/ChallengeOptionView.prefab

@@ -145,6 +145,7 @@ GameObject:
   - component: {fileID: 8137645198829436190}
   - component: {fileID: 8137645198829436190}
   - component: {fileID: 2074049217324940862}
   - component: {fileID: 2074049217324940862}
   - component: {fileID: 4104590795617810777}
   - component: {fileID: 4104590795617810777}
+  - component: {fileID: 8334057067575870466}
   m_Layer: 0
   m_Layer: 0
   m_Name: Name
   m_Name: Name
   m_TagString: Untagged
   m_TagString: Untagged
@@ -209,7 +210,7 @@ MonoBehaviour:
     m_Alignment: 4
     m_Alignment: 4
     m_AlignByGeometry: 0
     m_AlignByGeometry: 0
     m_RichText: 1
     m_RichText: 1
-    m_HorizontalOverflow: 0
+    m_HorizontalOverflow: 1
     m_VerticalOverflow: 0
     m_VerticalOverflow: 0
     m_LineSpacing: 1
     m_LineSpacing: 1
   m_Text: "\u91CE\u5154\u5173\u5361"
   m_Text: "\u91CE\u5154\u5173\u5361"
@@ -228,6 +229,24 @@ MonoBehaviour:
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectDistance: {x: 1, y: -1}
   m_EffectDistance: {x: 1, y: -1}
   m_UseGraphicAlpha: 1
   m_UseGraphicAlpha: 1
+--- !u!114 &8334057067575870466
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 2090181052093417642}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: b7cbfcb0916cf694fb3d059ea4b4c1da, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  textID: 135
+  layoutRebuildObject: {fileID: 0}
+  textFormatArgs: []
+  languageFontSizes:
+  - language: 1
+    fontSize: 30
 --- !u!1 &3036196993393545847
 --- !u!1 &3036196993393545847
 GameObject:
 GameObject:
   m_ObjectHideFlags: 0
   m_ObjectHideFlags: 0
@@ -240,6 +259,7 @@ GameObject:
   - component: {fileID: 3127471641122945682}
   - component: {fileID: 3127471641122945682}
   - component: {fileID: 6562723318422101771}
   - component: {fileID: 6562723318422101771}
   - component: {fileID: 5358085935297291318}
   - component: {fileID: 5358085935297291318}
+  - component: {fileID: 7033976470557098490}
   m_Layer: 0
   m_Layer: 0
   m_Name: Name
   m_Name: Name
   m_TagString: Untagged
   m_TagString: Untagged
@@ -304,7 +324,7 @@ MonoBehaviour:
     m_Alignment: 4
     m_Alignment: 4
     m_AlignByGeometry: 0
     m_AlignByGeometry: 0
     m_RichText: 1
     m_RichText: 1
-    m_HorizontalOverflow: 0
+    m_HorizontalOverflow: 1
     m_VerticalOverflow: 0
     m_VerticalOverflow: 0
     m_LineSpacing: 1
     m_LineSpacing: 1
   m_Text: "\u91CE\u9E21\u5173\u5361"
   m_Text: "\u91CE\u9E21\u5173\u5361"
@@ -323,6 +343,24 @@ MonoBehaviour:
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectDistance: {x: 1, y: -1}
   m_EffectDistance: {x: 1, y: -1}
   m_UseGraphicAlpha: 1
   m_UseGraphicAlpha: 1
+--- !u!114 &7033976470557098490
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 3036196993393545847}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: b7cbfcb0916cf694fb3d059ea4b4c1da, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  textID: 136
+  layoutRebuildObject: {fileID: 0}
+  textFormatArgs: []
+  languageFontSizes:
+  - language: 1
+    fontSize: 30
 --- !u!1 &3579497287012709974
 --- !u!1 &3579497287012709974
 GameObject:
 GameObject:
   m_ObjectHideFlags: 0
   m_ObjectHideFlags: 0
@@ -808,6 +846,7 @@ GameObject:
   - component: {fileID: 4507770290359092604}
   - component: {fileID: 4507770290359092604}
   - component: {fileID: 4507770290359092605}
   - component: {fileID: 4507770290359092605}
   - component: {fileID: 4507770290359092602}
   - component: {fileID: 4507770290359092602}
+  - component: {fileID: 7609508172001134087}
   m_Layer: 0
   m_Layer: 0
   m_Name: Text
   m_Name: Text
   m_TagString: Untagged
   m_TagString: Untagged
@@ -891,6 +930,22 @@ MonoBehaviour:
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectDistance: {x: 1, y: -1}
   m_EffectDistance: {x: 1, y: -1}
   m_UseGraphicAlpha: 1
   m_UseGraphicAlpha: 1
+--- !u!114 &7609508172001134087
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 4507770290359092600}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: b7cbfcb0916cf694fb3d059ea4b4c1da, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  textID: 134
+  layoutRebuildObject: {fileID: 0}
+  textFormatArgs: []
+  languageFontSizes: []
 --- !u!1 &4507770291076110919
 --- !u!1 &4507770291076110919
 GameObject:
 GameObject:
   m_ObjectHideFlags: 0
   m_ObjectHideFlags: 0
@@ -1376,6 +1431,7 @@ GameObject:
   - component: {fileID: 4765462912308898158}
   - component: {fileID: 4765462912308898158}
   - component: {fileID: 4965531987415886667}
   - component: {fileID: 4965531987415886667}
   - component: {fileID: 7362187666306467871}
   - component: {fileID: 7362187666306467871}
+  - component: {fileID: 2430240629095068504}
   m_Layer: 0
   m_Layer: 0
   m_Name: Name
   m_Name: Name
   m_TagString: Untagged
   m_TagString: Untagged
@@ -1440,7 +1496,7 @@ MonoBehaviour:
     m_Alignment: 4
     m_Alignment: 4
     m_AlignByGeometry: 0
     m_AlignByGeometry: 0
     m_RichText: 1
     m_RichText: 1
-    m_HorizontalOverflow: 0
+    m_HorizontalOverflow: 1
     m_VerticalOverflow: 0
     m_VerticalOverflow: 0
     m_LineSpacing: 1
     m_LineSpacing: 1
   m_Text: "\u91CE\u72FC\u5173\u5361"
   m_Text: "\u91CE\u72FC\u5173\u5361"
@@ -1459,3 +1515,21 @@ MonoBehaviour:
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectColor: {r: 0.3339622, g: 0.5847058, b: 1, a: 0.5}
   m_EffectDistance: {x: 1, y: -1}
   m_EffectDistance: {x: 1, y: -1}
   m_UseGraphicAlpha: 1
   m_UseGraphicAlpha: 1
+--- !u!114 &2430240629095068504
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 8913206415654739051}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: b7cbfcb0916cf694fb3d059ea4b4c1da, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  textID: 137
+  layoutRebuildObject: {fileID: 0}
+  textFormatArgs: []
+  languageFontSizes:
+  - language: 1
+    fontSize: 30

+ 2 - 2
Assets/BowArrow/Resources/Prefabs/Views/MeView.prefab

@@ -699,12 +699,12 @@ MonoBehaviour:
   m_PrefabInstance: {fileID: 0}
   m_PrefabInstance: {fileID: 0}
   m_PrefabAsset: {fileID: 0}
   m_PrefabAsset: {fileID: 0}
   m_GameObject: {fileID: 2337784068815447064}
   m_GameObject: {fileID: 2337784068815447064}
-  m_Enabled: 0
+  m_Enabled: 1
   m_EditorHideFlags: 0
   m_EditorHideFlags: 0
   m_Script: {fileID: 11500000, guid: b7cbfcb0916cf694fb3d059ea4b4c1da, type: 3}
   m_Script: {fileID: 11500000, guid: b7cbfcb0916cf694fb3d059ea4b4c1da, type: 3}
   m_Name: 
   m_Name: 
   m_EditorClassIdentifier: 
   m_EditorClassIdentifier: 
-  textID: 1
+  textID: 126
   layoutRebuildObject: {fileID: 0}
   layoutRebuildObject: {fileID: 0}
   textFormatArgs: []
   textFormatArgs: []
   languageFontSizes: []
   languageFontSizes: []

File diff suppressed because it is too large
+ 739 - 12
Assets/BowArrow/Scenes/Home.unity


+ 47 - 6
Assets/BowArrow/Scripts/Components/TextAutoLanguage.cs

@@ -14,8 +14,11 @@ public class TextAutoLanguage : MonoBehaviour
     public string[] textFormatArgs = {};
     public string[] textFormatArgs = {};
     [SerializeField] LanguageFontSize[] languageFontSizes = {};
     [SerializeField] LanguageFontSize[] languageFontSizes = {};
 
 
+    private static bool inited = false;
     public static void Init()
     public static void Init()
     {
     {
+        if (inited) return;
+        inited = true;
         int id = PlayerPrefs.GetInt("Language", 0);
         int id = PlayerPrefs.GetInt("Language", 0);
         ChangeLanguage((LanguageEnum) id);
         ChangeLanguage((LanguageEnum) id);
     }
     }
@@ -23,10 +26,10 @@ public class TextAutoLanguage : MonoBehaviour
     public static void ChangeLanguage(LanguageEnum languageEnum) 
     public static void ChangeLanguage(LanguageEnum languageEnum) 
     {
     {
         currentLanguageEnum = languageEnum;
         currentLanguageEnum = languageEnum;
-        if (languageEnum == LanguageEnum.Chinese) {
-            language = new LanguageDefault();
-        } else if (languageEnum == LanguageEnum.English) {
+        if (languageEnum == LanguageEnum.English) {
             language = new LanguageEnglish();
             language = new LanguageEnglish();
+        } else {
+            language = new LanguageDefault();
         }
         }
         PlayerPrefs.SetInt("Language", ((int)languageEnum));
         PlayerPrefs.SetInt("Language", ((int)languageEnum));
         foreach (var textAutoLanguage in textAutoLanguages)
         foreach (var textAutoLanguage in textAutoLanguages)
@@ -47,7 +50,7 @@ public class TextAutoLanguage : MonoBehaviour
 
 
     void Awake()
     void Awake()
     {
     {
-        if (language == null) ChangeLanguage(currentLanguageEnum);
+        Init();
     }
     }
 
 
     void Start()
     void Start()
@@ -218,7 +221,26 @@ class LanguageDefault {
     public string text503 = "16G加速计";
     public string text503 = "16G加速计";
     public string text504 = "64G加速计";
     public string text504 = "64G加速计";
     //主页面
     //主页面
-    
+    public string text122 = "排行榜";
+    public string text123 = "好友";
+    public string text124 = "开始游戏";
+    public string text125 = "联机游戏";
+    //我的
+    public string text126 = "编 号 :";
+    //开始游戏
+    public string text133 = "开始游戏";
+    public string text127 = "闯关游戏";
+    public string text128 = "限时游戏";
+    public string text129 = "PK游戏";
+    //PK模式选择页面
+    public string text132 = "PK模式";
+    public string text130 = "静止靶PK";
+    public string text131 = "闯关PK";
+    //关卡选择
+    public string text134 = "关卡选择";
+    public string text135 = "野兔关卡";
+    public string text136 = "野鸡关卡";
+    public string text137 = "野狼关卡";
     //设置页面
     //设置页面
     public string text302 = "背景音乐";
     public string text302 = "背景音乐";
     public string text303 = "音效";
     public string text303 = "音效";
@@ -399,7 +421,26 @@ class LanguageEnglish : LanguageDefault {
     public new string text503 = "16G Acc";
     public new string text503 = "16G Acc";
     public new string text504 = "64G Acc";
     public new string text504 = "64G Acc";
     //主页面
     //主页面
-
+    public new string text122 = "Rank";
+    public new string text123 = "Friend";
+    public new string text124 = "Start";
+    public new string text125 = "Online";
+    //我的
+    public new string text126 = "ID :";
+    //开始游戏
+    public new string text133 = "Game Start";
+    public new string text127 = "Challenge Game";
+    public new string text128 = "TimeLimit Game";
+    public new string text129 = "PK Game";
+    //PK模式选择页面
+    public new string text132 = "PK Mode";
+    public new string text130 = "FixedTarget PK";
+    public new string text131 = "Challenge PK";
+    //关卡选择
+    public new string text134 = "Level Select";
+    public new string text135 = "Rabbit Level";
+    public new string text136 = "Pheasant Level";
+    public new string text137 = "Wolf Level";
     //设置页面
     //设置页面
     public new string text302 = "BGM";
     public new string text302 = "BGM";
     public new string text303 = "Sound";
     public new string text303 = "Sound";

+ 0 - 2
Assets/BowArrow/Scripts/Entry.cs

@@ -20,8 +20,6 @@ public class Entry : MonoBehaviour
         // QualitySettings.vSyncCount = 0;
         // QualitySettings.vSyncCount = 0;
         // Application.targetFrameRate = 60;
         // Application.targetFrameRate = 60;
         QualitySettings.vSyncCount = 1;
         QualitySettings.vSyncCount = 1;
-        //初始化
-        TextAutoLanguage.Init();
         SetTip("正在检测对比软件版本", Color.white);
         SetTip("正在检测对比软件版本", Color.white);
         StartCoroutine(CheckAppVersion());
         StartCoroutine(CheckAppVersion());
         StartCoroutine(AsyncLoadScene());
         StartCoroutine(AsyncLoadScene());

BIN
Assets/BowArrow/Textures/Home/LeftPanel/按钮-商城.png


BIN
Assets/BowArrow/Textures/Home/LeftPanel/按钮-教程.png


BIN
Assets/BowArrow/Textures/Home/LeftPanel/按钮-设备.png


BIN
Assets/BowArrow/Textures/Home/RightPanel/按钮-好友.png


BIN
Assets/BowArrow/Textures/Home/RightPanel/按钮-排行榜.png


Some files were not shown because too many files changed in this diff