protected int cmpCardFunc(CardItemBase a, CardItemBase b) { int ret = 0; if (a.m_tableItemCard.m_magicConsume < b.m_tableItemCard.m_magicConsume) { ret = -1; } else if (a.m_tableItemCard.m_magicConsume > b.m_tableItemCard.m_magicConsume) { ret = 1; } else // 相等 { if (a.m_tujian.id < b.m_tujian.id) { ret = -1; } else if (a.m_tujian.id > b.m_tujian.id) { ret = 1; } else { ret = 0; } } return(ret); }
override public void createCard(CardItemBase cardItem, GameObject pntGo_) { base.createCard(cardItem, pntGo_); UtilApi.setLayer(m_model.selfGo, Config.UIModelLayer); //UtilApi.setScale(gameObject.transform, new Vector3(0.24f, 1, 0.24f)); this.cardItemBase = cardItem; addEventHandle(); }