Example #1
0
        public void AfterTest()
        {
            _goal = null;

            _otherSpecies = null;
            _species      = null;

            _ownerSpecies = null;
            _pathfinding  = null;

            _wildlifeService = null;
            _params          = null;
        }
Example #2
0
        public void BeforeTest()
        {
            _params = new FollowTargetGoalParams {
                ValidTargetDesirability = 1.0f, LoseFollowRadiusSquared = 2000.0f, FollowRadius = 10.0f
            };
            _wildlifeService = new MockWildlifeService();

            var owner = new GameObject();

            _pathfinding  = owner.AddComponent <MockPathfindingComponent>();
            _ownerSpecies = owner.AddComponent <MockSpeciesComponent>();

            _species      = new GameObject().AddComponent <MockSpeciesComponent>();
            _otherSpecies = new GameObject().AddComponent <MockSpeciesComponent>();

            _goal = new FollowTargetGoal(owner, _params, _wildlifeService);
        }