You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
133 lines
3.1 KiB
133 lines
3.1 KiB
1 month ago
|
using System.Collections.Generic;
|
||
|
|
||
|
|
||
|
namespace Sog
|
||
|
{
|
||
|
public class IDValue32Class
|
||
|
{
|
||
|
public int id;
|
||
|
public int value;
|
||
|
}
|
||
|
|
||
|
public class TypeIDValue32Class
|
||
|
{
|
||
|
public int type;
|
||
|
public int id;
|
||
|
public int value;
|
||
|
}
|
||
|
|
||
|
public class IDValue64Class
|
||
|
{
|
||
|
public long id;
|
||
|
public long value;
|
||
|
}
|
||
|
|
||
|
public interface ISyncData
|
||
|
{
|
||
|
ulong GetRuntimeId();
|
||
|
}
|
||
|
|
||
|
public class SyncList<T>
|
||
|
{
|
||
|
public string name;
|
||
|
|
||
|
public List<T> data;
|
||
|
|
||
|
public Dictionary<ulong, int> index;
|
||
|
|
||
|
|
||
|
// 当前访问索引
|
||
|
public int visitIdx;
|
||
|
|
||
|
public long beginVisitTime;
|
||
|
|
||
|
|
||
|
public SyncList(string name, int capacity)
|
||
|
{
|
||
|
this.name = name;
|
||
|
|
||
|
data = new List<T>(capacity);
|
||
|
|
||
|
index = new Dictionary<ulong, int>();
|
||
|
|
||
|
visitIdx = 0;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
public class RealmBriefInfo
|
||
|
{
|
||
|
public int realmId;
|
||
|
public int logicWorldId;
|
||
|
public int WorldId;
|
||
|
public int ShowSeq;
|
||
|
public string realmName;
|
||
|
public string realmBdcName;
|
||
|
public int state;
|
||
|
public int openTime;
|
||
|
public int bigRealmId;
|
||
|
public string ip;
|
||
|
public string areaName;
|
||
|
public int onlinePlayer;
|
||
|
public int timeZone;
|
||
|
public string visibleOnlyCliVersion;
|
||
|
public int visibleOnlyWhiteList;
|
||
|
public int visibleTime;
|
||
|
public int regMax;
|
||
|
|
||
|
public RealmBriefInfo() { }
|
||
|
|
||
|
public RealmBriefInfo(ref ProtoCSStruct.CSRealmBrief cSRealmBrief)
|
||
|
{
|
||
|
realmId = cSRealmBrief.RealmId;
|
||
|
logicWorldId = cSRealmBrief.LogicWorldId;
|
||
|
WorldId = cSRealmBrief.WorldId;
|
||
|
realmName = cSRealmBrief.RealmName.GetString();
|
||
|
realmBdcName = cSRealmBrief.RealmBdcName.GetString();
|
||
|
state = cSRealmBrief.State;
|
||
|
openTime = cSRealmBrief.OpenTime;
|
||
|
ShowSeq = cSRealmBrief.ShowSeq;
|
||
|
|
||
|
bigRealmId = cSRealmBrief.BigRealmId;
|
||
|
ip = cSRealmBrief.Ip.GetString();
|
||
|
areaName = cSRealmBrief.AreaName.GetString();
|
||
|
onlinePlayer = cSRealmBrief.OnlinePlayer;
|
||
|
timeZone = cSRealmBrief.TimeZone;
|
||
|
visibleOnlyCliVersion = cSRealmBrief.VisibleOnlyCliVersion.GetString();
|
||
|
visibleOnlyWhiteList = cSRealmBrief.VisibleOnlyWhiteList;
|
||
|
visibleTime = cSRealmBrief.VisibleTime;
|
||
|
regMax = cSRealmBrief.RegMax;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
// 英雄支付中的cp自定义消息
|
||
|
public class HeroPayCpCustomMsg
|
||
|
{
|
||
|
public int worldId { get; set; }
|
||
|
}
|
||
|
|
||
|
// 库存信息
|
||
|
public class ItemStockInfoOne
|
||
|
{
|
||
|
public int itemId;
|
||
|
public int remainCount;
|
||
|
}
|
||
|
|
||
|
public class RealmItemStockInfo
|
||
|
{
|
||
|
public int realmId;
|
||
|
public Dictionary<int, ItemStockInfoOne> stockDict = new Dictionary<int, ItemStockInfoOne>();
|
||
|
|
||
|
public int lastSendWorldTime;
|
||
|
}
|
||
|
|
||
|
public class HeroUsdkProjCfgOne
|
||
|
{
|
||
|
public int cpId;
|
||
|
public string cpName;
|
||
|
|
||
|
public string pcode;
|
||
|
public string appKey;
|
||
|
public string callbackKey;
|
||
|
}
|
||
|
}
|