|
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using Svelto.ECS;
- using GamecraftModdingAPI.Utility;
-
- namespace GamecraftModdingAPI.Events
- {
- class SimpleEventEmitterEngine : IEventEmitterEngine
- {
- public string Name { get; set; }
- public object type { get; set; }
-
- public IEntityFactory Factory { private get; set; }
-
- public IEntitiesDB entitiesDB { set; private get; }
-
- public void Ready() { }
-
- public void Emit()
- {
- Factory.BuildEntity<ModEventEntityDescriptor>(ApiExclusiveGroups.eventID++, ApiExclusiveGroups.eventsExclusiveGroup)
- .Init(new ModEventEntityStruct
- {
- type = type
- });
- }
-
- public SimpleEventEmitterEngine(EventType type, string name)
- {
- this.type = type;
- this.Name = name;
- }
-
- public SimpleEventEmitterEngine(object type, string name)
- {
- this.type = type;
- this.Name = name;
- }
- }
- }
|