public void UpdateValue() { ArenaPlayerHistory dataOfClass = DataSource.FindDataOfClass <ArenaPlayerHistory>(((Component)this).get_gameObject(), (ArenaPlayerHistory)null); if (dataOfClass == null) { return; } this.PlayerLevel.set_text(dataOfClass.enemy.PlayerLevel.ToString()); this.result_image.ImageIndex = !dataOfClass.IsWin() ? 1 : 0; ((Component)this.NewImage).get_gameObject().SetActive(dataOfClass.IsNew()); if (dataOfClass.IsNew()) { ((Graphic)this.created_at).set_color(new Color((float)byte.MaxValue, (float)byte.MaxValue, 0.0f, 1f)); } this.history_type.ImageIndex = !dataOfClass.IsAttack() ? 1 : 0; this.Ranking.set_text(dataOfClass.ranking.up.ToString()); ((Component)this.Ranking).get_gameObject().SetActive(dataOfClass.ranking.up != 0); if (dataOfClass.ranking.up > 0) { this.ranking_delta.ImageIndex = 0; } else if (dataOfClass.ranking.up < 0) { this.ranking_delta.ImageIndex = 1; ((Graphic)this.Ranking).set_color(new Color((float)byte.MaxValue, 0.0f, 0.0f, 1f)); } else { ((Component)this.ranking_delta).get_gameObject().SetActive(false); } this.PlayerName.set_text(dataOfClass.enemy.PlayerName.ToString()); this.created_at.set_text(dataOfClass.battle_at.ToString("MM/dd HH:mm")); }
private void OnItemDetail(GameObject go) { if (Object.op_Equality((Object)this.DetailWindow, (Object)null)) { return; } ArenaPlayerHistory dataOfClass = DataSource.FindDataOfClass <ArenaPlayerHistory>(go, (ArenaPlayerHistory)null); if (dataOfClass == null) { return; } GameObject gameObject = (GameObject)Object.Instantiate <GameObject>((M0)this.DetailWindow); DataSource.Bind <ArenaPlayer>(gameObject, dataOfClass.enemy); ((ArenaPlayerInfo)gameObject.GetComponent <ArenaPlayerInfo>()).UpdateValue(); }