dao::world::ModelBox
struct
A creature model’s bounding box, the one the game uses for drawing.
The box is in model space, relative to the point where the model stands, unscaled and unrotated. It comes from the model’s rest pose and is made once, so it does not change as the creature animates: a person’s box has the arms held out, and a winged creature’s includes the spread wings. The model’s widest horizontal extent is the larger of Size().x and Size().y.
Declared in dao/World.h.
Functions
Size()
Vector Size() const
Returns the box’s size in metres as drawn: (max - min) times the scale.
Fields
| Field | Type | |
|---|---|---|
max |
Vector |
|
min |
Vector |
model space: x and y horizontal, z up from where the model stands |
scale |
float = 1 |
the model’s uniform scale |
worldMax |
Vector |
|
worldMin |
Vector |
The game’s own world-space corners: min and max moved by the model’s position, rotation and scale. They rotate with the model, so they are not the corners of an axis-aligned box unless the model faces along an axis. |