Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Oct 24, 2008, 4:00:00 PM (16 years ago)
Author:
scheusso
Message:

server is now able to deliver ping time and packet loss ratio for all its clients

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/objecthierarchy/src/network/ClientInformation.cc

    r1990 r2009  
    162162
    163163  enet_uint32 ClientInformation::getRTT(){
    164     return peer_->roundTripTime;
    165   }
    166 
    167   enet_uint32 ClientInformation::getPacketLoss(){
    168     return peer_->packetLoss;
     164    return this->peer_->roundTripTime;
     165  }
     166
     167  double ClientInformation::getPacketLoss(){
     168    return ((double)this->peer_->packetLoss)/ENET_PEER_PACKET_LOSS_SCALE;
    169169  }
    170170
Note: See TracChangeset for help on using the changeset viewer.