-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathUnsubscribeMsesage.cs
More file actions
40 lines (35 loc) · 1.05 KB
/
UnsubscribeMsesage.cs
File metadata and controls
40 lines (35 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using DiscordRPC.RPC.Payload;
namespace DiscordRPC.Message
{
/// <summary>
/// Called as validation of a subscribe
/// </summary>
public class UnsubscribeMessage : IMessage
{
/// <summary>
/// The type of message received from discord
/// </summary>
public override MessageType Type
{ get { return MessageType.Unsubscribe; } }
/// <summary>
/// The event that was subscribed too.
/// </summary>
public EventType Event { get; internal set; }
internal UnsubscribeMessage(ServerEvent evt)
{
switch (evt)
{
default:
case ServerEvent.ActivityJoin:
Event = EventType.Join;
break;
case ServerEvent.ActivityJoinRequest:
Event = EventType.JoinRequest;
break;
case ServerEvent.ActivitySpectate:
Event = EventType.Spectate;
break;
}
}
}
}