Author Topic: packetlossTotal not being updated  (Read 18528 times)

BlackMoon

  • Not-a-newbie
  • *
  • Posts: 3
  • Karma: 0
    • View Profile
packetlossTotal not being updated
« on: August 30, 2014, 12:15:22 AM »
Hi. new to raknet but I think I found a bug or two.

When I call GetStatistics (every frame) packetlossTotal never changes from 0. I am simulating 10% packet loss using clumsy and the packetlossLastSecond variable seems to update just fine (showing values of 15~25% as clumsy seems to double the loss for localhost loopback and it randomly goes up/down a little) , but packetlossTotal never changes.

Also, Ping never updated (GetLowestPing, GetLastPing, GetAveragePing) until I called SetOccasionalPing(true); yet the documents say 'By default this is true'
http://www.jenkinssoftware.com/raknet/manual/Doxygen/classRakNet_1_1RakPeerInterface.html#fdc6e658512d2f01d6bb211758721f21

So either the documentation is wrong or the code is. I am assuming its the code since one would assume occasional pings by default would be expected default behavior.

BlackMoon

  • Not-a-newbie
  • *
  • Posts: 3
  • Karma: 0
    • View Profile
Re: packetlossTotal not being updated
« Reply #1 on: September 02, 2014, 02:42:47 AM »
Found another minor bug in documentation:
http://www.jenkinssoftware.com/raknet/manual/Doxygen/classRakNet_1_1RakPeerInterface.html#d5667c9d47585be3a65485f9c81f7045
Quote
virtual bool RakNet::RakPeerInterface::Ping(const char *host...
Send a ping to the specified unconnected system. The remote system, if it is Initialized, will respond with ID_PONG followed by sizeof(RakNet::TimeMS) containing the system time the ping was sent.(Default is 4 bytes - See __GET_TIME_64BIT in RakNetTypes.h System should reply with ID_PONG if it is active

there is no ID_PONG. I believe its now called ID_UNCONNECTED_PONG ?