A stable modding interface between Techblox and mods https://mod.exmods.org/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
1.2KB

  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using Svelto.ECS;
  7. namespace GamecraftModdingAPI.Events
  8. {
  9. /// <summary>
  10. /// Engine interface to create a ModEventEntityStruct in entitiesDB when Emit() is called.
  11. /// </summary>
  12. public interface IEventEmitterEngine : IEngine, IQueryingEntitiesEngine, IDisposable
  13. {
  14. /// <summary>
  15. /// The name of the IEventEmitterEngine
  16. /// </summary>
  17. string Name { get; }
  18. /// <summary>
  19. /// The type of event emitted
  20. /// </summary>
  21. object type { get; }
  22. /// <summary>
  23. /// Whether the emitter can be removed with Manager.RemoveEventEmitter(name)
  24. /// </summary>
  25. bool isRemovable { get; }
  26. /// <summary>
  27. /// The EntityFactory for the entitiesDB.
  28. /// Use this to create a ModEventEntityStruct when Emit() is called.
  29. /// </summary>
  30. IEntityFactory Factory { set; }
  31. /// <summary>
  32. /// Emit the event so IEventHandlerEngines can handle it.
  33. /// Call Emit() to trigger the IEventEmitterEngine's event.
  34. /// </summary>
  35. void Emit();
  36. }
  37. }