Function override

Summary

#include <include/flecs/addons/cpp/mixins/entity/builder.hpp>

(1) Self & override(flecs::id_t id)

(2) Self & override(flecs::entity_t first, flecs::entity_t second)

(3) template <typename T>
    Self & override()

(4) template <typename First>
    Self & override(flecs::entity_t second)

(5) template <typename First, typename Second>
    Self & override()

Function overload

Synopsis

#include <include/flecs/addons/cpp/mixins/entity/builder.hpp>

Self & override(flecs::id_t id)

Description

Mark id for auto-overriding. When an entity inherits from a base entity (using the IsA relationship) any ids marked for auto-overriding on the base will be overridden automatically by the entity.

Parameters

id - The id to mark for overriding.

Source

Lines 343-345 in include/flecs/addons/cpp/mixins/entity/builder.hpp.

Self& override(flecs::id_t id) {
    return this->add(ECS_OVERRIDE | id);
}

Synopsis

#include <include/flecs/addons/cpp/mixins/entity/builder.hpp>

Self & override(flecs::entity_t first, flecs::entity_t second)

Description

Mark pair for auto-overriding.

See
override(flecs::id_t id)
Parameters

first - The first element of the pair.

second - The second element of the pair.

Source

Lines 353-355 in include/flecs/addons/cpp/mixins/entity/builder.hpp.

Self& override(flecs::entity_t first, flecs::entity_t second) {
    return this->override(ecs_pair(first, second));
}

Synopsis

#include <include/flecs/addons/cpp/mixins/entity/builder.hpp>

template <typename T>
Self & override()

Description

Mark component for auto-overriding.

See
override(flecs::id_t id)
Template Parameters

T - The component to mark for overriding.

Source

Lines 362-365 in include/flecs/addons/cpp/mixins/entity/builder.hpp.

template <typename T>
Self& override() {
    return this->override(_::cpp_type<T>::id(this->m_world));
}

Synopsis

#include <include/flecs/addons/cpp/mixins/entity/builder.hpp>

template <typename First>
Self & override(flecs::entity_t second)

Description

Mark pair for auto-overriding.

See
override(flecs::id_t id)
Template Parameters

First - The first element of the pair.

Parameters

second - The second element of the pair.

Source

Lines 373-376 in include/flecs/addons/cpp/mixins/entity/builder.hpp.

template <typename First>
Self& override(flecs::entity_t second) {
    return this->override(_::cpp_type<First>::id(this->m_world), second);
}

Synopsis

#include <include/flecs/addons/cpp/mixins/entity/builder.hpp>

template <typename First, typename Second>
Self & override()

Description

Mark pair for auto-overriding.

See
override(flecs::id_t id)
Template Parameters

First - The first element of the pair.

Second - The second element of the pair.

Source

Lines 384-387 in include/flecs/addons/cpp/mixins/entity/builder.hpp.

template <typename First, typename Second>
Self& override() {
    return this->override<First>(_::cpp_type<Second>::id(this->m_world));
}