< Summary

Information
Class: Trailblazer.Pathing.NavigationGraphCellState
Assembly: Trailblazer
File(s): /home/runner/work/Trailblazer/Trailblazer/src/Trailblazer/Pathing/Graph/NavigationGraphCellState.cs
Line coverage
100%
Covered lines: 12
Uncovered lines: 0
Coverable lines: 12
Total lines: 50
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)100%11100%
get_IsBlocked()100%11100%

File(s)

/home/runner/work/Trailblazer/Trailblazer/src/Trailblazer/Pathing/Graph/NavigationGraphCellState.cs

#LineLine coverage
 1//=======================================================================
 2// NavigationGraphCellState.cs
 3//=======================================================================
 4// MIT License, Copyright (c) 2024-present David Oravsky (mrdav30)
 5// See LICENSE file in the project root for full license information.
 6//=======================================================================
 7
 8using GridForge.Spatial;
 9
 10namespace Trailblazer.Pathing;
 11
 12/// <summary>Copies one composed graph cell state for tests and bounded diagnostics.</summary>
 13internal readonly struct NavigationGraphCellState
 14{
 15    internal NavigationGraphCellState(
 16        string mapId,
 17        VoxelIndex index,
 18        int slot,
 19        bool isDynamic,
 20        bool hasCell,
 21        NavigationCell cell,
 22        bool isMaterialized,
 23        bool isPresent,
 24        byte obstacleCount,
 25        long gridSpawnToken)
 26    {
 35927        MapId = mapId;
 35928        Index = index;
 35929        Slot = slot;
 35930        IsDynamic = isDynamic;
 35931        HasCell = hasCell;
 35932        Cell = cell;
 35933        IsMaterialized = isMaterialized;
 35934        IsPresent = isPresent;
 35935        ObstacleCount = obstacleCount;
 35936        GridSpawnToken = gridSpawnToken;
 35937    }
 38
 39    internal string MapId { get; }
 40    internal VoxelIndex Index { get; }
 41    internal int Slot { get; }
 42    internal bool IsDynamic { get; }
 43    internal bool HasCell { get; }
 44    internal NavigationCell Cell { get; }
 45    internal bool IsMaterialized { get; }
 46    internal bool IsPresent { get; }
 447    internal bool IsBlocked => ObstacleCount > 0;
 48    internal byte ObstacleCount { get; }
 49    internal long GridSpawnToken { get; }
 50}