mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2024-12-25 14:15:47 +03:00
Replaced NETCORE
defines with NET_CORE
This commit is contained in:
parent
60933de240
commit
7d30ffc734
@ -108,10 +108,16 @@ public void RunUpdateCallbacks()
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public void UpdateWhile( Func<bool> func )
|
public void UpdateWhile( Func<bool> func )
|
||||||
{
|
{
|
||||||
|
const int sleepMs = 1;
|
||||||
|
|
||||||
while ( func() )
|
while ( func() )
|
||||||
{
|
{
|
||||||
Update();
|
Update();
|
||||||
System.Threading.Thread.Sleep( 1 );
|
#if NET_CORE
|
||||||
|
System.Threading.Tasks.Task.Delay( sleepMs ).Wait();
|
||||||
|
#else
|
||||||
|
System.Threading.Thread.Sleep( sleepMs );
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -75,7 +75,7 @@ public void Cancel()
|
|||||||
remoteStorage.native.FileWriteStreamCancel( _handle );
|
remoteStorage.native.FileWriteStreamCancel( _handle );
|
||||||
}
|
}
|
||||||
|
|
||||||
#if NETCORE
|
#if NET_CORE
|
||||||
public void Close()
|
public void Close()
|
||||||
#else
|
#else
|
||||||
public override void Close()
|
public override void Close()
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
using System.Net.Sockets;
|
using System.Net.Sockets;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
|
||||||
#if !NETCORE
|
#if !NET_CORE
|
||||||
|
|
||||||
internal class SourceServerQuery :IDisposable
|
internal class SourceServerQuery :IDisposable
|
||||||
{
|
{
|
||||||
|
@ -227,11 +227,17 @@ public bool IsRunning
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public void Block()
|
public void Block()
|
||||||
{
|
{
|
||||||
|
const int sleepMs = 10;
|
||||||
|
|
||||||
workshop.steamworks.Update();
|
workshop.steamworks.Update();
|
||||||
|
|
||||||
while ( IsRunning )
|
while ( IsRunning )
|
||||||
{
|
{
|
||||||
System.Threading.Thread.Sleep( 10 );
|
#if NET_CORE
|
||||||
|
System.Threading.Tasks.Task.Delay( sleepMs ).Wait();
|
||||||
|
#else
|
||||||
|
System.Threading.Thread.Sleep( sleepMs );
|
||||||
|
#endif
|
||||||
workshop.steamworks.Update();
|
workshop.steamworks.Update();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
using System.Runtime.CompilerServices;
|
using System.Runtime.CompilerServices;
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
#if !NETCORE
|
#if !NET_CORE
|
||||||
|
|
||||||
// General Information about an assembly is controlled through the following
|
// General Information about an assembly is controlled through the following
|
||||||
// set of attributes. Change these attribute values to modify the information
|
// set of attributes. Change these attribute values to modify the information
|
||||||
|
@ -37,7 +37,7 @@ internal static Facepunch.Steamworks.OperatingSystem Os
|
|||||||
{
|
{
|
||||||
_os = Facepunch.Steamworks.OperatingSystem.Windows;
|
_os = Facepunch.Steamworks.OperatingSystem.Windows;
|
||||||
|
|
||||||
#if !NETCORE
|
#if !NET_CORE
|
||||||
//
|
//
|
||||||
// These checks aren't so accurate on older versions of mono
|
// These checks aren't so accurate on older versions of mono
|
||||||
//
|
//
|
||||||
|
Loading…
Reference in New Issue
Block a user