@@ -41,6 +41,8 @@ namespace Discord.API | |||||
public Optional<Emoji> Emoji { get; set; } | public Optional<Emoji> Emoji { get; set; } | ||||
[JsonProperty("created_at")] | [JsonProperty("created_at")] | ||||
public Optional<long> CreatedAt { get; set; } | public Optional<long> CreatedAt { get; set; } | ||||
[JsonProperty("buttons")] | |||||
public Optional<RichPresenceButton[]> Buttons { get; set; } | |||||
[OnError] | [OnError] | ||||
internal void OnError(StreamingContext context, ErrorContext errorContext) | internal void OnError(StreamingContext context, ErrorContext errorContext) | ||||
@@ -0,0 +1,18 @@ | |||||
using Newtonsoft.Json; | |||||
using System; | |||||
using System.Collections.Generic; | |||||
using System.Linq; | |||||
using System.Text; | |||||
using System.Threading.Tasks; | |||||
namespace Discord.API | |||||
{ | |||||
internal class RichPresenceButton | |||||
{ | |||||
[JsonProperty("label")] | |||||
public string Label { get; set; } | |||||
[JsonProperty("url")] | |||||
public string Url { get; set; } | |||||
} | |||||
} |
@@ -1,4 +1,4 @@ | |||||
using Newtonsoft.Json; | |||||
using Newtonsoft.Json; | |||||
using System; | using System; | ||||
using System.Collections.Generic; | using System.Collections.Generic; | ||||
@@ -1,4 +1,4 @@ | |||||
<Project Sdk="Microsoft.NET.Sdk"> | |||||
<Project Sdk="Microsoft.NET.Sdk"> | |||||
<Import Project="../../Discord.Net.targets" /> | <Import Project="../../Discord.Net.targets" /> | ||||
<Import Project="../../StyleAnalyzer.targets" /> | <Import Project="../../StyleAnalyzer.targets" /> | ||||
<PropertyGroup> | <PropertyGroup> | ||||
@@ -18,7 +18,7 @@ | |||||
<DocumentationFile>..\Discord.Net.WebSocket\Discord.Net.WebSocket.xml</DocumentationFile> | <DocumentationFile>..\Discord.Net.WebSocket\Discord.Net.WebSocket.xml</DocumentationFile> | ||||
</PropertyGroup> | </PropertyGroup> | ||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> | ||||
<DefineConstants>TRACE</DefineConstants> | |||||
<DefineConstants>TRACE;</DefineConstants> | |||||
</PropertyGroup> | </PropertyGroup> | ||||
<ItemGroup> | <ItemGroup> | ||||