Class SmolVert
One MLIQ liquid vertex (8 bytes). The byte layout is fixed but its interpretation depends on the group's liquid type: water/ocean read the named flow fields; magma/slime reinterpret the first four bytes as two int16 texture coordinates (s, t) — use as_magma()/set_magma() for that reading. Both are 8 bytes, so round-trip is layout-agnostic — pick the reading from the group's liquid type.
public class SmolVert : IDisposable
- Inheritance
-
SmolVert
- Implements
- Inherited Members
Constructors
SmolVert()
public SmolVert()
SmolVert(byte, byte, byte, byte, float)
public SmolVert(byte flow1, byte flow2, byte flow1Pct, byte filler, float height)
Parameters
SmolVert(SmolVert)
Copy-construct: a deep copy of other (the C++ copy constructor).
public SmolVert(SmolVert other)
Parameters
otherSmolVert
Properties
Filler
Water: filler. Magma/slime: high byte of int16 t.
public byte Filler { get; set; }
Property Value
Flow1
Water: flow velocity 1. Magma/slime: low byte of int16 s.
public byte Flow1 { get; set; }
Property Value
Flow1Pct
Water: flow-1 percentage. Magma/slime: low byte of int16 t.
public byte Flow1Pct { get; set; }
Property Value
Flow2
Water: flow velocity 2. Magma/slime: high byte of int16 s.
public byte Flow2 { get; set; }
Property Value
Height
Liquid surface height at this vertex.
public float Height { get; set; }
Property Value
Methods
AsMagma()
Reinterpret this vertex under the magma/slime reading (int16 s, t texcoords). A pure byte reinterpretation; use it only when the group's liquid type is magma or slime.
public SmomVert AsMagma()
Returns
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()
SetMagma(SmomVert)
Overwrite this vertex's bytes from a magma/slime reading.
public void SetMagma(SmomVert magma)
Parameters
magmaSmomVert