From 84053a37cfde5e6bd94bf5fdd973db026e243be2 Mon Sep 17 00:00:00 2001 From: Bruce Mitchener Date: Fri, 5 Jul 2024 11:07:26 +0700 Subject: [PATCH] Fix more typos. --- docs/DesignWithFlecs.md | 2 +- flecs.c | 2 +- flecs.h | 12 ++++++------ include/flecs.h | 10 +++++----- include/flecs/addons/cpp/utils/signature.hpp | 2 +- src/addons/json/serialize_iter_result_query.c | 2 +- test/script/project.json | 4 ++-- test/script/src/Eval.c | 4 ++-- test/script/src/main.c | 12 ++++++------ 9 files changed, 25 insertions(+), 25 deletions(-) diff --git a/docs/DesignWithFlecs.md b/docs/DesignWithFlecs.md index 491d4db84..dd6af512f 100644 --- a/docs/DesignWithFlecs.md +++ b/docs/DesignWithFlecs.md @@ -144,7 +144,7 @@ An application can add phases to the existing list, or define a pipeline from sc Large applications can often contain many components and systems. Some large commercial projects have reported up to 800 components! Managing all those components and systems becomes important on that scale, and that is what modules are for. Modules are one of those features that you usually don't think about when selecting an ECS, but they can make your life a lot easier. ### Defining Modules -The purpose of modules is really to enable reusability. A well written module can be imported into any project, and will do its thing without any tweaking or tinkering. To achieve this, make sure to define your modules around features. Features seldomly consist out of a single system or component, but can have many. Examples are rendering, collision detection, input management, and so on. +The purpose of modules is really to enable reusability. A well written module can be imported into any project, and will do its thing without any tweaking or tinkering. To achieve this, make sure to define your modules around features. Features seldom consist out of a single system or component, but can have many. Examples are rendering, collision detection, input management, and so on. ### Module Dependencies and Ordering Modules can depend on each other. In fact, often do! Importing a module twice has no penalties in Flecs, it will not define your systems and components twice. This enables your application code to import the modules it needs, without having to worry about whether they were already loaded. diff --git a/flecs.c b/flecs.c index c34c3f463..38eb9c2f9 100644 --- a/flecs.c +++ b/flecs.c @@ -43533,7 +43533,7 @@ bool flecs_json_serialize_iter_result_sources( } if (f == field_count) { - /* All fields are mathced on $this */ + /* All fields are matched on $this */ return false; } diff --git a/flecs.h b/flecs.h index eda0bf555..8aaec8031 100644 --- a/flecs.h +++ b/flecs.h @@ -3403,8 +3403,8 @@ struct ecs_observer_t { ecs_run_action_t run; /**< See ecs_observer_desc_t::run */ void *ctx; /**< Observer context */ - void *callback_ctx; /**< Callback language binfding context */ - void *run_ctx; /**< Run language binfding context */ + void *callback_ctx; /**< Callback language binding context */ + void *run_ctx; /**< Run language binding context */ ecs_ctx_free_t ctx_free; /**< Callback to free ctx */ ecs_ctx_free_t callback_ctx_free; /**< Callback to free callback_ctx */ @@ -7246,7 +7246,7 @@ bool ecs_id_in_use( * EcsComponent value with size 0, the operation will return 0. * * For a pair id the operation will return the type associated with the pair, by - * applying the following querys in order: + * applying the following queries in order: * - The first pair element is returned if it is a component * - 0 is returned if the relationship entity has the Tag property * - The second pair element is returned if it is a component @@ -8071,8 +8071,8 @@ int32_t ecs_iter_count( /** Test if iterator is true. * This operation will return true if the iterator returns at least one result. - * This is especially useful in combination with fact-checking querys (see the - * querys addon). + * This is especially useful in combination with fact-checking queries (see the + * queries addon). * * The operation requires a valid iterator. After the operation is invoked, the * application should no longer invoke next on the iterator and should treat it @@ -28137,7 +28137,7 @@ namespace _ { ecs_assert( !ti->size || !ecs_has_id(world_, id, flecs::Union), ECS_INVALID_PARAMETER, - "use withs() method to add union relationship"); + "use with() method to add union relationship"); } } diff --git a/include/flecs.h b/include/flecs.h index cbd8bc030..20e7d670a 100644 --- a/include/flecs.h +++ b/include/flecs.h @@ -808,8 +808,8 @@ struct ecs_observer_t { ecs_run_action_t run; /**< See ecs_observer_desc_t::run */ void *ctx; /**< Observer context */ - void *callback_ctx; /**< Callback language binfding context */ - void *run_ctx; /**< Run language binfding context */ + void *callback_ctx; /**< Callback language binding context */ + void *run_ctx; /**< Run language binding context */ ecs_ctx_free_t ctx_free; /**< Callback to free ctx */ ecs_ctx_free_t callback_ctx_free; /**< Callback to free callback_ctx */ @@ -4074,7 +4074,7 @@ bool ecs_id_in_use( * EcsComponent value with size 0, the operation will return 0. * * For a pair id the operation will return the type associated with the pair, by - * applying the following querys in order: + * applying the following queries in order: * - The first pair element is returned if it is a component * - 0 is returned if the relationship entity has the Tag property * - The second pair element is returned if it is a component @@ -4899,8 +4899,8 @@ int32_t ecs_iter_count( /** Test if iterator is true. * This operation will return true if the iterator returns at least one result. - * This is especially useful in combination with fact-checking querys (see the - * querys addon). + * This is especially useful in combination with fact-checking queries (see the + * queries addon). * * The operation requires a valid iterator. After the operation is invoked, the * application should no longer invoke next on the iterator and should treat it diff --git a/include/flecs/addons/cpp/utils/signature.hpp b/include/flecs/addons/cpp/utils/signature.hpp index 3d043009c..c8e53d410 100644 --- a/include/flecs/addons/cpp/utils/signature.hpp +++ b/include/flecs/addons/cpp/utils/signature.hpp @@ -68,7 +68,7 @@ namespace _ { ecs_assert( !ti->size || !ecs_has_id(world_, id, flecs::Union), ECS_INVALID_PARAMETER, - "use withs() method to add union relationship"); + "use with() method to add union relationship"); } } diff --git a/src/addons/json/serialize_iter_result_query.c b/src/addons/json/serialize_iter_result_query.c index 4bbf9ee72..6484489a4 100644 --- a/src/addons/json/serialize_iter_result_query.c +++ b/src/addons/json/serialize_iter_result_query.c @@ -99,7 +99,7 @@ bool flecs_json_serialize_iter_result_sources( } if (f == field_count) { - /* All fields are mathced on $this */ + /* All fields are matched on $this */ return false; } diff --git a/test/script/project.json b/test/script/project.json index f0bda75cb..9c1e5029a 100644 --- a/test/script/project.json +++ b/test/script/project.json @@ -262,8 +262,8 @@ "auto_override_pair", "auto_override_pair_component", "lowercase_prefab_kind", - "assing_component_to_const", - "assing_component_member_to_const", + "assign_component_to_const", + "assign_component_member_to_const", "prefab_w_slot", "prefab_w_slot_no_parent", "prefab_w_slot_variant", diff --git a/test/script/src/Eval.c b/test/script/src/Eval.c index b71534fdd..b2e16983c 100644 --- a/test/script/src/Eval.c +++ b/test/script/src/Eval.c @@ -7606,7 +7606,7 @@ void Eval_lowercase_prefab_kind(void) { ecs_fini(world); } -void Eval_assing_component_to_const(void) { +void Eval_assign_component_to_const(void) { ecs_world_t *world = ecs_init(); ecs_entity_t ecs_id(Position) = ecs_struct_init(world, &(ecs_struct_desc_t){ @@ -7639,7 +7639,7 @@ void Eval_assing_component_to_const(void) { ecs_fini(world); } -void Eval_assing_component_member_to_const(void) { +void Eval_assign_component_member_to_const(void) { ecs_world_t *world = ecs_init(); ecs_entity_t ecs_id(Position) = ecs_struct(world, { diff --git a/test/script/src/main.c b/test/script/src/main.c index 3a9e6d9cc..9c6dc05fa 100644 --- a/test/script/src/main.c +++ b/test/script/src/main.c @@ -258,8 +258,8 @@ void Eval_auto_override_component(void); void Eval_auto_override_pair(void); void Eval_auto_override_pair_component(void); void Eval_lowercase_prefab_kind(void); -void Eval_assing_component_to_const(void); -void Eval_assing_component_member_to_const(void); +void Eval_assign_component_to_const(void); +void Eval_assign_component_member_to_const(void); void Eval_prefab_w_slot(void); void Eval_prefab_w_slot_no_parent(void); void Eval_prefab_w_slot_variant(void); @@ -1605,12 +1605,12 @@ bake_test_case Eval_testcases[] = { Eval_lowercase_prefab_kind }, { - "assing_component_to_const", - Eval_assing_component_to_const + "assign_component_to_const", + Eval_assign_component_to_const }, { - "assing_component_member_to_const", - Eval_assing_component_member_to_const + "assign_component_member_to_const", + Eval_assign_component_member_to_const }, { "prefab_w_slot",