From 51cf44cde7c2bf1867f7680f6e2b6b2eb98305d7 Mon Sep 17 00:00:00 2001 From: MrGadget1024 Date: Fri, 24 Sep 2021 07:21:46 -0400 Subject: [PATCH] Simplified interpolations --- Assets/Mirror/Examples/Room/Scripts/PlayerScore.cs | 2 +- Assets/Mirror/Tests/Editor/NetworkIdentityTests.cs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Assets/Mirror/Examples/Room/Scripts/PlayerScore.cs b/Assets/Mirror/Examples/Room/Scripts/PlayerScore.cs index fdd57de5e..80afd78c5 100644 --- a/Assets/Mirror/Examples/Room/Scripts/PlayerScore.cs +++ b/Assets/Mirror/Examples/Room/Scripts/PlayerScore.cs @@ -12,7 +12,7 @@ public class PlayerScore : NetworkBehaviour void OnGUI() { - GUI.Box(new Rect(10f + (index * 110), 10f, 100f, 25f), $"P{index}: {score.ToString("0000000")}"); + GUI.Box(new Rect(10f + (index * 110), 10f, 100f, 25f), $"P{index}: {score:0000000}"); } } } diff --git a/Assets/Mirror/Tests/Editor/NetworkIdentityTests.cs b/Assets/Mirror/Tests/Editor/NetworkIdentityTests.cs index 31e8121a4..8b1db5889 100644 --- a/Assets/Mirror/Tests/Editor/NetworkIdentityTests.cs +++ b/Assets/Mirror/Tests/Editor/NetworkIdentityTests.cs @@ -337,7 +337,7 @@ public void SetAssetId_GivesErrorIfOneExists() // assign a guid Guid guid2 = Guid.NewGuid(); - LogAssert.Expect(LogType.Error, $"Can not Set AssetId on NetworkIdentity '{identity.name}' because it already had an assetId, current assetId '{guid1.ToString("N")}', attempted new assetId '{guid2.ToString("N")}'"); + LogAssert.Expect(LogType.Error, $"Can not Set AssetId on NetworkIdentity '{identity.name}' because it already had an assetId, current assetId '{guid1:N}', attempted new assetId '{guid2:N}'"); identity.assetId = guid2; // guid was changed @@ -358,7 +358,7 @@ public void SetAssetId_GivesErrorForEmptyGuid() // assign a guid Guid guid2 = new Guid(); - LogAssert.Expect(LogType.Error, $"Can not set AssetId to empty guid on NetworkIdentity '{identity.name}', old assetId '{guid1.ToString("N")}'"); + LogAssert.Expect(LogType.Error, $"Can not set AssetId to empty guid on NetworkIdentity '{identity.name}', old assetId '{guid1:N}'"); identity.assetId = guid2; // guid was NOT changed