public void SetData(LoverFlowerWindow parentWindow, int count, string name, string num) { m_parentWindow = parentWindow; Rank.text = count.ToString(); Name.text = name; Num.text = num; if (1 <= count && count <= 3) { RankInfoBack.SetActive(true); } }
void Awake() { m_Instance = this; m_nTipWaitWindow = 0; m_MySonghuaName.text = GameManager.gameManager.PlayerDataPool.MainPlayerBaseAttr.RoleName; m_MyShouhuaName.text = GameManager.gameManager.PlayerDataPool.MainPlayerBaseAttr.RoleName; if (IsFirstEnter) { SendRankPack((int)Games.GlobeDefine.GameDefine_Globe.RANKTYPE.TYPE_GIVEROSE, 1); SendRankPack((int)Games.GlobeDefine.GameDefine_Globe.RANKTYPE.TYPE_RECEIVEROSE, 1); } }
public static LoverRankInfoItem CreateItem(GameObject grid, GameObject resItem, int count, string name, string num, LoverFlowerWindow parentWindow) { GameObject curItem = Utils.BindObjToParent(resItem, grid); if (null == curItem) { LogModule.ErrorLog("CreateItem, curItem error!"); } curItem.name = count.ToString(); LoverRankInfoItem curItemComponent = curItem.GetComponent <LoverRankInfoItem>(); if (null == curItemComponent) { LogModule.ErrorLog("relation list item error!"); ResourceManager.DestroyResource(ref curItem); return(null); } curItemComponent.SetData(parentWindow, count, name, num); return(curItemComponent); }