EntityTransform.h file
Classes
- struct TransformField
- A float field of an entity, found by name: its value now, and how a FieldEdit addresses it.
- struct EntityTransform
Functions
- auto FindFloatField(Archetype* arch, void** fieldArrayTable, const char* name, uint32_t localIndex) -> TransformField
- A float field (Float32 or Fixed32) by its reflected name, in an archetype's field array table.
- auto FindAnyField(Archetype* arch, void** fieldArrayTable, const char* name, uint32_t localIndex, size_t elementSize) -> const void*
- A field of any type by name, for reading only.
- void ClearPosition(JsonValue& entity)
- void RotateByQuat(const float q[4], const float v[3], float out[3])
- Rotate
vby the unit quaternionq(x, y, z, w). - void MultiplyQuat(const float b[4], const float a[4], float out[4])
athenb:the quaternion b * a.
Function documentation
void ClearPosition(JsonValue& entity)
Take the position out of an entity's saved form ({"components": {...}}). A prefab is placed where it is spawned, so it is kept centred: rotation and scale stay, the scene offset goes.