QcMobTraitsContent Namespace
Checks the traits of creatures (decision E-460) when the content is finished. More...
| Header: | #include <common/content/mobs/QcMobTraitsContent.h> |
Classes
Functions
| QStringList | checkStructurePets(const QcContentRegistry &content) |
| QcMobTraitsContent::Resolved | resolve(const QcContentRegistry &content, const QcMobDefinition &mob) |
| QcMobTraitsContent::Part<QcTameDefinition> | resolveTame(const QcContentRegistry &content, const QcMobDefinition &mob) |
Detailed Description
Classes
class Part
One trait of a creature checked against the content: what is left of it and the warnings. Trait is the type of the trait. More...
class Resolved
The traits of a creature checked against the content, and the warnings in the order of the traits. More...
Function Documentation
QStringList QcMobTraitsContent::checkStructurePets(const QcContentRegistry &content)
Returns warnings for the structure creatures in content with an owner (QcStructureDefinition::Mob::owner) of a kind that is not tameable: they are placed wild.
QcMobTraitsContent::Resolved QcMobTraitsContent::resolve(const QcContentRegistry &content, const QcMobDefinition &mob)
Returns the traits of the creature mob checked against content, with warnings.
Resolves the blocks a creature carries (QcCarryDefinition::blockIds): a name without a block, or a block without an item of its own (it could not drop when the creature dies), with a block entity (storage, machine, sapling, circuit part) or of two cells (door, bed) is left out with a warning; a creature left without any carries nothing. Also resolves the kind a tamed one becomes (QcTameDefinition::becomesType; a name that is no tameable creature is ignored with a warning) and warns of unknown taming, healing and dye items, and leaves out crumbling and drinking that name unknown blocks or items, and a family whose child is no creature, flies, lives in water or has a family of its own (decision E-839); unknown items among the family's pop drops are warned of.
QcMobTraitsContent::Part<QcTameDefinition> QcMobTraitsContent::resolveTame(const QcContentRegistry &content, const QcMobDefinition &mob)
Returns the taming part of resolve() for the creature mob in content (decision E-480).