wowlib 0.0.0
Read & write World of Warcraft client files — a C++26 core
Loading...
Searching...
No Matches
records.hpp
Go to the documentation of this file.
1#pragma once
2
5
6#include <array>
7#include <cstdint>
8
9#include <welder/vocabulary.hpp>
10
12
14 struct [[
15 =welder::weld,
16 =welder::doc("One volumetric fog (VFOG, 8.0+).")
18 [[=welder::doc("Fog color as r, g, b floats; 1.0 equals 255.")]]
21 [[=welder::doc("Radius-related intensities.")]]
22 std::array<float, 3> intensity{};
24 [[=welder::doc("Unknown; 0 to 5000 in shipped files.")]]
25 float unk18 = 0;
27 [[=welder::doc("Position, in server coordinates.")]]
30 [[=welder::doc("Unknown; 0 in files, set to 1.0 on loading.")]]
31 float unk28 = 0;
33 [[=welder::doc("Rotation quaternion.")]]
36 [[=welder::doc("Fog start radii.")]]
37 std::array<float, 3> radius{};
39 [[=welder::doc(
40 "Animation periods, used to derive the animation coefficients.")]]
41 std::array<std::int32_t, 4> animationPeriods{};
42
43 [[=welder::doc("Flags.")]]
44 std::uint32_t flags = 0;
45
46 [[=welder::doc(
47 "FileDataID of the volume model (one M2Batch only); 0 falls back "
48 "to spells/errorcube.m2.")]]
49 std::uint32_t modelFdid = 0;
51 [[=welder::doc("Fog level, 0 to 2 (inclusive against the client's "
52 "volumeFogLevel setting).")]]
53 std::uint32_t fogLevel = 0;
54
55 [[=welder::doc("Globally unique fog id.")]]
56 std::uint32_t id = 0;
57 };
59 static_assert(sizeof(VolumetricFog) == 0x68);
60
61 struct [[
62 =welder::weld,
63 =welder::doc(
64 "One VFEX extension record (11.0+, format version 2): optional "
65 "extra data for a VFOG entry, matched by fog id.")
67 [[=welder::doc("Unknown; defaults to 1.")]]
68 std::uint32_t unk0 = 1;
69
70 [[=welder::doc(
71 "Unknown floats; the first three carry values, the rest are 1.")]]
72 std::array<float, 16> unk1{};
73
74 [[=welder::doc("The VFOG entry this record extends (its id field).")]]
75 std::uint32_t fogId = 0;
76
77 [[=welder::doc("Unknown; defaults to 0.")]]
78 std::array<std::uint32_t, 6> unk3{};
79 };
80
81 static_assert(sizeof(VolumetricFogExtra) == 0x60);
82}
_fogs.wdt chunk binary structs (volumetric fogs and their extensions).
Definition records.hpp:13
A 3D float vector — the workhorse: positions, normals, rotations-as-Euler-degrees in placements.
Definition types.hpp:49
One VFEX extension record (11.0+, format version 2): optional extra data for a VFOG entry,...
Definition records.hpp:56
std::uint32_t fogId
The VFOG entry this record extends (its id field).
Definition records.hpp:64
std::array< float, 16 > unk1
Unknown floats; the first three carry values, the rest are 1.
Definition records.hpp:61
std::uint32_t unk0
Unknown; defaults to 1.
Definition records.hpp:58
std::array< std::uint32_t, 6 > unk3
Unknown; defaults to 0.
Definition records.hpp:67
One volumetric fog (VFOG, 8.0+).
Definition records.hpp:15
std::array< float, 3 > intensity
Radius-related intensities.
Definition records.hpp:20
C3Vector position
Position, in server coordinates.
Definition records.hpp:26
std::array< std::int32_t, 4 > animationPeriods
Animation periods, used to derive the animation coefficients.
Definition records.hpp:38
C3Vector color
Fog color as r, g, b floats; 1.0 equals 255.
Definition records.hpp:17
std::array< float, 3 > radius
Fog start radii.
Definition records.hpp:35
std::uint32_t fogLevel
Fog level, 0 to 2 (inclusive against the client's volumeFogLevel setting).
Definition records.hpp:47
std::uint32_t modelFdid
FileDataID of the volume model (one M2Batch only); 0 falls back to spells/errorcube....
Definition records.hpp:44
float unk18
Unknown; 0 to 5000 in shipped files.
Definition records.hpp:23
float unk28
Unknown; 0 in files, set to 1.0 on loading.
Definition records.hpp:29
The binary-level math and color primitives shared across WoW file formats (wowdev....