| | |
| | | [RequireComponent(typeof(UIEffectPlayer))] |
| | | public class GuildEmblemCell : MonoBehaviour |
| | | { |
| | | [SerializeField] ImageEx emblemIcon; |
| | | [SerializeField] Image emblemIcon; |
| | | [SerializeField] UIFrame frame; |
| | | [SerializeField] UIEffectPlayer uiEffect; |
| | | [Header("字 F9E29F 包边 683C00 字号36 Y:-9")] |
| | | [Header("代码已处理 字 F9E29F 包边 683C00 字号72 Y:-18")] |
| | | [SerializeField] Text emblemNameText; //字 F9E29F 包边 683C00 字号36 Y-9 |
| | | |
| | | public void Display(int emblemID, string emblemName, float _scale = 1f) |
| | |
| | | FamilyEmblemConfig config = FamilyEmblemConfig.Get(emblemID); |
| | | if (config == null) |
| | | { |
| | | return; |
| | | } |
| | | if (emblemIcon == null) |
| | | { |
| | | Debug.LogError("公会徽章未设置"); |
| | | return; |
| | | } |
| | | |
| | |
| | | if (effectID != 0) |
| | | { |
| | | uiEffect.effectId = effectID; |
| | | uiEffect.isPlaySpineLoop = true; |
| | | uiEffect.Play(); |
| | | } |
| | | } |
| | |
| | | emblemIcon.SetNativeSize(); |
| | | } |
| | | emblemIcon.rectTransform.localScale = new Vector3(_scale, _scale, _scale); |
| | | emblemNameText.text = emblemName; |
| | | if (emblemNameText != null) |
| | | { |
| | | emblemNameText.text = emblemName; |
| | | emblemNameText.fontSize = 72; |
| | | emblemNameText.rectTransform.localPosition = new Vector3(0, -18, 0); |
| | | emblemNameText.color = new Color32(255, 222, 159, 255); |
| | | var outline = emblemNameText.GetComponent<OutlineEx>(); |
| | | if (outline != null) |
| | | { |
| | | emblemNameText.GetComponent<OutlineEx>().OutlineColor = new Color32(104, 60, 0, 255); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | } |