mirror of
https://github.com/simtactics/mysimulation.git
synced 2025-03-25 18:59:12 +00:00
- NioTSO client isn't needed because we're using RayLib - Added FreeSO's API server to handle most backend operations
45 lines
1.4 KiB
C#
Executable file
45 lines
1.4 KiB
C#
Executable file
using FSO.Common.Utils;
|
|
|
|
namespace FSO.Server.Protocol.CitySelector
|
|
{
|
|
public class ShardSelectorServletResponse : IXMLEntity
|
|
{
|
|
public string Address;
|
|
public string Ticket;
|
|
public string ConnectionID;
|
|
public uint PlayerID;
|
|
public string AvatarID;
|
|
|
|
public bool PreAlpha = false;
|
|
|
|
#region IXMLPrinter Members
|
|
|
|
public System.Xml.XmlElement Serialize(System.Xml.XmlDocument doc)
|
|
{
|
|
var result = doc.CreateElement("Shard-Selection");
|
|
result.AppendTextNode("Connection-Address", Address);
|
|
result.AppendTextNode("Authorization-Ticket", Ticket);
|
|
result.AppendTextNode("PlayerID", PlayerID.ToString());
|
|
|
|
if (PreAlpha == false)
|
|
{
|
|
result.AppendTextNode("ConnectionID", ConnectionID);
|
|
result.AppendTextNode("EntitlementLevel", "");
|
|
}
|
|
result.AppendTextNode("AvatarID", AvatarID); //freeso now uses this
|
|
|
|
return result;
|
|
}
|
|
|
|
public void Parse(System.Xml.XmlElement element)
|
|
{
|
|
this.Address = element.ReadTextNode("Connection-Address");
|
|
this.Ticket = element.ReadTextNode("Authorization-Ticket");
|
|
this.PlayerID = uint.Parse(element.ReadTextNode("PlayerID"));
|
|
|
|
this.AvatarID = element.ReadTextNode("AvatarID");
|
|
}
|
|
|
|
#endregion
|
|
}
|
|
}
|