Class VertexFlags
- Namespace
- Vintagestory.API.Common
- Assembly
- VintagestoryAPI.dll
Special class to handle the vertex flagging in a very nicely compressed space.
Bit 0-7: Glow level
Bit 8-10: Z-Offset
Bit 11: Reflective bit
Bit 12: Lod 0 Bit
Bit 13-24: X/Y/Z Normals
Bit 25, 26, 27, 28: Wind mode
Bit 29, 30, 31: Wind data (also sometimes used for other data, e.g. reflection mode if Reflective bit is set, or additional water surface data if this is a water block)
[JsonObject(MemberSerialization.OptIn)]
public class VertexFlags
- Inheritance
-
VertexFlags
Examples
"vertexFlagsByType": {
"metalblock-new-*": {
"reflective": true,
"windDataByType": {
"*-gold": 1,
"*": 1
}
}
},
Properties
All
Sets all the vertex flags from one integer.
[JsonProperty]
public int All { get; set; }
Property Value
GlowLevel
[JsonProperty]
public byte GlowLevel { get; set; }
Property Value
Lod0
[JsonProperty]
public bool Lod0 { get; set; }
Property Value
Normal
[JsonProperty]
public short Normal { get; set; }
Property Value
Reflective
[JsonProperty]
public bool Reflective { get; set; }
Property Value
WindData
[JsonProperty]
public byte WindData { get; set; }
Property Value
WindMode
[JsonProperty]
public EnumWindBitMode WindMode { get; set; }
Property Value
ZOffset
[JsonProperty]
public byte ZOffset { get; set; }