コード例 #1
0
        public void AfterTest()
        {
            _playerCamera = null;

            _characterComponent = null;
            _actionStateMachine = null;
            _inputBinder        = null;
        }
コード例 #2
0
        public void AfterTest()
        {
            _spawnable          = null;
            _actionStateMachine = null;
            _health             = null;

            _spawner = null;
        }
コード例 #3
0
        public void AfterTest()
        {
            _transformSpecies            = null;
            _species                     = null;
            _actionStateMachineComponent = null;

            _totem = null;
        }
コード例 #4
0
        public void AfterTest()
        {
            _pushPoint = null;
            _pushable  = null;

            _heldItem           = null;
            _actionStateMachine = null;
        }
コード例 #5
0
        public void BeforeTest()
        {
            _inputBinder        = new GameObject().AddComponent <MockInputBinderComponent>();
            _actionStateMachine = _inputBinder.gameObject.AddComponent <MockActionStateMachineComponent>();
            _characterComponent = _inputBinder.gameObject.AddComponent <CharacterComponent>();
            _inputBinder.gameObject.AddComponent <TestUnityMessageEventDispatcherComponent>().TestAwake();

            _characterComponent.ActiveController = _inputBinder.gameObject.AddComponent <ControllerComponent>();
            _playerCamera = _characterComponent.ActiveController.gameObject.AddComponent <MockPlayerCameraComponent>();
        }
コード例 #6
0
        public void BeforeTest()
        {
            _actionStateMachineComponent = new GameObject().AddComponent <MockActionStateMachineComponent>();

            _dispatcherComponent = _actionStateMachineComponent.gameObject
                                   .AddComponent <TestUnityMessageEventDispatcherComponent>();
            _dispatcherComponent.TestAwake();

            _healthComponent = _actionStateMachineComponent.gameObject.AddComponent <TestHealthComponent>();
        }
コード例 #7
0
        public void BeforeTest()
        {
            _actionStateMachine = new GameObject().AddComponent <MockActionStateMachineComponent>();
            _heldItem           = _actionStateMachine.gameObject.AddComponent <MockHeldItemComponent>();

            _pushable  = new GameObject();
            _pushPoint = new GameObject().AddComponent <TestPushObjectPointComponent>();

            _pushPoint.PushableObject = _pushable;
        }
コード例 #8
0
        public void BeforeTest()
        {
            _spawner = new GameObject().AddComponent <MockSpawnerComponent>();

            _health             = new GameObject().AddComponent <MockHealthComponent>();
            _actionStateMachine = _health.gameObject.AddComponent <MockActionStateMachineComponent>();
            _health.gameObject.AddComponent <TestUnityMessageEventDispatcherComponent>().TestAwake();
            _spawnable = _health.gameObject.AddComponent <TestAISpawnableComponent>();
            _spawnable.SetSpawner(_spawner);
        }
コード例 #9
0
        public void AfterTest()
        {
            GameInstance.ClearGameInstance();

            _controllerAudio = null;
            _music           = null;

            _character    = null;
            _stateMachine = null;
        }
コード例 #10
0
        public void AfterTest()
        {
            GameModeComponent.RegisteredGameMode = null;

            _actionStateMachine = null;

            _cameraTrigger.TestDestroy();

            _cameraTrigger = null;
            _camera        = null;
        }
コード例 #11
0
        public void AfterTest()
        {
            _playerUi.TestDestroy();
            _playerUi = null;

            _actionStateMachineComponent = null;

            GameInstance.ClearGameInstance();

            LocalisationManager.CurrentLocalisationInterface = null;
        }
コード例 #12
0
        public void BeforeTest()
        {
            _actionStateMachine = new GameObject().AddComponent <MockActionStateMachineComponent>();
            _heldItem           = _actionStateMachine.gameObject.AddComponent <MockHeldItemComponent>();

            _pushable    = new GameObject();
            _pushableASM = _pushable.AddComponent <MockActionStateMachineComponent>();
            _pushableASM.IsActionStateActiveResult = true;

            _pushPoint = new GameObject().AddComponent <OrganicPushObjectPointComponent>();

            _pushPoint.PushableObject = _pushable;
        }
コード例 #13
0
        public void BeforeTest()
        {
            _totem = new GameObject().AddComponent <TestTotemComponent>();

            _actionStateMachineComponent = new GameObject().AddComponent <MockActionStateMachineComponent>();
            _species = _actionStateMachineComponent.gameObject.AddComponent <MockSpeciesComponent>();

            var transformObject = new GameObject();

            _transformSpecies          = transformObject.AddComponent <MockSpeciesComponent>();
            _totem.TransformTypePrefab = transformObject;

            _totem.TestStart();
        }
