예제 #1
0
        //physicScheduler -> earlyScheduler -> updateScheduler -> coroutineScheduler -> lateScheduler

        internal static void KillSchedulers()
        {
            if (_multiThreadScheduler != null && multiThreadScheduler.isKilled == false)
            {
                _multiThreadScheduler.Dispose();
            }
            _multiThreadScheduler = null;

#if UNITY_5 || UNITY_5_3_OR_NEWER && later
            if (_coroutineScheduler != null)
            {
                _coroutineScheduler.Dispose();
            }
            if (_physicScheduler != null)
            {
                _physicScheduler.Dispose();
            }
            if (_lateScheduler != null)
            {
                _lateScheduler.Dispose();
            }
            if (_updateScheduler != null)
            {
                _updateScheduler.Dispose();
            }

            _coroutineScheduler = null;
            _physicScheduler    = null;
            _lateScheduler      = null;
            _updateScheduler    = null;
            _earlyScheduler     = null;
#endif
        }
예제 #2
0
 static StandardSchedulers()
 {
     mainThreadScheduler  = new MonoRunner();
     syncScheduler        = new SyncRunner();
     multiThreadScheduler = new MultiThreadRunner();
     physicScheduler      = new PhysicMonoRunner();
 }
예제 #3
0
        //physicScheduler -> updateScheduler -> coroutineScheduler -> lateScheduler

        static StandardSchedulers()
        {
            syncScheduler        = new SyncRunner(false);
            multiThreadScheduler = new MultiThreadRunner("MultiThreadRunner", true);
#if UNITY_5 || UNITY_5_3_OR_NEWER
            coroutineScheduler = new CoroutineMonoRunner("StandardCoroutineRunner");
            physicScheduler    = new PhysicMonoRunner("StandardPhysicRunner");
            lateScheduler      = new LateMonoRunner("StandardLateRunner");
            updateScheduler    = new UpdateMonoRunner("StandardMonoRunner");
#endif
        }