Table of Contents

Class MapChunkLiquid

Namespace
WoWLib.Formats.ADT
Assembly
WoWLib.dll

The liquid of one terrain cell (an MH2O chunk entry): the 8x8 fishable and deep attribute bit masks and the stacked liquid layers (instances). A cell with no liquid has no instances.

public class MapChunkLiquid : IDisposable
Inheritance
MapChunkLiquid
Implements
Inherited Members

Constructors

MapChunkLiquid()

public MapChunkLiquid()

MapChunkLiquid(ulong, ulong, bool, Vector<LiquidInstance>)

public MapChunkLiquid(ulong fishable, ulong deep, bool hasAttributes, Vector<LiquidInstance> instances)

Parameters

fishable ulong
deep ulong
hasAttributes bool
instances Vector<LiquidInstance>

MapChunkLiquid(MapChunkLiquid)

Copy-construct: a deep copy of other (the C++ copy constructor).

public MapChunkLiquid(MapChunkLiquid other)

Parameters

other MapChunkLiquid

Properties

Deep

The 8x8 deep bit mask (fatigue water); 0 when the cell omits attributes.

public ulong Deep { get; set; }

Property Value

ulong

Empty

Whether the chunk carries any liquid.

public bool Empty { get; }

Property Value

bool

Fishable

The 8x8 fishable bit mask (visibility); 0 when the cell omits attributes.

public ulong Fishable { get; set; }

Property Value

ulong

HasAttributes

Whether this cell wrote an explicit attributes block (so an all-zero mask round-trips as present rather than omitted).

public bool HasAttributes { get; set; }

Property Value

bool

Instances

The stacked liquid layers over this chunk.

public Vector<LiquidInstance> Instances { get; }

Property Value

Vector<LiquidInstance>

Methods

Dispose()

Release the native object now. Optional: the finalizer releases it on collection anyway - dispose (or using) when you want native memory back promptly.

public virtual void Dispose()

Equals(object?)

Determines whether the specified object is equal to the current object.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

GetHashCode()

Reference-identity hash (the C++ type has no hash to mirror).

public override int GetHashCode()

Returns

int

Operators

operator ==(MapChunkLiquid?, MapChunkLiquid?)

public static bool operator ==(MapChunkLiquid? l, MapChunkLiquid? r)

Parameters

l MapChunkLiquid
r MapChunkLiquid

Returns

bool

operator !=(MapChunkLiquid?, MapChunkLiquid?)

public static bool operator !=(MapChunkLiquid? l, MapChunkLiquid? r)

Parameters

l MapChunkLiquid
r MapChunkLiquid

Returns

bool