Example #1
0
        private static void AddFps(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
        {
            if (entry.timeSinceLastUpdate.ElapsedMilliseconds >= 250)
            {
                entry.fps = Mathf.Clamp((int)(1f / Time.deltaTime), -99, 999); // Clamp between -99 and 999
                entry.timeSinceLastUpdate.Restart();
            }

            tempString.Append("<color=" + PlayerUtils.GetFpsColor(entry.fps) + ">" + entry.fps.ToString().PadRight(3) + "</color>" + separator);
        }
Example #2
0
        private static void AddOwnedObjectsSafe(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
        {
            int num = entry.ownedObjects;

            if (num > (int)(totalObjects * 0.75))
            {
                tempString.Append(entry.ownedObjects.ToString().PadRight(highestOwnedObjectsLength) + separator);
            }
            else
            {
                tempString.Append("0".PadRight(highestOwnedObjectsLength) + separator);
            }
        }
Example #3
0
 private static void AddPing(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
 {
     entry.ping = (short)Photon.Pun.PhotonNetwork.field_Public_Static_LoadBalancingClient_0.prop_LoadBalancingPeer_0.RoundTripTime;
     tempString.Append("<color=" + PlayerUtils.GetPingColor(entry.ping) + ">");
     if (entry.ping < 9999 && entry.ping > -999)
     {
         tempString.Append(entry.ping.ToString().PadRight(4) + "ms</color>");
     }
     else
     {
         tempString.Append(((double)(entry.ping / 1000)).ToString("N1").PadRight(5) + "s</color>");
     }
     tempString.Append(separator);
 }
Example #4
0
 private static void AddDisplayName(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
 {
     tempString.Append("<color=" + entry.playerColor + ">" + entry.apiUser.displayName + "</color>" + separator);
 }
Example #5
0
 private static void AddOwnedObjects(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
 {
     tempString.Append(entry.ownedObjects.ToString().PadRight(highestOwnedObjectsLength) + separator);
 }
Example #6
0
 private static void AddPhotonId(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
 {
     tempString.Append(player.prop_VRCPlayer_0.prop_PhotonView_0.field_Private_Int32_0.ToString().PadRight(highestPhotonIdLength) + separator);
 }
Example #7
0
 private static void AddDistance(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
 {
     tempString.Append("0.0 m" + separator);
 }
Example #8
0
 private static void AddPerf(Player player, LocalPlayerEntry entry, ref StringBuilder tempString)
 {
     tempString.Append(entry.perfString + separator);
 }