public InputController(PlayerBase player) { _playerBase = player; _saveDataRepository = new SaveDataRepository(); _repository = new Repository(); new ControllerTest1(_repository); new ControllerTest2(_repository); }
private void Awake() { Instance = this; MainCamera = Camera.main; Player = GameObject.FindGameObjectWithTag("Player").transform; SaveDataRepository = new SaveDataRepository(); PhotoController = new PhotoController(); PlayerController = new PlayerController(new UnitMotor( GameObject.FindObjectOfType <CharacterController>().transform)); InputController = new InputController(); _controllers = new IOnUpdate[2]; _controllers[0] = InputController; _controllers[1] = PlayerController; }