Package com.ngt.jopenmetaverse.shared.protocol

Examples of com.ngt.jopenmetaverse.shared.protocol.CompletePingCheckPacket


  /// <param name="sender">The sender</param>
  /// <param name="e">The EventArgs object containing the packet data</param>
  protected void StartPingCheckHandler(Object sender, PacketReceivedEventArgs e)
  {
    StartPingCheckPacket incomingPing = (StartPingCheckPacket)e.getPacket();
    CompletePingCheckPacket ping = new CompletePingCheckPacket();
    ping.PingID.PingID = incomingPing.PingID.PingID;
    ping.header.Reliable = false;
    // TODO: We can use OldestUnacked to correct transmission errors
    //   I don't think that's right.  As far as I can tell, the Viewer
    //   only uses this to prune its duplicate-checking buffer. -bushing
View Full Code Here


  /// <summary>Process an incoming packet and raise the appropriate events</summary>
  /// <param name="sender">The sender</param>
  /// <param name="e">The EventArgs object containing the packet data</param>
  protected void CompletePingCheckHandler(Object sender, PacketReceivedEventArgs e)
  {
    CompletePingCheckPacket pong = (CompletePingCheckPacket)e.getPacket();
    //String retval = "Pong2: " + (Environment.TickCount - e.getSimulator().Stats.LastPingSent);
    //if ((pong.PingID.PingID - e.getSimulator().Stats.LastPingID + 1) != 0)
    //    retval += " (gap of " + (pong.PingID.PingID - e.getSimulator().Stats.LastPingID + 1) + ")";

    e.getSimulator().Stats.LastLag = Utils.getUnixTime() - e.getSimulator().Stats.LastPingSent;
View Full Code Here

TOP

Related Classes of com.ngt.jopenmetaverse.shared.protocol.CompletePingCheckPacket

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.