Mark old event system as deprecated

This commit is contained in:
NGnius (Graham) 2020-08-02 22:39:26 -04:00
parent b81562ea58
commit ca0e6e089d
17 changed files with 21 additions and 1 deletions

View file

@ -18,6 +18,7 @@ namespace GamecraftModdingAPI.Events
/// Patch of RobocraftX.StateSync.DeterministicStepCompositionRoot.ComposeEnginesGroups(...)
/// </summary>
//[HarmonyPatch(typeof(DeterministicStepCompositionRoot), "DeterministicCompose")]
[Obsolete]
[HarmonyPatch]
class GameHostTransitionDeterministicGroupEnginePatch
{

View file

@ -4,6 +4,7 @@ using Svelto.ECS;
namespace GamecraftModdingAPI.Events
{
[Obsolete]
public class EmitterBuilder
{
private string name;

View file

@ -11,6 +11,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Convenient factories for mod event engines
/// </summary>
[Obsolete]
public static class EventEngineFactory
{
/// <summary>

View file

@ -14,6 +14,7 @@ namespace GamecraftModdingAPI.Events
/// Keeps track of event handlers and emitters.
/// This is used to add, remove and get API event handlers and emitters.
/// </summary>
[Obsolete]
public static class EventManager
{
private static Dictionary<string, IEventEmitterEngine> _eventEmitters = new Dictionary<string, IEventEmitterEngine>();

View file

@ -17,6 +17,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Patch of RobocraftX.FullGameCompositionRoot.ActivateGame()
/// </summary>
[Obsolete]
[HarmonyPatch]
class GameActivatedComposePatch
{

View file

@ -14,6 +14,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Patch of RobocraftX.FullGameCompositionRoot.ReloadGame()
/// </summary>
[Obsolete]
[HarmonyPatch(typeof(FullGameCompositionRoot), "ReloadGame")]
class GameReloadedPatch
{

View file

@ -12,6 +12,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Event emitter engine for switching to to build mode.
/// </summary>
[Obsolete]
public class GameStateBuildEmitterEngine : IEventEmitterEngine, IUnorderedInitializeOnTimeStoppedModeEntered
{
public string Name { get; } = "GamecraftModdingAPIGameStateBuildEventEmitter" ;

View file

@ -12,6 +12,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Event emitter engine for switching to simulation mode.
/// </summary>
[Obsolete]
public class GameStateSimulationEmitterEngine : IEventEmitterEngine, IUnorderedInitializeOnTimeRunningModeEntered
{
public string Name { get; } = "GamecraftModdingAPIGameStateSimulationEventEmitter" ;

View file

@ -18,6 +18,7 @@ namespace GamecraftModdingAPI.Events
/// Patch of RobocraftX.FullGameCompositionRoot.ActivateGame()
/// (scheduled for execution during RobocraftX.FullGameCompositionRoot.SwitchToGame())
/// </summary>
[Obsolete]
[HarmonyPatch(typeof(FullGameCompositionRoot), "SwitchToGame")]
class GameSwitchedToPatch
{

View file

@ -4,6 +4,7 @@ using Svelto.ECS;
namespace GamecraftModdingAPI.Events
{
[Obsolete]
public class HandlerBuilder
{
private string name;

View file

@ -13,6 +13,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Engine interface to create a ModEventEntityStruct in entitiesDB when a specific event occurs.
/// </summary>
[Obsolete]
public interface IEventEmitterEngine : IFactoryEngine
{
/// <summary>

View file

@ -14,6 +14,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Engine interface to handle ModEventEntityStruct events emitted by IEventEmitterEngines.
/// </summary>
[Obsolete]
public interface IEventHandlerEngine : IReactionaryEngine<ModEventEntityStruct>
{
}

View file

@ -15,6 +15,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Patch of RobocraftX.FullGameCompositionRoot.ActivateMenu()
/// </summary>
[Obsolete]
[HarmonyPatch(typeof(FullGameCompositionRoot), "ActivateMenu")]
class MenuActivatedPatch
{

View file

@ -15,6 +15,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// Patch of RobocraftX.FullGameCompositionRoot.SwitchToMenu()
/// </summary>
[Obsolete]
[HarmonyPatch(typeof(FullGameCompositionRoot), "SwitchToMenu")]
class MenuSwitchedToPatch
{

View file

@ -12,6 +12,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// A simple implementation of IEventEmitterEngine sufficient for most uses
/// </summary>
[Obsolete]
public class SimpleEventEmitterEngine : IEventEmitterEngine
{
public string Name { get; set; }

View file

@ -13,6 +13,7 @@ namespace GamecraftModdingAPI.Events
/// <summary>
/// A simple implementation of IEventHandlerEngine sufficient for most uses
/// </summary>
[Obsolete]
public class SimpleEventHandlerEngine : IEventHandlerEngine
{
public int type { get; set; }

View file

@ -14,6 +14,7 @@ namespace GamecraftModdingAPI.Utility
/// Tracks the API version the current game was built for.
/// For compatibility reasons, this must be enabled before it will work.
/// </summary>
[Obsolete]
public static class VersionTracking
{
private static readonly VersionTrackingEngine versionEngine = new VersionTrackingEngine();
@ -58,6 +59,7 @@ namespace GamecraftModdingAPI.Utility
}
[Obsolete]
internal class VersionTrackingEngine : IEventEmitterEngine
{
public string Name { get; } = "GamecraftModdingAPIVersionTrackingGameEngine";
@ -94,11 +96,13 @@ namespace GamecraftModdingAPI.Utility
public void Emit() { }
}
[Obsolete]
public struct ModVersionStruct : IEntityComponent
{
public uint version;
}
[Obsolete]
public class ModVersionDescriptor: SerializableEntityDescriptor<ModVersionDescriptor._ModVersionDescriptor>
{
[HashName("GamecraftModdingAPIVersionV0")]