how to use PhotonPeer.TrafficStatsGameLevel

Options
The PhotonPeer.TrafficStatsGameLevel track how often you call DispatchIncomingCommands and SendOutgoingCommands when you turn the stats on (PhotonPeer.TrafficStatsEnabled = true). Check the values of LongestDeltaBetweenSending and LongestDeltaBetweenDispatching.

i cant understand how to track ..

lite peer = new peer;
peer.TrafficStatsEnabled = true;
and then ?
any one can tell me ?

Comments

  • Leepo
    Options
    Have you already seen the PhotonStatsTracker.cs file? Simply drag this in your scene to have a simple GUI with these stats. This should show you how to use the TrafficStats
  • ymlyjq
    Options
    e, i cant find the file photonstatstracker.cs ,in unity3d i only add photon3unity3d.dll into unity's Plugins

    where can i find this file ?

    thank Leepo
  • Tobias
    Options
    I think Leepo wanted to point you to PhotonStatsGui.cs which is part of PUN. The linked file uses traffic stats as well but this is intended for debugging only.

    After enabling the traffic stats you only have to use Photon and check the values you're looking for. All bundled in TrafficStats.