removed useless thing

This commit is contained in:
z__
2022-01-26 11:00:44 +07:00
parent e2cdd803af
commit 8efe8ae398

View File

@@ -1,29 +0,0 @@
using System;
using System.Reflection;
using System.Windows.Data;
using VRage.GameServices;
namespace Torch
{
/// <summary>
/// Provides static accessor for MySteamService because Keen made it internal
/// </summary>
public static class MySteamServiceWrapper
{
private static readonly MethodInfo _getGameService;
public static IMyGameService Static => (IMyGameService)_getGameService.Invoke(null, null);
static MySteamServiceWrapper()
{
var type = Type.GetType("VRage.Steam.MySteamService, VRage.Steam");
var prop = type.GetProperty("Static", BindingFlags.Static | BindingFlags.Public);
_getGameService = prop.GetGetMethod();
}
public static IMyGameService Init(bool dedicated, uint appId)
{
return (IMyGameService)Activator.CreateInstance(Type.GetType("VRage.Steam.MySteamService, VRage.Steam"), dedicated, appId);
}
}
}