Skip to content

Commit 6b15157

Browse files
committed
fix compile error with casting
1 parent 21c6774 commit 6b15157

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Runtime/NativeTime.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ internal class NativeTimeInternal
2020
[BurstCompatible]
2121
public struct ValueStopwatch
2222
{
23-
public const int TicksToNanoseconds = 100;
23+
public const ulong TicksToNanoseconds = 100;
2424
ulong start;
2525

2626
/// <summary> Returns the number of nanoseconds since system startup. </summary>
@@ -31,7 +31,7 @@ public TimeSpan ElapsedTicks
3131
get
3232
{
3333
ulong elapsed = GetTimestamp() - this.start;
34-
return new TimeSpan(elapsed / TicksToNanoseconds);
34+
return new TimeSpan((long)(elapsed / TicksToNanoseconds));
3535
}
3636
}
3737

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "com.strangeloopgames.nativetime",
33
"displayName": "NativeTime",
4-
"version": "0.1.3",
4+
"version": "0.1.4",
55
"unity": "2020.3",
66
"author": {
77
"name": "Strange Loop Games",

0 commit comments

Comments
 (0)