Skip to content

v0.4.0-preview.2

Pre-release
Pre-release

Choose a tag to compare

@github-actions github-actions released this 28 Oct 16:15
· 32 commits to main since this release

Added

  • Grids for deterministic hosts: Grid.CreateSearch returns a non-generic resumable GridSearch (TryBegin, Step, CopyPath, byte-exact SaveState/RestoreState, allocation-free on the specialised engine) that returns the path FindPath returns; GridReplanner.TryReplan/CopyPath (no allocation); AStar.TryBegin, Topology, Start, Goal; Grid.ContentHash; Grid.TryFindNearestWalkable, CanFit, MaxAgentSizeAt; Grid.TryGetFixedCost (Q31.32) and GridPath.TryGetStepCounts; options SpecializedEngines (force the generic engine so tier-1 and tier-2 A* break ties alike) and NearestRadius. Documented in docs/grids.md and docs/grids-state.md (state kind 12).
  • Crowd state without allocation: Crowd.StateHash() (FNV-1a 64 of the snapshot bytes), Crowd.GetStateSize() and Crowd.TrySaveState(Span<byte>, out int) write the same OPCS v1 bytes as SaveState() into caller memory; RestoreState restores the same agents without allocating (followers and corridors are read in place, so a held Agent.Path stays valid). Documented in docs/crowds.md.

Changed

  • The run-time tile cache is no longer experimental: the [Experimental] marker is removed from TileCache, TileObstacle, ObstacleShape, Mesh3DPipeline.Build*Cached and Mesh3DPipeline.Obstacles. An obstacle add-and-remove cycle now measures 0.78-0.93 (x64) and 0.68-0.91 (arm64) of DetourTileCache's time on the city and terraces levels. Rebuilds repair the contours of the changed layer instead of redoing them, and the result is byte-identical to a fresh build of the same state.

Fixed

  • A crowd whose settings (speed, horizon, wall clearance) were huge but valid, for example restored from a saved state, could ask the wall query for a radius beyond its limit; the radius is now bounded.
  • Restoring a sliced search whose open list named a node the search never reached is now a GridStateException (it would have popped the node with stale parent links, and PathLength could loop). A state saved before Begin restores as NotStarted; check Status before Step.
  • Restoring a sliced search (AStar, jump point, Theta*, graph A*) from a state that claimed found with a goal the search never closed could be accepted and then hang in PathLength/CopyPath by following leftover parent links in a loop; it is now a GridStateException.