Struct NativeListWrapper<TSeg>
Wrapper struct to allow SSFA.GetDirection to be used in native context. NativeList does not implement IReadOnlyList or some other interface that provides a read only indexer and Length, so wrapping a NativeList containing the path within this struct allows for using the same code for the managed version as well as on a raw NativeList.
Namespace: AnyPath.Native
Assembly: AnyPath.dll
Syntax
public struct NativeListWrapper<TSeg> where TSeg : unmanaged
Type Parameters
| Name | Description |
|---|---|
| TSeg | The type of path segment. Currently this is only used for UnrolledNavMeshGraphPortal |
Remarks
The same pattern can be used for DynamicBuffer if you use ECS. The code is provided but needs to be uncommented in NativeListWraper.cs