47 lines
1.2 KiB
C#
47 lines
1.2 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Torch.API.Managers;
|
|
using VRage.Game.ModAPI;
|
|
|
|
namespace Torch.API
|
|
{
|
|
public interface ITorchBase
|
|
{
|
|
event Action SessionLoading;
|
|
event Action SessionLoaded;
|
|
event Action SessionUnloading;
|
|
event Action SessionUnloaded;
|
|
ITorchConfig Config { get; }
|
|
IMultiplayerManager Multiplayer { get; }
|
|
IPluginManager Plugins { get; }
|
|
Version TorchVersion { get; }
|
|
void Invoke(Action action);
|
|
void InvokeBlocking(Action action);
|
|
Task InvokeAsync(Action action);
|
|
string[] RunArgs { get; set; }
|
|
bool IsOnGameThread();
|
|
void Start();
|
|
void Stop();
|
|
/// <summary>
|
|
/// Initializes a save of the game.
|
|
/// </summary>
|
|
/// <param name="callerId">Id of the player who initiated the save.</param>
|
|
void Save(long callerId);
|
|
void Init();
|
|
T GetManager<T>() where T : class, IManager;
|
|
}
|
|
|
|
public interface ITorchServer : ITorchBase
|
|
{
|
|
string InstancePath { get; }
|
|
}
|
|
|
|
public interface ITorchClient : ITorchBase
|
|
{
|
|
|
|
}
|
|
}
|