Skip to content

Commit

Permalink
InvariantCulture on ToString()
Browse files Browse the repository at this point in the history
  • Loading branch information
momintlh committed Jan 16, 2024
1 parent 33103e7 commit c9a0a86
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Assets/PlayroomKit/PlayroomKit.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using UnityEngine;
using System.Collections.Generic;
using System.Globalization;
using System.Runtime.InteropServices;
using AOT;
using System;
Expand Down Expand Up @@ -335,7 +336,7 @@ public static void SetState(string key, float value, bool reliable = false)
{
if (IsRunningInBrowser())
{
var floatAsString = value.ToString();
var floatAsString = value.ToString(CultureInfo.InvariantCulture);
SetStateFloatInternal(key, floatAsString, reliable);
}
else
Expand Down Expand Up @@ -928,7 +929,7 @@ public void SetState(string key, float value, bool reliable = false)
{
if (IsRunningInBrowser())
{
SetPlayerStateFloatByPlayerId(id, key, value.ToString(), reliable);
SetPlayerStateFloatByPlayerId(id, key, value.ToString(CultureInfo.InvariantCulture), reliable);
}
else
{
Expand Down

0 comments on commit c9a0a86

Please sign in to comment.