Infohazard.HyperNav 2.3.0
A pathfinding and avoidance solution for volumetric and omnidirectional navigation.
Loading...
Searching...
No Matches
Infohazard.HyperNav.NavLayerMask Struct Reference

A mask of NavLayers with one bit for each possible layer. More...

Public Member Functions

readonly bool Contains (int layer)
 Returns true if the mask contains the given layer index. More...
 
readonly Enumerator GetEnumerator ()
 Non-allocating enumerator over this mask. More...
 
IEnumerator< NavLayer > IEnumerable< NavLayer >. GetEnumerator ()
 
IEnumerator IEnumerable. GetEnumerator ()
 
readonly override string ToString ()
 
readonly bool Equals (NavLayerMask other)
 
readonly override bool Equals (object obj)
 
readonly override int GetHashCode ()
 

Static Public Member Functions

static NavLayerMask Combine (NavLayer layer1, NavLayer layer2)
 Get a mask representing the combination of two layers. More...
 
static NavLayerMask Combine (NavLayer layer1, NavLayer layer2, NavLayer layer3)
 Get a mask representing the combination of three layers. More...
 
static NavLayerMask Combine (NavLayer layer1, NavLayer layer2, NavLayer layer3, NavLayer layer4)
 Get a mask representing the combination of four layers. More...
 
static bool operator== (NavLayerMask layer1, NavLayerMask layer2)
 Equality check. More...
 
static bool operator!= (NavLayerMask layer1, NavLayerMask layer2)
 Inequality check. More...
 
static implicit operator NavLayerMask (uint value)
 Convert from uint. More...
 
static implicit operator NavLayerMask (int value)
 Convert from int. More...
 
static implicit operator uint (NavLayerMask i)
 Convert to uint. More...
 
static implicit operator int (NavLayerMask i)
 Convert to int. More...
 
static NavLayerMask operator| (NavLayerMask lhs, NavLayerMask rhs)
 Apply bitwise OR operator to two NavLayerMasks. More...
 
static NavLayerMask operator| (NavLayerMask lhs, uint rhs)
 Apply bitwise OR operator to a NavLayerMask and an unsigned integer. More...
 
static uint operator| (uint lhs, NavLayerMask rhs)
 Apply bitwise OR operator to an unsigned integer and a NavLayerMask. More...
 
static NavLayerMask operator& (NavLayerMask lhs, NavLayerMask rhs)
 Apply bitwise AND operator to two NavLayerMasks. More...
 
static NavLayerMask operator& (NavLayerMask lhs, uint rhs)
 Apply bitwise AND operator to a NavLayerMask and an unsigned integer. More...
 
static uint operator& (uint lhs, NavLayerMask rhs)
 Apply bitwise AND operator to an unsigned integer and a NavLayerMask. More...
 
static NavLayerMask operator^ (NavLayerMask lhs, NavLayerMask rhs)
 Apply bitwise XOR operator to two NavLayerMasks. More...
 
static NavLayerMask operator^ (NavLayerMask lhs, uint rhs)
 Apply bitwise XOR operator to a NavLayerMask and an unsigned integer. More...
 
static uint operator^ (uint lhs, NavLayerMask rhs)
 Apply bitwise XOR operator to an unsigned integer and a NavLayerMask. More...
 
static NavLayerMask operator~ (NavLayerMask lhs)
 Invert a NavLayerMask. More...
 

Static Public Attributes

static readonly NavLayerMask None = new(0)
 A mask that represents no layers. More...
 
static readonly NavLayerMask All = new(0xFFFFFFFF)
 A mask that represents all possible layers. More...
 

Properties

readonly bool IsEmpty [get]
 Whether this mask is empty. More...
 

Detailed Description

A mask of NavLayers with one bit for each possible layer.

Member Function Documentation

