Skip to content

Commit c8093ef

Browse files
author
Viktor Gaponenko
committed
fix: DataRader write
1 parent 80fe705 commit c8093ef

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

Runtime/Scripts/Components/DataReader.cs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,16 @@ public void Read()
107107
}
108108
}
109109

110+
public void Write(float value)
111+
{
112+
var str = value.ToString(CultureInfo.InvariantCulture);
113+
if (float.TryParse(value.ToString(CultureInfo.InvariantCulture), NumberStyles.Float, CultureInfo.InvariantCulture, out var result))
114+
{
115+
_targetData.Value = str;
116+
Write();
117+
}
118+
}
119+
110120
public void Write()
111121
{
112122
try

0 commit comments

Comments
 (0)