Function is_stage

Synopsis

#include <include/flecs/addons/cpp/world.hpp>

bool is_stage() const

Description

Test if is a stage. If this function returns false, it is guaranteed that this is a valid world object.

Returns
True if the world is a stage, false if not.

Source

Lines 327-333 in include/flecs/addons/cpp/world.hpp.

bool is_stage() const {
    ecs_assert(
        ecs_poly_is(m_world, ecs_world_t) || 
        ecs_poly_is(m_world, ecs_stage_t),
            ECS_INVALID_PARAMETER, NULL);
    return ecs_poly_is(m_world, ecs_stage_t);
}