◆ Combine() [1/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.Combine ( NavLayer  layer1,
NavLayer  layer2 
)
static

Get a mask representing the combination of two layers.

◆ Combine() [2/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.Combine ( NavLayer  layer1,
NavLayer  layer2,
NavLayer  layer3 
)
static

Get a mask representing the combination of three layers.

◆ Combine() [3/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.Combine ( NavLayer  layer1,
NavLayer  layer2,
NavLayer  layer3,
NavLayer  layer4 
)
static

Get a mask representing the combination of four layers.

◆ Contains()

readonly bool Infohazard.HyperNav.NavLayerMask.Contains ( int  layer)

Returns true if the mask contains the given layer index.

Parameters
layerThe index of the layer to check.
Returns
Whether the mask contains that value.

◆ Equals() [1/2]

readonly bool Infohazard.HyperNav.NavLayerMask.Equals ( NavLayerMask  other)

◆ Equals() [2/2]

readonly override bool Infohazard.HyperNav.NavLayerMask.Equals ( object  obj)

◆ GetEnumerator() [1/3]

readonly Enumerator Infohazard.HyperNav.NavLayerMask.GetEnumerator ( )

Non-allocating enumerator over this mask.

◆ GetEnumerator() [2/3]

IEnumerator< NavLayer > IEnumerable< NavLayer >. Infohazard.HyperNav.NavLayerMask.GetEnumerator ( )

◆ GetEnumerator() [3/3]

IEnumerator IEnumerable. Infohazard.HyperNav.NavLayerMask.GetEnumerator ( )

◆ GetHashCode()

readonly override int Infohazard.HyperNav.NavLayerMask.GetHashCode ( )

◆ operator int()

static implicit Infohazard.HyperNav.NavLayerMask.operator int ( NavLayerMask  i)
static

Convert to int.

◆ operator NavLayerMask() [1/2]

static implicit Infohazard.HyperNav.NavLayerMask.operator NavLayerMask ( int  value)
static

Convert from int.

◆ operator NavLayerMask() [2/2]

static implicit Infohazard.HyperNav.NavLayerMask.operator NavLayerMask ( uint  value)
static

Convert from uint.

◆ operator uint()

static implicit Infohazard.HyperNav.NavLayerMask.operator uint ( NavLayerMask  i)
static

Convert to uint.

◆ operator!=()

static bool Infohazard.HyperNav.NavLayerMask.operator!= ( NavLayerMask  layer1,
NavLayerMask  layer2 
)
static

Inequality check.

◆ operator&() [1/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.operator& ( NavLayerMask  lhs,
NavLayerMask  rhs 
)
static

Apply bitwise AND operator to two NavLayerMasks.

◆ operator&() [2/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.operator& ( NavLayerMask  lhs,
uint  rhs 
)
static

Apply bitwise AND operator to a NavLayerMask and an unsigned integer.

◆ operator&() [3/3]

static uint Infohazard.HyperNav.NavLayerMask.operator& ( uint  lhs,
NavLayerMask  rhs 
)
static

Apply bitwise AND operator to an unsigned integer and a NavLayerMask.

◆ operator==()

static bool Infohazard.HyperNav.NavLayerMask.operator== ( NavLayerMask  layer1,
NavLayerMask  layer2 
)
static

Equality check.

◆ operator^() [1/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.operator^ ( NavLayerMask  lhs,
NavLayerMask  rhs 
)
static

Apply bitwise XOR operator to two NavLayerMasks.

◆ operator^() [2/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.operator^ ( NavLayerMask  lhs,
uint  rhs 
)
static

Apply bitwise XOR operator to a NavLayerMask and an unsigned integer.

◆ operator^() [3/3]

static uint Infohazard.HyperNav.NavLayerMask.operator^ ( uint  lhs,
NavLayerMask  rhs 
)
static

Apply bitwise XOR operator to an unsigned integer and a NavLayerMask.

◆ operator|() [1/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.operator| ( NavLayerMask  lhs,
NavLayerMask  rhs 
)
static

Apply bitwise OR operator to two NavLayerMasks.

◆ operator|() [2/3]

static NavLayerMask Infohazard.HyperNav.NavLayerMask.operator| ( NavLayerMask  lhs,
uint  rhs 
)
static

Apply bitwise OR operator to a NavLayerMask and an unsigned integer.

◆ operator|() [3/3]

static uint Infohazard.HyperNav.NavLayerMask.operator| ( uint  lhs,
NavLayerMask  rhs 
)
static

Apply bitwise OR operator to an unsigned integer and a NavLayerMask.

◆ operator~()

static NavLayerMask Infohazard.HyperNav.NavLayerMask.operator~ ( NavLayerMask  lhs)
static

Invert a NavLayerMask.

◆ ToString()

readonly override string Infohazard.HyperNav.NavLayerMask.ToString ( )

Member Data Documentation

◆ All

readonly NavLayerMask Infohazard.HyperNav.NavLayerMask.All = new(0xFFFFFFFF)
static

A mask that represents all possible layers.

◆ None

readonly NavLayerMask Infohazard.HyperNav.NavLayerMask.None = new(0)
static

A mask that represents no layers.

Property Documentation

◆ IsEmpty

readonly bool Infohazard.HyperNav.NavLayerMask.IsEmpty
get

Whether this mask is empty.


The documentation for this struct was generated from the following file: