public void Set(CopyAchievementDefinitionV2ByAchievementIdOptions other) { if (other != null) { m_ApiVersion = AchievementsInterface.Copyachievementdefinitionv2ByachievementidApiLatest; AchievementId = other.AchievementId; } }
/// <summary> /// Fetches an achievement definition from a given achievement ID. /// <seealso cref="Release" /> /// </summary> /// <param name="options">Structure containing the achievement ID being accessed</param> /// <param name="outDefinition">The achievement definition for the given achievement ID, if it exists and is valid, use <see cref="Release" /> when finished</param> /// <returns> /// <see cref="Result.Success" /> if the information is available and passed out in OutDefinition /// <see cref="Result.InvalidParameters" /> if you pass a null pointer for the out parameter /// <see cref="Result.NotFound" /> if the achievement definition is not found /// <see cref="Result.InvalidProductUserID" /> if any of the userid options are incorrect /// </returns> public Result CopyAchievementDefinitionV2ByAchievementId(CopyAchievementDefinitionV2ByAchievementIdOptions options, out DefinitionV2 outDefinition) { System.IntPtr optionsAddress = new System.IntPtr(); Helper.TryMarshalSet <CopyAchievementDefinitionV2ByAchievementIdOptionsInternal, CopyAchievementDefinitionV2ByAchievementIdOptions>(ref optionsAddress, options); var outDefinitionAddress = System.IntPtr.Zero; var funcResult = EOS_Achievements_CopyAchievementDefinitionV2ByAchievementId(InnerHandle, optionsAddress, ref outDefinitionAddress); Helper.TryMarshalDispose(ref optionsAddress); if (Helper.TryMarshalGet <DefinitionV2Internal, DefinitionV2>(outDefinitionAddress, out outDefinition)) { EOS_Achievements_DefinitionV2_Release(outDefinitionAddress); } return(funcResult); }