43 lines
939 B
C#
43 lines
939 B
C#
|
using System.Collections;
|
|||
|
using System.Collections.Generic;
|
|||
|
using UnityEngine;
|
|||
|
using UnityEngine.U2D;
|
|||
|
using UnityEngine.UI;
|
|||
|
|
|||
|
public class RankItem2 : MonoBehaviour
|
|||
|
{
|
|||
|
//<2F>û<EFBFBD>ͷ<EFBFBD><CDB7>
|
|||
|
public Image imgUserPic;
|
|||
|
|
|||
|
//<2F><><EFBFBD>Ű<EFBFBD>ť
|
|||
|
public Button btnPlaying;
|
|||
|
|
|||
|
//<2F>dz<EFBFBD>
|
|||
|
public Text txtName;
|
|||
|
|
|||
|
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
public Text txtRanking;
|
|||
|
|
|||
|
//<2F><><EFBFBD><EFBFBD>
|
|||
|
public Text txtScore;
|
|||
|
|
|||
|
// Start is called before the first frame update
|
|||
|
void Start()
|
|||
|
{
|
|||
|
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ű<EFBFBD>ť<EFBFBD><C5A5>ʲô
|
|||
|
btnPlaying.onClick.AddListener(() => { });
|
|||
|
}
|
|||
|
|
|||
|
public void InitInfo(PlayerData info,int i)
|
|||
|
{
|
|||
|
//<2F><><EFBFBD>°<EFBFBD>ť<EFBFBD>ϵ<EFBFBD><CFB5><EFBFBD>Ϣ
|
|||
|
txtName.text = "<22>dzƣ<C7B3>" + info.username;
|
|||
|
txtScore.text = info.weekScore.ToString();
|
|||
|
txtRanking.text = i.ToString();
|
|||
|
//<2F><><EFBFBD><EFBFBD>ͼ<EFBFBD><CDBC>
|
|||
|
SpriteAtlas sa = Resources.Load<SpriteAtlas>("Atlas/RankPanel");
|
|||
|
//Ĭ<><C4AC>ͷ<EFBFBD><CDB7>
|
|||
|
imgUserPic.sprite = sa.GetSprite("frame_head");
|
|||
|
}
|
|||
|
}
|