Пример #1
0
        public void AfterTest()
        {
            _heldItem  = null;
            _character = null;

            GameInstance.ClearGameInstance();
        }
 public void AfterTest()
 {
     _rigidbody       = null;
     _heldItem        = null;
     _interactionZone = null;
     _holdable        = null;
 }
        public void AfterTest()
        {
            _pushPoint = null;
            _pushable  = null;

            _heldItem           = null;
            _actionStateMachine = null;
        }
Пример #4
0
        public void AfterTest()
        {
            _deadActionState = null;

            _heldItem     = null;
            _stamina      = null;
            _playerBinder = null;

            GameModeComponent.RegisteredGameMode = null;
        }
        public void BeforeTest()
        {
            _actionStateMachine = new GameObject().AddComponent <MockActionStateMachineComponent>();
            _heldItem           = _actionStateMachine.gameObject.AddComponent <MockHeldItemComponent>();

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

            _pushPoint.PushableObject = _pushable;
        }
        public void BeforeTest()
        {
            _holdable                 = new GameObject().AddComponent <TestHoldableItemComponent>();
            _interactionZone          = new GameObject();
            _holdable.InteractionZone = _interactionZone;
            _heldItem                 = new GameObject().AddComponent <MockHeldItemComponent>();

            _heldItem.GetHeldItemSocketResult = _interactionZone.transform;

            _rigidbody = _holdable.gameObject.AddComponent <Rigidbody>();
        }
Пример #7
0
        public void AfterTest()
        {
            _target = null;

            _weapon   = null;
            _holdable = null;

            _attack.TestDestroy();

            _attack   = null;
            _heldItem = null;
        }
        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;
        }
Пример #9
0
        public void BeforeTest()
        {
            _heldItem = new GameObject().AddComponent <MockHeldItemComponent>();
            _attack   = _heldItem.gameObject.AddComponent <TestAttackComponent>();

            _attack.TestStart();

            _holdable = new GameObject().AddComponent <MockHoldableComponent>();
            _holdable.GetHoldableObjectResult = _holdable.gameObject;
            _weapon = _holdable.gameObject.AddComponent <MockWeaponComponent>();

            _target = new GameObject();
        }
        public void BeforeTest()
        {
            _holdable                     = new GameObject().AddComponent <TestHoldableWeaponComponent>();
            _interactionZone              = new GameObject();
            _holdable.InteractionZone     = _interactionZone;
            _holdable.AttackRadiusSquared = 100.0f;
            _heldItem                     = new GameObject().AddComponent <MockHeldItemComponent>();

            _heldItem.GetHeldItemSocketResult = _interactionZone.transform;

            _rigidbody = _holdable.gameObject.AddComponent <Rigidbody>();

            _target = new GameObject();
        }
Пример #11
0
        public void BeforeTest()
        {
            var instance = new GameObject().AddComponent <MockInputComponent>();

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

            var prefabObject = new GameObject();

            prefabObject.AddComponent <MockActionStateMachineComponent>();
            prefabObject.AddComponent <MockInputBinderComponent>();
            _character = prefabObject.AddComponent <TestCharacterComponent>();
            _character.TestStart();

            _heldItem = _character.gameObject.AddComponent <MockHeldItemComponent>();
        }
Пример #12
0
        public void BeforeTest()
        {
            var gameMode = new GameObject();

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

            GameModeComponent.RegisteredGameMode = gameMode.AddComponent <TestGameModeComponent>();

            var player = new GameObject();

            player.AddComponent <TestUnityMessageEventDispatcherComponent>().TestAwake();
            _playerBinder = player.AddComponent <MockInputBinderComponent>();
            _stamina      = player.AddComponent <MockStaminaComponent>();
            _heldItem     = player.AddComponent <MockHeldItemComponent>();
            _params       = new DeadActionStateParams {
                CanRespawn = true
            };
        }
Пример #13
0
 public void AfterTest()
 {
     _camera   = null;
     _movement = null;
     _heldItem = null;
 }
Пример #14
0
 public void BeforeTest()
 {
     _movement = new GameObject().AddComponent <MockMovementComponent>();
     _camera   = _movement.gameObject.AddComponent <MockPlayerCameraComponent>();
     _heldItem = _movement.gameObject.AddComponent <MockHeldItemComponent>();
 }