You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I’m encountering an issue with generating a DtDynamicNavMesh in DotRecast, particularly when placing colliders at the boundaries between tiles. I’ve been testing this using the RcDynamicUpdateTool.cs from the Recast.Demo project, specifically with the box collider generation function. Below is the code I’m using for the collider creation:
public RcGizmo BoxCollider(RcVec3f p, float walkableClimb)
{
RcVec3f extent = new RcVec3f(
25.0f * 2,
25.0f * 2,
25.0f * 2
);
RcVec3f forward = RcVec3f.UnitX;
RcVec3f up = RcVec3f.UnitY;
RcVec3f[] halfEdges = Detour.Dynamic.Colliders.DtBoxCollider.GetHalfEdges(up, forward, extent);
var collider = new DtBoxCollider(p, halfEdges, SampleAreaModifications.SAMPLE_POLYAREA_TYPE_WATER, walkableClimb);
var gizmo = RcGizmoFactory.Box(p, halfEdges);
return new RcGizmo(collider, gizmo);
}
I’m using the following settings:
public class RcNavMeshBuildSettings
{
public float cellSize = 19.0f;
public float cellHeight = 25.0f;
public float agentHeight = 144.0f;
public float agentRadius = 35.0f;
public float agentMaxClimb = 49.0f;
public float agentMaxSlope = 60.0f;
public float agentMaxAcceleration = 800.0f;
public float agentMaxSpeed = 600.0f;
public int minRegionSize = 0;
public int mergedRegionSize = 20;
public int partitioning = RcPartitionType.WATERSHED.Value;
public bool filterLowHangingObstacles = true;
public bool filterLedgeSpans = true;
public bool filterWalkableLowHeightSpans = true;
public float edgeMaxLen = 12.0f;
public float edgeMaxError = 1.3f;
public int vertsPerPoly = 6;
public float detailSampleDist = 6.0f;
public float detailSampleMaxError = 1.0f;
public bool tiled = true;
public int tileSize = 150;
}
When using these settings, the NavMesh fails to generate correctly at the tile boundaries where the box colliders are placed. The colliders on these boundaries are either not being processed correctly, resulting in gaps or incomplete navigation data at the borders. I’ve tried adjusting various parameters like tile size and collider extents, but the problem persists.
Could you provide guidance on how to resolve this issue so that colliders at tile boundaries are correctly integrated into the DtDynamicNavMesh generation?
Thank you for your help!
The text was updated successfully, but these errors were encountered:
First, I apologize.
I've been busy and couldn't pay attention to this. @ppiastucki from recast4j has made the correction, and I've ported it as is.
Thank you once again for reporting this!
Hello,
I’m encountering an issue with generating a DtDynamicNavMesh in DotRecast, particularly when placing colliders at the boundaries between tiles. I’ve been testing this using the RcDynamicUpdateTool.cs from the Recast.Demo project, specifically with the box collider generation function. Below is the code I’m using for the collider creation:
I’m using the following settings:
When using these settings, the NavMesh fails to generate correctly at the tile boundaries where the box colliders are placed. The colliders on these boundaries are either not being processed correctly, resulting in gaps or incomplete navigation data at the borders. I’ve tried adjusting various parameters like tile size and collider extents, but the problem persists.
Could you provide guidance on how to resolve this issue so that colliders at tile boundaries are correctly integrated into the DtDynamicNavMesh generation?
Thank you for your help!
The text was updated successfully, but these errors were encountered: