![]() |
Flecs v4.1
A fast entity component system (ECS) for C & C++
|
Used with ecs_unit_init(). More...
#include <meta.h>
Public Attributes | |
| ecs_entity_t | entity |
| Existing entity to associate with unit (optional). | |
| const char * | symbol |
| Unit symbol, e.g., "m", "%", "g". | |
| ecs_entity_t | quantity |
| Unit quantity, e.g., distance, percentage, weight. | |
| ecs_entity_t | base |
| Base unit, e.g., "meters" (optional). | |
| ecs_entity_t | over |
| Over unit, e.g., "per second" (optional). | |
| ecs_unit_translation_t | translation |
| Translation to apply to derived unit (optional). | |
| ecs_entity_t | prefix |
| Prefix indicating order of magnitude relative to the derived unit. | |
Used with ecs_unit_init().
| ecs_entity_t ecs_unit_desc_t::base |
| ecs_entity_t ecs_unit_desc_t::entity |
| ecs_entity_t ecs_unit_desc_t::over |
| ecs_entity_t ecs_unit_desc_t::prefix |
Prefix indicating order of magnitude relative to the derived unit.
If set together with "translation", the values must match. If translation is not set, setting prefix will auto-populate it. Additionally, setting the prefix will enforce that the symbol (if set) is consistent with the prefix symbol + symbol of the derived unit. If the symbol is not set, it will be auto-populated.
| ecs_entity_t ecs_unit_desc_t::quantity |
| const char* ecs_unit_desc_t::symbol |
| ecs_unit_translation_t ecs_unit_desc_t::translation |