void Send(int n) { var fbb = new FlatBufferBuilder(1); fbb.Finish(SendMeStat.CreateSendMeStat(fbb, Class.SendMeStat, Class.MonsterStat, 1).Value); TCPClient.Instance.Send(fbb.SizedByteArray()); }
public static void Send(int PlayerID) { NetworkSendManager.instance.actions.Enqueue(() => { var fbb = new FlatBufferBuilder(1); fbb.Finish(SendMeStat.CreateSendMeStat(fbb, Class.SendMeStat, Class.MonsterStat, PlayerID).Value); TCPClient.Instance.Send(fbb.SizedByteArray()); }); }
public static Offset <SendMeStat> CreateSendMeStat(FlatBufferBuilder builder, Class cType = Class.Base, Class StatDataType = Class.Base, int ID = 0) { builder.StartObject(3); SendMeStat.AddID(builder, ID); SendMeStat.AddStatDataType(builder, StatDataType); SendMeStat.AddCType(builder, cType); return(SendMeStat.EndSendMeStat(builder)); }
public static SendMeStat GetRootAsSendMeStat(ByteBuffer _bb, SendMeStat obj) { return(obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); }