コード例 #14
0
        public void AfterTest()
        {
            _actionState = null;

            _originalCamera = null;
            _controller     = null;

            _character          = null;
            _health             = null;
            _inputBinder        = null;
            _actionStateMachine = null;

            _inCamera = null;
        }
コード例 #15
0
        public void BeforeTest()
        {
            _inCamera = new GameObject().AddComponent <Camera>();

            _actionStateMachine = new GameObject().AddComponent <MockActionStateMachineComponent>();
            _inputBinder        = _actionStateMachine.gameObject.AddComponent <MockInputBinderComponent>();
            _health             = _actionStateMachine.gameObject.AddComponent <MockHealthComponent>();
            _character          = _inputBinder.gameObject.AddComponent <TestCharacterComponent>();
            _character.gameObject.AddComponent <TestUnityMessageEventDispatcherComponent>().TestAwake();

            _controller                 = new GameObject().AddComponent <TestControllerComponent>();
            _originalCamera             = _controller.gameObject.AddComponent <Camera>();
            _character.ActiveController = _controller;

            _cameraTime = 2.0f;

            _actionState = new CinematicCameraActionState(new CinematicCameraActionStateInfo(_character.gameObject, _inCamera, _cameraTime));
        }
コード例 #16
0
        public void BeforeTest()
        {
            _stateMachine = new GameObject().AddComponent <MockActionStateMachineComponent>();
            _inputBinder  = _stateMachine.gameObject.AddComponent <MockInputBinderComponent>();

            _character = _stateMachine.gameObject.AddComponent <TestCharacterComponent>();
            _music     = _character.gameObject.AddComponent <PlayerMusicComponent>();

            var controller = new GameObject().AddComponent <ControllerComponent>();

            _controllerAudio = controller.gameObject.AddComponent <AudioSource>();

            _character.ActiveController = controller;

            var instance = new GameObject();

            instance.AddComponent <MockInputComponent>();
            instance.AddComponent <TestGameInstance>().TestAwake();
        }
コード例 #17
0
        public void BeforeTest()
        {
            var locInstance = new MockLocalisationInterface
            {
                GetTextForLocalisationKeyResult = new LocalisedText(new LocalisedTextEntries())
            };

            LocalisationManager.CurrentLocalisationInterface = locInstance;

            var instance = new GameObject().AddComponent <MockInputComponent>();

            instance.gameObject.AddComponent <TestGameInstance>().TestAwake();

            var player = new GameObject();

            player.AddComponent <TestUnityMessageEventDispatcherComponent>().TestAwake();

            _actionStateMachineComponent = player.AddComponent <MockActionStateMachineComponent>();

            _playerUi = player.gameObject.AddComponent <TestPlayerUIControllerComponent>();
            _playerUi.TestStart();
        }
コード例 #18
0
        public void BeforeTest()
        {
            var gameObject = new GameObject();

            _camera        = gameObject.AddComponent <Camera>();
            _cameraTrigger = gameObject.AddComponent <TestCinematicCameraTriggerResponseComponent>();

            _cameraTrigger.TriggerObject = new GameObject();
            _cameraTrigger.TriggerObject.AddComponent <TestUnityMessageEventDispatcherComponent>().TestAwake();

            _cameraTrigger.TestStart();

            _actionStateMachine = new GameObject().AddComponent <MockActionStateMachineComponent>();

            var controller = new GameObject().AddComponent <ControllerComponent>();

            controller.SetPawn(_actionStateMachine.gameObject);

            var gameMode = new GameObject().AddComponent <TestGameModeComponent>();

            GameModeComponent.RegisteredGameMode = gameMode;

            gameMode.SetActiveController(controller);
        }
コード例 #19
0
 public void BeforeTest()
 {
     _actionStateMachine = new GameObject().AddComponent <MockActionStateMachineComponent>();
     _actionStateMachine.IsActionStateActiveResult = false;
     _attack = new GameObject().AddComponent <MockAttackComponent>();
 }
コード例 #20
0
 public void AfterTest()
 {
     _attack             = null;
     _actionStateMachine = null;
 }
コード例 #21
0
 public void AfterTest()
 {
     _dispatcherComponent         = null;
     _actionStateMachineComponent = null;
     _healthComponent             = null;
 }