public virtual Legacy_UnityImage GetUnityImage( Color?backgroundColor = null, string imageIdentifier = null, Guid?imageOwnerId = null, string title = null, string header = null, int?voteCount = null, Legacy_UnityImageVoteRevealOptions voteRevealOptions = null) { backgroundColor ??= Color.White; List <int> backgroundColorList = new List <int> { Convert.ToInt32(backgroundColor.Value.R), Convert.ToInt32(backgroundColor.Value.G), Convert.ToInt32(backgroundColor.Value.B) }; return(new Legacy_UnityImage { BackgroundColor = new StaticAccessor <IReadOnlyList <int> > { Value = backgroundColorList }, SpriteGridWidth = new StaticAccessor <int?> { Value = 1 }, SpriteGridHeight = new StaticAccessor <int?> { Value = 1 }, ImageIdentifier = new StaticAccessor <string> { Value = imageIdentifier }, ImageOwnerId = new StaticAccessor <Guid?> { Value = imageOwnerId }, Title = new StaticAccessor <string> { Value = title }, Header = new StaticAccessor <string> { Value = header }, VoteCount = new StaticAccessor <int?> { Value = voteCount }, VoteRevealOptions = new StaticAccessor <Legacy_UnityImageVoteRevealOptions> { Value = voteRevealOptions }, }); }
public override Legacy_UnityImage GetUnityImage( Color?backgroundColor = null, string imageIdentifier = null, Guid?imageOwnerId = null, string title = null, string header = null, int?voteCount = null, Legacy_UnityImageVoteRevealOptions voteRevealOptions = null) { Legacy_UnityImage baseImage = base.GetUnityImage(backgroundColor, imageIdentifier, imageOwnerId, title, header, voteCount, voteRevealOptions); baseImage.Base64Pngs = new StaticAccessor <IReadOnlyList <string> > { Value = UserDrawings.Select(drawing => drawing.Drawing).ToList().AsReadOnly() }; return(baseImage); }
public override Legacy_UnityImage GetUnityImage( Color?backgroundColor = null, string imageIdentifier = null, Guid?imageOwnerId = null, string title = null, string header = null, int?voteCount = null, Legacy_UnityImageVoteRevealOptions voteRevealOptions = null) { Legacy_UnityImage baseImage = base.GetUnityImage(backgroundColor, imageIdentifier, imageOwnerId, title, header, voteCount, voteRevealOptions); baseImage.Base64Pngs = new StaticAccessor <IReadOnlyList <string> > { Value = GetOrderedDrawings() }; baseImage.SpriteGridWidth = new StaticAccessor <int?> { Value = 1 }; baseImage.SpriteGridHeight = new StaticAccessor <int?> { Value = 3 }; return(baseImage); }