Exemple #1
0
        public IIOSystem CreatIoSystemFactory(IOSystemType currentIOType)
        {
            IOSystem.IOSystemFactory ioSystemFactory = new IOSystem.IOSystemFactory();
            IIOSystem currentIoSystem = ioSystemFactory.GetIOSystem(currentIOType);

            currentIoSystem.IOSystemActions = IOActions;
            return(currentIoSystem);
        }
Exemple #2
0
        static void Main(string[] args)
        {
            var dataRogueGame = new DataRogueGame();

            IIOSystem ioSystem = BLTTilesConfig.GetBLTTilesIOSystem();

            var additionalComponents = typeof(Program).Assembly.GetTypes().Where(t => t.IsAssignableFrom(typeof(IEntityComponent))).ToList();

            dataRogueGame.Run("SEED_DEBUG", GameRules.Rules, ioSystem, null, additionalComponents);
        }
Exemple #3
0
    // Start is called before the first frame update
    void Start()
    {
        if (IOConfiguration == null)
        {
            throw new InvalidOperationException("No IO Config");
        }

        Debug.Log("CurrentIoSystemType :" + CurrentIoSystemType);

        currentIOSystem = IOConfiguration.CreatIoSystemFactory(CurrentIoSystemType);

        Debug.Log("CurrentIoSystemType :" + currentIOSystem.CurrentIOSystemType);

        currentIOSystem.Init();
    }
Exemple #4
0
        public void Run(string seed, List <Type> eventRules, IIOSystem ioSystem = null, EntityDataProviders entityDataProviders = null, IList <Type> additionalComponentTypes = null)
        {
            Seed = seed;

            IOSystem            = ioSystem ?? new RLNetConsoleIOSystem(RLNetConsoleIOSystem.DefaultConfiguration);
            entityDataProviders = entityDataProviders ?? EntityDataProviders.Default;

            InitialiseIOSystem(entityDataProviders);

            CreateAndRegisterSystems(entityDataProviders, additionalComponentTypes, IOSystem.Renderer, seed, IOSystem.Configuration);

            InitialiseState();

            StartDataLoad(eventRules);

            RunRootConsole(ioSystem);
        }
Exemple #5
0
 private void RunRootConsole(IIOSystem ioSystem)
 {
     ioSystem.Run();
 }