Example #1
0
 public ErrorCode OnBSAskPing(NetSessionBase session, Google.Protobuf.IMessage message)
 {
     Protos.G_AskPing    askPing    = (Protos.G_AskPing)message;
     Protos.G_AskPingRet askPingRet = ProtoCreator.R_G_AskPing(askPing.Opts.Pid);
     askPingRet.Stime = askPing.Time;
     askPingRet.Time  = TimeUtils.utcTime;
     session.Send(askPingRet);
     return(ErrorCode.Success);
 }
Example #2
0
 public ErrorCode OnGSAskPing(NetSessionBase session, IMessage message)
 {
     Protos.G_AskPing    request  = (Protos.G_AskPing)message;
     Protos.G_AskPingRet response = ProtoCreator.R_G_AskPing(request.Opts.Pid);
     response.Stime = request.Time;
     response.Time  = TimeUtils.utcTime;
     session.Send(response);
     return(ErrorCode.Success);
 }
Example #3
0
 public void PingCS(NetSessionBase session)
 {
     Protos.G_AskPing msg = ProtoCreator.Q_G_AskPing();
     msg.Time = TimeUtils.utcTime;
     session.Send(msg, RPCEntry.Pop(OnGSAskPingRet));
 }