Convert chatroom response to use a custom type
This commit is contained in:
39
Assets/Scripts/Types/ChatroomMessage.cs
Normal file
39
Assets/Scripts/Types/ChatroomMessage.cs
Normal file
@@ -0,0 +1,39 @@
|
||||
using UnityEngine.Scripting;
|
||||
using Newtonsoft.Json;
|
||||
using System.Numerics;
|
||||
using Newtonsoft.Json.Linq;
|
||||
|
||||
[Preserve]
|
||||
public class ChatroomMessage {
|
||||
[Preserve]
|
||||
[JsonProperty("username")]
|
||||
public string Username { get; set; }
|
||||
|
||||
[Preserve]
|
||||
[JsonProperty("userid")]
|
||||
public BigInteger UserID { get; set; }
|
||||
|
||||
[Preserve]
|
||||
[JsonProperty("content")]
|
||||
public string Content { get; set; }
|
||||
|
||||
[Preserve]
|
||||
[JsonProperty("id")]
|
||||
public BigInteger ID { get; set; }
|
||||
|
||||
[Preserve]
|
||||
[JsonProperty("icon")]
|
||||
public int Icon { get; set; }
|
||||
|
||||
[Preserve]
|
||||
[JsonProperty("overlay")]
|
||||
public int Overlay { get; set; }
|
||||
|
||||
[Preserve]
|
||||
[JsonProperty("birdColor")]
|
||||
public JArray BirdColor { get; set; }
|
||||
|
||||
[Preserve]
|
||||
[JsonProperty("overlayColor")]
|
||||
public JArray OverlayColor { get; set; }
|
||||
}
|
||||
2
Assets/Scripts/Types/ChatroomMessage.cs.meta
Normal file
2
Assets/Scripts/Types/ChatroomMessage.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 723ad85187921a8b780f6cd1cf09327f
|
||||
Reference in New Issue
Block a user