Behavior Designer + Core Game Kit ("GetRemainingDistance" Error)

Im working on making rounds with enemies that have Behavior Designer and Opsive UCC as controller and Core GameKit as Wave Manager.

Everything is working fine with UCC until i add PoolBoss.


Im getting a Warning from PoolBoss saying: Failed to create agent because it is not close enough to the NavMesh

Followed by an UltimateCharacterController Error saying: "GetRemainingDistance can only be called on an active agent that has been placed on a NavMesh."


I made a quick video showing my error:


I downloaded the Behavior Designer + Core GameKit integration but have no idea how to implement the "Is in Pool" logic on my zombie agent.

Any help would really help :D
 
It looks like when PoolBoss is spawning the object it is not spawning it near the navmesh so that's why you get the error.
 
Fixed it! I can now use PoolBoss and UCC and Behavior Designer with no issues

Error was on this c# script: NavMeshAgentMovement.cs

This function:
Code:
/// <summary>
        /// Ensure the move direction is valid.
        /// </summary>
        public override void ApplyPosition()
        {
            if (!m_NavMeshAgent.isOnNavMesh)
                return;


            if (m_NavMeshAgent.remainingDistance < m_NavMeshAgent.stoppingDistance) {
                // Prevent the character from jittering back and forth to land precisely on the target.
                var direction = m_Transform.InverseTransformPoint(m_NavMeshAgent.destination);
                var moveDirection = m_Transform.InverseTransformDirection(m_CharacterLocomotion.MoveDirection);
                if (Mathf.Abs(moveDirection.x) > Mathf.Abs(direction.x)) {
                    moveDirection.x = direction.x;
                }
                if (Mathf.Abs(moveDirection.z) > Mathf.Abs(direction.z)) {
                    moveDirection.z = direction.z;
                }
                m_CharacterLocomotion.MoveDirection = m_Transform.TransformDirection(moveDirection);
            }
            m_NavMeshAgent.nextPosition = m_Transform.position + m_CharacterLocomotion.MoveDirection;
        }

I just had to add this line in the start to stop the error from overloading the game memory:

Code:
if (!m_NavMeshAgent.isOnNavMesh)
                return;

Hop this helps anyone trying to figure this one out!

Notice: Error occurs when you use PoolBoss with Gaia Pro terrains!
 
Top