Пример #1
0
        public void ChangeDayOfNight(DaySettingsDatabase daySettingsDatabase)
        {
            int day = daySettingsDatabase.DayLength * daySettingsDatabase.HourLength;

            _timeOfDay += Time.deltaTime / day;
            //  if (_timeOfDay >= 360) _timeOfDay = 0;

            _sun.transform.localRotation = Quaternion.Euler(70f, 180, 0);
        }
Пример #2
0
        public DayCounterController(DaySettingsDatabase daySettingsDatabase,
                                    DayCounterPresenter dayCounterPresenter,
                                    IDayModel dayModel,
                                    HourController hourController,
                                    SunView sunView,
                                    SunPrefabFactory sunFactory)
        {
            _daySettingsDatabase = daySettingsDatabase;
            _dayCounterPresenter = dayCounterPresenter;

            _dayModel       = dayModel;
            _hourController = hourController;
            _sunFactory     = sunFactory;
            _sunView        = sunView;
        }
Пример #3
0
 public HourController(DaySettingsDatabase daySettingsDatabase, IDayModel dayModel)
 {
     _daySettingsDatabase = daySettingsDatabase;
     _dayModel            = dayModel;
 }