public void UnlockTrophies(List <int> trophy_ids) { if (!this.Available || this._data == null || this._callback_update != null) { return; } if (trophy_ids == null) { return; } for (int i = 0; i < trophy_ids.get_Count(); i++) { int num = trophy_ids.get_Item(i); this._Log(string.Format("ID:{0} 解除開始", num)); TrophyManager.TrophyData trophyData = this._GetTrophyData(num); trophyData.unlocked = true; int num2 = this._IDtoIndex(trophyData); if (num2 > 0) { ErrorCode errorCode = Trophies.AwardTrophy(num2); if (errorCode != null) { trophyData.unlocked = false; } } } }
private int _IDtoIndex(TrophyManager.TrophyData trophyData) { if (this._data == null) { return(-1); } if (trophyData == null) { return(-1); } return(this._data.IndexOf(trophyData)); }
private int _IDtoIndex(int trophy_id) { TrophyManager.TrophyData trophyData = this._GetTrophyData(trophy_id); return(this._IDtoIndex(trophyData)); }
public bool IsUnlocked(int trophy_id) { TrophyManager.TrophyData trophyData = this._GetTrophyData(trophy_id); return(trophyData == null || trophyData.unlocked); }