From 212f6ca91ce99e03bf3b7b3484697f16f20225dc Mon Sep 17 00:00:00 2001
From: lcy <1459594991@qq.com>
Date: 星期二, 07 四月 2026 20:12:46 +0800
Subject: [PATCH] 592 多语言适配 改程序字
---
Main/System/Guild/GuildEmblemSelectCell.cs | 6 +++---
Main/System/HeroUI/HeroCollectionCardCell.cs | 6 +++++-
Main/System/HeroUI/HeroCardCell.cs | 20 +++++++++++++++++++-
Main/System/HeroUI/HeroCollectionWin.cs | 14 ++++++++++++++
4 files changed, 41 insertions(+), 5 deletions(-)
diff --git a/Main/System/Guild/GuildEmblemSelectCell.cs b/Main/System/Guild/GuildEmblemSelectCell.cs
index b325ac1..6212360 100644
--- a/Main/System/Guild/GuildEmblemSelectCell.cs
+++ b/Main/System/Guild/GuildEmblemSelectCell.cs
@@ -7,7 +7,7 @@
public class GuildEmblemSelectCell : MonoBehaviour
{
[SerializeField] GuildEmblemCell emblemIcon;
- [SerializeField] Image useImg;
+ [SerializeField] TextEx usetext;
[SerializeField] Image lockImg;
[SerializeField] Image selectImg;
[SerializeField] Button selectBtn;
@@ -19,11 +19,11 @@
emblemIcon.Display(id, "", 0.5f);
if (PlayerDatas.Instance.fairyData.fairy == null)
{
- useImg.SetActive(false);
+ usetext.SetActive(false);
}
else
{
- useImg.SetActive(id == PlayerDatas.Instance.fairyData.fairy.EmblemID);
+ usetext.SetActive(id == PlayerDatas.Instance.fairyData.fairy.EmblemID);
}
lockImg.SetActive(!GuildEmblemModel.Instance.IsUnLock(id));
selectImg.SetActive(id == GuildEmblemModel.Instance.nowChooseEmblemId);
diff --git a/Main/System/HeroUI/HeroCardCell.cs b/Main/System/HeroUI/HeroCardCell.cs
index ad82c97..f778f47 100644
--- a/Main/System/HeroUI/HeroCardCell.cs
+++ b/Main/System/HeroUI/HeroCardCell.cs
@@ -14,6 +14,8 @@
[SerializeField] RedpointBehaviour redpoint;
[SerializeField] Image newImage; //鏂版爣璇嗗拰绾㈢偣浜掓枼
[SerializeField] Image trainStateImg;
+ [SerializeField] TextEx trainStatetxt;
+ [SerializeField] OutlineEx trainStateOutline;
[SerializeField] Image starRedImg;
[SerializeField] Text nameText;
[SerializeField] Image awakeImg;
@@ -48,7 +50,7 @@
newImage.SetActive(false);
}
else
- {
+ {
redpoint.redpointId = 0;
newImage.SetActive(HeroUIManager.Instance.newHeroIDList.Contains(hero.heroId));
}
@@ -58,6 +60,22 @@
{
trainStateImg.SetActive(true);
trainStateImg.SetSprite("herofuncstate" + funcState);
+ trainStatetxt.text = funcState switch
+ {
+ 1 => Language.Get("herocard41"),
+ 2 => Language.Get("HeroGift3"),
+ 3 => Language.Get("L1111"),
+ 4 => Language.Get("L1109"),
+ _ => string.Empty,
+ };
+ trainStateOutline.OutlineColor = funcState switch
+ {
+ 1 => new Color32(0x5c, 0x2b, 0x2b, 255),
+ 2 => new Color32(0x5c, 0x46, 0x2b, 255),
+ 3 => new Color32(0x2b, 0x3d, 0x5c, 255),
+ 4 => new Color32(0x2e, 0x5c, 0x2b, 255),
+ _ => Color.white,
+ };
}
else
{
diff --git a/Main/System/HeroUI/HeroCollectionCardCell.cs b/Main/System/HeroUI/HeroCollectionCardCell.cs
index 5ea7b56..e2b8469 100644
--- a/Main/System/HeroUI/HeroCollectionCardCell.cs
+++ b/Main/System/HeroUI/HeroCollectionCardCell.cs
@@ -12,6 +12,8 @@
[SerializeField] Image jobImg;
[SerializeField] Text nameText;
[SerializeField] Image trainStateImg;
+ [SerializeField] TextEx trainStatetxt;
+ [SerializeField] OutlineEx trainStateOutline;
[SerializeField] RedpointBehaviour redpoint;
// [SerializeField] Button bookLVBtn;
[SerializeField] GameObject unGetObj;
@@ -46,6 +48,8 @@
{
trainStateImg.SetActive(true);
trainStateImg.SetSprite("herofuncstate4");
+ trainStatetxt.text = Language.Get("L1109");
+ trainStateOutline.OutlineColor = new Color32(0x2e, 0x5c, 0x2b, 255);
}
else
{
@@ -72,7 +76,7 @@
UIManager.Instance.OpenWindow<HeroBestBaseWin>();
}
});
-
+
// bookLVBtn.AddListener(() =>
// {
// HeroUIManager.Instance.selectCollectHeroID = heroID;
diff --git a/Main/System/HeroUI/HeroCollectionWin.cs b/Main/System/HeroUI/HeroCollectionWin.cs
index 50bd021..7257a55 100644
--- a/Main/System/HeroUI/HeroCollectionWin.cs
+++ b/Main/System/HeroUI/HeroCollectionWin.cs
@@ -169,6 +169,20 @@
{
var _cell = cell.GetComponent<Image>();
_cell.SetSprite("herocoltitle" + cell.index);
+
+ var title = cell.GetComponentInChildren<Text>();
+ title.text = RichTextMsgReplaceConfig.GetRichReplace("HeroQuality", cell.index);
+
+ var outlineEx = title.GetComponent<OutlineEx>();
+ outlineEx.OutlineColor = cell.index switch
+ {
+ 1 => new Color32(0x17, 0x25, 0x43, 255),
+ 2 => new Color32(0x2a, 0x0f, 0x30, 255),
+ 3 => new Color32(0x4a, 0x2f, 0x00, 255),
+ 4 => new Color32(0x45, 0x18, 0x00, 255),
+ 5 => new Color32(0x51, 0x00, 0x00, 255),
+ _ => Color.white,
+ };
}
else if (type == ScrollerDataType.Normal)
{
--
Gitblit v1.8.0